froobynooby / ViewDistanceTweaks

Paper plugin that allows for dynamic simulation and view distances.
https://ci.froobworld.com/job/ViewDistanceTweaks/
MIT License
93 stars 18 forks source link

View Distance never changes. #49

Closed Yertled closed 2 weeks ago

Yertled commented 1 year ago

Hey, so I have been enjoying this plugin for the last couple of days. But I noticed only the simulation distance changes, but NEVER the view distance. Is there anything I am doing wrong?

Here is my settings: https://mclo.gs/faPj18s

The view distance never goes above or below 10, not matter the MSPT or amount of lag we have.

Context if needed: We peak at 80 players Minecraft 1.20 using Purpur Even when we have 12 TPS and high MSPT, the view distance never changes, only simulation distance.

In server.properties: view-distance=16 simulation-distance=7

DeSinc commented 11 months ago

I am having the same issue. The sim distance will go up and down in a pattern I haven't worked out yet, but the non-sim view distance will just stay locked at the maximum and keep going up and up and up to the top even when the dang server is falling over at 14 tps.

Is the MSPT measurement only affecting sim distance? MSPT is just pinning it at max distance even if I set MSPT to reduce to >1ms it just ignores this value completely pretty much. I think it's only setting non ticking view distance by the loaded chunks, and totally ignoring MSPT for that value entirely. This seems like a bug to me.

KingMuffin11 commented 5 months ago

I am having the same / a similar issue. I have the plugin installed with the enabled flag set to true. No matter what mode I use the plugin never changes the view distance, the simulation distance is changed only.

DeSinc commented 5 months ago

I am having the same / a similar issue. I have the plugin installed with the enabled flag set to true. No matter what mode I use the plugin never changes the view distance, the simulation distance is changed only.

I forgot where but the dev noted that this is intended functionality as sim distance and non-tick view distance can't easily go up and down at their different ranges without coding some other solution to make it happen. Currently only sim distance goes up and down based on milliseconds per tick. I think he said he intended to address this at one point but it seemed only theoretical not very concrete. edit: it has been coded and merged in issue #53 and now works as expected. non tick view dist goes down when MSPT gets too high when the feature is enabled in config.

That said, I think non-tick view dist might not be your main issue causing your tickrate to go down, if you are having that issue. I'd suggest trying to set the non-tick view dist lower manually and seeing if it actually fixes the tickrate if you have an issue with it first, or if it's actually a combination of other factors that is lowering it more. From memory I think my issue went away after fixing something else and non-tick view dist didn't seem to be as important as another problem that was lowering the tps on my server anyway.