godot-xr-tools
godot-xr-tools copied to clipboard
XRToolsInteractableAreaButton animation ignore node process mode and is always pausable
I use XRToolsInteractableAreaButton on my pause menu and it occured XRToolsInteractableAreaButton don't animate if the scene tree is paused even if the node process mode is set to always.
It's because the animation tweens are created with
# Construct the button animation tween
_tween = get_tree().create_tween()
_tween.set_trans(Tween.TRANS_LINEAR)
_tween.set_ease(Tween.EASE_IN_OUT)
_tween.tween_property(_button, "position", _button_down, duration)
I corrected it by adding :
_tween.bind_node(self)
_tween.set_pause_mode(Tween.TWEEN_PAUSE_BOUND)
in the animation code on the two places before the call to "tween_property".
I'm not sure it doesn't have unseen side effect or if it is desirable for everyone, but I can submit a pull request with the change if desired.