Blueprint Communications / Interface

Switch lights based on Time of day from a custom blueprint?

Will try to keep things short,

I am using the ‘Ultra_Dynamic_Sky_BP’ which is a custom Sky BP. The ‘Time of the Day’ is stored in a variable with values varying from 0000 to 2400. I need to toggle lights between a certain time frame. So i am trying to fetch the “Time Of the day” value from Sky BP to the Light BP. All tutorials on Blueprint comm and Interface couldnt help with a solution.

Currently I am using a custom function ‘CE Light’ to fetch the value from Sky BP to Light BP. Then using Boolean functions to satisfy the conditions and pass to the multi gate for material change of the light.!

Please help. Excuse if its a Noob Ques.9c625728cafe7ea9f906d56eb0c227338d024f55.jpegb126975b7561e4826b373f7ef308bc8933e000f1.jpeg

Could u show a bit more code?
What i can see is that u dont use CE Light since there is no connection.
On the right picture u should not get any values because CE Light is not called.
Also the AND node has 3 entrys and even if the first 2 are true, the last one isnt so u get false in every case. Delete the third point since u dont use it at all.


Thanks for your reply!

Here is the screenshot of the updated blueprint and the issue persists. 7c83245b93a8f4b2a9692f0c2a37c035c7537cd2.jpeg0f21f87f63164ffb9386179229cd230b62302919.jpeg

the CE light function in the skybox still have no execution pin connected (the white wire) so its never happening.

Also, you could use float in range. and use the bool value to switch the light on and off, no need for a multigate there.