My current goal: Monkey-patching the original CharacterBody3D template script to replace CharacterBody3D Input Handling in Godot 4.4
Godot Version
4.4
Question
I would like to know if there is any way to continue development using CharacterBody3D template script or It’s something completely not ready and is not made for further use: I would like to override the default script movement, replacing it by WASD keys and continue thinking on how I would create separate sub-nodes to improve the original. This is mostly to depend on official code and see how much can be done with the original template code.
Currently I’m baffled on how could I use another script to change local variables such as input_dir
and direction
. The only way I know is overwriting the entire func _physics_process
by extending character_body_3d.gd
. Which is surely not what would one want. So how do we change these variables (input_dir
and direction
) by giving control to other script, using another gd script?
CharacterBody3D .gd