Wieku / danser-go

Dancing visualizer of osu! standard maps and custom osu! client written in Go. Also a generator for osu! videos.
Other
753 stars 103 forks source link

Failed to parse settings.json! Please re-check the file for mistakes. Error: invalid character '}' looking for beginning of object key string #146

Closed timofey260 closed 3 years ago

timofey260 commented 3 years ago

I am trying to create a GUI for easy customization of settings.json and launch. Perhaps, somewhere instead of "int" I put "float" Can I get a list of value types?

settings.json


    "General": {
        "OsuSongsDir": "C:\\Users\\TiMoFey\\AppData\\Local\\osu!\\Songs",
        "OsuSkinsDir": "C:\\Users\\TiMoFey\\AppData\\Local\\osu!\\Skins",
        "DiscordPresenceOn": true,
        "UnpackOszFiles": true
    },
    "Graphics": {
        "Width": 1920,
        "Height": 1080,
        "WindowWidth": 1440,
        "WindowHeight": 810,
        "Fullscreen": true,
        "VSync": false,
        "FPSCap": 120,
        "MSAA": 0,
        "ShowFPS": true,
        "Experimental": {
            "UsePersistentBuffers": false
        }
    },
    "Audio": {
        "GeneralVolume": 0.5,
        "MusicVolume": 0.5,
        "SampleVolume": 0.5,
        "Offset": 0.0,
        "HitsoundPositionMultiplier": 1.0,
        "IgnoreBeatmapSamples": false,
        "IgnoreBeatmapSampleVolume": false,
        "BeatScale": 1.2,
        "BeatUseTimingPoints": false,
        "Linux/Unix": {
            "BassPlaybackBufferLength": 100,
            "BassDeviceBufferLength": 10,
            "BassUpdatePeriod": 5
        }
    },
    "Input": {
        "LeftKey": "X",
        "RightKey": "Z",
        "RestartKey": "`",
        "SmokeKey": "C",
        "MouseButtonsDisabled": false,
        "MouseHighPrecision": false,
        "MouseSensitivity": 1.0
    },
    "Gameplay": {
        "HitErrorMeter": {
            "Show": true,
            "Scale": 1,
            "Opacity": 0.0,
            "ShowUnstableRate": true,
            "UnstableRateDecimals": 0,
            "UnstableRateScale": 1
        },
        "Score": {
            "Show": true,
            "Scale": 1,
            "Opacity": 0.0,
            "ProgressBar": "Pie",
            "ShowGradeAlways": true
        },
        "HpBar": {
            "Show": true,
            "Scale": 1,
            "Opacity": 0.0,
        },
        "ComboCounter": {
            "Show": true,
            "Scale": 1,
            "Opacity": 0.0,
        },
        "PPCounter": {
            "Show": true,
            "Scale": 1,
            "Opacity": 0.0,
            "XPosition": 5,
            "YPosition": 150,
            "Decimals": 0,
            "Align": "CentreLeft",
            "ShowInResults": true
        },
        "KeyOverlay": {
            "Show": true,
            "Scale": 1,
            "Opacity": 0.0,
        },
        "ScoreBoard": {
            "Show": true,
            "Scale": 1,
            "Opacity": 0.0,
            "HideOthers": false,
            "ShowAvatars": false,
            "YOffset": 0
        },
        "Mods": {
            "Show": true,
            "Scale": 1,
            "Opacity": 0.0,
            "HideInReplays": false,
            "FoldInReplays": false
        },
        "Boundaries": {
            "Enabled": true,
            "BorderThickness": 1,
            "BorderFill": 1,
            "BorderColor": {
                "Hue": 0,
                "Saturation": 0,
                "Value": 1
            },
            "BorderOpacity": 1,
            "BackgroundColor": {
                "Hue": 0,
                "Saturation": 1,
                "Value": 0
            },
            "BackgroundOpacity": 0.5
        },
        "ShowResultsScreen": true,
        "ResultsScreenTime": 5,
        "ShowWarningArrows": true,
        "FlashlightDim": 1,
        "PlayUsername": "danser"
    },
    "Skin": {
        "CurrentSkin": "default",
        "UseColorsFromSkin": false,
        "UseBeatmapColors": false,
        "Cursor": {
            "UseSkinCursor": false,
            "Scale": 1.0,
            "ForceLongTrail": false,
            "LongTrailLength": 2048,
            "LongTrailDensity": 1
        }
    },
    "Cursor": {
        "TrailStyle": 1,
        "Style23Speed": 0.18,
        "Style4Shift": 0.5,
        "Colors": {
            "EnableRainbow": true,
            "RainbowSpeed": 8,
            "BaseColor": {
                "Hue": 0,
                "Saturation": 1,
                "Value": 1
            },
            "EnableCustomHueOffset": false,
            "HueOffset": 0,
            "FlashToTheBeat": false,
            "FlashAmplitude": 0
        },
        "EnableCustomTagColorOffset": true,
        "TagColorOffset": -36,
        "EnableTrailGlow": true,
        "EnableCustomTrailGlowOffset": true,
        "TrailGlowOffset": -36,
        "ScaleToCS": false,
        "CursorSize": 18,
        "CursorExpand": false,
        "ScaleToTheBeat": true,
        "ShowCursorsOnBreaks": true,
        "BounceOnEdges": true,
        "TrailScale": 1,
        "TrailEndScale": 0.4,
        "TrailDensity": 0.5,
        "TrailMaxLength": 2000,
        "TrailRemoveSpeed": 1,
        "GlowEndScale": 0.4,
        "InnerLengthMult": 0.9,
        "AdditiveBlending": true,
        "CursorRipples": true,
        "SmokeEnabled": true
    },
    "Objects": {
        "DrawApproachCircles": true,
        "DrawComboNumbers": true,
        "DrawFollowPoints": true,
        "LoadSpinners": true,
        "ScaleToTheBeat": false,
        "StackEnabled": true,
        "Sliders": {
            "ForceSliderBallTexture": true,
            "DrawEndCircles": true,
            "DrawSliderFollowCircle": true,
            "DrawScorePoints": true,
            "SliderMerge": false,
            "SliderDistortions": true,
            "BorderWidth": 1,
            "Quality": {
                "CircleLevelOfDetail": 50,
                "PathLevelOfDetail": 50
            },
            "Snaking": {
                "In": true,
                "Out": true,
                "DurationMultiplier": 0,
                "FadeMultiplier": 0
            }
        },
        "Colors": {
            "MandalaTexturesTrigger": 5,
            "MandalaTexturesAlpha": 0.3,
            "Color": {
                "EnableRainbow": true,
                "RainbowSpeed": 8,
                "BaseColor": {
                    "Hue": 0,
                    "Saturation": 1,
                    "Value": 1
                },
                "EnableCustomHueOffset": false,
                "HueOffset": 0,
                "FlashToTheBeat": false,
                "FlashAmplitude": 100
            },
            "UseComboColors": false,
            "ComboColors": [
                {
                    "Hue": 0,
                    "Saturation": 1,
                    "Value": 1
                }
            ],
            "UseSkinComboColors": false,
            "UseBeatmapComboColors": false,
            "Sliders": {
                "WhiteScorePoints": true,
                "ScorePointColorOffset": 0,
                "SliderBallTint": false,
                "Border": {
                    "UseHitCircleColor": false,
                    "Color": {
                        "EnableRainbow": false,
                        "RainbowSpeed": 8,
                        "BaseColor": {
                            "Hue": 0,
                            "Saturation": 0,
                            "Value": 1
                        },
                        "EnableCustomHueOffset": false,
                        "HueOffset": 0,
                        "FlashToTheBeat": false,
                        "FlashAmplitude": 100
                    },
                    "EnableCustomGradientOffset": true,
                    "CustomGradientOffset": 0
                },
                "Body": {
                    "UseHitCircleColor": true,
                    "Color": {
                        "EnableRainbow": false,
                        "RainbowSpeed": 8,
                        "BaseColor": {
                            "Hue": 0,
                            "Saturation": 1,
                            "Value": 0
                        },
                        "EnableCustomHueOffset": false,
                        "HueOffset": 0,
                        "FlashToTheBeat": true,
                        "FlashAmplitude": 100
                    },
                    "InnerOffset": -0.5,
                    "OuterOffset": -0.05,
                    "InnerAlpha": 0.8,
                    "OuterAlpha": 0.8
                }
            }
        }
    },
    "Playfield": {
        "DrawObjects": true,
        "DrawCursors": true,
        "Scale": 1,
        "OsuShift": true,
        "ShiftY": 0,
        "ShiftX": 0,
        "ScaleStoryboardWithPlayfield": true,
        "LeadInTime": 5,
        "LeadInHold": 2,
        "FadeOutTime": 5,
        "SeizureWarning": {
            "Enabled": true,
            "Duration": 5
        },
        "Background": {
            "LoadStoryboards": true,
            "LoadVideos": false,
            "FlashToTheBeat": true,
            "Dim": {
                "Intro": 0.0,
                "Normal": 0.6,
                "Breaks": 0.0
            },
            "Parallax": {
                "Amount": 0.1,
                "Speed": 0.6
            },
            "Blur": {
                "Enabled": false,
                "Values": {
                    "Intro": 0.0,
                    "Normal": 0.6,
                    "Breaks": 0.0
                }
            },
            "Triangles": {
                "Enabled": false,
                "Shadowed": true,
                "DrawOverBlur": true,
                "ParallaxMultiplier": 0.5,
                "Density": 1,
                "Scale": 1,
                "Speed": 1
            }
        },
        "Logo": {
            "DrawSpectrum": true,
            "Dim": {
                "Intro": 0.0,
                "Normal": 1.0,
                "Breaks": 1.0
            }
        },
        "Bloom": {
            "Enabled": true,
            "BloomToTheBeat": true,
            "BloomBeatAddition": 0.3,
            "Threshold": 0.0,
            "Blur": 0.6,
            "Power": 0.7
        }
    },
    "Dance": {
        "Movers": [
        "spline"
        ],
        "Spinners": [
        "circle"
        ],
        "DoSpinnersTogether": true,
        "SpinnerRadius": 100,
        "Battle": false,
        "SliderDance": false,
        "RandomSliderDance": false,
        "TAGSliderDance": true,
        "Bezier": {
            "Aggressiveness": 60,
            "SliderAggressiveness": 3
        },
        "Flower": {
            "AngleOffset": 90,
            "DistanceMult": 0.666,
            "StreamAngleOffset": 90,
            "LongJump": -1,
            "LongJumpMult": 0.7,
            "LongJumpOnEqualPos": false
        },
        "HalfCircle": {
            "RadiusMultiplier": 1,
            "StreamTrigger": 130
        },
        "Spline": {
            "RotationalForce": false,
            "StreamHalfCircle": true,
            "StreamWobble": true,
            "WobbleScale": 0.67
        },
        "Momentum": {
            "SkipStackAngles": false,
            "StreamRestrict": true,
            "DurationMult": 2,
            "DurationTrigger": 500,
            "StreamMult": 0.7,
            "RestrictAngle": 90,
            "RestrictArea": 40,
            "RestrictInvert": true,
            "DistanceMult": 0.6,
            "DistanceMultOut": 0.45
        },
        "ExGon": {
            "Delay": 50
        }
    },
    "Knockout": {
        "Mode": 0,
        "ExcludeMods": "",
        "HideMods": "",
        "MaxPlayers": 50,
        "BubbleMinimumCombo": 200,
        "RevivePlayersAtEnd": true,
        "LiveSort": false,
        "SortBy": "Score",
        "MinCursorSize": 3,
        "MaxCursorSize": 7,
        "AddDanser": true,
    "DanserName": "danser"
    },
    "Recording": {
        "FrameWidth": 1920,
        "FrameHeight": 1080,
        "FPS": 60,
        "Encoder": "libx264",
        "EncoderOptions": "-crf 14",
        "Profile": "high",
        "Preset": "faster",
        "PixelFormat": "yuv420p",
        "Filters": "",
        "AudioCodec": "aac",
        "AudioBitrate": "320k",
        "AudioFilters": "",
        "OutputDir": "F:\\Desktop\\dancer",
        "Container": "mp4",
        "MotionBlur": {
            "Enabled": false,
            "OversampleMultiplier": 3,
            "BlendFrames": 5,
            "BlendWeights": {
                "UseManualWeights": false,
                "ManualWeights": "1 1.7 2.1 4.1 5",
                "AutoWeightsID": 1,
                "GaussWeightsMult": 1.5
            }
        }
    }
}```

**logs**
[danser.log](https://github.com/Wieku/danser-go/files/6720155/danser.log)
sbrstrkkdwmdr commented 3 years ago

put two \s in the settings for directory. so C:\\idk\\songs instead of C:\idk\songs

Wieku commented 3 years ago

Open the json in VSCode, it should show the mistake. Also, be aware that 0.5.3 update will have some drastic changes to settings

Wieku commented 3 years ago

And about such things, it's better to discuss over discord

timofey260 commented 3 years ago

@sbrstrkkdwmdr i put \\, but markdown change it to \