Remedy_510540.cs 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. using CommonAI.Zone;
  2. using CommonAI.Zone.Helper;
  3. using CommonAI.Zone.Instance;
  4. using XmdsCommon.Plugin;
  5. using XmdsCommonServer.Plugin;
  6. using XmdsCommonServer.XLS.Data;
  7. using XmdsCommonSkill.Plugin.Buffs;
  8. namespace XmdsCommonSkill.Plugin.Skills.Remedy
  9. {
  10. /// <summary>
  11. /// 治疗, 五技能 5-4(自己造成的伤害提高10%,新增:叠毒几率上升n%)
  12. /// </summary>
  13. public class Remedy_510540 : Remedy_510500
  14. {
  15. private static readonly int ID = 510540;
  16. public override int SkillID { get { return ID; } }
  17. //伤害倍数, 叠毒几率提高
  18. public XmdsSkillValue valueSet2;
  19. protected override int OnLaunchSkillOver(GameSkill info, XmdsCommonServer.Plugin.XmdsVirtual launcher, CommonAI.Zone.Instance.InstanceUnit.SkillState skill)
  20. {
  21. base.OnLaunchSkillOver(info, launcher, skill);
  22. var playerTalent = launcher.GetPlayerCache() as PlayerCache_Remedy;
  23. if(playerTalent != null)
  24. {
  25. playerTalent.SetStrong5_4(valueSet5.GetValue(info.SkillLevel, 4), valueSet2.GetValue(info.TalentSkillLevel1, 2));
  26. }
  27. return 0;
  28. }
  29. protected override void OnSkillDamagePerEvent(BattleParams param)
  30. {
  31. base.OnSkillDamagePerEvent(param);
  32. param.SkillDamagePer += valueSet2.GetValue(param.GameSkill.TalentSkillLevel1);
  33. }
  34. protected override void OnInitConfig()
  35. {
  36. XmdsSkillData data = XmdsDataMgr.GetInstance().GetXmdsSkillData(ID);
  37. base.InitBaseConfig(data);
  38. InitData(data, out valueSet, XmdsSkillData.XmdsSkillDataKey.ValueSet);
  39. InitData(data, out valueSet2, XmdsSkillData.XmdsSkillDataKey.ValueSet2);
  40. // 扩展配置
  41. InitData(data, out valueSet5, XmdsSkillData.XmdsSkillDataKey.ValueSet5);
  42. InitData(data, out valueSet7, XmdsSkillData.XmdsSkillDataKey.ValueSet7);
  43. }
  44. }
  45. }