Need help gate Zcmd...
#1

Hey i gets this error when i Compiler the it in pawno

PHP код:
error 029: invalid expression, assumed zero 
what is the error...
---------

Here is the gate script.

PHP код:
#include <a_samp>
new Gate;
public 
OnGameModeInit()
{
    
Gate = CreateObject(7657, 2234, 2215.39, 14.30, 0.0, 0.0, 0.0, 300.0);
    return 
1;
}
CMD:open(playerid, params[])
{
    if( ==  && !
IsObjectMoving(Gate) && IsPlayerInRangeOfPoint(playerid, 5999, 2234, 2215.39, 14.30))
    {
        
MoveObject(Gate, 2222.69, 2203.89, 14.30, 3.0, 0.0, 0.0, 0.0);
        return 
1;
    }
}
CMD:close(playerid, params[])
{
    if( ==  && !
IsObjectMoving(Gate) && IsPlayerInRangeOfPoint(playerid, 5000, 2222.69, 2203.89, 14.30))
    {
        
MoveObject(Gate, 2234, 2215.39, 14.30, 3.0, 0.0, 0.0, 0.0);
        return 
1;
    }
} 
Reply
#2

Offtopic: Why do people keep using PHP-code, without even considering to try out [pawn] tags instead.

Ontopic:
pawn Код:
==  &&
This is why.
Reply
#3

pawn Код:
#include <a_samp>

new Gate;

public OnGameModeInit()
{
    Gate = CreateObject(7657, 2234, 2215.39, 14.30, 0.0, 0.0, 0.0, 300.0);
    return 1;
}

CMD:open(playerid, params[])
{
    if(!IsObjectMoving(Gate) && IsPlayerInRangeOfPoint(playerid, 5999, 2234, 2215.39, 14.30))
    {
        MoveObject(Gate, 2222.69, 2203.89, 14.30, 3.0, 0.0, 0.0, 0.0);
        return 1;
    }
}

CMD:close(playerid, params[])
{
    if( !IsObjectMoving(Gate) && IsPlayerInRangeOfPoint(playerid, 5000, 2222.69, 2203.89, 14.30))
    {
        MoveObject(Gate, 2234, 2215.39, 14.30, 3.0, 0.0, 0.0, 0.0);
        return 1;
    }
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)