0 votes

I have a code that moves and slides the object using JoyStick and I am able t successfully get the result of movement. But when I start the animation using AnimationPlayer the movement suddenly stops. What might I be doing wrong?

Here is the code I am using

 func set_direction_and_smovement_trength(direction, strength):
    var directionForCharacterAxis_Y = -direction - 90
    rotation_degrees.y = directionForCharacterAxis_Y
    strengthOfMovement = strength
    if(strength > 0):

func _physics_process(delta: float) -> void:
    velocity = delta * movementSpeed * strengthOfMovement * transform.basis.z
    move_and_slide(velocity, Vector3.UP)

Also my movement begins when my Animation has finished

Godot version 3.2.3 Stable
in Engine by (12 points)

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.