コード例 #1
0
    public override void Calculate(List <Survivor> sel)
    {
        if (CurLoc.Scouted)
        {
            MaxDanger = 10;
            MinDanger = 0;
        }
        else
        {
            MaxDanger = 30;
            MinDanger = 10;
        }

        Danger = MaxDanger;

        SelSurv.Clear();
        RequareTime = MaxRequareTime;
        int newDanger = MaxDanger;

        for (int i = 0; i < sel.Count; i++)
        {
            SelSurv.Add(sel[i]);
            SelSurv[i].Status = "Killing zombies";
            newDanger        -= (int)(SelSurv[i].SpecBonus.SoldierBonus * 3f);

            if (newDanger < MinDanger)
            {
                newDanger = 0;
                break;
            }
        }

        Danger = newDanger;
    }
コード例 #2
0
    public override void Calculate(List <Survivor> sel)
    {
        MaxDanger = 3;
        MinDanger = 0;

        Danger = MaxDanger;

        SelSurv.Clear();
        RequareTime = MaxRequareTime;
        int newDanger = MaxDanger;

        for (int i = 0; i < sel.Count; i++)
        {
            SelSurv.Add(sel[i]);
            SelSurv[i].Status = "Scouting area";
            newDanger        -= (int)(SelSurv[i].SpecBonus.SoldierBonus * 3f);

            if (newDanger < MinDanger)
            {
                newDanger = 0;
                break;
            }
        }

        Danger = newDanger;
    }
コード例 #3
0
    public override void Calculate(List <Survivor> sel)
    {
        SelSurv.Clear();
        int newRequareTime = MaxRequareTime;

        for (int i = 0; i < sel.Count; i++)
        {
            SelSurv.Add(sel[i]);
            SelSurv[i].Status = "Building Farm";
            if (newRequareTime > MinRequareTime)
            {
                newRequareTime -= (int)SelSurv[i].SpecBonus.BuilderBonus;
            }
        }

        RequareTime = newRequareTime;
    }
コード例 #4
0
    public override void Calculate(List <Survivor> sel)
    {
        SelSurv.Clear();
        int newRequareTime = MaxRequareTime;
        int newDanger      = MaxDanger;

        for (int i = 0; i < sel.Count; i++)
        {
            SelSurv.Add(sel[i]);
            SelSurv[i].Status = "Reclaiming the area";
            if (newRequareTime > MinRequareTime)
            {
                newRequareTime -= (int)SelSurv[i].SpecBonus.BuilderBonus;
            }
            if (newDanger > MinDanger)
            {
                newDanger -= (int)SelSurv[i].SpecBonus.SoldierBonus * 10;
            }
        }

        RequareTime = newRequareTime;
        Danger      = newDanger;
    }