Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Day/Night Cycle - Lights

Hey Guys,

I hope I'm posting in the right place. Anyway, I have a simple day/night cycle set up that works perfectly, but I can't set it up so that when it turns to night-time, all of the point lights and/or spotlights come on.

Can anybody recommend any solutions? I have attached my BP for reference.

Thanks!alt text

Product Version: UE 4.10
sunques.png (172.3 kB)
more ▼

asked May 10 '16 at 10:19 PM in Rendering

avatar image

8 1 3

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Not 100% certain what you're asking but it seems like you want an idea on how to go about it.

If you use PIE you can check the current rotation of your light source by ejecting/pausing and selecting the light source in the outliner, if you let it rotate to where you consider night time to start, or night time to end, then this will give you those values.

You could additionally have a range, such as at 160-180 degrees it transitions to night time, and map that 160-180 degree range into 0-1 and multiply the light's intensity that comes on during night time by that amount, and the inverse for the lights turning off that were on during the day. I believe blueprints have a "Map Range" node that will do this.

Then on Tick, you would have a branch to check if the rotation is over X amount and under Y amount, and if true then lerp the intensity of the light. For example if the light has an intensity of 0.7 when on, just multiply the 0-1 value by 0.7.

If you want them to simply turn on / off then "Affects World" should do it, otherwise just set the intensity by using a branch checking if the rotation is over X amount and if it's still on, then turn it off.

more ▼

answered May 11 '16 at 12:24 AM

avatar image

601 29 24 52

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question