using System.Collections.Generic; using HarmonyLib; namespace WalleyeFix.Patches { [HarmonyPatch(typeof(PlayerFishingController), "pickFish")] public static class PlayerFishingControllerPatches { [HarmonyPrefix] public static void PickFishPrefix() { List allFish = ConfigManager.GetAllByType(); if (allFish == null) { return; } for (int i = 0; i < allFish.Count; i++) { FishConfig fishConfig = allFish[i]; if (fishConfig == null) { continue; } if (fishConfig._FishName != "Walleye") { continue; } List newWeights = new List { new TierWeight { _Tier = 1, _Weight = 3 }, new TierWeight { _Tier = 2, _Weight = 3 }, new TierWeight { _Tier = 3, _Weight = 3 } }; Traverse.Create(fishConfig).Field("_spawnWeights").SetValue(newWeights); break; } } } }