Boss fight now has combat stats and damage so I can now have a boss fight.

This commit is contained in:
Zed A. Shaw 2025-11-22 00:50:47 -05:00
parent 8ee3e8736f
commit 63a17d7efa
7 changed files with 58 additions and 9 deletions

View file

@ -46,7 +46,7 @@ namespace boss {
dbc::check(world->has<ai::EntityAI>(boss_id), "boss doesn't have an AI");
return make_shared<boss::Fight>(world, boss_id);
return make_shared<boss::Fight>(world, boss_id, level.player);
}
void System::combat(std::shared_ptr<DinkyECS::World> world, DinkyECS::Entity boss_id, int attack_id) {
@ -55,8 +55,8 @@ namespace boss {
dbc::check(world->has<ai::EntityAI>(boss_id), "boss doesn't have an AI");
auto& player_combat = world->get<Combat>(level.player);
auto& boss_ai = world->get<ai::EntityAI>(boss_id);
auto& boss_combat = world->get<Combat>(boss_id);
auto& boss_ai = world->get<ai::EntityAI>(boss_id);
combat::BattleEngine battle;
battle.add_enemy({boss_id, boss_ai, boss_combat});