//APPETITE private static void FoodMeter_ctor(On.HUD.FoodMeter.orig_ctor orig, HUD.FoodMeter self, HUD.HUD hud, int maxFood, int survivalLimit) { if (hud.owner is SlugcatSelectMenu.SlugcatPageContinue) { maxFood = KarmaAppetite.GetFoodFromKarma(((SlugcatSelectMenu.SlugcatPageContinue)hud.owner).saveGameData.karma).x; survivalLimit = KarmaAppetite.GetFoodFromKarma(((SlugcatSelectMenu.SlugcatPageContinue)hud.owner).saveGameData.karma).y; } orig.Invoke(self, hud, maxFood, survivalLimit); if (hud.owner is Player && (hud.owner as Player).slugcatStats.name != SlugcatStats.Name.Red) { self.quarterPipShower = new FoodMeter.QuarterPipShower(self); } }
//REMOVING FOOD POINTS private static void FoodMeter_UpdateShowCount(On.HUD.FoodMeter.orig_UpdateShowCount orig, HUD.FoodMeter self) { if (self.showCount < self.hud.owner.CurrentFood) { if (self.showCountDelay == 0) { self.showCountDelay = 10; if (self.showCount >= 0 && self.showCount < self.circles.Count && !self.circles[self.showCount].foodPlopped) { self.circles[self.showCount].FoodPlop(); } self.showCount++; if (self.quarterPipShower != null) { self.quarterPipShower.Reset(); } } else { self.showCountDelay--; } } else if (self.showCount > 0 && self.showCount > self.hud.owner.CurrentFood) { self.circles[self.showCount - 1].EatFade(); self.showCount--; } }