I want the player to be unable to alter its own view angles during the cutscene so that the view after the cutscene has ended is identical to the view before the cutscene. Locking player movement works already, it's just the view angles that won't seem to stick.
Anyone know how I can achieve this? Current source can be found here.
I already have this bit of code in PM_UpdateViewAngles in bg_pmove.c, but it doesn't seem to help anything:
Code: Select all
if ( ps->pm_type == PM_INTERMISSION || ps->pm_type == PM_SPINTERMISSION || ps->pm_type == PM_CUTSCENE ) {
return; // no view changes at all
}
I've also tried storing the player's viewangles in a temporary variable when the cutscene starts and then restore that when the cutscene has finished playing. This is done serverside (in the game project):
Code: Select all
VectorCopy(self->activator->orgAngles, self->activator->client->ps.viewangles);
Anyone know how I can stop the player from giving input that changes the view angles?