Environmental Nodes

Tips and discussion about scenery creation for RailWorks.

Environmental Nodes

Unread postby JerryC » Sat Apr 09, 2016 8:16 am

I already know that you can specify a particular node (part) in an Asset to show during the day or night by naming the object fx_day or fx_night. Does anyone know if you can also do this with environmental variables? Some thing like having the object only show when it's raining? (fx_rain?)
JerryC
 

Re: Environmental Nodes

Unread postby mrennie » Sat Apr 09, 2016 9:19 am

JerryC wrote:I already know that you can specify a particular node (part) in an Asset to show during the day or night by naming the object fx_day or fx_night. Does anyone know if you can also do this with environmental variables? Some thing like having the object only show when it's raining? (fx_rain?)


Not as far as I know, but I used nodes textured with weather effects to create rain droplets on the outside of the cab windows in the FEF-3. In the script, I make these calls to see if it's raining:

Code: Select all
         
                        local PrecipitationType = SysCall("WeatherController:GetCurrentPrecipitationType")
         -- 0 = rain or clear, 1 = sleet, 2 = hail, 3 = snow
         
         local PrecipitationDensity = SysCall("WeatherController:GetPrecipitationDensity")
         -- 0 = none, 0.5 = rainy, 1.0 = stormy


Then it's just a matter of activating or deactivating the outside rain nodes accordingly, although there is also the complication of having to deactivate the outside ones when you're in cab view.
User avatar
mrennie
 
Posts: 3214
Joined: Wed May 30, 2012 12:22 pm

Re: Environmental Nodes

Unread postby JerryC » Sat Apr 09, 2016 11:36 am

That is a step in the right direction. The node that i'm targeting is "photosensitive", so it would switch on under darker conditions such as storm or fog. The node is not on the locomotive though, so I also have to call the car it is on.

Thanks!
JerryC
 


Return to Scenery Design

Who is online

Users browsing this forum: No registered users and 1 guest