Cudan Problem

Započeo spectro123, Jun 09, 2010, 00:26:31 PRE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Pozz decki
Sa SA:MP Foruma sam skino 2 dijaloga
Shop dijalog i airstrike dijalog
Ok ovak znaci radi kad imam jedan drugi ne
Probao sam oba u isto vreme upalit radi znaci otvorim meni ali onaj koji je prvi u fs linijama radi drugi otvori se ali kad odaberem akciju ne izvrsi to
Nije isti ID
Probao sam u isti FS dodat isto je
Mozetel pomoci molim vas?
Hvala

pa postaj nam kodove da vidimo...

Evo samo sec
O i da jos nesto
Nije do gm-a mog ili do fs jer sam sklonio sve i samo to ostavio
veoma je cudno

evo ovaj spojeni u jedno on radi ali ne radi >.< ubacite pa vidite sami znacete sta mislim

/shop radi sve i mogu sve vidit
/airstrike otvori selekciju ali ne izvrsi operraciju koju sam odabrao

[aeva]/*==========================================
=====PhIlMcKrAkIn's Weapons Shop Script=====
==========================================*/
#define DS 10000
/* Also in this script is a little commented
guide on how to get this intoyour gamemode
if you wish to not use it as a filter script*/
//include sa-mp stuff
#include <a_samp>
//define FS
#define FILTERSCRIPT
//colours
#define LIGHTGREEN 0x00ff009e

new CalledStrike[MAX_PLAYERS];
new Airstrike[MAX_PLAYERS];
new Adromada;
new Airstriking[MAX_PLAYERS];

#define COLOR_WHITE 0xFFFFFFFF

forward PlayerToPoint(Float:radi, playerid, Float:x, Float:y, Float:z);

public OnFilterScriptInit()
{
print("\n=============================");
print("= PhIlMcKrAkIn's Weapon Shop =");
print("=============================\n");
return 1;
}

public OnFilterScriptExit()
{
print("\n===================================");
print("= PhIl's Weps Succesfully Unloaded =");
print("===================================\n");
}

public OnPlayerConnect(playerid)
{
    Airstriking[playerid] = 0;
CalledStrike[playerid] = 0;
Airstrike[playerid] = 0;
Adromada = 0;
return 1;
}


