Moving Gate [Help]
#4

I did have the whole script up, but i edited it and deleted it cause i fixed some other errors i originally had posted


pawn Код:
//automatic

//Change the coordinate by yourself

#define FILTERSCRIPT

#include <a_samp>
#include <foreach>//Download this include if you don't have one

#define MAX_GATES 1

new Gate[MAX_GATES],
    bool:Open[MAX_GATES];

new GateTimer[MAX_GATES];

forward GateMovement1();
forward GateMovement2();
forward GateMovement3();

public OnFilterScriptInit()
{
    Gate[0] = CreateObject(980, -2126.5476, -80.8152, 37.1033, -2116.7076, -80.8152, 37.1033, 250.0);
    GateTimer[0] = SetTimer("GateMovement1",5000,1)
 ;
    return 1;
}

public GateMovement1()
{
    switch(Open{0})
    {
        case true:
        {
            foreach(Player,i)
            {
                if(IsPlayerInRangeOfPoint(i,10,-2116.7076, -80.8152, 37.1033)) return 1;
            }
            MoveObject(Gate[0],-2126.5476, -80.8152, 37.1033,1000);
            Open{0} == false;
        }
        case false:
        {
            foreach(Player,i)
            {
                if(IsPlayerInRangeOfPoint(i,10,-2116.7076, -80.8152, 37.1033))
                {
                    MoveObject(Gate[0],-2126.5476, -80.8152, 37.1033,1000);
                    Open{0} == true;
                    return 1;
                }
            }
        }
    }
    return 1;
}
Reply


Messages In This Thread
warning 215: expression has no effect [Gates] - by MrPlatinum - 01.10.2012, 14:38
Re: Moving Gate [Help] - by trapstar2020 - 01.10.2012, 14:57
Re: Moving Gate [Help] - by newbienoob - 01.10.2012, 14:59
Re: Moving Gate [Help] - by MrPlatinum - 01.10.2012, 15:00
Re: Moving Gate [Help] - by mamorunl - 01.10.2012, 15:00
Re: Moving Gate [Help] - by MrPlatinum - 01.10.2012, 15:03
Re: Moving Gate [Help] - by trapstar2020 - 01.10.2012, 15:04
Re: Moving Gate [Help] - by mamorunl - 01.10.2012, 15:07
Re: Moving Gate [Help] - by Vince - 01.10.2012, 15:11
Re: Moving Gate [Help] - by mamorunl - 01.10.2012, 15:15

Forum Jump:


Users browsing this thread: 2 Guest(s)