[PATCH] Improvements to obstructions
|Reported by:||stanislas69||Owned by:|
Description (last modified by )
There are several improvements that could be made wrt obstructions:
- Allow circular static obstructions:
Some buildings are circular, and it's weird that the ability to place them sometimes depends on the angle. If you check the stonehenge wonder f.e., the invisible corners are very big.
All wall towers should also have circular obstructions as the player can't determine the rotation of the first tower (but the rotation of the first tower is determined by the angle of the wall). So when starting a wall-piece in the direction you want, it can either obstruct the tower, or create a gap because the obstruction gets rotated.
Since the obstructions are always rasterized, it shouldn't be very calculation intensive to support circular static obstructions (just adding a check in the rasterization loop).
- It should be possible to overlay different obstruction types on one template
Most buildings aren't made to serve as a wall. So passages should be guaranteed between them. This would be possible by overlaying two different obstructions:
- An obstruction that blocks pathfinding, so units don't walk through the building
- A bigger obstruction that blocks construction, so buildings can't be placed close enough, and units can always pass.
The gap between two buildings should be wide enough so units can actually cross in that gap.
Walls on the other hand are in a different situation, and should probably block more pathfinding than they block construction, so they can create a certain obstruction overlap, and block all units with certainty. This may be a bit more difficult to achieve.
Note that these double obstructions seem already possible, since it's done with the gate (a gate has 3 obstructions, of which the center one can be made passable but not be constructed on). So I guess it mainly misses a way to put this into the schema.
Together, this should fix most issues with wall-placement, make building placement more relaxing, but also help fixing issues like #3517 (due to the guaranteed gap).
Change History (18)
comment:1 by , 5 years ago
|Summary:||Can't build straight walls over obstruction → Improvements to obstructions|
|Type:||defect → enhancement|
comment:2 by , 5 years ago
|Keywords:||patch review added; pathfinding removed|
|Milestone:||Backlog → Alpha 21|
comment:7 by , 5 years ago
|Summary:||Improvements to obstructions → [PATCH] Improvements to obstructions|