[HELP]Auto Gate?
#1

How can i make a gate who automaticly opens when i get close to the gate
Like an hangar (the gate opens when i am getting close to it)

Script (The gate)
pawn Код:
#include <a_samp>

#define FILTERSCRIPT
#define COLOR_GREEN 0x33AA33AA


forward loadobjects();
forward loadvehicles();
forward Resetbase();

new Gate1;

public OnFilterScriptInit()
{
    Gate1 = CreateObject(2933,96.71507263,1920.44409180,17.12633896,0.00000000,270.00000000,90.00000000); //gate(/gate)
    return 1;
}


public OnPlayerCommandText(playerid, cmdtext[])
{
    if (strcmp("/gate", cmdtext, true) == 0)
    {
        if(IsPlayerAdmin(playerid)==1)
        {
            SendClientMessage(playerid,COLOR_GREEN,"The HQ gate Is now opening!");
            MoveObject(Gate1, 96.715072631836,1920.4440917969,12.12633895874, 2.00);
            SetTimer("Resetbase",5000,0);
            return 1;
        }
    }
    return 0;
}


public Resetbase()
{
    MoveObject(Gate1, 96.715072631836,1920.4440917969,17.12633895874, 2.00);
    }
Reply


Messages In This Thread
[HELP]Auto Gate? - by Larsey123IsMe - 16.11.2010, 22:28
Re: [HELP]Auto Gate? - by Nero_3D - 16.11.2010, 23:54
Re: [HELP]Auto Gate? - by Rafa - 17.11.2010, 08:39
Re: [HELP]Auto Gate? - by Larsey123IsMe - 17.11.2010, 12:40
Re: [HELP]Auto Gate? - by Nero_3D - 17.11.2010, 13:29
Re: [HELP]Auto Gate? - by yvoms - 17.11.2010, 13:32
Re: [HELP]Auto Gate? - by Larsey123IsMe - 17.11.2010, 13:59
Re: [HELP]Auto Gate? - by yvoms - 17.11.2010, 14:09
Re: [HELP]Auto Gate? - by Larsey123IsMe - 17.11.2010, 15:07
Re: [HELP]Auto Gate? - by yvoms - 18.12.2010, 20:01

Forum Jump:


Users browsing this thread: 1 Guest(s)