Frictional Games Forum (read-only)

Full Version: [solved] Turning lights red then fade
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
i there how can i make some lights (incloding lamps) to turn to red then fade?
Do you mean Light or lamp entities?

If it's a light then you can do this:
Code:
FadeLightTo(string& asLightName, float afR, float afG, float afB, float afA, float afRadius, float afTime)
Example:
FadeLightTo("SpotLight_1", 1, 0, 0, 1, 5, 0.4);

To turn them back, do the same but then another number. To turn them of, do this
Code:
SetLightVisible(string& asLightName, bool abVisible);
Example:
SetLightVisible("SpotLight_1", false);

I don't know what to do with the lamps. There's a red lamp, you could do something with the SetEntityActive script and place 2 of those on eachother. But for other lamps, I really don't know
i kinda meant both but sorry if i didn't write that very well Tongue
(03-23-2011, 01:01 AM)Danarogon Wrote: [ -> ]i kinda meant both but sorry if i didn't write that very well Tongue

oh c*** sorry didn't saw the lower part of the comment =/ oh well i hope i can find a way...
i think i have a problem... a poit light that was supossed tp be unactive well is geting "activated" wend i want =/ because it is already turned on.... i don't undestand...
Putting
SetLightVisible("point_light", false);
At void OnStart() works for me
Yea, even if you default them as unactive, I think they activate when the map loads anyway.
oh i get Smile thanks