01.01.2010, 11:55
Forwarder:
Add this in the last line of your script:
Then Add this to all Teleports Commands
EXAMPLE:
Add all this line on all Teles CMDS:
Code:
forward DynUpdateStart(playerid); // freezes a player for some seconds forward DynUpdateEnd(playerid); // unfreeze function
Code:
public DynUpdateStart(playerid) { TogglePlayerControllable(playerid, false); // Freeze new string[255]; format(string, sizeof(string), "~g~Objects~n~~r~Loading"); GameTextForPlayer(playerid, string, 3000, 6); PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0); SetTimerEx("DynUpdateEnd", 2000, 0,"e",playerid); return 1; } public DynUpdateEnd(playerid) { TogglePlayerControllable(playerid, true); // Unfreeze new string[255]; format(string, sizeof(string), "~g~Objects~n~~r~Loaded!"); GameTextForPlayer(playerid, string, 3000, 6); PlayerPlaySound(playerid, 1056, 0.0, 0.0, 0.0); return 1; }
EXAMPLE:
Code:
if (strcmp("/example", cmdtext, true, 10) == 0) { SetPlayerPos(playerid,-239.1891,1203.2264,19.5938); SetVehiclePos(playerid,-239.1891,1203.2264,19.5938); SendClientMessage(playerid, 0xAAAAAAAA, "EXAMPLE TELE"); DynUpdateStart(playerid); return 1; }
Code:
DynUpdateStart(playerid);