12.12.2012, 21:25
Retirei aki caso Reiniciar eu aviso.
Bem aki tudo do gm onde se encontra a gLastCar:
Sгo esses ai..
Quote:
O mбximo que consigo te ajudar й dizer a Variбvel que estб causando isso, que й a Var gLastCar, O valor dela estб maior que as cйlulas de algumas Vars, causando o Crash..
|
pawn Код:
new gLastCar[301];
//OnPlayerConnect
gLastCar[playerid] = 0;
//OnPlayerDisconnect
if (gLastCar[playerid] > 0)
{
gLastDriver[gLastCar[playerid]] = 300;
if(PlayerInfo[playerid][pPHousekey] != gLastCar[playerid]-1)
{
VTrancado[gLastCar[playerid]] = 0;
UnLockCar(gLastCar[playerid]);
}
}
//OnPlayerStateChange
new oldcar = gLastCar[playerid];
gLastCar[playerid] = newcar;
//CMD /trancar
if(gLastCar[playerid] == 0 && PlayerInfo[playerid][pPHousekey] == 255)
{
SendClientMessage(playerid, COLOR_GRAD2, "Vocк nгo tem um carro de casa/alugado.");
return true;
}
else if(gLastCar[playerid] != 0 && gLastCar[playerid] != PlayerInfo[playerid][pPHousekey]+totalveiculos)
{
if (HireCar[playerid] != gLastCar[playerid] && HireCar[playerid] > 0)
{
gLastDriver[HireCar[playerid]] = 300;
VTrancado[HireCar[playerid]] = 0;
UnLockCar(HireCar[playerid]);
}
HireCar[playerid] = gLastCar[playerid];
}
//CMD /carroantigo
format(string, sizeof(string), "ID do ъltimo carro: %d",gLastCar[playerid]);