예제 #1
0
        public override void Entry(IModHelper helper)
        {
            Config = Helper.ReadConfig <ForageFantasyConfig>();

            ForageFantasyConfig.VerifyConfigValues(Config, this);

            Helper.Events.GameLoop.GameLaunched += delegate { ForageFantasyConfig.SetUpModConfigMenu(Config, this); };

            Helper.Events.GameLoop.GameLaunched += delegate { DeluxeGrabberCompatibility.Setup(this); };

            Helper.Events.GameLoop.DayStarted += delegate
            {
                TapperAndMushroomQualityLogic.IncreaseTreeAges(this);
                GrapeLogic.SetDropToNewGrapes(this);
                CheckForTappersDream();
            };

            Helper.Events.GameLoop.DayEnding += delegate { GrapeLogic.ResetGrapes(this); };

            Helper.Events.GameLoop.SaveLoaded += delegate { FernAndBurgerLogic.ChangeBundle(this); };

            helper.Events.Input.ButtonsChanged += OnButtonsChanged;

            Patcher.PatchAll(this);
        }
        public override void Entry(IModHelper helper)
        {
            Config = Helper.ReadConfig <ForageFantasyConfig>();

            ForageFantasyConfig.VerifyConfigValues(Config, this);

            Helper.Events.GameLoop.GameLaunched += delegate { ForageFantasyConfig.SetUpModConfigMenu(Config, this); };

            Helper.Events.GameLoop.GameLaunched += delegate { DeluxeGrabberCompatibility.Setup(this); };

            Helper.Events.GameLoop.DayStarted += delegate { TapperAndMushroomQualityLogic.IncreaseTreeAges(this); };

            Helper.Events.GameLoop.SaveLoaded += delegate { FernAndBurgerLogic.ChangeBundle(this); };

            Patcher.PatchAll(this);
        }
예제 #3
0
        public static bool PatchSummerWildSeedResult(ref int __result)
        {
            try
            {
                if (mod.Config.CommonFiddleheadFern && Game1.currentSeason == "summer")
                {
                    __result = FernAndBurgerLogic.GetWildSeedSummerForage();

                    return(false);
                }
                else
                {
                    return(true);
                }
            }
            catch (Exception e)
            {
                mod.ErrorLog("There was an exception in a patch", e);
                return(true);
            }
        }
 public void Edit <T>(IAssetData asset)
 {
     FernAndBurgerLogic.Edit <T>(asset, Config);
 }
 public bool CanEdit <T>(IAssetInfo asset)
 {
     return(FernAndBurgerLogic.CanEdit <T>(asset, Config));
 }