From 37afae20715625990105a36db1c384b3ba16971b Mon Sep 17 00:00:00 2001 From: Sara Date: Sun, 5 Jan 2025 23:33:01 +0100 Subject: [PATCH] feat: increased random modifier to enemy update interval --- src/enemy.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/enemy.cpp b/src/enemy.cpp index fdf8f41..9ab40b9 100644 --- a/src/enemy.cpp +++ b/src/enemy.cpp @@ -17,7 +17,7 @@ void Enemy::_ready() { // set up the timer used to reduce process time gd::Timer *timer{memnew(gd::Timer)}; this->add_child(timer); - timer->start(this->update_interval); + timer->start(this->update_interval + this->update_interval * gd::UtilityFunctions::randf_range(0.0f, 0.25f)); timer->connect("timeout", callable_mp(this, &Enemy::update)); // starting target rotation is just the current rotation this->target_rotation = this->get_rotation().y;