Resseting a button before release.

Hello.

Let’s say I have a button that the player presses and holds.
Is there a way to make it unpressed (reset it’s state to default), other than by releasing a mouse button.
I have a function that checks some variables every tick as long as the button is pressed. I would like to reset it when specified criteria are met without executing the “on released” event.
I know I can just have a branch as a first node of the “on released” event and do nothing but it still only half of a problem, because the button will appear pressed as long as the player is holding the mouse button and I would like to cancel that.

Thanks for help.