Exemplo n.º 1
0
        static bool Prefix(MobileParty mobileParty, ref int __result)
        {
            int partySizeLimit = mobileParty.Party.PartySizeLimit;

            __result = MBRandom.RoundRandomized(((float)QuestPartySizeHelper.GetPartySize(mobileParty) - mobileParty.PaymentRatio * (float)partySizeLimit) * 0.2f);
            return(false);
        }
Exemplo n.º 2
0
        static bool Prefix(MobileParty party, ref ExplainedNumber result, TextObject ____partySizeMoraleText)
        {
            int num = QuestPartySizeHelper.GetPartySize(party) - party.Party.PartySizeLimit;

            if (num > 0)
            {
                result.Add(-1f * (float)Math.Sqrt((double)num), ____partySizeMoraleText);
            }
            return(false);
        }
 static bool Prefix(MobileParty mobileParty, ref int __result)
 {
     if (mobileParty != null && mobileParty.Party != null && mobileParty.Party.LeaderHero != null && mobileParty.Party.LeaderHero == Hero.MainHero)
     {
         int partySizeLimit = mobileParty.Party.PartySizeLimit;
         __result = MBRandom.RoundRandomized(((float)QuestPartySizeHelper.GetPartySize(mobileParty) - mobileParty.PaymentRatio * (float)partySizeLimit) * 0.2f);
         return(false);
     }
     else
     {
         return(true);
     }
 }
 static bool Prefix(MobileParty mobileParty, ref ExplainedNumber result, TextObject ____partySizeMoraleText)
 {
     if (mobileParty != null && mobileParty.Party != null && mobileParty.Party.LeaderHero != null && !mobileParty.IsMilitia && !mobileParty.IsVillager)
     {
         int num = QuestPartySizeHelper.GetPartySize(mobileParty) - mobileParty.Party.PartySizeLimit;
         if (num > 0)
         {
             result.Add(-1f * (float)Math.Sqrt((double)num), ____partySizeMoraleText);
         }
         return(false);
     }
     return(true);
 }