In Progress [UI] HUDExtension team banner and captured flags not lining up when in spectator

Users who are viewing this thread

Version number
1.1.3.16165
Branch
Main
Modded/unmodded
Unmodded
Summary: if you are spectating, the position of the captured flags and the team banners above are switched - in the attached screenshot, the battanian B flag should be on the right side, rather than on the left (or the aserai team banner/score on the right, either works - should just be consistent).
How to Reproduce: just play
Scene Name (if related): any
Media (Screenshots & Video):
0h2mt.png

Computer Specs: any

Some Fix Speculation:
From a brief look around, I believe this issue comes down to class a difference in how MissionMultiplayerHUDExtensionVM and CommanderInfoVM determine what your current allyTeam is:
in HUDExtension its this._isAttackerTeamAlly = newTeam.Side == BattleSideEnum.Attacker;
meanwhile in CommanderInfo theres also a check for whether you're spectator, setting attacker as ally if so:
Code:
            this._allyTeam = GameNetwork.MyPeer.GetComponent<MissionPeer>().Team;
                        // ...
            if (this._allyTeam.Side == BattleSideEnum.None)
            {
                this._allyTeam = Mission.Current.AttackerTeam;
            }

My (admittedly untested) fix suggestion would be simply changing the related line in HUDExtension to be this._isAttackerTeamAlly = newTeam.Side == BattleSideEnum.Attacker || newTeam.Side == BattleSideEnum.None;, which should be a simple solution to have things be consistent
 
@Dejan Not sure if 1.2.9 was intended to fix this, but the flags now don't show up at all while in spectator. If that was considered as a fix by TaleWorlds - it is not.

I'm probably gonna end up just recreating this for my streamer tools, but this really should be fixed in the main game. Similarly, I don't think these two reports were resolved, either:

edit: also it seems the flags are not consistently gone. rewatching Nexoners stream today, they were there again on the second spawn...
 
Last edited:
Back
Top Bottom