Prism

Prism

91.2k Downloads

PlayerJoinEvent could be optimised

I-Knight-I opened this issue ยท 1 comments

commented
  • Prism 2.1.6
  • Paper 103
  • Minecraft 1.15.2
  • R5 3600 + 8GB RAM

As it currently stands, the PlayerJoinEvent in Prism is the 2nd biggest contributor to tick usage (when testing joining performance). The 1st is chunkAwait.

image

I think that the majority (if not all) of the PlayerJoinEvent listener could probably be run asynchronously since, from what I can tell, it doesn't directly interact with the Bukkit API and is simply for caching.

Would alleviate a bit (or a lot) of the impact placed upon servers during joining. Mostly beneficial for those that have a lot of people leaving/joining in short periods of time.

commented

I believe my original intent was to ensure the join was logged/player data was cached so that future logging could contain their data correctly. I'm not sure if that was truly necessary.