Closed darkautism closed 1 week ago
Need this patch: https://github.com/mapeditor/rs-tiled/pull/313
Do not fix #41 . If you want to flip the Y axis, do it independently.
Also fix IsoCoordSystem::Diamond
Hi!
Thanks for the PR and the example to reproduce the issue. Actually, it seems we have an issue with colliders from tiles for hex and iso maps. We only tested colliders from objects, not from tiles. Now I understand your issue.
Regarding your code:
hexside_length
. Have a look to https://github.com/adrien-bon/bevy_ecs_tiled/blob/main/src/loader.rs#L864. I'm not good at math (and I did not check yours thoroughly) but if we can it would be nice to unify how we handle objects (previous link) and tiles so we only have one "math" function for bothdebug_render
is a nice addition but it should go in the debug pluginI pushed an update to your PR in order to re-use the example assets from the repo instead of yours. Unfortunately, it seems your fix does not work with them.
FYI I just updated both hex_map
and isometric_map
examples.
You just have to run them with either avian
or rapier
feature enable:
cargo run --example isometric_map --features=avian
cargo run --example hex_map --features=avian
Could you please have a look and fix the maths so these examples work ?
This patch fix the tile collider not object collider. I think this is helpful: https://bevyengine.org/examples/animation/custom-skinned-mesh/
This patch fix the tile collider not object collider.
Yes I know what you want to fix here. What I am saying is that when I add tile colliders to the existing examples in the repo your fix does not work. For instance, in the 1st screenshot,tile colliders should be on the mountain. Not to their left.
I think this is helpful: https://bevyengine.org/examples/animation/custom-skinned-mesh/
Not sure what do you mean ?
According to #32, these object deformers not only have incorrect positions, they also need to be deformed.
Here we are trying to fix tile colliders not having a correct position, both for hexagonal and isometric maps. As I said, I think the maths you added do not fix the tile collider position issue. Please, have a look to the screenshot I posted (there is an issue with hexagonal maps too, not only isometric).
If we reach in this PR a status where tile colliders have the correct position but not the proper shape for isometric maps I'll consider it done and that the shape issue will be fixed in #32.
I'm closing this PR since the tile colliders positionning issue is now fixed in v0.4.0.
Fix Hexagon colider bugs