예제 #1
0
 // 		private const int key_BuffId1_SkillConfig = 0;
 // 		private const int key_BuffId2_SkillConfig = 1;
 // 		private const int key_BuffId3_SkillConfig = 2;
 public override bool OnEffect(SkillObj self, SkillObj target, SkillInfo_New skillInfo, SkillConfig_New skillConfig)
 {
     var buffIds = self.GetSkillIntParams(skillConfig);
     foreach(var buffId in buffIds)
     {
         BattleModule.AddBuff(target, self, buffId, BattleReason.Skill);
     }
     return true;
 }
예제 #2
0
//      private const int key_BuffId1_SkillConfig = 0;
//      private const int key_BuffId2_SkillConfig = 1;
//      private const int key_BuffId3_SkillConfig = 2;
        public override bool OnEffect(SkillObj self, SkillObj target, SkillInfo_New skillInfo, SkillConfig_New skillConfig)
        {
            var buffIds = self.GetSkillIntParams(skillConfig);

            foreach (var buffId in buffIds)
            {
                BattleModule.AddBuff(target, self, buffId, BattleReason.Skill);
            }
            return(true);
        }
예제 #3
0
 public override bool OnEffect(SkillObj self, SkillObj target, SkillInfo_New skillInfo, SkillConfig_New skillConfig)
 {
     int id = self.GetSkillIntParam(skillConfig, key_SummonId);
     var summonTar = BattleModule.Summon(id, self, target, skillInfo, skillConfig);
     if(summonTar != null)
     {
         var buffIds = self.GetSkillIntParams(skillConfig);
         foreach (var buffId in buffIds.Skip(key_SummonId + 1))
         {
             BattleModule.AddBuff(summonTar, self, buffId, BattleReason.Skill);
         }
     }
     {
         //int iBuffId = self.GetSkillIntParam(skillConfig, key_BuffId);
         //if (iBuffId > 0)
         //{
         //	BattleModule.AddBuff(summonTar, self, iBuffId, BattleReason.Skill);
         //}
     }
     return true;
 }
예제 #4
0
        public override bool OnEffect(SkillObj self, SkillObj target, SkillInfo_New skillInfo, SkillConfig_New skillConfig)
        {
            int id        = self.GetSkillIntParam(skillConfig, key_SummonId);
            var summonTar = BattleModule.Summon(id, self, target, skillInfo, skillConfig);

            if (summonTar != null)
            {
                var buffIds = self.GetSkillIntParams(skillConfig);
                foreach (var buffId in buffIds.Skip(key_SummonId + 1))
                {
                    BattleModule.AddBuff(summonTar, self, buffId, BattleReason.Skill);
                }
            }
            {
                //int iBuffId = self.GetSkillIntParam(skillConfig, key_BuffId);
                //if (iBuffId > 0)
                //{
                //	BattleModule.AddBuff(summonTar, self, iBuffId, BattleReason.Skill);
                //}
            }
            return(true);
        }
예제 #5
0
 //private const int Key_Double_BuffBegin_SkillConfig = 0;
 public override bool OnEffect(SkillObj self, SkillObj target, SkillInfo_New skillInfo, SkillConfig_New skillConfig)
 {
     if(self.GetCamp()!=target.GetCamp())
     {
         int iDamamge = self.GetSkillIntParam(skillConfig, Key_Damege_SkillConfig);
         Damage damage = BattleModule.CreateDamage(iDamamge);
         BattleModule.DamageTarget(target, self, damage);
         var buffIds = self.GetSkillIntParams(skillConfig).Skip(Key_Damege_SkillConfig + 1);
         foreach (var buffId in buffIds)
         {
             BattleModule.AddBuff(target, self, buffId, BattleReason.Skill);
         }
     }
     else
     {
         var buffIds = self.GetSkillDoubleParams(skillConfig).Select(d=>(int)d);
         foreach (var buffId in buffIds)
         {
             BattleModule.AddBuff(target, self, buffId, BattleReason.Skill);
         }
     }
     return true;
 }
예제 #6
0
 //private const int Key_Double_BuffBegin_SkillConfig = 0;
 public override bool OnEffect(SkillObj self, SkillObj target, SkillInfo_New skillInfo, SkillConfig_New skillConfig)
 {
     if (self.GetCamp() != target.GetCamp())
     {
         int    iDamamge = self.GetSkillIntParam(skillConfig, Key_Damege_SkillConfig);
         Damage damage   = BattleModule.CreateDamage(iDamamge);
         BattleModule.DamageTarget(target, self, damage);
         var buffIds = self.GetSkillIntParams(skillConfig).Skip(Key_Damege_SkillConfig + 1);
         foreach (var buffId in buffIds)
         {
             BattleModule.AddBuff(target, self, buffId, BattleReason.Skill);
         }
     }
     else
     {
         var buffIds = self.GetSkillDoubleParams(skillConfig).Select(d => (int)d);
         foreach (var buffId in buffIds)
         {
             BattleModule.AddBuff(target, self, buffId, BattleReason.Skill);
         }
     }
     return(true);
 }