Page 1 of 1

[1.1.59] collision_mask_util.get_first_unused_layer() doesn’t check tiles

Posted: Sun May 22, 2022 4:27 pm
by Xorimuth
`collision_mask_util.get_first_unused_layer()` doesn’t check for collision masks only used by tiles. If I use it and only assign it to tiles then the next mod that uses it will be given the same layer that I just used.

This obviously causes all sorts of problems and is quite hard to diagnose (in my case it resulted in no resources spawning! I assigned the layer to all non-shallow-water tiles and cargo-ships gets the same layer and assigns it to all resource entities..).

This is very hard to work around without hard coding in a high collision layer and hoping that it doesn’t collide with any other mods - the very problem this library is intended to avoid!

Re: [1.1.59] collision_mask_util.get_first_unused_layer() doesn’t check tiles

Posted: Mon Jun 06, 2022 2:39 pm
by Xorimuth
Thanks for the report. It's now fixed for the next release. (1.1.60)