in / dm remain how to ?
#1

my english:

i dont know ?
i must have it in /dm when i was killing that im again in dm my dm is when im kill i must new conect /dm

i will a cmd that i will leave dm /exit

******:

I do not know what to do
I have my script dm so I enter again and again / dm has
how do I do it if I am killed I will stay in the / dm?

and if I want to leave dm / exit
Reply
#2

Googling for sa-mp script, what's next.

Use PVars for the player. Set them to 1 or something when he joins the DM, and check at OnPlayerSpawn if the PVar is 1 and if so, put him back in the DM.
Reply
#3

pawn Код:
if(!strcmp(cmdtext,"/dm", true))
{
    // stuff here ..
    SetPVarInt(playerid, "IsDM", 1);
}

if(!strcmp(cmdtext,"/exit", true))
{
    // stuff here ..
    SetPVarInt(playerid, "IsDM", 0);
}

public OnPlayerSpawn(playerid)
{
    if(GetPVarInt(playerid, "IsDM") == 1)
    {
      // Warp him back to the DM zone
      SetPlayerPos(playerid, x_to_dm, y_to_dm, z_to_dm);
    }
}
Reply
#4

EDIT: Above answer was faster and will work good enough for you
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)