public override void BuildAttribute()
    {
        //1、实例化数值属性
        CharacterAttribute attribute = new SoldierAttribute(FactoryManger.AttributeFactory.GetCharShareAttribute(base.CharacterType), base.Lv);

        base.Character.Attribute = attribute;
    }
Exemplo n.º 2
0
    public override void AddCharacterAttr()
    {
        CharacterBaseAttr baseAttr = FactoryManager.attrFactory.GetCharacterBaseAttr(mType);

        mPrefabName = baseAttr.prefabName;
        ICharacterAttribute attr = new SoldierAttribute(new SoldierAttrStrategy(), mLevel, baseAttr);

        mCharacter.Attr = attr;
    }
Exemplo n.º 3
0
    public SoldierCaptive(IEnemy enemy)
    {
        mEnemy = enemy;

        ICharacterAttribute attr = new SoldierAttribute(enemy.Attr.strategy, 1, enemy.Attr.baseAttr);

        this.Attr = attr;

        this.gameObject = mEnemy.gameObject;

        this.weapon = mEnemy.weapon;
    }