Zulfen / ZulfBungee

A Skript addon which adds proxy integration.
Apache License 2.0
10 stars 2 forks source link

[IMPROVEMENT] Network variable #12

Open Lennord opened 1 year ago

Lennord commented 1 year ago

Hello, I would like to know if it is possible to make network variables faster (instantly direct), because network variables are a bit slow, it checks 1 variable per variable and so if I check several variables at the same time. time is quite slow.

Lennord commented 1 year ago

I tried changing the "packet-response-time" value to a lower number but it still works so slow.

Zulfen commented 1 year ago

Yeah, unfortunately due to limitations with Skript it makes it a bit hard to have decent performance with this addon. My code also has probably something to do with it though.

There might be a way around it using the new section stuff that has been added to Skript that supports running the syntax in async, but gotta figure out how to code that!

Until then, have you tried using /zulfbungee ping and setting the response time to something slightly higher than that? For example, I have mine set to 50 as my ping is around 46ms, and it works okay.

Lennord commented 1 year ago

Yeah, unfortunately due to limitations with Skript it makes it a bit hard to have decent performance with this addon. My code also has probably something to do with it though.

There might be a way around it using the new section stuff that has been added to Skript that supports running the syntax in async, but gotta figure out how to code that!

Until then, have you tried using /zulfbungee ping and setting the response time to something slightly higher than that? For example, I have mine set to 50 as my ping is around 46ms, and it works okay.

Ok, I just tested the /zulfbungee ping and changed the config to the value I have in the ping but it still doesn't work, the network variables are still slow..

In short, it does not matter, I will do it with time that you find a solution to solve this problem.

MaitreFranck commented 1 year ago

Based on my experience, using network/global variables isn't the best way to store players data on long term. If you want to store things like ranks, coins, ect you might be fine with databases like MongoDB or MySQL, with their related addons (I personnaly use MongoSK and it works fine). It can be a good solution for your speed issues.

Lennord commented 1 year ago

Good evening, do you know if this will be changed in the next few days?

Lennord commented 1 year ago

Hello, is the variable loading time on the H2 the same as MySQL with your plugin?

Lennord commented 1 year ago

I noticed after closing the issue, that it works perfectly in localhost but not on a vps (Pterodactyl or pufferpanel), I'm sorry for closing the issue.

Lennord commented 1 year ago

Do you think the global variables will be corrected regarding this problem as soon as possible?

Lennord commented 1 year ago

Hi, sorry to ask you this question but it is to know if the network variables will be fixed on the vps including PufferPanel.

Lennord commented 1 year ago

Hello, I tested the variable networks on the "Release v0.9.8-pre1" and it is still slow.

I think you haven't fixed or changed this problem yet but I prefer to test when you changed a few things on the network variables to see if that fixes it.

Thank you for your understanding !

Lennord commented 1 year ago

Hello, do you think the problem will be fixed in the next few weeks?

Lennord commented 1 year ago

I also noticed that if we check and modify several network variables it lowers the tps to around 13/20 tps.

Lennord commented 1 year ago

Good evening @Zulfen,

When I put in the configuration of the Proxy and spigot on "socket", it causes a latency of the network variables but when I put "pluginmessage", the network variables work very quickly but the problem is that I only want to put socket because with pluginmessage it must have a player connected for the network variables to work while I don't want.

Cordially Mr.Lennord.

INFO: Zulfbungee version: ALPHA-0.9.8