Bug Closed · Resolved

Projectile item type mechanic spawning a massive amount of items after hitting a target

#2230 opened by Unknown 4 years ago

Unknownreported this bug

I tried to make a projectile that repeats himself 5 times with an interval of 1 tick, after hitting a Pillager with it, it started spawning a massive amount of pink wool items, (my projectile was a pink wool item type) and basically crashed my server because of the ridiculous amount of entities.

Also an error appeared in my log, here's the pastebin: https://pastebin.com/9yYKax4Y

And if you wanna check my skill, it's fine but anyways here it is too: https://pastebin.com/wWG9YRTn

Unknowncommented

Is a mob casting this skill or a player?

Unknowncommented

A player. Also, after testing a little more, I noticed that happens even with not repeat thing, but it looks like it's way more common when the projectile repeats itself. But as I said, I tried using it with no repeat and happened the same.

Additional useful info:

Shooted agaisnt a Llama and a Pillager and a friend of mine had the same error in another server.

Unknowncommented

Yeah, your issue is exponential recursion with the last line in RanaTongue-HIT. When the skill pulls the target, the target gets hit again and again with the projectile from RanaTongue-HIT, causing it to lag your server. I suggest removing the projectile mechanic entirely from your onHit skill.

Unknowncommented

It doesn't have anything to do with that, as it spawns a lot of item entities, not projectiles, and the projectile comes right to me. Even if I delete that, the bug it's still present.

Sign in to join the discussion.