Community Forum

SunAdmirer

Forum Overview >> Scripting

CategoryScripting
Created04.06.2017 17:14


Dean Rude (rude1957) 04.06.2017 17:14
I was wondering if it is possible to change the times that objects that have the SunAdmirer.onCreate, appear and disappear?

Emil Drefers (Unknown) 06.06.2017 07:31
Hi,

it is possible by adjusting the "environment", but doing so has an influence on more things than just the SunAdmirer.
But, as always, you could overwrite the SunAdmirer.

The original function looks like this:

function SunAdmirer:weatherChanged()
setVisibility(self.id, g_currentMission.environment.isSunOn and g_currentMission.environment.currentRain == nil);
end;

Cheers,
Emil

Dean Rude (rude1957) 06.06.2017 12:34
Thanks very much, I'll do some experimenting and see what happens. Dean...




Note: Log in to post. Create a new account here.