Exemplo n.º 1
0
        public override void GiveRewards(bool bDialogResult, Sim sim, string icon, Origin origin)
        {
            if (bDialogResult)
            {
                if (RewardsManager.CheckForWin(mChanceToWin, mModifiersList, sim))
                {
                    base.ShowEventTNS(Common.LocalizeEAString(sim.IsFemale, mYesResultText, new object[] { sim }), sim.ObjectId, icon);
                    RewardsManager.GiveRewards(mYesRewardsList, sim, origin);

                    RewardInfoEx.GiveRewards(sim, null, mYesRewardsList);
                }
                else
                {
                    base.ShowEventTNS(Common.LocalizeEAString(sim.IsFemale, mYesLoseResultText, new object[] { sim }), sim.ObjectId, icon);
                    RewardsManager.GiveRewards(mYesLoseRewardsList, sim, origin);

                    RewardInfoEx.GiveRewards(sim, null, mYesLoseRewardsList);
                }
            }
            else
            {
                base.ShowEventTNS(Common.LocalizeEAString(sim.IsFemale, mNoResultText, new object[] { sim }), sim.ObjectId, icon);
                RewardsManager.GiveRewards(mNoRewardsList, sim, origin);

                RewardInfoEx.GiveRewards(sim, null, mNoRewardsList);
            }
        }
Exemplo n.º 2
0
        public override void OnCompletion(out OpportunityNames triggerOpportunity)
        {
            bool      opportunityWin = RewardsManager.CheckForWin(mSharedData.mCompletionWinChance, mSharedData.mModifierList, Actor);
            ArrayList rewardsList    = opportunityWin ? mSharedData.mWinRewardsList : mSharedData.mLossRewardsList;

            RewardInfoEx.GiveRewards(Actor, TargetObject, rewardsList);

            base.OnCompletion(out triggerOpportunity);
        }