Beispiel #1
0
    public void initLegging(int heroHashCode)
    {
        GDEEquipmentData armor = SDDataManager.Instance.getHeroEquipLegging(heroHashCode);
        Legging          a     = unit_model.gameObject.AddComponent <Legging>();

        HeroProperty._legging = a;
        if (armor == null || string.IsNullOrEmpty(armor.id))
        {
            HeroProperty._legging.initDataEmpty(); return;
        }
        EquipItem Item = SDDataManager.Instance.GetEquipItemById(armor.id);

        if (Item == null)
        {
            HeroProperty._legging.initDataEmpty(); return;
        }
        //
        HeroProperty._legging.initData(Item.LEVEL, Item.RAL, 0, 0, 0, 0, RoleBarChart.zero
                                       , Item.ID, Item.NAME, 0);
        HeroProperty._legging.PassiveEffectInit(Item.PassiveEffect);
        HeroProperty._legging.armorRank = Item.ArmorRank;
        int lv = armor.lv;

        HeroProperty._legging.initGradeShow(lv);
    }
Beispiel #2
0
 public void BuildEquipListBase()
 {
     if (_helmet == null && helmetD != null)
     {
         _helmet = helmetD.gameObject.AddComponent <Helmet>();
     }
     if (_breastplate == null && breastplateD != null)
     {
         _breastplate = breastplateD.gameObject.AddComponent <Breastplate>();
     }
     if (_gardebras == null && gardebrasD != null)
     {
         _gardebras = gardebrasD.gameObject.AddComponent <Gardebras>();
     }
     if (_legging == null && leggingD != null)
     {
         _legging = leggingD.gameObject.AddComponent <Legging>();
     }
     if (_jewelry0 == null && jewelry0D != null)
     {
         _jewelry0 = jewelry0D.gameObject.AddComponent <Jewelry>();
     }
     if (_jewelry1 == null && jewelry1D != null)
     {
         _jewelry1 = jewelry1D.gameObject.AddComponent <Jewelry>();
     }
     if (_weapon == null && weaponD != null)
     {
         _weapon = weaponD.gameObject.AddComponent <SDWeapon>();
     }
 }