I’m having trouble getting a blueprint to call a function.
what i have currently is some on screen buttons that, when clicked, move the camera. when I had my code in the button widget it all worked fine but i decided to move the code to the player so that I can use a timeline to make a smooth transition. from what i’ve found i should be able to do this with an event dispatcher but i guess i can’t figure out how they work. the images are of the player blueprint where i have labeled the ‘Print string’ nodes that are working and not working, and the UI blueprint that is calling the event dispatcher.
what am i doing wrong?
Edit: I’m also adding a picture of the blurprint that was working before i moved it off the button click event and onto this event dispatcher.
How on earth do you know which one
you’re binding to?
To the last one in the array. If he’s lucky! No reference, it’s not in the viewport, if the GC kicks in between the ticks, the whole thing comes crashing down:
there is only one actual camera in the scene, it just moves on a button press to another locator i have set up. I’m referring them to cameras which i can see now that would be confusing to anyone but me. if i understand you correctly, your comment should still work but doesn’t unless i set it up wrong. I added more sequence pins to go to the other button press events.
it does! but not for the reason you would expect. I noticed your ‘add to viewport’ for your widget. realized that i was creating an empty widget with the same name as the widget i was trying to use. I have corrected that issue and now everything is working as it should.