EarendelDevelopers / factorio-mods

This is a public repository for tracking issues with Earendel's factorio mods.
19 stars 3 forks source link

Spaceship landing collision detection is overzealous when checking core seams #223

Open BurninSun opened 2 years ago

BurninSun commented 2 years ago

This ship is unable to land even though visually it should easily be able to. Assuming its because the collision check just squares off the whole spaceship to do the check.

image

InappropriatePenguin commented 2 years ago

I don't think this is fixable. We have to use a bounding box for the find_entities_filtered calls that we make to look for special entities that we don't want you to land on.

Breaking down a ship into multiple areas isn't an option either. Aside from the added complexity, we'd have to repeat find_entities_filtered calls for each area, which would be quite bad for performance.

InappropriatePenguin commented 2 years ago

I took another look, and it seems like we're already doing the inefficient thing I was describing for all other non-special entities. I'm not sure why both approaches are used for different searches. That does at least make this feasible to add. I'll just have to do some profiling to be sure.