Witam mam problem z bf2 v1.5.1a https://amxx.pl/topi...-mod-pl-v151a/
Jest bug ponieważ gdy się wejdzie na serwer i wpiszę się kila dostaje się odznakę z szturmówki jak się zrobi tak drugi raz dostaje się 2 odznakę z szturmówki i z grawitacji czy może ktoś pomóc w naprawie tego ? Z góry dziękuję za pomoc daje ++
wycinek z check.inl z bronią szturmową :
[spoiler]
//Assault badge section currentbadge=g_PlayerBadges[id][BADGE_ASSAULT]; wstats[0]=0; wstats[4]=0; wstats[5]=0; wroundstats[0]=0; get_user_stats(id,wstats,wbodyhits); new acc = floatround((float(wstats[5])/float(wstats[4]))*100); accuracy[id]=acc; switch (currentbadge) { case LEVEL_NONE: { if (roundkills[0]>3) { g_PlayerBadges[id][BADGE_ASSAULT]=LEVEL_START; //Poczatkujacy Assault Badge #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_ASSAULT][LEVEL_START]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_ASSAULT][LEVEL_START]); #endif badgegained=true; } } case LEVEL_START: { if (acc>24) { g_PlayerBadges[id][BADGE_ASSAULT]=LEVEL_BASIC; //Basic Assault Badge #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_ASSAULT][LEVEL_BASIC]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_ASSAULT][LEVEL_BASIC]); #endif badgegained=true; } } case LEVEL_BASIC: { if ((roundkills[0]>4) && (roundkills[2]>2) && (totalkills[id]>1999)) { g_PlayerBadges[id][BADGE_ASSAULT]=LEVEL_VETERAN; //Veteran Assault Badge #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_ASSAULT][LEVEL_VETERAN]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_ASSAULT][LEVEL_VETERAN]); #endif badgegained=true; } } case LEVEL_VETERAN: { if ((roundkills[0]>6) && (roundkills[2]>4) && (totalkills[id]>3999)) { g_PlayerBadges[id][BADGE_ASSAULT]=LEVEL_EXPERT; //Expert Assault Badge #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_ASSAULT][LEVEL_VETERAN]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_ASSAULT][LEVEL_VETERAN]); #endif badgegained=true; } } case LEVEL_EXPERT: { if ((roundkills[0]>4) && (roundkills[2]>1) && (totalkills[id]>4999)) { g_PlayerBadges[id][BADGE_ASSAULT]=LEVEL_PROFESIONAL; //Profesjonalista Assault Badge #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_ASSAULT][LEVEL_PROFESIONAL]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_ASSAULT][LEVEL_PROFESIONAL]); #endif badgegained=true; } } case LEVEL_PROFESIONAL: { if ((roundkills[0]>4) && (roundkills[2]>1) && (totalkills[id]>5999)) { g_PlayerBadges[id][BADGE_ASSAULT]=LEVEL_AGENT; //Profesjonalista Assault Badge #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_ASSAULT][LEVEL_AGENT]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_ASSAULT][LEVEL_AGENT]); #endif badgegained=true; } } } //End Assault section
[/spoiler]
Odznaka z grawitacją:
[spoiler]
//GRAVITY badge section currentbadge=g_PlayerBadges[id][BADGE_GRAVITY]; wstats[0]=0; wstats[4]=0; wstats[5]=0; wroundstats[0]=0; get_user_stats(id,wstats,wbodyhits); switch (currentbadge) { case LEVEL_NONE: { if (roundkills[0]>8) { g_PlayerBadges[id][BADGE_GRAVITY]=LEVEL_START; //Poczatkujacy GRAVITY Badge #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_GRAVITY][LEVEL_START]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_GRAVITY][LEVEL_START]); #endif badgegained=true; } } case LEVEL_START: { if ((roundkills[0]>1) && (roundkills[2]>1) && (totalkills[id]>999)) { g_PlayerBadges[id][BADGE_GRAVITY]=LEVEL_BASIC; //Basic GRAVITY Badge #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_GRAVITY][LEVEL_BASIC]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_GRAVITY][LEVEL_BASIC]); #endif badgegained=true; } } case LEVEL_BASIC: { if ((roundkills[0]>2) && (roundkills[2]>2) && (totalkills[id]>1999)) { g_PlayerBadges[id][BADGE_GRAVITY]=LEVEL_VETERAN; //Veteran GRAVITY Badge #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_GRAVITY][LEVEL_VETERAN]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_GRAVITY][LEVEL_VETERAN]); #endif badgegained=true; } } case LEVEL_VETERAN: { if ((roundkills[0]>3) && (roundkills[2]>3) && (totalkills[id]>2999)) { g_PlayerBadges[id][BADGE_GRAVITY]=LEVEL_EXPERT; //Expert GRAVITY Badge #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_GRAVITY][LEVEL_VETERAN]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_GRAVITY][LEVEL_VETERAN]); #endif badgegained=true; } } case LEVEL_EXPERT: { if ((roundkills[0]>4) && (roundkills[2]>4) && (totalkills[id]>3999)) { g_PlayerBadges[id][BADGE_GRAVITY]=LEVEL_PROFESIONAL; //Profesjonalista GRAVITY Badge #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_GRAVITY][LEVEL_PROFESIONAL]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_GRAVITY][LEVEL_PROFESIONAL]); #endif badgegained=true; } } case LEVEL_PROFESIONAL: { if ((roundkills[0]>6) && (roundkills[2]>6) && (totalkills[id]>5999)) { g_PlayerBadges[id][BADGE_GRAVITY]=LEVEL_AGENT; //Profesjonalista GRAVITY Badge #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_GRAVITY][LEVEL_AGENT]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_GRAVITY][LEVEL_AGENT]); #endif badgegained=true; } } } //End GRAVITY section //Start agent gadgets section currentbadge=g_PlayerBadges[id][BADGE_AGENT]; kills=totalkills[id]; switch (currentbadge) { case LEVEL_NONE: { if (kills>2499) { g_PlayerBadges[id][BADGE_AGENT]=LEVEL_START; #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_AGENT][LEVEL_START]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_AGENT][LEVEL_START]); #endif badgegained=true; } } case LEVEL_START: { if (kills>3999) { g_PlayerBadges[id][BADGE_AGENT]=LEVEL_BASIC; #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_AGENT][LEVEL_BASIC]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_AGENT][LEVEL_BASIC]); #endif badgegained=true; } } case LEVEL_BASIC: { if (kills>5499) { g_PlayerBadges[id][BADGE_AGENT]=LEVEL_VETERAN; #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_AGENT][LEVEL_VETERAN]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_AGENT][LEVEL_VETERAN]); #endif badgegained=true; } } case LEVEL_VETERAN: { if (kills>6999) { g_PlayerBadges[id][BADGE_AGENT]=LEVEL_EXPERT; #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_AGENT][LEVEL_EXPERT]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_AGENT][LEVEL_EXPERT]); #endif badgegained=true; } } case LEVEL_EXPERT: { if (kills>8499) { g_PlayerBadges[id][BADGE_AGENT]=LEVEL_PROFESIONAL; #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_AGENT][LEVEL_PROFESIONAL]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_AGENT][LEVEL_PROFESIONAL]); #endif badgegained=true; } } case LEVEL_PROFESIONAL: { if (kills>9499) { g_PlayerBadges[id][BADGE_AGENT]=LEVEL_AGENT; #if defined KOLOROWY_SAY ColorChat(id,TEAM_COLOR,"[BF2]^x03 Zdobyles odznake:^x04 %s",gBadgeName[BADGE_AGENT][LEVEL_AGENT]); #else client_print(id,print_chat,"[BF2] Zdobyles odznake: %s",gBadgeName[BADGE_AGENT][LEVEL_AGENT]); #endif badgegained=true; } } } //End agent gadgets section
[/spoiler]