fix: changed get_is_health_safe to use integer division ipv float division

This commit is contained in:
Sara 2024-09-09 21:24:17 +02:00
parent a2863006f7
commit a5bde58e57

View file

@ -116,7 +116,7 @@ bool UnitWorldState::get_is_in_range() const {
}
bool UnitWorldState::get_is_health_safe() const {
return float(this->health->get_injury_current()) > (float(this->health->get_injury_max()) / 2.f);
return this->health->get_injury_current() > this->health->get_injury_max() / 2;
}
gd::Vector3 UnitWorldState::get_parent_global_position() const {