Conversation
Switch to getLighting so the night check is based on light levels instead of sound controller
|
Hmm. Testing indicated that units on headless clients may have problems. HC reports different value for getLighting. It is possible to use getLightingAt, but that is actually slower than getEnvSoundController . |
Does it work on dedi servers? If it does, then this sounds like a HC bug |
|
Tested on dedicated server environment. Both server and HC had units spawned on it. I'll give it another test in a 'live' mission too. |
|
Server reported correct values. Only HC struggled. Wonder if there is some silliness about the location of the HC too. |
|
location about the hc unit should only affect update rates iirc. can always bother dedmen in the arma discord. |
this is a "global" value getter not a local one. so I expect that there is some issue related to how HCs are handled. this should be reported to to BI/dedmen |
|
Feedback tracker ticket: https://feedback.bistudio.com/T178396 |
When merged this pull request will: Utilise
getLightingto check if it's nightUtilise
getLightingso the night check is based off of the amount of light instead of a soundcontroller. This might be an important distinction in cases where the night is really bright, due to midnight sun or the full moon.~65 is the approximate light level where AI uses nightvision. Tested on Stratis (2035/07/06 YYYY/MM/DD) with vanilla AI.
getEnvSoundControllertogetLighting