1234567891011121314151617181920212223242526272829303132333435363738394041424344454647 |
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- using XmdsCommonServer.XLS.Data;
- using XmdsCommonServer.Plugin;
- using CommonAI.Zone.Formula;
- using XmdsCommonSkill.Plugin.Skills;
- namespace XmdsCommonSkill.Plugin.CardSkill
- {
- public class CardSkill_1030000 : CardSkill_LiangYiBase
- {
- private static readonly int ID = 1030000;
- public override int SkillID { get { return ID; } }
- /// 伤害倍数: 百分比
- protected static XmdsSkillValue s_ValueSet1;
- // 获得权重最高的球的概率
- protected static XmdsSkillValue s_ValueSet2;
- protected override void OnGetCardSkillDamage(BattleParams param)
- {
- param.SkillDamagePer = s_ValueSet1.GetValue(param.GameSkill.SkillLevel);
- }
- //触发卡牌技能
- public override void OnTriggerCardSkill(XmdsVirtual player, XmdsVirtual hitter, AttackSource source, CardSkillData skillData, int sameNums)
- {
- base.unitLaunchSpell(player, hitter, this.GetEffectID(skillData.skilLv, sameNums));
- if (player.RandomPercent(s_ValueSet2.GetValue(skillData.skilLv)))
- {
- //获得一个权重最高的求
- player.CardModule.AddCard(1, false);
- }
- }
- protected override void OnInitSkillParam()
- {
- XmdsSkillData data = XmdsDataMgr.GetInstance().GetXmdsSkillData(this.SkillID);
- InitData(data, out s_ValueSet1, XmdsSkillData.XmdsSkillDataKey.ValueSet);
- InitData(data, out s_ValueSet2, XmdsSkillData.XmdsSkillDataKey.ValueSet2);
- }
- }
- }
|