Hey, I am trying to put a client into third person mode using this code:
PHP Code:
#include <sourcemod>
#include <smlib>
public OnPluginStart()
{
HookEvent("player_say", EventPlayerSay);
}
public EventPlayerSay(Handle:hEvent, String:sEventName[], bool:bDontBroadcast)
{
new userid = GetEventInt(hEvent, "userid");
new client = GetClientOfUserId(userid);
new String:textmessage[64];
GetEventString(hEvent, "text", textmessage, sizeof(textmessage));
if (StrEqual(textmessage, "!third", false))
Client_SetThirdPersonMode(client);
if (StrEqual(textmessage, "!first", false))
Client_SetThirdPersonMode(client, false);
}
But the result looks like this:
https://www.youtube.com/watch?v=QsFNwA_LUug
The viewangles of the camera aren't updated, the view doesn't move, whereas the player model turns..
__________________