OFPEC Forum
Editors Depot - Mission Editing and Scripting => Arma2 - Editing/Scripting General => Topic started by: DMarkwick on 03 Sep 2009, 10:53:23
-
Is there any way to get information on the sun's position? i.e. height or angle?
-
Maybe, in theory.
It seems that the sun is sun.p3d (as far as I can tell) so in theory you might be able to find it with some of the nearestObject commands (like you find the trees I guess) and then calculate stuff with that data..
I doubt it's any way feasible though since you would have to search for the whole island area for the sun and that causes your search results to be in the hundreds of thousands of objects.. :dunno:
-
Based solely on gameplay, it seems as though there is some "trigger" (not like a script-trigger) that tells AI when they need to use NV goggles. Any idea how that is accomplished? Or get the current ambient lighting parameters? I believe the notoriously circumspect DM is interested in figuring out how near to sunrise and sunset it is, when those times can vary by a couple hours depending on the season. :)
I have found the lightIsOn query, but that kind of binary result is pretty heavy-handed.
-
That's actually a very good point T, I hadn't considered the NV goggles or lights logic.