08.02.2014, 15:46
(
Последний раз редактировалось WaZP; 08.02.2014 в 19:24.
)
Helo SA-MP.COM,
Recently, I found a bug in my house system, when i write /exit to exit out of house, teleport me at house with id 0, but my house id is 30..
This is Command /exit
When i change " for(new i = 0; i < sizeof(HouseInfo); i++) " with " for(new i = 20; i < sizeof(HouseInfo); i++) ", teleport me at House with id 20
Recently, I found a bug in my house system, when i write /exit to exit out of house, teleport me at house with id 0, but my house id is 30..
This is Command /exit
Код:
if(strcmp(cmd, "/exit", true) == 0) { if(IsPlayerConnected(playerid)) { for(new i = 0; i < sizeof(HouseInfo); i++) { if (PlayerToPoint(3, playerid,HouseInfo[i][hIesireX], HouseInfo[i][hIesireY], HouseInfo[i][hIesireZ])) { SetPlayerInterior(playerid,0); SetPlayerPos(playerid,HouseInfo[i][hIntrareX],HouseInfo[i][hIntrareY],HouseInfo[i][hIntrareZ]); PlayerInfo[playerid][pInt] = 0; PlayerInfo[playerid][pLocal] = 255; SetPlayerVirtualWorld(playerid,0); if(HouseInfo[i][hHealUpgrade] == 1) { new Float:tempheal; GetPlayerHealth(playerid,tempheal); if(tempheal < 100.0) { SetPlayerHealth(playerid,100.0); } } return 1; } }