Exemplo n.º 1
0
        public static void Prefix(ref float efficiency)
        {
            ModExt_Difficulty extDiff = Find.Storyteller.difficulty.GetModExtension <ModExt_Difficulty>();

            if (extDiff != null)
            {
                efficiency *= extDiff.butcherProductFactor;
            }
        }
Exemplo n.º 2
0
        public static void Postfix(ref float __result)
        {
            ModExt_Difficulty extDiff = Find.Storyteller.difficulty.GetModExtension <ModExt_Difficulty>();

            if (extDiff != null)
            {
                __result *= extDiff.needJoyFallFactor;
            }
        }
        public static void Postfix(ref float __result, StatDef ___stat)
        {
            if (___stat != StatDefOf.WorkSpeedGlobal)
            {
                return;
            }
            ModExt_Difficulty extDiff = Find.Storyteller.difficulty.GetModExtension <ModExt_Difficulty>();

            if (extDiff != null)
            {
                __result *= extDiff.workSpeedGlobalFactor;
            }
        }
Exemplo n.º 4
0
        public static void Postfix(ref float __result)
        {
            ModExt_Difficulty extDiff = Find.Storyteller.difficulty.GetModExtension <ModExt_Difficulty>();

            if (extDiff != null)
            {
                if (__result > 0f)
                {
                    __result *= extDiff.moodImpactFactorPositive;
                }
                else
                {
                    __result *= extDiff.moodImpactFactorNegative;
                }
            }
        }
        public static void Prefix(Thing __instance, ref DamageInfo dinfo)
        {
            ModExt_Difficulty extDiff = Find.Storyteller.difficulty.GetModExtension <ModExt_Difficulty>();

            if (extDiff != null)
            {
                if (__instance.Faction == Faction.OfPlayer)
                {
                    dinfo.SetAmount(dinfo.Amount * extDiff.damageFactorOnPlayer);
                }
                else if (__instance.Faction != null)
                {
                    dinfo.SetAmount(dinfo.Amount * extDiff.damageFactorOnOther);
                }
            }
        }