26.03.2016, 21:50
Nгo estou usando settime, e eu percebi que onplayerspawn estб setando duas veses
olha meu onplayerspawn completo
olha meu onplayerspawn completo
pawn Код:
public OnPlayerSpawn(playerid)
{
TogglePlayerSpectating(playerid, false);
SkinsJogadores(playerid);
Cores_jogadores(playerid);
if(INFO_P[playerid][LOCAL_NASCIMENTO_P] == 0 && INFO_P[playerid][JOGADOR_PRESO_P] == 0) // SPAWN CIVIL
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 1338.7610, -1820.8293, 13.5572);
SetPlayerFacingAngle(playerid, 267.9267);
}
else if(INFO_P[playerid][LOCAL_NASCIMENTO_P] == 1 && INFO_P[playerid][JOGADOR_PRESO_P] == 0) // ULTIMO LOCAL
{
SetPlayerInterior(playerid, INFO_P[playerid][ULTIMO_INTERIOR_P]);
SetSpawnInfo(playerid, 1, SkinsJogadores(playerid), INFO_P[playerid][ULTIMA_POSX_P], INFO_P[playerid][ULTIMA_POSY_P], INFO_P[playerid][ULTIMA_POSZ_P], INFO_P[playerid][ULTIMO_ANGULO_P], 0, 0, 0, 0, 0, 0);
}
else if(INFO_P[playerid][LOCAL_NASCIMENTO_P] == 2 && INFO_P[playerid][JOGADOR_PRESO_P] == 0) // HQ - PROFISSOES
{
if(INFO_P[playerid][PROFISSAO_P] == 1) //pizzaboy
{
SetPlayerInterior(playerid, 5);
SetPlayerPos(playerid, 368.7952, -115.1770, 1001.4922);
SetPlayerFacingAngle(playerid, 180.4866);
SkinsJogadores(playerid);
Cores_jogadores(playerid);
}
else if(INFO_P[playerid][PROFISSAO_P] == 2) //cet
{
SetPlayerInterior(playerid, 0);
SetPlayerPos(playerid, 2773.2039, -1625.8854, 10.9272);
SetPlayerFacingAngle(playerid, 355.7406);
SkinsJogadores(playerid);
Cores_jogadores(playerid);
}
}
else if(INFO_P[playerid][LOCAL_NASCIMENTO_P] == 3 && INFO_P[playerid][JOGADOR_PRESO_P] == 0) // CASAS
{
}
if(JogadorQMorreu[playerid] == true && INFO_P[playerid][JOGADOR_PRESO_P] == 0) // Hospital pуs morte
{
if(INFO_P[playerid][PLANO_DE_SAUDE_P] == 0)
{
SetPlayerInterior(playerid, 0);
new randmaca = random(sizeof(MacaAposMorrer));
SetPlayerPos(playerid, MacaAposMorrer[randmaca][0], MacaAposMorrer[randmaca][1], MacaAposMorrer[randmaca][2]);
SetPlayerFacingAngle(playerid, MacaAposMorrer[randmaca][3]);
SendClientMessage(playerid, 0x95FF00FF, "[HOSPITAL]: "Branco"Vocк se acidentou e como nгo tem um plano de saъde, ficarб 30 segundos na maca atй se recuperar.");
TextDrawShowForPlayer(playerid, Texto_Tempo_Hospital[playerid]);
Jogador_Serecuperando[playerid] = true;
Minutos_TempoHospital[playerid] = 0;
Segundos_TempoHospital[playerid] = 30;
ClearAnimations(playerid);
ApplyAnimation(playerid, "CRACK", "crckdeth2", 4.0, 1, 0, 0, 0, 0);
Salvar_Contas(playerid);
return true;
}
if(INFO_P[playerid][PLANO_DE_SAUDE_P] == 1)
{
new randrecuperar = random(sizeof(MacaAposSeRecuperar));
SetPlayerPos(playerid, MacaAposSeRecuperar[randrecuperar][0], MacaAposSeRecuperar[randrecuperar][1], MacaAposSeRecuperar[randrecuperar][2]);
SetPlayerFacingAngle(playerid, MacaAposSeRecuperar[randrecuperar][3]);
SendClientMessage(playerid, 0x95FF00FF, "[HOSPITAL]: "Branco"Vocк se acidentou e o seu plano de saъde arcou com todas as despesas.");
}
}
if(INFO_P[playerid][JOGADOR_PRESO_P] == 1)
{
TextDrawShowForPlayer(playerid, TempoCadeiaT[playerid]);
if(INFO_P[playerid][LOCAL_PRESO_P] == 1)
{
SetPlayerInterior(playerid, 1);
SetPlayerPos(playerid, 2146.8123, 1611.1268, 1000.9688);
SetPlayerFacingAngle(playerid, 11.2993);
}
}
return true;
}