Page MenuHomeFeedback Tracker

enableGunLights issues
Closed, ResolvedPublic

Description

Stable ver. Arma 3 and no mods.
First issue: when executing a command for a group, not all members turn on their flashlights
Second issue: apparently command does not work for the player(s)

Details

Severity
Minor
Resolution
Open
Reproducibility
Always
Operating System
Windows 10 x64
Operating System Version
2004
Category
Scripting
Steps To Reproduce
  1. Create group with flashlights on primary weapon
  2. Start mission
  3. Execute {_x enableGunLights "forceOn"} forEach (units group player); using Debug Console. Next "forceOff" and again "forceOn" several times.

or

  1. Start mission
  2. Execute player enableGunLights "forceOn" using Debug Console
Additional Information

Demonstration video:

Event Timeline

TRAGER created this task.Nov 3 2020, 7:16 AM

There is an issue with this command - that might come from an unscheduled/pause issue:

if (isNil "switchLights") then { switchLights = true };
[] spawn { sleep 0.1; joe enableGunLights (["forceOff", "forceOn"] select switchLights); // works with a timer, 100%
joe enableGunLights (["forceOff", "forceOn"] select switchLights); // doesn't work well 
switchLights = !switchLights;

↑ this applied to a full AI group whose leader is named joe.

BIS_fnc_KK changed the task status from New to Need More Info.EditedJul 6 2021, 12:24 PM

@LouMontana Could you make a copy paste repro plz? no spawn just unscheduled fail

Second issue: apparently command does not work for the player(s)

Intended, you can use action command for that

BIS_fnc_KK changed the task status from Need More Info to Feedback.Jul 6 2021, 4:05 PM

Revision: 147857

BIS_fnc_KK removed BIS_fnc_KK as the assignee of this task.Jul 6 2021, 4:05 PM
BIS_fnc_KK added a subscriber: BIS_fnc_KK.
Tenshi added a subscriber: Tenshi.Jul 7 2021, 11:36 AM
This comment was removed by Tenshi.
TRAGER added a comment.Jul 8 2021, 2:21 PM

Arma 3 ver.147859
4 attempts and successful all, I guess can be closed as resolved

What happens if you use _unit enableGunLights "forceOn"; during the day and later the night falls. (Do they turn the flashlights ON automatically or you have to issue the command again at night for it to work?)

Tenshi closed this task as Resolved.Jul 14 2021, 10:05 AM
Tenshi claimed this task.

Issue seems solved indeed!
and if you use

{_x enableGunLights "forceOn"} forEach (units group player);

during the day it will just make the lights auto turn on when nightfalls.

Issue seems solved indeed!
and if you use

{_x enableGunLights "forceOn"} forEach (units group player);

during the day it will just make the lights auto turn on when nightfalls.

That is great! Well done!

Now I am having the same old issue with
_helicopter setCollisionLight true;

It works if I run the command at night but not if run during the day. I mean the night will come and the aircraft still won't turn its collision lights ON. Perhaps we also need a "forceON" option for collision lights too.