06.06.2015, 13:04
In OnPlayerStateChange:
if the new state is in vehicle (driver or passenger) for a player and this player is being spectated by others, re-spectate the vehicle the player is in.
else if the new state is on foot for a player and this player is being specated by others, re-spectate the player.
It's pretty much similar in OnPlayerInteriorChange, you have to change the interior of the players who are spectating the player whose interior is changed. It also applies for virtual worlds.
if the new state is in vehicle (driver or passenger) for a player and this player is being spectated by others, re-spectate the vehicle the player is in.
else if the new state is on foot for a player and this player is being specated by others, re-spectate the player.
It's pretty much similar in OnPlayerInteriorChange, you have to change the interior of the players who are spectating the player whose interior is changed. It also applies for virtual worlds.