diff options
author | WBoerenkamps <wrj.boerenkamps@student.avans.nl> | 2025-01-10 14:07:30 +0100 |
---|---|---|
committer | WBoerenkamps <wrj.boerenkamps@student.avans.nl> | 2025-01-10 14:07:30 +0100 |
commit | d7c8cc30e1d37526cf142f950038500b96760514 (patch) | |
tree | 4f8d6c60f33855eda9833c3a24e9ef810014b44d /game | |
parent | 22d77b99d700e6317a7432e475330e4bb3c9745d (diff) |
balance changes
Diffstat (limited to 'game')
-rw-r--r-- | game/enemy/EnemyScript.cpp | 4 | ||||
-rw-r--r-- | game/scheduler/ObjectsScheduler.cpp | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/game/enemy/EnemyScript.cpp b/game/enemy/EnemyScript.cpp index 24583c0..0822c29 100644 --- a/game/enemy/EnemyScript.cpp +++ b/game/enemy/EnemyScript.cpp @@ -19,7 +19,7 @@ using namespace std; EnemyScript::EnemyScript() { engine.seed(rd()); this->last_fired = std::chrono::steady_clock::now(); - this->shot_delay = std::chrono::duration<float>(3 + Random::f(1, 0)); + this->shot_delay = std::chrono::duration<float>(1.5 + Random::f(2, 0)); } void EnemyScript::init() { Metadata & meta = this->get_component<Metadata>(); @@ -72,7 +72,7 @@ void EnemyScript::fixed_update(duration_t dt) { if (elapsed > shot_delay) { this->shoot(transform.position); last_fired = now; - this->shot_delay = std::chrono::duration<float>(Random::f(4, 1.5)); + this->shot_delay = std::chrono::duration<float>(Random::f(3, 1.5)); } } diff --git a/game/scheduler/ObjectsScheduler.cpp b/game/scheduler/ObjectsScheduler.cpp index 816e1ee..c33c707 100644 --- a/game/scheduler/ObjectsScheduler.cpp +++ b/game/scheduler/ObjectsScheduler.cpp @@ -16,7 +16,7 @@ void ObjectsScheduler::preset_0() { trigger_event<MissileSpawnEvent>(MissileSpawnEvent {}); trigger_event<MissileSpawnEvent>(MissileSpawnEvent {}); this->trigger_event<BattleStartEvent>(BattleStartEvent { - .num_enemies = Random::i(2, 1), + .num_enemies = Random::i(2, 0), .battle = false, }); } @@ -40,7 +40,7 @@ void ObjectsScheduler::boss_fight_1() { this->get_components_by_name<Rigidbody>("camera").front().get().data.linear_velocity.x = 0; this->get_components_by_name<Rigidbody>("player").front().get().data.linear_velocity.x = 0; this->trigger_event<BattleStartEvent>(BattleStartEvent { - .num_enemies = 7, + .num_enemies = 5, .battle = true, }); |