Quote:
Originally Posted by Mr.GeEk
en DestruirRampa tienes el gRampaGrande[playerid] = false; ?
pawn Код:
if (PRESSED(KEY_ACTION)) gRampaGrande[playerid] = false; else if (PRESSED(KEY_SECONDARY_ATTACK)) gRampaGrande[playerid] = true;
if (!gRampaGrande[playerid]) { gIDRampa[playerid] = CreateDynamicObject(ID_RAMPA, ......); gEnRampa[playerid] = true; gRampaGrande[playerid] = true;//activada gTimerDestRampa[playerid] = SetTimerEx("DestruirRampa", TIEMPO_EN_DEST_RAMPA, false, "d", playerid); }else { gIDRampa[playerid] = CreateDynamicObject(ID_RAMPA_GRANDE, .....); gEnRampa[playerid] = true; gRampaGrande[playerid] = false;//desactivada gTimerDestRampa[playerid] = SetTimerEx("DestruirRampa", TIEMPO_EN_DEST_RAMPA, false, "d", playerid); }
|
Si
Код:
public DestruirRampa(playerid)
{
if (gRampaActivada[playerid] && gEnRampa[playerid] == true)
{
DestroyDynamicObject(gIDRampa[playerid]);
KillTimer(gTimerDestRampa[playerid]);
gRampaGrande[playerid] = false;
}
return 1;
}