28.05.2009, 14:58
Hi all,
I just wonder if its possible that people can't leave a deathmatch area till they die.
or/and
That people cant use commands anymore, but only the /back command to go back to las venturas.
code for going to a dm :
Code for go to /back
I just wonder if its possible that people can't leave a deathmatch area till they die.
or/and
That people cant use commands anymore, but only the /back command to go back to las venturas.
code for going to a dm :
Код:
case 0:
{
new rand = random(sizeof(DMSniperSpawns));
new Playername[30], str[256];
GetPlayerName(playerid, Playername, 30);
GetPlayerPos(playerid, PosX[playerid], PosY[playerid], PosZ[playerid]);
GetPlayerFacingAngle(playerid, PosA[playerid]);
PosI[playerid] = (GetPlayerInterior(playerid));
format(str, 256, "*** %s has teleported to deathmatch 1 (Sniper).", Playername);
SendClientMessageToAll(COLOR_RED, str);
SetPlayerPos(playerid, DMSniperSpawns[rand][0], DMSniperSpawns[rand][1], DMSniperSpawns[rand][2]); // Warp the player
GetPlayerName(playerid, var0, 25);
SetPlayerFacingAngle(playerid, 270.0);
ResetPlayerWeapons(playerid);
GivePlayerWeapon(playerid, 34, 25);
SetPlayerHealth(playerid, 0.0);
SetPlayerHealth(playerid, 100.0);
SetPlayerInterior(playerid, 0);
SetPlayerColor(playerid,COLOR_BLANK);
TogglePlayerControllable(playerid,1);
Код:
if(strcmp(cmdtext, "/back", true) == 0)
{
SetPlayerPos(playerid, PosX[playerid], PosY[playerid], PosZ[playerid]);
SetPlayerFacingAngle(playerid, PosA[playerid]);
SetCameraBehindPlayer(playerid);
SetPlayerInterior(playerid, PosI[playerid]);
return 1;
}


