Help OnPlayerDeath
#3

new string[600] ;
No. Never. Ever.

pawn Код:
//TOP OF SCRIPT
new bool: IsPlayerInDM[MAX_PLAYERS]; // 0 = false, 1 = true.

CMD:dmpirate(playerid, params[]) // If CMD Doesn't work replace with COMMAND
{
     new string[128], pname[MAX_PLAYER_NAME]; // The larger the string, the larger the file, in result the more lag.
     GetPlayerName(playerid, pname, sizeof(pname));
     if(IsPlayerInDM[playerid] == true) return SendClientMessage(playerid, COLOR_ORANGE, "Tu es deja dans le dm Pirate, fait /dmpirateq pour le quitter");
     IsPlayerInDM[playerid] = true;
     format(string, sizeof(string), "%s A rejoint le /dmpirate, rejoignez le !", pname);
     SendClientMessageToAll(COLOR_ORANGE, string);
     SendClientMessage(playerid, COLOR_ORANGE, "Tu as rejoint le dm pirate");
     SetPlayerPos(playerid, -2050.0810547,-7609.0312500,2.2020721);
     ResetPlayerWeapons(playerid);
     GivePlayerWeapon(playerid, 26, 900);
     GivePlayerWeapon(playerid, 24, 900);
     SetPlayerFacingAngle(playerid, 0);
     return 1;
}


PF: OnPlayerSpawn(playerid)
{
    if(IsPlayerInDM[playerid] == true)
    {
        SetPlayerPos(playerid, -2050.0810547,-7609.0312500,2.2020721);
        GivePlayerWeapon(playerid, 26, 900);
        GivePlayerWeapon(playerid, 24, 900);
        SetPlayerFacingAngle(playerid, 0);
    }
    else {
        // Place Current spawn info here. Outside of DM
    }
    return true;
}
Reply


Messages In This Thread
Help OnPlayerDeath - by EclipseWho - 22.06.2016, 20:09
Re: Help OnPlayerDeath - by Dayrion - 22.06.2016, 20:23
Re: Help OnPlayerDeath - by Lynn - 22.06.2016, 21:12
Re: Help OnPlayerDeath - by Dayrion - 22.06.2016, 21:24
Re: Help OnPlayerDeath - by Lynn - 22.06.2016, 21:26
Re: Help OnPlayerDeath - by Dayrion - 22.06.2016, 21:27
Re: Help OnPlayerDeath - by Lynn - 22.06.2016, 21:33
Re: Help OnPlayerDeath - by Vince - 22.06.2016, 21:43
Re: Help OnPlayerDeath - by Stinged - 22.06.2016, 21:44
Re: Help OnPlayerDeath - by EclipseWho - 23.06.2016, 22:24

Forum Jump:


Users browsing this thread: 1 Guest(s)