Obstacles shared between pathfinding objects

Report Construct 2 bugs here.

Post » Sun Oct 27, 2013 11:49 am

Link to .capx file (required!): capx


Steps to reproduce:
1. Run the layout
2. Disable the add obstacle event and run layout again

Observed result:

Both objects move the same way around the obstacle, while only one of them has obstacle added.

Expected result:

The other object should go through the obstacle. This is fixed when objects have separate cell sizes.

Manual quote :     "For best efficiency, use the same cell size and border for all objects using the Pathfinding behavior in a layout. If different objects use different values, then the Pathfinding behavior must generate multiple obstacle grids in memory, and pathfind along them separately."

Changing cell size is poor mans fix to have them generate separate obstacle maps, but as mentioned in the manual this can have performance implications.


Browsers affected:
Chrome: yes

Operating system & service pack:
Win 7

Construct 2 version:
r148
B
24
S
9
G
7
Posts: 756
Reputation: 7,312

Return to Bugs

Who is online

Users browsing this forum: No registered users and 0 guests