Apologies in advance, I’ve tried a couple of tutorials but I can’t seem to retro fit code to use in my game.
I have a day cycle[from tutorial] that checks the angle of rotation and when the rotation hits a certain angle I started a new day.
Lots of things are meant to trigger on a new day so here is the logic.
- New day logic [I created a event dispatcher in this Level BP and when the new day is set I connect the “Call New Dat” ] , In my head this means that things can now listen out for a “new day” event.
- Making things “listen” [ I imagine this needs to be on a recurring period unless I just need to fire it once. For now I just want to use the event tick on another BP. So in my head to code should be something like on tick → check if even fired → if it did run a function etc.
My BP where I bind is different to the Player controller BP where the event dispatcher is.
I’ve tried a couple of options on the bind but it seems to just call on every tick and not just when the event is dispatched.
I’ve tried creating a custom event… * time passes*
I figured it out, premo.
So unchecked the context box. Added reference to player controller, then grabbed dispatch “bind event” and then created custom event. I didn’t connect the bind event to anything but the custom event is connected to a print and it prints ever time the day changes. Pretty cool!
TIA