public OnPlayerCommandText(playerid, cmdtext[])
{
    if(strcmp(cmdtext, "/shop", true) == 0)
{
if(PlayerToPoint(2.0, playerid, 548.1549,2270.9978,34.8421))
{
    ShowPlayerDialog(playerid, 12, DIALOG_STYLE_LIST, "Welcome to the Shop!", "Weapons\nAmmo\nItems", "Accept", "Cancel");
}
else
{
SendClientMessage(playerid, COLOR_WHITE, "You Aint at John's Market.");
}
return 1;
}

if (strcmp(cmdtext, "/airstrike", true) == 0)
{
ShowPlayerDialog(playerid,DS,2,"Airstrikes","Vehicle Smasher \nEnemy Wave Attack \nTank Buster \nCarpet Bomb \nNuke \nAir Attack \nAir Bomber \nMegaNuke \nVehicle Nuke \nAircracker bomb \nAirCluster Bomb \nDestructorBomb \nFireCluster \nSplitterMissile \nMOAB ","Ok","Cancel");
return 1;
}
return 0;
}
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
// Add all of the below code to your GM's OnDialogResponse
if(dialogid == 12 && response)
{
    switch(listitem)
    {
        case 0:
        {
                ShowPlayerDialog(playerid, 22, DIALOG_STYLE_LIST, "Choose Your Weapon", "Colt.45 ($250)\nColt.45 Silenced ($300)\nDesert Eagle ($400)\nMac 10 ($500)\nTech 9 ($550)\nMP5 ($600)\nSawn Off's ($1000)\nCombat Shotgun ($1000)\nAK-47 ($1500)\nM4 ($1500)\nRifle ($2000)\nSniper ($2500)", "Buy", "Cancel");
        }
        case 1:
        {
            ShowPlayerDialog(playerid, 32, DIALOG_STYLE_LIST, "Choose Your Ammo", "Colt.45 - 1000 ammo ($200)\nColt.45 Silenced - 1000 ammo ($200)\nDesert Eagle - 1000 ammo ($200)\nMac 10 - 1000 ammo ($200)\nTech 9 - 1000 ammo ($200)\nMP5 - 1000 ammo ($200)\nSawn Off's - 1000 ammo ($200)\nCombat Shotgun - 1000 ammo ($200)\nAK-47 - 1000 ammo ($200)\nM4 - 1000 ammo ($200)\nRifle - 1000 ammo ($200)\nSniper - 1000 ammo ($200)", "Buy", "Cancel");
        }
        case 2:
        {
            ShowPlayerDialog(playerid, 42, DIALOG_STYLE_LIST, "Choose Your Item", "Health Refill ($100)\nArmour Refill ($100)\nGrenades ($5000)\nBrass Knuckles ($50)\nParachute ($500)", "Buy", "Cancel");
        }
       
    }
}
if(dialogid == 22 && response)
{
    switch(listitem)
    {
        case 0://colt.45
        {
            if(GetPlayerMoney(playerid) >=250)//change price here...
            {
                GivePlayerMoney(playerid, -250);//and here
            GivePlayerWeapon(playerid,22,50);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 1://colt.45 silenced
        {
            if(GetPlayerMoney(playerid) >=300)//change price here...
            {
                GivePlayerMoney(playerid, -300);//and here
            GivePlayerWeapon(playerid,23,50);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 2://desert eagle
        {
            if(GetPlayerMoney(playerid) >=400)//change price here...
            {
                GivePlayerMoney(playerid, -400);//and here
            GivePlayerWeapon(playerid,24,50);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 3://mac 10
        {
            if(GetPlayerMoney(playerid) >=500)//change price here...
            {
                GivePlayerMoney(playerid, -500);//and here
            GivePlayerWeapon(playerid,28,100);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 4://tech 9
        {
            if(GetPlayerMoney(playerid) >=550)// i think you get the picture of how to change the prices now xD have fun :D.
            {
            GivePlayerMoney(playerid, -550);
            GivePlayerWeapon(playerid,32,100);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 5://mp5
        {
            if(GetPlayerMoney(playerid) >=600)
            {
                GivePlayerMoney(playerid, -600);
            GivePlayerWeapon(playerid,29,100);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 6://sawnoffs
        {
            if(GetPlayerMoney(playerid) >=1000)
            {
            GivePlayerMoney(playerid, -1000);
            GivePlayerWeapon(playerid,26,50);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 7://combat shotgun
        {
            if(GetPlayerMoney(playerid) >=1000)
            {
                GivePlayerMoney(playerid, -1000);
            GivePlayerWeapon(playerid,27,50);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 8://AK-47
        {
            if(GetPlayerMoney(playerid) >=1500)
            {
                GivePlayerMoney(playerid, -1500);
            GivePlayerWeapon(playerid,30,50);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 9://m4
        {
            if(GetPlayerMoney(playerid) >=1500)
            {
                GivePlayerMoney(playerid, -1500);
            GivePlayerWeapon(playerid,31,50);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 10://rifle
        {
            if(GetPlayerMoney(playerid) >=2000)
            {
                GivePlayerMoney(playerid, -2000);
            GivePlayerWeapon(playerid,33,50);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 11://sniper
        {
            if(GetPlayerMoney(playerid) >=2500)
            {
                GivePlayerMoney(playerid, -2500);
            GivePlayerWeapon(playerid,34,50);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
    }
}
if(dialogid == 32 && response)
{
    switch(listitem)
    {
        case 0:
        {
            if(GetPlayerMoney(playerid) >=200)//colt.45 ammo
            {
                GivePlayerMoney(playerid, -200);
            GivePlayerWeapon(playerid,22,1000);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 1:
        {
            if(GetPlayerMoney(playerid) >=200)//colt.45 silenced ammo
            {
                GivePlayerMoney(playerid, -200);
            GivePlayerWeapon(playerid,23,1000);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 2:
        {
            if(GetPlayerMoney(playerid) >=200)//desert eagle ammo
            {
                GivePlayerMoney(playerid, -2000);
            GivePlayerWeapon(playerid,24,1000);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 3:
        {
            if(GetPlayerMoney(playerid) >=200)//mac 10 ammo
            {
                GivePlayerMoney(playerid, -200);
            GivePlayerWeapon(playerid,28,1000);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 4:
        {
            if(GetPlayerMoney(playerid) >=200)//tech 9 ammo
            {
            GivePlayerMoney(playerid, -200);
            GivePlayerWeapon(playerid,32,1000);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 5:
        {
            if(GetPlayerMoney(playerid) >=200)//mp5 ammo
            {
                GivePlayerMoney(playerid, -200);
            GivePlayerWeapon(playerid,29,1000);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 6:
        {
            if(GetPlayerMoney(playerid) >=200)//sawnoffs ammo
            {
            GivePlayerMoney(playerid, -200);
            GivePlayerWeapon(playerid,26,1000);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 7:
        {
            if(GetPlayerMoney(playerid) >=200)//combat ammo
            {
                GivePlayerMoney(playerid, -200);
            GivePlayerWeapon(playerid,27,1000);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 8:
        {
            if(GetPlayerMoney(playerid) >=200)//AK-47 ammo
            {
                GivePlayerMoney(playerid, -200);
            GivePlayerWeapon(playerid,30,1000);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 9:
        {
            if(GetPlayerMoney(playerid) >=200)//m4 ammo
            {
                GivePlayerMoney(playerid, -200);
            GivePlayerWeapon(playerid,31,1000);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 10:
        {
            if(GetPlayerMoney(playerid) >=200)//rifle ammo
            {
                GivePlayerMoney(playerid, -200);
            GivePlayerWeapon(playerid,33,1000);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 11:
        {
            if(GetPlayerMoney(playerid) >=200)//sniper rifle ammo
            {
                GivePlayerMoney(playerid, -200);
            GivePlayerWeapon(playerid,34,1000);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }

    }
}
if(dialogid == 42 && response)
{
    switch(listitem)
    {
        case 0://health
        {
            if(GetPlayerMoney(playerid) >=100)
            {
                GivePlayerMoney(playerid,-100);
            SetPlayerHealth(playerid,100.0);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 1://armour
        {
              if(GetPlayerMoney(playerid) >=100)
            {
                GivePlayerMoney(playerid,-100);
            SetPlayerArmour(playerid,100.0);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 2://grenade
        {
              if(GetPlayerMoney(playerid) >=5000)
            {
                GivePlayerMoney(playerid,-5000);
            GivePlayerWeapon(playerid,16,10);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
                case 3://brass
        {
              if(GetPlayerMoney(playerid) >=50)
            {
                GivePlayerMoney(playerid,-50);
            GivePlayerWeapon(playerid,1,1);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
        case 4://para
        {
              if(GetPlayerMoney(playerid) >=500)
            {
                GivePlayerMoney(playerid,-500);
            GivePlayerWeapon(playerid,46,1);
            SendClientMessage(playerid,LIGHTGREEN,"=Shop= Thankyou For Purchasing!");
            }
            else
            {
                SendClientMessage(playerid,LIGHTGREEN,"=Shop= You Do Not Have Enough Money For That Item");
            }
        }
       
   }
        if(dialogid == DS) // Cars
    {
if(listitem == 0)
        {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 1;
Adromada = CreateObject(14553,x-55,y,z+75,0.000000,0.000000,90);
        MoveObject(Adromada,x+250,y,z+75,29);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",5000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 1)
        {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 2;
Adromada = CreateObject(14553,x-55,y,z+75,0.000000,0.000000,90);
        MoveObject(Adromada,x+250,y,z+75,29);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",5000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 2)
        {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 3;
Adromada = CreateObject(14553,x-55,y,z+75,0.000000,0.000000,90);
        MoveObject(Adromada,x+250,y,z+75,29);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",5000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 3)
        {
        if(!response) return 4;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 4;
Adromada = CreateObject(14553,x-55,y,z+75,0.000000,0.000000,90);
        MoveObject(Adromada,x+250,y,z+75,29);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",5000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 4)
        {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 5;
new Float:ang;
GetPlayerFacingAngle(playerid,ang);
Adromada = CreateObject(14553,x-55,y,z+75,0.000000,0.000000,90);
        MoveObject(Adromada,x+250,y,z+75,29);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",5000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 5)
        {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 6;
  Adromada = CreateObject(14553,x-55,y,z+75,0.000000,0.000000,90);
        MoveObject(Adromada,x+250,y,z+75,29);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",5000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 6)
{
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 7;
  Adromada = CreateObject(14553,x-55,y,z+75,0.000000,0.000000,90);
        MoveObject(Adromada,x+250,y,z+75,29);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",5000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 7)
        {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 8;
  Adromada = CreateObject(14553,x,y,z+75,0.000000,0.000000,90);
        MoveObject(Adromada,x+250,y,z+75,26);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",5000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 8)
        {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 9;
  Adromada = CreateObject(14553,x-55,y,z+75,0.000000,0.000000,90);
        MoveObject(Adromada,x+250,y,z+75,29);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",5000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 9)
        {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 10;
  Adromada = CreateObject(14553,x-55,y,z+75,0.000000,0.000000,90);
        MoveObject(Adromada,x+250,y,z+75,29);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",5000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 10)
  {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 11;
  Adromada = CreateObject(14553,x-50,y,z+75,0.000000,40.000000,90);
        MoveObject(Adromada,x+250,y,z+75,29);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",6000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 11)
  {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 12;
  Adromada = CreateObject(354,x,y,z+75,0.000000,0.000000,0.000000);
        MoveObject(Adromada,x,y,z,29);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",4000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 12)
  {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 13;
  Adromada = CreateObject(354,x,y,z+75,0.000000,0.000000,0.000000);
        MoveObject(Adromada,x,y,z,29);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",3000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 13)
  {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 14;
  Adromada = CreateObject(354,x,y,z+75,0.000000,0.000000,0.000000);
        MoveObject(Adromada,x,y,z,30);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",3000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}

if(listitem == 14)
  {
        if(!response) return 1;
        if(Airstriking[playerid] == 1) return SendClientMessage(playerid,0xFF0000AA,"Please Wait");
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
Airstrike[playerid] = 15;
  Adromada = CreateObject(354,x,y,z+75,0.000000,0.000000,0.000000);
        MoveObject(Adromada,x,y,z,30);
        Airstriking[playerid] = 1;
SetTimerEx("AirstrikeGo",3000,false,"dfffd",playerid,x,y,z,Airstrike[playerid]);
}
    }

}
return 1;
}

forward AirstrikeGo3(playerid,Float:x,Float:y,Float:z,type);
public AirstrikeGo3(playerid,Float:x,Float:y,Float:z,type)
{
if(type == 1)
{
CreateExplosion(x,y+5,z,6,5);
    CreateExplosion(x,y+6,z,6,5);
      CreateExplosion(x,y+7,z,6,5);
      CreateExplosion(x,y+8,z,6,5);
  }

  if(type == 2)
{
  CreateExplosion(x,y,z,7,10);
    CreateExplosion(x,y,z+3,7,10);
    CreateExplosion(x,y,z+6,7,10);
    CreateExplosion(x,y,z+9,7,10);
    CreateExplosion(x,y,z+12,7,10);
    CreateExplosion(x,y,z+15, 7, 10);
    CreateExplosion(x,y,z+18,7,10);
    CreateExplosion(x,y,z+21,7,10);
    CreateExplosion(x,y+3,z+21,7,10);
    CreateExplosion(x,y-3,z+21,7,10);
    CreateExplosion(x+3,y,z+21,7,10);
    CreateExplosion(x-3,y,z+21,7,10);
}

if(type == 3)
{
CreateExplosion(x,y,z,6,5);
    CreateExplosion(x+3,y,z,6,5);
    CreateExplosion(x+2,y,z,6,5);
    CreateExplosion(x+4,y,z,6,5);
    CreateExplosion(x+6,y,z,6,5);
    CreateExplosion(x+8,y,z,6,5);
    CreateExplosion(x+10,y,z,6,5);
    CreateExplosion(x+12,y,z,6,5);
    CreateExplosion(x+14,y,z,6,5);
    CreateExplosion(x+16,y,z,6,5);
    CreateExplosion(x+18,y,z,6,5);
    CreateExplosion(x+20,y,z,6,5);
    CreateExplosion(x+22,y,z,6,5);
    CreateExplosion(x+24,y,z,6,5);
    CreateExplosion(x+26,y,z,6,5);
    CreateExplosion(x+28,y,z,6,5);
    CreateExplosion(x+30,y,z,6,5);
    CreateExplosion(x+32,y,z,6,5);
}

if(type == 4)
{
    CreateExplosion(x,y,z,6,5);
    CreateExplosion(x+1,y,z,6,5);
    CreateExplosion(x+3,y,z,6,5);

}
return 1;
}

forward AirstrikeGo2(playerid,Float:x,Float:y,Float:z,type);
public AirstrikeGo2(playerid,Float:x,Float:y,Float:z,type)
{
if(type == 1)
{
CreateExplosion(x,y+5,z,6,5);
    CreateExplosion(x,y+6,z,6,5);
      CreateExplosion(x,y+7,z,6,5);
      CreateExplosion(x,y+8,z,6,5);
  }

if(type == 2)
{
CreateExplosion(x-8,y,z,6,5);
    CreateExplosion(x+8,y+6,z,6,5);
    CreateExplosion(x-12,y,z,6,5);
    CreateExplosion(x+12,y+6,z,6,5);
    SetTimerEx("AirstrikeGo3",2000,false,"dfffd",playerid,x,y,z,1);

  }

if(type == 3)
{
CreateExplosion(x+4,y,z,6,5);
    CreateExplosion(x-4,y,z,6,5);
    CreateExplosion(x+4,y+2,z+2,6,5);
    CreateExplosion(x-4,y+2,z+2,6,5);
    SetTimerEx("AirstrikeGo3",2000,false,"dfffd",playerid,x,y,z,2);

  }

  if(type == 4)
{
CreateExplosion(x,y,z+7,6,5);
    CreateExplosion(x+3,y,z+7,6,5);
    CreateExplosion(x+2,y,z+7,6,5);
    CreateExplosion(x+4,y,z+7,6,5);
    CreateExplosion(x+6,y,z+7,6,5);
    CreateExplosion(x+8,y,z+7,6,5);
    CreateExplosion(x+10,y,z+7,6,5);
    CreateExplosion(x+12,y,z+7,6,5);
    CreateExplosion(x+14,y,z+7,6,5);
    CreateExplosion(x+16,y,z+7,6,5);
    CreateExplosion(x+18,y,z+7,6,5);
    CreateExplosion(x+20,y,z+7,6,5);
    CreateExplosion(x+22,y,z+7,6,5);
    CreateExplosion(x+24,y,z+7,6,5);
    CreateExplosion(x+26,y,z+7,6,5);
    CreateExplosion(x+28,y,z+7,6,5);
    CreateExplosion(x+30,y,z+7,6,5);
    CreateExplosion(x+32,y,z+7,6,5);
    SetTimerEx("AirstrikeGo3",2000,false,"dfffd",playerid,x,y,z,3);
}

if(type == 5)
{
CreateExplosion(x,y,z,6,5);
    CreateExplosion(x+3,y,z,6,5);
    CreateExplosion(x+2,y,z,6,5);
    CreateExplosion(x+4,y,z,6,5);
    CreateExplosion(x+6,y,z,6,5);
    CreateExplosion(x+8,y,z,6,5);
    CreateExplosion(x+10,y,z,6,5);
    CreateExplosion(x+12,y,z,6,5);
    CreateExplosion(x+14,y,z,6,5);
    CreateExplosion(x+16,y,z,6,5);
    CreateExplosion(x+18,y,z,6,5);
    CreateExplosion(x+20,y,z,6,5);
    CreateExplosion(x+22,y,z,6,5);
    CreateExplosion(x+24,y,z,6,5);
    CreateExplosion(x+26,y,z,6,5);
    CreateExplosion(x+28,y,z,6,5);
    CreateExplosion(x+30,y,z,6,5);
    CreateExplosion(x+32,y,z,6,5);
    CreateExplosion(x+32,y-1,z,6,5);
    CreateExplosion(x+32,y-2,z,6,5);
    CreateExplosion(x+32,y-3,z,6,5);
      CreateExplosion(x+32,y+1,z,6,5);
    CreateExplosion(x+32,y+2,z,6,5);
    CreateExplosion(x+32,y+3,z,6,5);
    SetTimerEx("AirstrikeGo3",2000,false,"dfffd",playerid,x,y,z,4);

}
return 1;
}

forward AirstrikeGo(playerid,Float:x,Float:y,Float:z,type);
public AirstrikeGo(playerid,Float:x,Float:y,Float:z,type)
{
if(type == 1)
{
Airstriking[playerid] = 0;
     DestroyObject(Adromada);
     CreateExplosion(x,y,z,6,5);
}

    if(type == 2)
{
Airstriking[playerid] = 0;
DestroyObject(Adromada);
    CreateExplosion(x+4,y,z,6,5);
    CreateExplosion(x+6,y,z,6,5);
}

if(type == 3)
{
    Airstriking[playerid] = 0;
    DestroyObject(Adromada);
    CreateExplosion(x,y+1,z+1,6,5);
    CreateExplosion(x,y+4,z+1,6,5);
    CreateExplosion(x,y+6,z+1,6,5);
}

if(type == 4)
{
Airstriking[playerid] = 0;
DestroyObject(Adromada);
    CreateExplosion(x,y,z,6,5);
    CreateExplosion(x+3,y,z,6,5);
    CreateExplosion(x+2,y,z,6,5);
    CreateExplosion(x+4,y,z,6,5);
    CreateExplosion(x+6,y,z,6,5);
    CreateExplosion(x+8,y,z,6,5);
    CreateExplosion(x+10,y,z,6,5);
    CreateExplosion(x+12,y,z,6,5);
    CreateExplosion(x+14,y,z,6,5);
    CreateExplosion(x+16,y,z,6,5);
    CreateExplosion(x+18,y,z,6,5);
    CreateExplosion(x+20,y,z,6,5);
    CreateExplosion(x+22,y,z,6,5);
    CreateExplosion(x+24,y,z,6,5);
    CreateExplosion(x+26,y,z,6,5);
    CreateExplosion(x+28,y,z,6,5);
    CreateExplosion(x+30,y,z,6,5);
    CreateExplosion(x+32,y,z,6,5);
    CreateExplosion(x+34,y,z,6,5);
    CreateExplosion(x+36,y,z,6,5);
    CreateExplosion(x+38,y,z,6,5);
    CreateExplosion(x+40,y,z,6,5);
    CreateExplosion(x+42,y,z,6,5);
}

if(type == 5)
{
    Airstriking[playerid] = 0;
    DestroyObject(Adromada);
  CreateExplosion(x,y,z,7,10);
    CreateExplosion(x,y,z+3,7,10);
    CreateExplosion(x,y,z+6,7,10);
    CreateExplosion(x,y,z+9,7,10);
    CreateExplosion(x,y,z+12,7,10);
    CreateExplosion(x,y,z+15, 7, 10);
    CreateExplosion(x,y,z+18,7,10);
    CreateExplosion(x,y,z+21,7,10);
    CreateExplosion(x,y,z+24,7,10);
    CreateExplosion(x,y,z+26,7,10);
    CreateExplosion(x,y,z+29,7,10);
    CreateExplosion(x,y,z+32,7,10);
CreateExplosion(x,y,z+36,7,10);
    CreateExplosion(x,y,z+40,7,10);
    CreateExplosion(x,y,z+43,7,10);
    CreateExplosion(x,y,z+46,7,10);
    CreateExplosion(x,y+3,z+46,7,10);
    CreateExplosion(x,y-3,z+46,7,10);
    CreateExplosion(x+3,y,z+46,7,10);
    CreateExplosion(x-3,y,z+46,7,10);
    CreateExplosion(x+6,y+1,z+46,7,10);
    CreateExplosion(x-6,y-1,z+46,7,10);
    CreateExplosion(x+8,y+2,z+46,7,10);
    CreateExplosion(x-8,y-2,z+46,7,10);
}

if(type == 6)
{
Airstriking[playerid] = 0;
    DestroyObject(Adromada);
    CreateExplosion(x,y+1,z,6,5);
    CreateExplosion(x,y+2,z,6,5);
      CreateExplosion(x,y+3,z,6,5);
      CreateExplosion(x,y+4,z,6,5);
      SetTimerEx("AirstrikeGo2",3000,false,"dfffd",playerid,x,y,z,1);
}

if(type == 7)
{
Airstriking[playerid] = 0;
    DestroyObject(Adromada);
    CreateExplosion(x+2,y,z,6,5);
    CreateExplosion(x-2,y,z,6,5);
      CreateExplosion(x+4,y,z,6,5);
      CreateExplosion(x-4,y,z,6,5);
    CreateExplosion(x+6,y,z,6,5);
      CreateExplosion(x-6,y,z,6,5);
      SetTimerEx("AirstrikeGo2",2000,false,"dfffd",playerid,x,y,z,2);
}

if(type == 8)
{
Airstriking[playerid] = 0;
    DestroyObject(Adromada);
    CreateExplosion(x+2,y,z,6,5);
    CreateExplosion(x-2,y,z,6,5);
      SetTimerEx("AirstrikeGo2",2000,false,"dfffd",playerid,x,y,z,3);
}

if(type == 9)
{
Airstriking[playerid] = 0;
    DestroyObject(Adromada);
    CreateExplosion(x+2,y-1,z+2,6,5);
    CreateExplosion(x-2,y+1,z+4,6,5);
      CreateExplosion(x,y,z+6,6,5);
    CreateExplosion(x,y,z+8,6,5);
    CreateExplosion(x,y,z+12,6,5);
    CreateExplosion(x,y,z+14,6,5);
    CreateExplosion(x-1,y,z+12,6,5);
    CreateExplosion(x+1,y,z+14,6,5);
}

if(type == 10)
{
Airstriking[playerid] = 0;
    DestroyObject(Adromada);
    CreateExplosion(x+4,y+10,z+7,6,5);
    CreateExplosion(x+8,y+8,z+7,6,5);
    CreateExplosion(x+12,y+6,z+7,6,5);
    CreateExplosion(x+16,y+8,z+7,6,5);
    CreateExplosion(x+18,y+6,z+7,6,5);
    CreateExplosion(x+20,y+10,z+7,6,5);
}

if(type == 11)
{
Airstriking[playerid] = 0;
    DestroyObject(Adromada);
    CreateExplosion(x,y,z+15,6,5);
    CreateExplosion(x+3,y,z+15,6,5);
    CreateExplosion(x+2,y,z+15,6,5);
    CreateExplosion(x+4,y,z+15,6,5);
    CreateExplosion(x+6,y,z+15,6,5);
    CreateExplosion(x+8,y,z+15,6,5);
    CreateExplosion(x+10,y,z+15,6,5);
    CreateExplosion(x+12,y,z+15,6,5);
    CreateExplosion(x+14,y,z+15,6,5);
    CreateExplosion(x+16,y,z+15,6,5);
    CreateExplosion(x+18,y,z+15,6,5);
    CreateExplosion(x+20,y,z+15,6,5);
    CreateExplosion(x+22,y,z+15,6,5);
    CreateExplosion(x+24,y,z+15,6,5);
    CreateExplosion(x+26,y,z+15,6,5);
    CreateExplosion(x+28,y,z+15,6,5);
    CreateExplosion(x+30,y,z+15,6,5);
    CreateExplosion(x+32,y,z+15,6,5);
    CreateExplosion(x+26,y-1,z+15,6,5);
    CreateExplosion(x+28,y-2,z+15,6,5);
    CreateExplosion(x+30,y-3,z+15,6,5);
    CreateExplosion(x+32,y-4,z+15,6,5);
    SetTimerEx("AirstrikeGo2",2000,false,"dfffd",playerid,x,y,z,4);
}

if(type == 12)
{
Airstriking[playerid] = 0;
    DestroyObject(Adromada);
    CreateExplosion(x,y-1,z,6,5);
    CreateExplosion(x+6,y+1,z,6,5);
    CreateExplosion(x+12,y,z,6,5);
    CreateExplosion(x-6,y,z,6,5);
    CreateExplosion(x+8,y,z,6,5);
    CreateExplosion(x,y-1,z,6,5);
    CreateExplosion(x+6,y+6,z,6,5);
    CreateExplosion(x+12,y+12,z,6,5);
    CreateExplosion(x-6,y-6,z,6,5);
    CreateExplosion(x+8,y+8,z,6,5);
    CreateExplosion(x,y-1,z,6,5);
    CreateExplosion(x+6,y+6,z+2,6,5);
    CreateExplosion(x+12,y+12,z+2,6,5);
    CreateExplosion(x-6,y-6,z+4,6,5);
    CreateExplosion(x+8,y+8,z+4,6,5);
}

if(type == 13)
{
Airstriking[playerid] = 0;
    DestroyObject(Adromada);
    CreateExplosion(x,y-1,z,6,5);
    CreateExplosion(x,y-2,z,6,5);
    CreateExplosion(x,y-3,z,6,5);
    CreateExplosion(x,y-4,z,6,5);
    CreateExplosion(x,y-6,z,6,5);
    CreateExplosion(x,y-8,z,6,5);
    CreateExplosion(x,y-12,z,6,5);
    CreateExplosion(x,y-14,z,6,5);
    CreateExplosion(x,y-16,z,6,5);
    CreateExplosion(x,y-18,z,6,5);
    CreateExplosion(x,y,z,7,10);
    CreateExplosion(x,y,z+3,7,10);
    CreateExplosion(x,y,z+6,7,10);
    CreateExplosion(x,y,z+9,7,10);
    CreateExplosion(x,y,z+12,7,10);
    CreateExplosion(x,y,z+15, 7, 10);
    CreateExplosion(x,y,z+18,7,10);
    CreateExplosion(x,y,z+21,7,10);
    CreateExplosion(x,y,z+24,7,10);
    CreateExplosion(x,y,z+26,7,10);
    CreateExplosion(x,y,z+29,7,10);
    CreateExplosion(x,y,z+32,7,10);
}

if(type == 14)
{
Airstriking[playerid] = 0;
    DestroyObject(Adromada);
    CreateExplosion(x-1,y,z,6,5);
    CreateExplosion(x-2,y,z,6,5);
    CreateExplosion(x-3,y,z,6,5);
    CreateExplosion(x-4,y,z,6,5);
    CreateExplosion(x-5,y,z,6,5);
    CreateExplosion(x-6,y,z,6,5);
      CreateExplosion(x-7,y,z,6,5);
    CreateExplosion(x,y,z-3,7,10);
    CreateExplosion(x,y,z-6,7,10);
    CreateExplosion(x,y,z-9,7,10);
    CreateExplosion(x,y,z-12,7,10);
    CreateExplosion(x,y,z-15,7,10);
    CreateExplosion(x,y,z-18,7,10);
    CreateExplosion(x,y,z-21,7,10);
    CreateExplosion(x,y,z-24,7,10);
    CreateExplosion(x,y,z-26,7,10);
    CreateExplosion(x,y,z-29,7,10);
    CreateExplosion(x,y,z-32,7,10);
}

if(type == 15)
{
Airstriking[playerid] = 0;
    DestroyObject(Adromada);
Airstriking[playerid] = 0;
    DestroyObject(Adromada);
    CreateExplosion(x-1,y,z,6,5);
    CreateExplosion(x-2,y,z,6,5);
    CreateExplosion(x+1,y,z,6,5);
    CreateExplosion(x+2,y,z,6,5);
    CreateExplosion(x+3,y,z+1,6,5);
    CreateExplosion(x+2,y,z+2,6,5);
    CreateExplosion(x+4,y,z+3,6,5);
    CreateExplosion(x+6,y,z+4,6,5);
    CreateExplosion(x+8,y,z+6,6,5);
    CreateExplosion(x+10,y,z+7,6,5);
    CreateExplosion(x+12,y,z+8,6,5);
    CreateExplosion(x+14,y-4,z+8,6,5);
    CreateExplosion(x+16,y+4,z+8,6,5);
    CreateExplosion(x+18,y+8,z+8,6,5);
    CreateExplosion(x+20,y-8,z+8,6,5);
}

    Airstrike[playerid] = 0;
return 1;
}


public PlayerToPoint(Float:radi, playerid, Float:x, Float:y, Float:z)
{
    if(IsPlayerConnected(playerid))
{
new Float:oldposx, Float:oldposy, Float:oldposz;
new Float:tempposx, Float:tempposy, Float:tempposz;
GetPlayerPos(playerid, oldposx, oldposy, oldposz);
tempposx = (oldposx -x);
tempposy = (oldposy -y);
tempposz = (oldposz -z);
//printf("DEBUG: X:%f Y:%f Z:%f",posx,posy,posz);
if (((tempposx < radi) && (tempposx > -radi)) && ((tempposy < radi) && (tempposy > -radi)) && ((tempposz < radi) && (tempposz > -radi)))
{
return 1;
}
}
return 0;
}
[/aeva]