01.09.2011, 08:18
Hello.
I have an error in my code: when I spawn, I have a message: "Stay Within The world boundries" and a white screen, basically a big bug.
Here is my code to connect:
The pre-spawn:
And OnPlayerSpawn:
The positions are correct, I checked and I even do a AddPlayerClass with the same positions in the GM init.
Thank you!
I have an error in my code: when I spawn, I have a message: "Stay Within The world boundries" and a white screen, basically a big bug.
Here is my code to connect:
Код:
SendClientMessage(playerid, SUCCESS, "The password is correctly !"); //pLoadData(playerid); pData[playerid][isLogged] = 1; new date[126], annee, mois, jour, heure, minute, seconde, pIp[126]; getdate(annee, mois, jour); gettime(heure, minute, seconde); format(date, 126, "the %s/%s/%s - %s:%s:%s", jour, mois, annee, heure, minute, seconde); GetPlayerIp(playerid, pIp, 126); format(query, 400, "UPDATE `members` SET last_connection_date = '%s', last_connection_ip = '%s' WHERE pseudo = '%s'", date, pIp, playerName); mysql_query(query);
Код:
public OnPlayerRequestSpawn(playerid) { if(pData[playerid][isLogged] == 1) { return 1; } else { SendClientMessage(playerid, ERROR, " "); SendClientMessage(playerid, ERROR, "Vous devez кtre inscrit et connectй pour pouvoir Spawn !"); SendClientMessage(playerid, ERROR, " "); return 0; } }
Код:
SetPlayerPos(playerid, -1333.1995,483.5709,12.1750); SetPlayerFacingAngle(playerid, 179.9017); SetPlayerInterior(playerid,0); TogglePlayerClock(playerid,1); ResetPlayerMoney(playerid); GivePlayerMoney(playerid, pData[playerid][argent]); SetPlayerScore(playerid, pData[playerid][score]); SetPlayerSkin(playerid, pData[playerid][skin]); switch(pData[playerid][TTteam]) { case 1 : SetPlayerColor(playerid, GREEN); case 2 : SetPlayerColor(playerid, YELLOW); case 3 : SetPlayerColor(playerid, BLUE); } if(pData[playerid][isSpec] == 1) { pData[playerid][isSpec] = 0; SetPlayerPos(playerid, pData[playerid][sX], pData[playerid][sY], pData[playerid][sZ]); }
Thank you!