private static void ApplyStatChangeVars(Heroine heroine, PregnancyData preg, Dictionary <string, ValData> vars) { if (vars.TryGetVarValue("PillUsed", out bool used) && used) { PregnancyGameController.ForceStopPregnancyDelayed(heroine); var freePill = _personalityHasPills.TryGetValue(heroine.personality, out var val) && val; if (!freePill) { StoreApi.SetItemAmountBought(AfterpillStoreId, Mathf.Clamp(StoreApi.GetItemAmountBought(AfterpillStoreId) - 1, 0, 99)); } } if (vars.TryGetVarValue <int>("FavorChange", out var favor)) { heroine.favor = Mathf.Clamp(heroine.favor + favor, 0, 150); } if (vars.TryGetVarValue <int>("LewdChange", out var lewd)) { heroine.lewdness = Mathf.Clamp(heroine.lewdness + lewd, 0, 100); } if (vars.TryGetVarValue <int>("MoneyChange", out var money)) { Manager.Game.saveData.player.koikatsuPoint += money; } }