Gates-no errors yet dont open?
#1

pawn Код:
new pdgate1;
new pdgate2;
new pdgate3;
new tugate;
new lspddoor1;
new lspddoor2;
new armygate1;
new armygate2;
new fbigate;
new hspdgate;
new lucianogate;

pdgate1 = CreateObject(971,1589.053344,-1638.123168,14.122960,0.000000,0.000000,180);
        pdgate2 = CreateObject(968,1544.700317,-1630.735717,13.096980,-1.000000,-91.000000,269.972869);
        tugate = CreateObject(971, 1042.2530,-1026.0344,32.1016,0, 0.0000, 0.0000);
        CreateObject(971, 2644.4778,-2038.8990,13.5500,0, 0.0000, 0.0000);
        lspddoor1 = CreateObject(1500, 245.0578,72.4314,1002.5406,0, 0.0000, 0.0000);
        lspddoor2 = CreateObject(1500, 245.9478,72.4314,1002.5406,0, 0.0000, 0.0000);
        CreateObject(971, 1972.8408,-1622.1426,15.9688,0, 0.0000, 90);
        armygate1 = CreateObject(969, 2720.3772,-2409.7523,12.6,0, 0.0000, 90);
        armygate2 = CreateObject(969, 2720.3772,-2508.3069,12.6,0, 0.0000, 90);
        CreateObject(980, 2774.4670,-2494.5842,14.2665,0, 0.0000, 90);
        CreateObject(971, 2796.7512,-2481.5188,12.5143,0, 0.0000, 0);
        CreateObject(971, 2796.7512,-2506.3359,12.5143,0, 0.0000, 0);
        CreateObject(980, 2625.6016,-2347.2651,13.6328,0, 0.0000, 90);
        CreateObject(980, 2625.6016,-2336.8651,13.6328,0, 0.0000, 90);
        fbigate = CreateObject(980, 1534.9020,-1451.5979,14.4882,0, 0.0000, 0);
        hspdgate = CreateObject(971, 1643.3379,-1714.9338,15.3067,0, 0.0000, 90);






