Shopkeepers

Shopkeepers

2M Downloads

Shopkeeper + Multiverse-Core = Fall of TPS

Twister1one opened this issue ยท 3 comments

commented

Hi,

  • Shopkeepers version: 2.7.1
  • Spigot version: git-Paper-119 (MC: 1.14.3)

Reproduction on a fresh and up-to-date Spigot server:

I was able to reproduce my issue on a freshly setup and up-to-date Spigot server (currently git-Paper-119 (MC: 1.14.3)) with the latest version of Shopkeepers (currently Shopkeepers version:** 2.7.1`), With a plugin: Multiverse-Core-4.0.0.jar

The issue:

When I create 20 to 30 shopkeepers the GST goes down to 15.
The more I put Shopkeeper, the more the GST will go down.
This bug only works when Multiverse-Core-4.0.0.jar is installed.
If I put Shopkeeper 2.7.1 without Multiverse-Core-4.0.0.jar, the TPS remains at 20.
Likewise, if I put Multiverse-Core-4.0.0.jar without Shopkeeper2.7.1 the TPS remains at 20, when both plugins are together and I have created more than 20 shopkeepers.
Here is a Timings paste:
https://timings.aikar.co/?id=ba7411b367764462bb139e85370ff89d

To reproduce the bug:

  • Install git-Paper-119 (MC: 1.14.3)
  • Install Shopkeeper 2.7.1
  • Install Multiverse-Core-4.0.0
  • Create multiple shopkeeper and monitor the time.
commented

I can't really determine the issue from the timings report alone. It seems like villagers take excessive amounts of time for their ticking. However, unless you have use-legacy-mob-behavior enabled (it is disabled by default) in Shopkeeper's config, the villagers spawned by Shopkeepers should not be ticking at all (their are spawned with the NoAI flag).

I will try to reproduce this later. In the meantime, can you please try to reproduce this with:

  • The latest version of Spigot. Paper has some internal differences which makes it harder for me to determine whether this might be a Paper-specific issue. Also create a timings report there.
  • Also update Paper and create a fresh timings report, because they fixed something regarding the entity ticking timings in v120.
  • Also disable 'tick-inactive-villagers' in the Spigot settings. Maybe this makes a difference.

Also: Shopkeepers v2.7.1 has an issue which prevents player shops from properly working on 1.14.3. I have uploaded an update (v2.7.2) which should fix that. You can find this on dev.bukkit.org, once it has been approved and becomes visible there, or alternatively from https://nexus.lichtspiele.org/repository/releases/com/nisovin/shopkeepers/Shopkeepers/2.7.2/Shopkeepers-2.7.2.jar

commented

Great to hear that this resolved this issue!
Not sure how this relates to the MultiVerse + Shopkeepers combo being the problem though. Maybe you have some world with many shopkeepers, that only get get loaded if you have both MultiVerse and Shopkeepers enabled. However, as said above, the shopkeeper villagers should not get ticked at all, regardless of the tick-inactive-villagers setting, IF you have use-legacy-mob-behavior disabled (which you should..).

commented

Thank you for your quick reply ! I tried everything and in the end, the solution!
I set false on tick-inactive-villagers in spigot.yml
TPS stays good after that ^^