Пример #1
0
 public void InitTalent(int _talentID, int _cdTime)
 {
     if (this.talentCount < 6)
     {
         PassiveSkill skill = new PassiveSkill(_talentID, this.actor);
         for (int i = 0; i < 6; i++)
         {
             if (this.TalentObjArray[i] == null)
             {
                 this.TalentObjArray[i] = skill;
                 this.talentCount++;
                 skill.InitCDTime(_cdTime);
                 return;
             }
         }
     }
 }
Пример #2
0
 public void InitTalent(int _talentID, int _cdTime)
 {
     if (this.talentCount < 10)
     {
         PassiveSkill passiveSkill = new PassiveSkill(_talentID, this.actor);
         passiveSkill.SlotType = SkillSlotType.SLOT_SKILL_VALID;
         for (int i = 0; i < 10; i++)
         {
             if (this.TalentObjArray[i] == null)
             {
                 this.TalentObjArray[i] = passiveSkill;
                 this.talentCount++;
                 passiveSkill.InitCDTime(_cdTime);
                 return;
             }
         }
     }
 }
Пример #3
0
 public void InitTalent(int _talentID, int _cdTime, SKILL_USE_FROM_TYPE skillUseFrom = SKILL_USE_FROM_TYPE.SKILL_USE_FROM_TYPE_SKILL, uint uiFromId = 0u)
 {
     if (this.talentCount < 10)
     {
         PassiveSkill passiveSkill = new PassiveSkill(_talentID, this.actor);
         if (passiveSkill.skillContext != null)
         {
             passiveSkill.skillContext.uiFromId     = uiFromId;
             passiveSkill.skillContext.skillUseFrom = skillUseFrom;
         }
         for (int i = 0; i < 10; i++)
         {
             if (this.TalentObjArray[i] == null)
             {
                 this.TalentObjArray[i] = passiveSkill;
                 this.talentCount++;
                 passiveSkill.InitCDTime(_cdTime);
                 return;
             }
         }
     }
 }