03.12.2012, 20:49
Hello, i'm trying to set money at first spawn with something like this:
But when i log in the money loads to 400 and when i try to buy smting it says that i do not have money (if i check /stats it says i do not have any money, with if i look at money Textdraw it says i've 400$), any suggestions?
pawn Код:
public OnPlayerConnect(playerid)
{
SetPVarInt(playerid, "FirstSpawn", 1); //The player is going to spawn for the first time
return 1;
}
public OnPlayerSpawn(playerid)
{
if(GetPVarInt(playerid, "FirstSpawn")) //If its the first time the player has spawned
{
GivePlayerMoney(playerid, 400);
SetPVarInt(playerid, "FirstSpawn", 0);
}
return 1;
}