CMD:minigundm(playerid, params[]) { new Random = random(sizeof(RandomSpawns)); SetPlayerHealth(playerid, 100); SetPlayerArmour(playerid, 100); SetPlayerPos(playerid, RandomSpawns[Random][0], RandomSpawns[Random][1], RandomSpawns[Random][2]); SetPlayerFacingAngle(playerid, RandomSpawns[Random][3]); GivePlayerWeapon(playerid,38 ,10000); return 1; } |
new bool:inMinigun[MAX_PLAYERS char];
//In this CMD:minigundm
inMinigun{playerid} = true;
//In the other commands:
if(inMinigun{playerid}) return SCM(playerid,-1,"You are in a Minigun DM! Make /leave to leave it!");
//In the leave command:
if(!inMinigun{playerid}) return SCM(playerid,-1,"You aren't in a Minigun Event!");
inMinigun{playerid} = false;
#define SCM SendClientMessage
Erm? Can you give me the /leave cmd codes according to my script? zcmd
|
CMD:leave(playerid)
{
//In the leave command:
if(!inMinigun{playerid}) return SCM(playerid,-1,"You aren't in a Minigun Event!");
inMinigun{playerid} = false;
return 1;
}
new bool:inMinigun[MAX_PLAYERS char]; new Float:RandomSpawns[][] = { {3218.5200,-5201.4214,19.9078,262.0082}, {3227.8022,-5166.6245,24.2328,96.1082}, // Randomspawn {3175.1887,-5153.1538,19.9078,98.8068}, // Randomspawn {3120.7822,-5154.1133,20.0940,273.9126}, {3096.3271,-5249.3701,19.9078,271.0925}, {3182.8801,-5266.5200,19.9078,199.3386}, {3170.6882,-5214.8340,21.7125,94.0811}, {3196.1052,-5163.3623,19.9078,265.6208}, {3227.5005,-5140.2788,27.3782,270.0076}, {3111.1736,-5198.4761,22.2381,183.0685}, {3114.3625,-5227.9263,20.0844,240.3857}, {3130.5708,-5266.6069,23.7437,359.0188}, {3228.0046,-5244.7256,24.2328,99.6953} }; CMD:minigundm(playerid, params[]) { inMinigun{playerid} = true; new Random = random(sizeof(RandomSpawns)); SetPlayerHealth(playerid, 100); SetPlayerArmour(playerid, 100); SetPlayerPos(playerid, RandomSpawns[Random][0], RandomSpawns[Random][1], RandomSpawns[Random][2]); SetPlayerFacingAngle(playerid, RandomSpawns[Random][3]); GivePlayerWeapon(playerid,38 ,10000); return 1; } CMD:leave(playerid) { //In the leave command: if(!inMinigun{playerid}) return SendClientMessage(playerid,-1,"You aren't in a Minigun Event!"); inMinigun{playerid} = false; return 1; } CMD:kart1(playerid, params[]) { SetPlayerPos(playerid , -1187.89453125,-1032.46899414,128.55102539); ResetPlayerWeapons(playerid); SetPlayerHealth(playerid , 100000); SendClientMessage(playerid ,0x00FF00FF , " Welcome to Kart FreeRoam"); SetPlayerArmour(playerid , 0); if(inMinigun{playerid}) return SendClientMessage(playerid,-1,"You are in a Minigun DM! Type /leave to leave it!"); return 1; } CMD:dm(playerid, params[]) { SetPlayerPos(playerid , -1386.0922, 3986.8069, 98.6692); SendClientMessage(playerid, 0x00FF00FF, "Welcome TO Deagle and Shotgun DM ."); SetPlayerHealth(playerid, 100); ResetPlayerWeapons(playerid); GivePlayerWeapon(playerid, 25, 100000); GivePlayerWeapon(playerid, 24, 100000); SetPlayerArmour(playerid, 100); if(inMinigun{playerid}) return SendClientMessage(playerid,-1,"You are in a Minigun DM! Make /leave to leave it!"); return 1; } CMD:kill(playerid,params[]) { SetPlayerHealth(playerid, 0); if(inMinigun{playerid}) return SendClientMessage(playerid,-1,"You are in a Minigun DM! Make /leave to leave it!"); return 1; } |
CMD:minigundm(playerid, params[])
{
if(inMinigun{playerid}) return SendClientMessage(playerid,-1,"You are already in a Minigun DM!");
inMinigun{playerid} = true;
new Random = random(sizeof(RandomSpawns));
SetPlayerHealth(playerid, 100);
SetPlayerArmour(playerid, 100);
SetPlayerPos(playerid, RandomSpawns[Random][0], RandomSpawns[Random][1], RandomSpawns[Random][2]);
SetPlayerFacingAngle(playerid, RandomSpawns[Random][3]);
GivePlayerWeapon(playerid,38 ,10000);
return 1;
}
CMD:leave(playerid)
{
//In the leave command:
if(!inMinigun{playerid}) return SendClientMessage(playerid,-1,"You aren't in a Minigun Event!");
inMinigun{playerid} = false;
return 1;
}
CMD:kart1(playerid, params[])
{
if(inMinigun{playerid}) return SendClientMessage(playerid,-1,"You are in a Minigun DM! Type /leave to leave it!");
SetPlayerPos(playerid , -1187.89453125,-1032.46899414,128.55102539);
ResetPlayerWeapons(playerid);
SetPlayerHealth(playerid , 100000);
SendClientMessage(playerid ,0x00FF00FF , " Welcome to Kart FreeRoam");
SetPlayerArmour(playerid , 0);
return 1;
}
CMD:dm(playerid, params[])
{
if(inMinigun{playerid}) return SendClientMessage(playerid,-1,"You are in a Minigun DM! Type /leave to leave it!");
SetPlayerPos(playerid , -1386.0922, 3986.8069, 98.6692);
SendClientMessage(playerid, 0x00FF00FF, "Welcome TO Deagle and Shotgun DM .");
SetPlayerHealth(playerid, 100);
ResetPlayerWeapons(playerid);
GivePlayerWeapon(playerid, 25, 100000);
GivePlayerWeapon(playerid, 24, 100000);
SetPlayerArmour(playerid, 100);
return 1;
}
CMD:kill(playerid,params[])
{
if(inMinigun{playerid}) return SendClientMessage(playerid,-1,"You are in a Minigun DM! Type /leave to leave it!");
SetPlayerHealth(playerid, 0);
return 1;
}
CMD:minigundm(playerid, params[]) { if(inMinigun{playerid}) return SendClientMessage(playerid,-1,"You are already in a Minigun DM!"); new Random = random(sizeof(RandomSpawns)); SetPlayerHealth(playerid, 100); SetPlayerArmour(playerid, 100); SetPlayerPos(playerid, RandomSpawns[Random][0], RandomSpawns[Random][1], RandomSpawns[Random][2]); SetPlayerFacingAngle(playerid, RandomSpawns[Random][3]); GivePlayerWeapon(playerid,38 ,10000); return 1; } CMD:leave(playerid) { //In the leave command: if(!inMinigun{playerid}) return SendClientMessage(playerid,-1,"You aren't in a Minigun Event!"); inMinigun{playerid} = false; return 1; } CMD:weapons(playerid,params[]) { ShowPlayerDialog(playerid, DIALOG_WEAPONS, DIALOG_STYLE_LIST, "Weapons", "Desert Eagle - 150 Ammo [ Cost - $500 ]\nChainSaw - 1 [ Cost - $500 ]\nSilenced 9mm - 150 Ammo [ Cost - $500]\nShotGun - 150 Ammo [ Cost - $700]\nSawnoff Shotgun - 200 Ammo [ Cost - $1k ]\nCombactShotgun - 200 Ammo [ Cost $1k ]\nMicro Guns - SMG[ Cost - $800 ]\nMicro Guns - UZI [ Cost - $800 ]\nM4 - [ Cost - $1500 ]\nAK47 [ Cost - $1500 ]\nCountyRifle [ Cost - $2000 ]\nSniperRifle [ Cost - $2000]", "Select", "Close"); return 1; } CMD:kart1(playerid, params[]) { if(inMinigun{playerid}) return SendClientMessage(playerid,-1,"You are in a Minigun DM! Type /leave to leave it!"); SetPlayerPos(playerid , -1187.89453125,-1032.46899414,128.55102539); ResetPlayerWeapons(playerid); SetPlayerHealth(playerid , 100000); SendClientMessage(playerid ,0x00FF00FF , " Welcome to Kart FreeRoam"); SetPlayerArmour(playerid , 0); return 1; } CMD:dm(playerid, params[]) { if(inMinigun{playerid}) return SendClientMessage(playerid,-1,"You are in a Minigun DM! Type /leave to leave it!"); SetPlayerPos(playerid , -1386.0922, 3986.8069, 98.6692); SendClientMessage(playerid, 0x00FF00FF, "Welcome TO Deagle and Shotgun DM ."); SetPlayerHealth(playerid, 100); ResetPlayerWeapons(playerid); GivePlayerWeapon(playerid, 25, 100000); GivePlayerWeapon(playerid, 24, 100000); SetPlayerArmour(playerid, 100); return 1; } CMD:kill(playerid,params[]) { if(inMinigun{playerid}) return SendClientMessage(playerid,-1,"You are in a Minigun DM! Type /leave to leave it!"); SetPlayerHealth(playerid, 0); return 1; } |