HomeWildfire Games

Fix formation merging issues.


Fix formation merging issues.

The motion parameters were calculated even without members, which caused us to try set a undefined passclass.
Also were members added to previously merged twin-formations. Once merged (i.e. disbanded), they are moved out of world now.

Some cleanups/deduplication whilst at it.

Reported by: @andy5995 at the forums (https://wildfiregames.com/forum/topic/71578-feedbacks-from-a26-svn-tests/page/8/#comment-505078)
Differential revision: https://code.wildfiregames.com/D4727
Comments by: @Langbart, @marder
Tested by: @Langbart
Fixes #6580

Event Timeline

wowgetoffyourcellphone raised a concern with this commit.Jul 2 2022, 3:44 AM

ERROR: Error in timer on entity 2409, IID105, function TimerHandler: TypeError: Engine.QueryInterface(...) is null UnitAI.prototype.RespondToTargetedEntities@simulation/components/UnitAI.js:5048:17 UnitAI.prototype.AttackEntitiesByPreference@simulation/components/UnitAI_DE.js:89:14 UnitAI.prototype.FindNewTargets@simulation/components/UnitAI.js:5994:14 Timer@simulation/components/UnitAI.js:1677:14 FSM.prototype.ProcessMessage@globalscripts/FSM.js:265:17 UnitAI.prototype.TimerHandler@simulation/components/UnitAI.js:4229:15 Timer.prototype.OnUpdate@simulation/components/Timer.js:139:44

ERROR: JavaScript error: gui/session/selection.js line 500 GetEntityState(...) is null EntitySelection.prototype.addFormationMembers@gui/session/selection.js:500:39 EntitySelection.prototype.setHighlightList@gui/session/selection.js:433:20 handleInputAfterGui@gui/session/input.js:821:17

This commit now has outstanding concerns.Jul 2 2022, 3:44 AM
Freagarach added a comment.EditedJul 2 2022, 7:30 AM

Can you attach a replay, please? :)

Freagarach added inline comments.Jul 3 2022, 8:33 AM

Ah, I see. I totally forgot to remove the other members here. ^^'
See also #6583.

Freagarach requested verification of this commit.Jul 4 2022, 7:07 AM
This commit now requires verification by auditors.Jul 4 2022, 7:07 AM
All concerns with this commit have now been addressed.Jul 6 2022, 4:59 PM