GodotVR / godot-xr-tools

Support scenes for AR and VR in Godot
MIT License
471 stars 64 forks source link

Hand pose animation override not working with Godot 4.2 #650

Closed handycz closed 1 day ago

handycz commented 2 days ago

Hand animation override is not working for me when changing the hand pose by GrabPointHand. The game logs error

USER SCRIPT ERROR: Invalid call. Nonexistent function 'remove_animation' in base 'AnimationPlayer'.
    at: XRToolsHand._update_pose (res://addons/godot-xr-tools/hands/hand.gd:346)

Calls to _animation_player.remove_animation(open_name) (and remove_animation(close_name) few lines later) causes the trouble, replacing it by _animation_player.get_animation_library("").remove_animation(open_name) seems to fix the problem.

My knowledge of the framework is pretty low though, I'm not really confident the fix wouldn't break something else.