Dynamic FPS

Dynamic FPS

16M Downloads

Crash on quilt

TheBossMagnus opened this issue ยท 6 comments

commented

Logs: https://mclo.gs/H3QVt7X
Also happens in 1.19.4

commented

OT question: Does GC have some impact on resource usage? In wich mesure?

commented

Your config file is most likely not valid. You can delete it (dynamic_fps.json in the config folder) and it should work again.


FWIW if you are manually editing the config you will need to keep all values in each individual object inside the states object, otherwise you will get this crash:

{
    "states": {
        "hovered": {
            "graphics_state": "default",
            "show_toasts": true,
            "run_garbage_collector": false,
            "frame_rate_target": 60,
            "volume_multiplier": 1.0
        },
        "unfocused": {
            "graphics_state": "default",
            "show_toasts": false,
            "run_garbage_collector": false,
            "frame_rate_target": 1,
            "volume_multiplier": 0.25
        },
        "invisible": { // Causes the crash, as the other four key value pairs are missing
            "volume_multiplier": 0.0
        }
    }
}

Modifying the config file by removing values is generally not supported anymore sadly, as it would make the config repopulation code kinda explode in size (as the defaults for each state are different).

commented

I assume you're reporting this via your modpack's config at least.

commented

Exactly!

I assume you're reporting this via your modpack's config at least.

Maybe a warning somewhere (like a comment) wouldn't be bad.
Sorry for the inaccurate report, in fabric was working bc I used it to build the config, so it was complete.

commented

I can see about a warning or maybe adding more info to the crash report, dw though it was not hard to find what was wrong :)

OT question: Does GC have some impact on resource usage? In wich mesure?

Personally I have not used this option, so I have little experience with it. Generally I would think it would have a pretty minor performance impact though since in the background while you are playing the garbage collector is always active to free memory.

I would however recommend that you only enable this option for uncofused and invisible mode, then Dynamic FPS will ask the JVM to clean garbage right after the window is no longer focused, without the user noticing (since they are looking elsewhere).

commented

Maybe a warning somewhere (like a comment) wouldn't be bad.

Fwiw in v3.5.0 you will now be able to have a partial config file, and the mod will start fine.
I've changed the way the config is saved so it will by default do this and only save values that deviate from the defaults.