yeeterlol / FishingPlus

another QOL that improves fishing
MIT License
1 stars 0 forks source link

Changing config in Hook, Line & Sinker prevents mod from loading. #6

Open crygup opened 4 hours ago

crygup commented 4 hours ago

Basically exactly what title says, since the patient lure setting doesn't show up in the in game mods configuration I tried the other way of configuring settings which is in said mod manager, via "Edit Config". After deselecting "Patient Lure" and saving and then relaunching the game, FishingPlus fails to load with the following error:

2024-11-04 22:35:19.713 -07:00 [WRN] Failed to load assembly for mod FishingPlus
System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation.
 ---> System.Text.Json.JsonException: The JSON value could not be converted to System.String[]. Path: $.FishIDs | LineNumber: 4 | BytePositionInLine: 56.
   at System.Text.Json.ThrowHelper.ThrowJsonException_DeserializeUnableToConvertValue(Type propertyType)
   at System.Text.Json.Serialization.JsonCollectionConverter`2.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, TCollection& value)
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
   at System.Text.Json.Serialization.Metadata.JsonPropertyInfo`1.ReadJsonAndSetMember(Object obj, ReadStack& state, Utf8JsonReader& reader)
   at System.Text.Json.Serialization.Converters.ObjectDefaultConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
   at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
   at System.Text.Json.Serialization.JsonConverter`1.ReadCore(Utf8JsonReader& reader, JsonSerializerOptions options, ReadStack& state)
   at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan`1 utf8Json, JsonTypeInfo`1 jsonTypeInfo, Nullable`1 actualByteCount)
   at System.Text.Json.JsonSerializer.ReadFromSpan[TValue](ReadOnlySpan`1 json, JsonTypeInfo`1 jsonTypeInfo)
   at System.Text.Json.JsonSerializer.Deserialize[TValue](String json, JsonSerializerOptions options)
   at GDWeave.ModInterface.ReadConfig[T]() in D:\a\GDWeave\GDWeave\GDWeave\Loader\ModInterface.cs:line 22
   at FishingPlus.Mod..ctor(IModInterface modInterface)
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Void** arguments, Signature sig, Boolean isConstructor)
   at System.Reflection.MethodBaseInvoker.InvokeDirectByRefWithFewArgs(Object obj, Span`1 copyOfArgs, BindingFlags invokeAttr)
   --- End of inner exception stack trace ---
   at System.Reflection.MethodBaseInvoker.InvokeDirectByRefWithFewArgs(Object obj, Span`1 copyOfArgs, BindingFlags invokeAttr)
   at System.Reflection.MethodBaseInvoker.InvokeWithOneArg(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at System.Reflection.RuntimeConstructorInfo.Invoke(BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at System.Reflection.ConstructorInfo.Invoke(Object[] parameters)
   at GDWeave.ModLoader.LoadAssembly(String id, String assemblyPath) in D:\a\GDWeave\GDWeave\GDWeave\Loader\ModLoader.cs:line 145
   at GDWeave.ModLoader.LoadAssemblies() in D:\a\GDWeave\GDWeave\GDWeave\Loader\ModLoader.cs:line 118
Hackstr0 commented 2 hours ago

can confirm this is a bug, 1.4.1 keeps not loading whenever I change any config values. Editing those config values using TackleBox's in-game menu is also broken, as it only shows the first three options (Current Fish Chance, Loot Table View, Need Certain Fish) but stops there