little help delay teleport or /class
#2

I would make it something like this, try to modify it to your needs:
Код:
// top of the script 
new TeleportTime[MAX_PLAYERS];

// on gamemodeinit
SetTimer("OneSecTimer",1000,true);

// under onplayerconnect
TeleportTime[playerid] = -1;

// under your command
TeleportTime[playerid] = 10;

public OneSecTimer()
{
     foreach(Player, i)
     {
           if(TeleportTime[i] > 0 && TeleportTime[i] != -1)
           TeleportTime[i] --;
           else if(TeleportTime[i] == 0)
           // place here a stock or something for teleporting
      }
}
// and onplayertakedamage
if(TeleportTime[playerid] > 0) 
TeleportTime[playerid] = 0;
Reply


Messages In This Thread
little help delay teleport or /class - by enzo27 - 15.11.2013, 10:47
Re: little help delay teleport or /class - by dominik523 - 15.11.2013, 12:18
Re: little help delay teleport or /class - by enzo27 - 15.11.2013, 13:01
Re: little help delay teleport or /class - by dominik523 - 15.11.2013, 13:59

Forum Jump:


Users browsing this thread: 1 Guest(s)