fix loc_off_act_area for outdoors

This commit is contained in:
2025-08-08 20:39:59 -05:00
parent ff2e565353
commit 1f8bc4b734

View File

@@ -138,8 +138,9 @@ bool loc_off_world(location p1) {
}
bool loc_off_act_area(location p1) {
if(is_out()) return false; // How should this check be handled?
if((p1.x > univ.town->in_town_rect.left) && (p1.x < univ.town->in_town_rect.right) &&
if(is_out() && univ.out->is_on_map(p1))
return false;
else if((p1.x > univ.town->in_town_rect.left) && (p1.x < univ.town->in_town_rect.right) &&
(p1.y > univ.town->in_town_rect.top) && (p1.y < univ.town->in_town_rect.bottom))
return false;
return true;