light control blueprint issue

Hi! I created a light blueprint included a lamp object and a point light. Then I created a billboard blueprint as a light switch. In billboard blueprint, I created a Actor variable for object reference for Cast to the lamp blueprint.
after all, event I switch the light on or off, the light still on. Please help!!!

Where are you storing the ‘Night Time’ boolean variable? Have you tried the same node setup in a function within the lamp, to make sure that your ‘Set Intensity’ nodes are correctly targeting the light?

Night Time variable is set in BillBoard blueprint. The reason I use Billboard blueprint cuz there are many lights and other setting needs to be change when switching between day time and night time. So I want one button to do all the works.

If I put the codes in the lamps’ blueprint like this. Then put the billboard blueprint into the scene. Will it works?

What’s your light’s mode?

Static or moveable?

static static

can someone show me how the codes should looks like, especially about object reference? Because I’m guessing the problem object reference is the problem.

Even I try this is not working at all. How to call a blueprint from another blueprint like this?

Is there anything in your Object R? If you just create a variable that is type of other blueprint the variable is “empty” just a hollow shell. You need to fill it with actor.

If you want to call blueprint from another blueprint you can use “get all actors of class” and then loop the actors and use variable or something so you know you got the right actor. After that you can do what ever you like with the actors variables or actor itself.

You can use this method if both of your actors are placed in game: Go to your first blueprint and create a variable that is a type of the other blueprint. Then you set that variable to be public. After that you go to your main view, click the first actor and in the right side where all the settings are you select the variable you just made public, press the pipet tool and press the other actor. Now when you are in the blueprint you can get the variable and you can do what ever you want with the variables that specific blueprint have.

You should change ligt mode to ‘Moveable’.

I tried and it works.

yes! Thank you guys! The “Get all actors of class” works. But one quick question. I’m setting this in Construction Script for beginning b4 the game start, why doesn’t work for static light, have to use stationary or movable light?


Static ligts are works with ligtmaps.

Lightmaps can’t change in real time.