SA-MP Forums Archive
Players are not moving - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Players are not moving (/showthread.php?tid=161300)



Players are not moving - markjaysonpinoy - 19.07.2010

I cant see players moving, is it a bug with my server scripts? i tried different gamemodes and it worked, except my server


Re: Players are not moving - kc - 19.07.2010

Are you returning 0 in OnPlayerUpdate by any chance?


Re: Players are not moving - ViruZZzZ_ChiLLL - 19.07.2010

Maybe its because somewhere in your script there's a :
TogglePlayerControllable(playerid, 0); // which means it freezes them


Re: Players are not moving - markjaysonpinoy - 19.07.2010

Yea I put it return 0; somewhere

pawn Код:
public OnPlayerUpdate(playerid)
{
if(GetPlayerVirtualWorld(playerid)!=1)return 0;
new Float:health;
new veh;
veh = GetPlayerVehicleID(playerid);
GetVehicleHealth(veh, health);
if(IsPlayerInAnyVehicle(playerid) && GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
RepairVehicle(GetPlayerVehicleID(playerid));
}
return 1;
}
for the auto repair only on world 1 but i didnt think that it will mess up the other woorlds


Re: Players are not moving - kc - 19.07.2010

Well, yeah that would explain it.

That is basically throwing away the sync data from any player who is NOT in virtual world 1.

Change that to return 1 if you wish for execution to stop there without causing player sync to stop.


Re: Players are not moving - markjaysonpinoy - 19.07.2010

Thanks kc your the best! I use ConvertFFS everytime I map on MTA and convert to SA-MP