mirror of
https://github.com/Relintai/godot-steering-ai-framework.git
synced 2024-11-14 04:57:19 +01:00
Fix bug using wrong random number generator
This commit is contained in:
parent
dffec9efa6
commit
0a21aaf3fc
@ -45,7 +45,7 @@ func setup(
|
||||
rng: RandomNumberGenerator
|
||||
) -> void:
|
||||
rng.randomize()
|
||||
_direction = Vector2(rand_range(-1, 1), rand_range(-1, 1)).normalized()
|
||||
_direction = Vector2(rng.randf_range(-1, 1), rng.randf_range(-1, 1)).normalized()
|
||||
_update_agent()
|
||||
agent.max_linear_speed = max_linear_speed
|
||||
agent.max_linear_acceleration = max_linear_accel
|
||||
|
Loading…
Reference in New Issue
Block a user