Event tick: better solution? (controller input)

Hey guys,

I’m setting up a BP to display my UI while I hold down an input. The method I have working is using an event tick to check to see if a gate is open. I’m wondering two things:

  1. Is there a better way to do this. (“Event ticks bad”, after all).

  2. When the gate is closed, does the event tick use up much memory - or is its effect basically nil being that nothing is being executed out of the gate’s exit?


It is not bad, if you truly need to run the trace every tick.

In general, using the input node to gate access to a block works well.

A gate is simply a conditional test using a DoOnce node (double click on it to see it)
Likewise you can view the DoOnce

Thanks! That’s good to know.

I used a custom event and called it ‘StartTimer’. When press “T” on the keyboard (or any input) is Pressed…it sets a variable (is pressed) and it triggers this event. Which then drives a ‘Set Timer by Event’ node. Feed Get World Delta Seconds into the Time of this node ( you will now have an Event Tick that will go for as long as that is pressed variable is positive) I added a delay of .25 after the Set Timer by Event to slow it down a bit, and then anything after that will increment every .25 seconds… UNTIL you release the input, change the Is Pressed variable to off, and then kill the timer which kills the loop. Hope that makes sense.