RG31 modules cause infinite loop (Satcom, Boomerang, Duke)
Closed, ResolvedPublic

Description

All 3 modules have same code structure and are mostly identical,
(e.g. CUP\WheeledVehicles\CUP_WheeledVehicles_RG31\modules\crewduke\sys_duke_animate.sqf)
The problem is they recursively call themselves after the vehicle is destroyed. (the execVM line at the bottom)
To see the problem just add some debug output into the file

_car = _this select 0;

_car animate ["SYS_satcom", 0];
systemChat "animate 0";

waitUntil {!alive _car};

_car animate ["SYS_satcom", 1];
systemChat "animate 1";

waitUntil {!(isNull _car)};

[_car] execVM "test.sqf";

Once car is destroyed, both waitUntils will return true, so it will animate 0,1,0,1,0.... with no delay
If car is deleted, the 2nd waitUntil will pause (but script still be running on the scheduler)

Easy fix is just remove the 2nd waitUntil and execVM at the bottom

Details

Commits
Restricted Diffusion Commit
Affected classnames
CUP_satcom, CUP_crewduke, CUP_boomerang
Chairborne triaged this task as High priority.Oct 20 2017, 6:52 PM
Chairborne added a subscriber: Chairborne.

These arent really maintained, they should either get fixed or nuked.

Chairborne added a project: Restricted Project.Oct 20 2017, 6:52 PM

I think nuking these would be best, all it really did was add some visual changes to the vehicle so we could really replace this with the virtual garage feature.

No, don't nuke them, because missions using them will no longer work. Instead, make them scope=1 and move the animations to the VhC.

Deltagamer closed this task as Resolved by committing Restricted Diffusion Commit.Feb 22 2018, 10:54 PM
Deltagamer added a commit: Restricted Diffusion Commit.