[205.024] Planetary encounters can spawn inside dynamic entities (grids, asteroids, trees)

Digi shared this bug 3 days ago
Submitted

Az4NJKp


You can tell from the gigantic grid spam that I did it intentionally =) but it did spawn by itself inside that grid spam, the grids were there before the encounter.


It would really suck if someone's landed ship or rover or anything that is not static got destroyed like this.


The spawn could do a simple check for entities within the radius of the prefab, it could delete floating objects if present and reroll if it hits a grid or character or asteroid (boulders), and of course ignore the planet itself.


To reproduce I changed PlanetaryEncounterDesiredSpawnRange to 1 and PlanetaryEncounterTimerMin/Max to 1 as well in sandbox_config.sbc, went to a snowy area, littered the place with gigantic wheeled grids so they'd land safely, and sat on the terrain in the middle (at 1m you pretty much have to be on the terrain to trigger any spawns).

The radius of the spawned thing gets added to the radius so it won't spawn directly on you. Use spec cam to get an idea of the radius they'll spawn away from you and sprinkle more grids.

Replies (1)

photo
1

lol, but tbh. that does not really suprise me at all as the config parameter is called PlanetaryEncounterExistingStructuresRange and Structures usually refer to static grids.

photo
1

Yes and that is fine, the setting should not be including dynamic grids either because flying around in a ship would prevent you from ever spawning any encounters =)

What this needs to do is not something admins should be configuring, it needs to use the prefab's boundingbox/sphere if there's something there, they already are storing that and using it for other things in regards to the spawning, but they're not checking if the area is free.


Although there is code for checking trees, it has some bugs as well.

photo
Leave a Comment
 
Attach a file