Skip to content

Match the squad check inside .CenterPosition#21736

Merged
pchote merged 1 commit into
OpenRA:bleedfrom
PunkPun:fix-squad-crash
Feb 1, 2025
Merged

Match the squad check inside .CenterPosition#21736
pchote merged 1 commit into
OpenRA:bleedfrom
PunkPun:fix-squad-crash

Conversation

@PunkPun

@PunkPun PunkPun commented Feb 1, 2025

Copy link
Copy Markdown
Member
Exception of type `System.InvalidOperationException`: Attempting to query the position of an invalid Target
   at OpenRA.Traits.Target.get_CenterPosition() in /OpenRA/OpenRA.Game/Traits/Target.cs:line 169
   at OpenRA.Mods.Common.Traits.BotModules.Squads.Squad.Serialize() in /OpenRA/OpenRA.Mods.Common/Traits/BotModules/Squads/Squad.cs:line 148
   at OpenRA.Mods.Common.Traits.SquadManagerBotModule.<>c.<OpenRA.Traits.IGameSaveTraitData.IssueTraitData>b__41_0(Squad s) in /OpenRA/OpenRA.Mods.Common/Traits/BotModules/SquadManagerBotModule.cs:line 525
   at System.Collections.Generic.List`1.ConvertAll[TOutput](Converter`2 converter)
   at OpenRA.Mods.Common.Traits.SquadManagerBotModule.OpenRA.Traits.IGameSaveTraitData.IssueTraitData(Actor self) in /OpenRA/OpenRA.Mods.Common/Traits/BotModules/SquadManagerBotModule.cs:line 523

@PunkPun PunkPun added this to the Next Release milestone Feb 1, 2025

@pchote pchote left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not tested, but fix is clearly correct (Target.Invalid is specifically set up to not equal itself).

@pchote pchote merged commit 09259be into OpenRA:bleed Feb 1, 2025
@pchote

pchote commented Feb 1, 2025

Copy link
Copy Markdown
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants