feat: basic arrow shoot event

This commit is contained in:
2021-09-29 14:48:25 +02:00
parent 9cf3916951
commit ef76437670
8 changed files with 25 additions and 14 deletions

View File

@@ -457,6 +457,15 @@ void World::cleanDeadMobs(){
}
}
void World::OnArrowShot(MobPtr target, Tower* shooter){
bool explosiveArrows = shooter->getLevel().getPath() == TowerPath::Bottom;
if(explosiveArrows){
// aoe damage
}else{
target->damage(shooter->getStats()->getDamage());
}
}
Team& World::getRedTeam() {
return m_Game->getRedTeam();
}