PDA

View Full Version : problem with OnPlayerUpdate


Lirbo
19/04/2014, 04:17 PM
public OnPlayerUpdate(playerid)
{
if(LSPDGGOPEN == false){
MoveObject(LSPDGG,1589.6, -1638.3, 14.26,2);
}else{
MoveObject(LSPDGG,1589.6, -1638.3, 10,2);}}

return 1;
}

Error:
error 010: invalid function or declaration

Line of error:
return 1;

juandiegox
19/04/2014, 04:22 PM
Replace that code for this..

public OnPlayerUpdate(playerid)
{
if(LSPDGGOPEN == false)
{
MoveObject(LSPDGG,1589.6, -1638.3, 14.26,2);
}
else
{
MoveObject(LSPDGG,1589.6, -1638.3, 10,2);
}
return 1;
}

Lirbo
19/04/2014, 04:25 PM
Replace that code for this..

public OnPlayerUpdate(playerid)
{
if(LSPDGGOPEN == false)
{
MoveObject(LSPDGG,1589.6, -1638.3, 14.26,2);
}
else
{
MoveObject(LSPDGG,1589.6, -1638.3, 10,2);
}
return 1;
}

Thanks alot :D