Turning blueprint on and off by pressing the key

I made hover component as scene component blueprint class, and it works perfectly once added to the vehicle (pawn). Now I want to be able to turn hover on and off by pressing key on the keyboard, and I’ve been trying to find out how to do that for days now and still haven’t figured it out.
Please help :slight_smile:

A simple way would be to add a boolean variable, create a function along the lines of “SetActive” which takes a boolean parameter.

When that function is called update that variable to the new state.

Only do the functionality while your variable is true.

Have your key input feed into a “FlipFlop”. Use the boolean from this FlipFlop to call your “SetActive” function.