Пример #1
0
    public TechFactory()
    {
        baseModel = Resources.Load <GameObject>("TechModel");

        attackPower = 0.9f;
        armor       = 0.4f;
        maxHP       = 10;
        maxMP       = 6;


        baseSkills.Add(SkillFactory.GetSnipe());
        baseSkills.Add(SkillFactory.GetRepair());
        baseSkills.Add(SkillFactory.GetMakeSentry());

        Talent t = new Talent();

        t.name        = "Med Station";
        t.description = "Able to create med stations. Static structures that restore health to nearby allies every turn.";
        t.IfChosen    = unit => {
            unit.AddSkill(SkillFactory.getMakeMedStation());
        };
        talentOptions.Add(t);

        t             = new Talent();
        t.name        = "Add Repair";
        t.description = "Adds Repair to Class";
        t.IfChosen    = unit =>
        {
            unit.AddSkill(SkillFactory.GetRepair());
        };
        talentOptions.Add(t);

        t             = new Talent();
        t.name        = "Battle Bot";
        t.description = "Creates a mobile robot buddy. Will move to and attack enemies for you.";
        t.IfChosen    = unit =>
        {
            unit.AddSkill(SkillFactory.getMakeBattlePet());
        };
        talentOptions.Add(t);

        t             = new Talent();
        t.name        = "Sticky Grenade";
        t.description = "Attaches a sticky grenade to an enemy, which explodes after 2 turns.";
        t.IfChosen    = unit =>
        {
            unit.AddSkill(SkillFactory.getStickyGrenade());
        };
        talentOptions.Add(t);

        t             = new Talent();
        t.name        = "Master Sniper";
        t.description = "Snipe is free.";
        t.IfChosen    = unit =>
        {
            unit.talentTags.Add("FreeSnipe");
        };
        talentOptions.Add(t);

        t             = new Talent();
        t.name        = "Toughness";
        t.description = "The Tech is just tough. Nothing complicated. Slight increase to armor and damage.";
        t.IfChosen    = Unit =>
        {
            Unit.AddEffect(EffectFactory.getToughEffect(), -1);
        };
        talentOptions.Add(t);

        name        = "Technician";
        description = "A repairman who can build robots";
        image       = Resources.Load <Sprite>("CharacterIcons/TechIcon");
    }