Teleport por Checkpoint
#2

pawn Код:
new EntroAlCheck[MAX_PLAYERS];

// Crear Checkpoint:

SetPlayerCheckpoint(playerid, 5.0, X, Y, Z); // 5.0 es el radio, es decir, el radio del circulo como quieres que sea grande o chico.
EntroAlCheck[playerid] = 1; // Seteamos la variable en 1 para luego efectuar el Checkpoint.

// Entrar al Checkpoint:

public OnPlayerEnterCheckpoint(playerid)
{
    if(EntroAlCheck[playerid] == 1) // Chequeamos si la variable estб en 1 entonces se efectъa el callback.
    {
    DisablePlayerCheckpoint(playerid); // Limpiamos el Checkpoint.
    EntroAlCheck[playerid] = 0; // Reseteamos la variable a 0.
    SetPlayerPos(playerid, X, Y, Z); // Teleport hacia donde quieras.
    }
    return 1;
}
Reply


Messages In This Thread
Teleport por Checkpoint - by CeKiT - 08.08.2012, 18:25
Respuesta: Teleport por Checkpoint - by TiNcH010 - 08.08.2012, 18:35
Respuesta: Teleport por Checkpoint - by santi.arg - 08.08.2012, 19:24
Respuesta: Teleport por Checkpoint - by CeKiT - 08.08.2012, 19:44
Respuesta: Teleport por Checkpoint - by TiNcH010 - 09.08.2012, 14:09
Respuesta: Teleport por Checkpoint - by santi.arg - 11.08.2012, 07:12

Forum Jump:


Users browsing this thread: 1 Guest(s)