26.10.2011, 15:21
Heey all,
I made a standard ransom price for kidnappers.
But when someone connects its turning to 10000 for every player because i putted onplayerconnect but i dont know where to place it.
Code:
Can someone have fix pls?
Thanks admigo
I made a standard ransom price for kidnappers.
But when someone connects its turning to 10000 for every player because i putted onplayerconnect but i dont know where to place it.
Code:
Код:
//on top of script new KidnapPrice[MAX_PLAYERS][2]; //onplayerconnect KidnapPrice[playerid][1]=10000; //setprice command if(gTeam[playerid] == TEAM_KIDNAP) { if(sscanf(params, "dd", price4)) { SendClientMessage(playerid,COLOR_RED,"USAGE: /setprice (price)"); return 1; } if(price4 < 5000 || price4 >= 100000) { SendClientMessage(playerid,COLOR_RED,"You can only set the price between 5000 and 100000!"); return 1; } KidnapPrice[playerid][1] = price4; format(string,sizeof(string),"You have set the ransom price to $%d", price4); SendClientMessage(playerid,COLOR_LIGHTBLUE,string); return 1; }
Thanks admigo