SA-MP Forums Archive
[Ajuda]Problema ou morrer! - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda]Problema ou morrer! (/showthread.php?tid=330271)



[RESOLVIDO]Problema ou morrer! - CJoao - 31.03.2012

Quando morro aparece o ecran todo preto com uma tela dizendo Loading o jogo trava todo..

pawn Код:
public OnPlayerDeath(playerid, killerid, reason)
{
    new Float:x,Float:y,Float:z;
    GetPlayerPos(playerid,x,y,z);
    PlayerInfo[playerid][pLoadPosX] = x;
    PlayerInfo[playerid][pLoadPosY] = y;
    PlayerInfo[playerid][pLoadPosZ] = z;
    PlayerInfo[playerid][pLoadPosInt] = GetPlayerInterior(playerid);
    PlayerInfo[playerid][pLoadPosW] = GetPlayerVirtualWorld(playerid);
    PlayerInfo[playerid][pHospital] = 1; // <-------------
    SafeResetPlayerWeapons(playerid);
    ResetPlayerWantedLevelEx(playerid);
    WantedPoints[playerid] = 0;
    InShamal[playerid] = 0;
    InAndrom[playerid] = 0;
    CopOnDuty[playerid] = 0;
    if(AdminDuty[playerid] == 1)
    {
        PlayerInfo[playerid][pHospital] = 0;
    }
    if(Planted[playerid] == 1)
    {
        DestroyObject(C4[playerid]);
        Bomb[playerid] = 0;
        Planted[playerid] = 0;
    }
    return 1;
}
pawn Код:
if(PlayerInfo[playerid][pHospital] > 1)
        {
            SetPlayerPos(playerid,PlayerInfo[playerid][pLoadPosX],PlayerInfo[playerid][pLoadPosY],PlayerInfo[playerid][pLoadPosZ]);
            SetPlayerInterior(playerid,PlayerInfo[playerid][pLoadPosInt]);
            SetPlayerVirtualWorld(playerid,PlayerInfo[playerid][pLoadPosW]);
            return 1;
        }
Nгo tou percebendo porque fica aparecendo a tela preta, alguem que me ajude!
o gamemod nao apresenta erros nada...


Re: [Ajuda]Problema ou morrer! - DouglasRodrigues - 31.03.2012

Ctrl + F
Veja se tem alguma AddPlayerClass no GM.


Re: [Ajuda]Problema ou morrer! - CJoao - 01.04.2012

Quote:
Originally Posted by Douglas_FusioN
Посмотреть сообщение
Ctrl + F
Veja se tem alguma AddPlayerClass no GM.
Nгo tenho nenhuma AddPlayerClass


Re: [Ajuda]Problema ou morrer! - IgorMendes - 01.04.2012

Coloque isso no topo de sua OnGameModeInit
pawn Код:
AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);



Re: [Ajuda]Problema ou morrer! - CJoao - 01.04.2012

Quote:
Originally Posted by IgorMendes
Посмотреть сообщение
Coloque isso no topo de sua OnGameModeInit
pawn Код:
AddPlayerClass(0, 1958.3783, 1343.1572, 15.3746, 269.1425, 0, 0, 0, 0, 0, 0);
Eu coloquei

pawn Код:
AddPlayerClass(0, 0.0, 0.0, 0.0, 0.0, 0, 0, 0, 0, 0, 0);
E agora ta dando tudo certo! Vou fazer uns teste para ver se ta funcionado mesmo

Obrigado pela ajuda +Rep


Re: [Ajuda]Problema ou morrer! - CJoao - 01.04.2012

Jб fiz os testes ta tudo certo Obrigado pela ajuda!