OctoD / godot-gameplay-systems

⚔️ A plugin for Godot to create your gameplay systems in a Godot way.
MIT License
509 stars 49 forks source link

character jitter in PointAndClick2D when movement speed is high🐛 [bug] #53

Open Mostafa137511 opened 3 months ago

Mostafa137511 commented 3 months ago

Describe the bug

when you set the movement_speed too high the Character2D never stops moving and jitters, although NavigationAgent2D is finished navigating.

To Reproduce Steps to reproduce the behavior:

  1. make Character2D move with the simple example the creator provided but set the speed high, for example 2000.
  2. character2D keeps moving

Expected behavior i expected it to stop and not jitter

Screenshots If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

Additional context i solved the problem with editing this part of code in the PointAndClick2D script (edited part in the qoutes): func _physics_process(delta: float) -> void: if not Engine.is_editor_hint() and automatic_movement "and !navigation_agent.is_navigation_finished()": move_to_clicked_position()

Reproducible project Attach a reproducibile project. Otherwise I'll look into the issue when I can.

Mostafa137511 commented 3 months ago

my first time submitting an issue, laugh if you want