Opened 9 years ago

Last modified 9 years ago

#3532 closed defect

Units can go through obstruction after long-path to the edge — at Version 1

Reported by: elexis Owned by:
Priority: Must Have Milestone: Alpha 19
Component: Core engine Keywords: pathfinding
Cc: Patch:

Description (last modified by elexis)

As reported in #3410, units can go through obstructions. This ticket should deal with one particular case.

http://trac.wildfiregames.com/raw-attachment/ticket/3532/cav_inside_cc.gif

Reproduce:

  1. Issue a walk order to the edge of a building or resource (The goal has to be far enough away so that the long-pathfinder will compute the path)
  2. Once reached that point, issue a walk order to the center of the building.

If you enable the obstruction and pathfinder overlay in the developer menu you will be easier able to see if you selected a long-path and a waypoint that will trigger the error.

Using this recipe you can enter every static obstruction, buildings, resources, but not units and you can also not leave the map.

Notice a second bug: If you get a short-path instead of a long-one, you will not be able to get as close to the obstruction as you should be able to get. The unit will cancel the move earlier.

Change History (5)

by elexis, 9 years ago

Attachment: commands_cav_in_cc.txt added

Replay with only two commands (cavalry inside CC, r17136)

by elexis, 9 years ago

Attachment: commands_infantry_in_cc.txt added

Replay with only two commands (infantry inside CC, r17136)

by elexis, 9 years ago

Attachment: cav_inside_cc.gif added

Replay with the overlays enabled. The blue cell shows the goal of the longpath. Red are impassable cells. The bug is triggered reliably if the target (blue) is a neighboring cell of an impassable one (red).

comment:1 by elexis, 9 years ago

Description: modified (diff)

Notice once the unit has finished the long-path, it is already standing inside the obstruction. The other command makes it only more visible.

Last edited 9 years ago by elexis (previous) (diff)

by elexis, 9 years ago

Attachment: after_longpath.jpg added

The opaque blue square is the goal of the longpath. The blue outlined square is the obstruction of the cavalry. The blue line is the obstruction border of the civic centre. The teal / light blue line is the obstruction of the CC extended outwards by the size (clearance) of the cavalry (here 1). Notice the obstructions intersect significantly.

Note: See TracTickets for help on using tickets.