Opened 6 years ago

Last modified 6 years ago

#5090 new enhancement

CityPainter improvements

Reported by: elexis Owned by:
Priority: Nice to Have Milestone: Backlog
Component: Maps Keywords:
Cc: Patch:

Description

Proposed improvements for the CityPainter from #5061 used in Jebel Barkal:

  • Buildings should face the path, so that (1) spawned units are spawned on the path and don't become trapped between buildings and (2) the city itself looks visually more appealing
  • Collision tests should be more precise than 1 terrain tile. As of r21598 we only pass 0 distances between the buildings, but in almost all cases there is at least 1 tile distance between buildings due to the imprecision.

Attachments (3)

align.jpg (530.6 KB ) - added by elexis 6 years ago.
meh.patch (10.7 KB ) - added by elexis 6 years ago.
43_useless_paths_per_turn.jpg (897.2 KB ) - added by elexis 6 years ago.

Download all attachments as: .zip

Change History (7)

by elexis, 6 years ago

Attachment: align.jpg added

comment:1 by elexis, 6 years ago

https://trac.wildfiregames.com/raw-attachment/ticket/5090/align.jpg

by elexis, 6 years ago

Attachment: meh.patch added

comment:2 by elexis, 6 years ago

The uploaded patch implements an option to let buildings at the border of the area face towards the border.

This is important for two reasons, in particular on Jebel Barkal:

  • Visually: the entrance of the building should be at the path of the city
  • Pathfinding bugs when spawning: Units can become trapped between buildings if they aren't spawned on the path at the border of the area.

The patch however has crucial issues:

  • Very slow (minutes)
  • No more large buildings placed on Jebel Barkal at all, because all buildings are at the border, all buildings have a forced orientation and that doesn't simply fit always.

The patch also fixes a different bug: Only two of the 4 possible 90° angles actually occur as the buildings aren't rotated around their center.

comment:3 by elexis, 6 years ago

In 21611:

Reduce pathfinding lag on Jebel Barkal a bit by using actor palms in the city (preventing units in formation from becoming locked in at the spawn point).

Preferably, the buildings should be rotated so that they face the path, refs #5090.
Start attacks again in case a player dared to rebuild a CC.
Fix missing negation in rP21609.
Variable naming consistency.

by elexis, 6 years ago

comment:4 by elexis, 6 years ago

Not rotating buildings correctly means computing 43 paths per turn uselessly per occurrence of the bug:

https://trac.wildfiregames.com/raw-attachment/ticket/5090/43_useless_paths_per_turn.jpg

Note: See TracTickets for help on using tickets.