if(!strcmp(cmdtext, "/gateopen", true)) // By Ellis
{
 if(PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pLeader] == 2 || PlayerInfo[playerid][pLeader] == 3 || PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pMember] == 3)
  {
    if (PlayerToPoint(15, playerid,1589.053344,-1638.123168,14.122960))
        {
        MoveObject(pdgate1,1599.053344,-1638.123168,14.122960, 0.8);
        SetTimer("GateClose", 12000, 0);
        SendClientMessage(playerid, COLOR_BLUE,"A garage is opened and will close in 7 seconds.");
        GetPlayerName(playerid, sendername, sizeof(sendername));
        format(string, sizeof(string), "* %s takes his/her remote and opens a garage.", sendername);
        ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        PlayerPlaySound(playerid, 1153, 1589.053344,-1638.123168,14.122960);
        }
        else if (PlayerToPoint(15, playerid,1544.700317,-1630.735717,13.096980))
        {
        DestroyObject( pdgate2 );
        pdgate3 = CreateObject(968,1544.700317,-1630.735717,12.924660,0.000000,0.000000,270.972869);
        SetTimer("GateClose5", 6000, 0);
        SendClientMessage(playerid, COLOR_BLUE,"The gate is opened and will close in 6 seconds.");
        GetPlayerName(playerid, sendername, sizeof(sendername));
        format(string, sizeof(string), "* %s takes his/her remote and opens the gate.", sendername);
        ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        }
        else if (PlayerToPoint(15, playerid,2720.3772,-2409.7523,12.6))
        {
        MoveObject(armygate1,2720.3772, -2401.2523, 12.6, 3.5);
        SetTimer("GateClose2", 7000, 0);
        SendClientMessage(playerid, COLOR_BLUE,"The Army gate Nr. 1 is opened and will close in 7 seconds.");
        GetPlayerName(playerid, sendername, sizeof(sendername));
        format(string, sizeof(string), "* %s takes his/her remote and opens the army gate #1.", sendername);
        ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        }
        else if (PlayerToPoint(15, playerid,2720.3772,-2508.3069,12.6))
        {
        MoveObject(armygate2,2720.3772, -2499.8069, 12.6, 3.5);
        SetTimer("GateClose2", 7000, 0);
        SendClientMessage(playerid, COLOR_BLUE,"The Army gate Nr. 2 is opened and will close in 7 seconds.");
        GetPlayerName(playerid, sendername, sizeof(sendername));
        format(string, sizeof(string), "* %s takes his/her remote and opens the army gate #2.", sendername);
        ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        }
        else if (PlayerToPoint(15, playerid,1534.9020,-1451.5979,14.4882))
        {
        MoveObject(fbigate,1534.9020,-1451.5979,20.4882, 1.5);
        SetTimer("GateClose3", 7000, 0);
        SendClientMessage(playerid, COLOR_BLUE,"FBI gate is opened and will close in 7 seconds.");
        GetPlayerName(playerid, sendername, sizeof(sendername));
        format(string, sizeof(string), "* %s takes his/her remote and opens fbi gate.", sendername);
        ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        }
        else if (PlayerToPoint(15, playerid,1643.3379,-1714.9338,15.3067))
        {
        MoveObject(hspdgate,1643.3379,-1705.9338,15.3067, 1.5);
        SetTimer("GateClose4", 7000, 0);
        SendClientMessage(playerid, COLOR_BLUE,"HSPD gate is opened and will close in 7 seconds.");
        GetPlayerName(playerid, sendername, sizeof(sendername));
        format(string, sizeof(string), "* %s takes his/her remote and opens hspd gate.", sendername);
        ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
        }
        else { SendClientMessage(playerid, COLOR_GREY,"Destination is too far."); }
    }
    else if(PlayerInfo[playerid][pMember] == 6 || PlayerInfo[playerid][pLeader] == 6)
    {
      if (PlayerToPoint(15, playerid,1246.0033,-767.3727,91.1473))
      {
        MoveObject(lucianogate,1256.2033,-767.3727,91.1473, 2.2);
        SetTimer("GateClose6", 7000, 0);
        GetPlayerName(playerid, sendername, sizeof(sendername));
        format(string, sizeof(string), "* %s takes his/her remote and opens La Famiglia Sinatra hq gate.", sendername);
        ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
      }
      else { SendClientMessage(playerid, COLOR_GREY,"Destination is too far."); }
    }
    /*else if(PlayerInfo[playerid][pMember] == 16 || PlayerInfo[playerid][pLeader] == 16)
    {
      if (PlayerToPoint(15, playerid,2796.1454,-1600.2020,10.1297))
      {
        MoveObject(iorgate,2786.1454,-1600.2020,10.1297, 2.2);
        SetTimer("GateClose7", 7000, 0);
        GetPlayerName(playerid, sendername, sizeof(sendername));
        format(string, sizeof(string), "* %s takes his/her remote and opens institute of race hq gate.", sendername);
        ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
      }
      else { SendClientMessage(playerid, COLOR_GREY,"Destination is too far."); }
    }*/

    else return SendClientMessage(playerid, COLOR_GREY,"You don't have a remote control.");
  return 1;
}


public GateClose(playerid)
{
   MoveObject(pdgate1,1589.053344,-1638.123168,14.122960, 0.97);
   PlayerPlaySound(playerid, 1153, 1589.053344,-1638.123168,14.122960);
   return 1;
}

public GateClose2()
{
   MoveObject(armygate1,2720.3772, -2409.7523, 12.6, 2.5);
   MoveObject(armygate2,2720.3772, -2508.3069, 12.6, 2.5);
   return 1;
}

public GateClose3()
{
   MoveObject(fbigate, 1534.9020,-1451.5979,14.4882, 1.5);
   return 1;
}

public GateClose4()
{
   MoveObject(hspdgate, 1643.3379,-1714.9338,15.3067, 1.5);
   return 1;
}

public GateClose5()
{
   DestroyObject( pdgate3 );
   pdgate2 = CreateObject(968,1544.700317,-1630.735717,13.096980,-1.000000,-91.000000,269.972869);
   return 1;
}

public GateClose6()
{
   MoveObject(lucianogate, 1246.0033,-767.3727,91.1473, 1.5);
     return 1;
}
Reply
#2

I'm woundering how you aren't getting errors theree..
Reply
#3

lol me neither But whats is wrong with that shit
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)