Jump to content

"testforshark" function in components/schoolspawner.lua checks for entities with "gnarwail" tag


Hornete
  • Fixed
local function testforshark(comp, spawnpoint)
    local ents = TheSim:FindEntities(spawnpoint.x, spawnpoint.y, spawnpoint.z, TUNING.SHARK_TEST_RADIUS, GNARWAIL_TAGS)
    if #ents < 2 and math.random() < TUNING.SHARK_SPAWN_CHANCE then

The testforshark function in components/schoolspawner.lua checks for other entities with the "gnarwail" tag for its check. This strikes odd to me because you'd think it'd check for other entities with the "shark" tag instead right? So it doesn't spawn another shark if there's two other sharks in the area, but instead it checks for gnarwails. This means theoretically an infinite amount of sharks can keep spawning in one area (Of course, practically that won't actually happen)

I report this because I had four sharks spawn in the span of a minute just a few days ago while sailing with someone else, and that seems very unintentional and just plain unfair.

my glommer died from one of these sharks please fix it : (


Steps to Reproduce

1. Look at components/schoolspawner.lua file
2. Notice in the "testforshark" function it checks for entities with the gnarwail tag, not the shark tag

  • Like 1
  • Ninja 1
  • Wavey 1



User Feedback


A developer has marked this issue as fixed. This means that the issue has been addressed in the current development build and will likely be in the next update.

There are no comments to display.



Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
  • Create New...