Skip to content

Commit e7bf917

Browse files
authored
Merge pull request Velaron#263 from Vladislav4KZ/spec-mode-fix
Fix spectator mode switching in spectator GUI and spec_mode command
2 parents 87335b5 + e83e512 commit e7bf917

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

cl_dll/hud_spectator.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -909,6 +909,10 @@ void CHudSpectator::SetModes(int iNewMainMode, int iNewInsetMode)
909909
// if we are NOT in HLTV mode, main spectator mode is set on server
910910
if ( !gEngfuncs.IsSpectateOnly() )
911911
{
912+
char cmdstring[32];
913+
// forward command to server
914+
sprintf(cmdstring,"specmode %i",iNewMainMode );
915+
gEngfuncs.pfnServerCmd(cmdstring);
912916
return;
913917
}
914918

0 commit comments

Comments
 (0)