Indicate overlapping workareas while placing a constructionsite

Bug #1826504 reported by GunChleoc on 2019-04-26
This bug affects 1 person
Affects Status Importance Assigned to Milestone

Bug Description

While placing a construction site, indicate whether its workarea overlaps with another workarea, so that the player will know that a forester will plant trees on a farm's field spots, for example.

This could be done by giving the overlapping parts of the workarea overlay a different color, e.g. red.

Forum discussion:

Related branches

Benedikt Straub (nordfriese) wrote :

I see a potential problem here: Since workareas can theoretically have any radius, we will need to iterate over all buildings of the player on the map to check for overlaps. That may be slow. Do we want to define a constant X so that a building with overlapping workarea will be ignored if it is further than X away from the new site?

Should we also indicate overlaps with buildings of other players if they are visible? (Useful e.g. for militarysites)

Changed in widelands:
assignee: nobody → Benedikt Straub (nordfriese)
milestone: none → build21-rc1
status: Confirmed → In Progress
GunChleoc (gunchleoc) wrote :

The tribes have the workarea information for each building. So, we could calculate a maximum workarea value when loading the tribes and use that as a radius for surrounding buildings.

GunChleoc (gunchleoc) on 2019-05-18
Changed in widelands:
status: In Progress → Fix Committed
assignee: Benedikt Straub (nordfriese) → nobody
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers