Gate script error
#1

Hey guys,

Whats wrong with this filter-script:
pawn Код:
#include <a_samp>
new Gate, bool:GateClosed = true;

public OnFilterScriptInit()
{
    Gate = CreateObject(968, 3268.3994140625, 150.5, 9.8999996185303, 0.0, 270.74993896484, 282.7470703125, 100.0);
    SetTimer("GateCheck", 3500, true);
    return 1;
}

forward GateCheck();
public GateCheck()
{
    if(!IsObjectMoving(Gate)){
        for(new i; i<GetMaxPlayers(); i++){
            if(IsPlayerConnected(i && IsPlayerInRangeOfPoint(i, 15.0, 3268.3994140625, 150.5, 9.8999996185303)){
                if(GateClosed){
                    GateClosed = false;
                    MoveObject(Gate, 3268.3994140625, 150.5, 9.8999996185303, 2.0, 0.0, 359.75006103516, 282.744140625);
                    SendClientMessage(i, 0xFF9D00FF, "You are ready to go!");
                }
                else{
                    GateClosed = true;
                    MoveObject(Gate, 3268.3994140625, 150.5, 9.8999996185303, 2.0, 0.0, 270.74993896484, 282.7470703125);
                    SendClientMessage(i, 0xFFFFFFFF, "");
            }
            }
        }
    }
}
First problem is fixed,

But why the gate isnt opening?

Please tell me what I did wrong...

Thanks
Reply


Messages In This Thread
Gate script error - by jeremy8810 - 11.08.2012, 12:23
Re: Gate script error - by telmo_ferreira - 11.08.2012, 12:26
Re: Gate script error - by kickerbat - 11.08.2012, 12:28
Re: Gate script error - by jeremy8810 - 11.08.2012, 12:29
Re: Gate script error - by jeremy8810 - 11.08.2012, 13:39
Re: Gate script error - by Vince - 11.08.2012, 14:14
Re: Gate script error - by jeremy8810 - 11.08.2012, 14:26
Re: Gate script error - by jeremy8810 - 11.08.2012, 16:02
Re: Gate script error - by PArescueEMT - 11.08.2012, 18:22

Forum Jump:


Users browsing this thread: 1 Guest(s)