示例#1
0
 public static void InvokeTargetedSkillUse(TargetedSkillUseEventArgs e)
 {
     if (TargetedSkillUse != null)
     {
         TargetedSkillUse(e);
     }
 }
示例#2
0
        private static void Targeted_Skill(TargetedSkillUseEventArgs e)
        {
            Mobile from = e.NetState.Mobile;

            try
            {
                int SkillId = e.SkillID;
                Mobile to = World.FindMobile(e.Target.Serial);
                Item toI = World.FindItem(e.Target.Serial);

                if (to != null)
                {
                    from.TargetLocked = true;
                    if (from.UseSkill(e.SkillID))
                        from.Target.Invoke(from, to);
                }
                else if (toI != null)
                {
                    from.TargetLocked = true;
                    if (from.UseSkill(e.SkillID))
                        from.Target.Invoke(from, toI);
                }
            }
            catch { }
            finally { from.TargetLocked = false; }
        }
 public static void InvokeTargetedSkillUse(TargetedSkillUseEventArgs e)
 {
     if (TargetedSkillUse != null)
         TargetedSkillUse(e);
 }