How to turn off a light completely by pressing a key, only while being inside a collision volume near it ?
Hi. I am working on a survival game, in which my character can turn off a light completely by pressing a key, only while being inside a collision volume near it.
I have made a blueprint. What I'm trying to do is to toggle visibility, as long as both boolean variables are true.
So... my character goes and enters volume. "Is globe overlapped" variable is set to true. The branch node sees in condition that only one variable is set to true, so it shouldn't fire. If I press the F key, the second boolean variable, "Is globe taken" is also set to true, so the branch sees that both are set to true so it fires. This is the logic I tought it would work, but it is not working. When I enter the volume, the light toggles on or off. Pressing F key does nothing.
asked Feb 04 '16 at 04:14 PM in Blueprint Scripting
Hopefully, paultech on unrealengine irc chat gave me the answer. I'll post it here for reference and for others who might have the same problem.
He said that overlap might have been tiny (the collision on the static mesh). He created a separate sphere collision.
answered Feb 04 '16 at 05:04 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here