/// <summary> /// Constructor for Addition: Short Sword Mastery /// </summary> /// <param name="id">Skill ID</param> /// <param name="actor">Actor, which this addition get attached to</param> public DefaultPassiveSkill(SkillIDs id, Actor actor, string name, bool ifActivate) { this.Name = name; this.skillID = id; this.AttachedActor = actor; this.activate = ifActivate; }
private static void AddSub(SkillIDs baseskill, int levels, SkillCommand func) { for (int i = 0; i < levels; i++) { SkillCommands.Add((SkillIDs)((int)baseskill + i), func); } }
/// <summary> /// Constructor for Addition: Short Sword Mastery /// </summary> /// <param name="id">Skill ID</param> /// <param name="actor">Actor, which this addition get attached to</param> public DefaultPassiveSkill(SkillIDs id, Actor actor,string name, bool ifActivate) { this.Name = name; this.skillID = id; this.AttachedActor = actor; this.activate = ifActivate; }
public DefaultBuff(SkillIDs id, Actor actor, string name, int lifetime, Addition.AdditionType type) { this.Name = name; this.skillID = id; this.AttachedActor = actor; this.lifeTime = lifetime; this.MyType = type; }
public DefaultBuff(SkillIDs id, Actor actor, string name,int lifetime, Addition.AdditionType type) { this.Name = name; this.skillID = id; this.AttachedActor = actor; this.lifeTime = lifetime; this.MyType = type; }
/// <summary> /// Check if the player has enough sp to cast skill, and decrease SP by the required amount /// </summary> /// <param name="pc">Player</param> /// <param name="skillid">Skill ID</param> /// <returns></returns> public static bool CheckSkillSP(ActorPC pc, SkillIDs skillid) { ActorEventHandlers.PC_EventHandler eh = (ActorEventHandlers.PC_EventHandler)pc.e; Skill skill = SkillFactory.GetSkill((uint)skillid); if (pc.SP < skill.sp) { return(false); } pc.SP -= (ushort)skill.sp; eh.C.SendCharStatus(0); return(true); }
public static int GetSkillMAtkBonus(SkillIDs id) { Actor tmpActor = new Actor(); tmpActor.BattleStatus = new BattleStatus(); Bonus.BonusHandler.Instance.SkillAddAddition(tmpActor, (uint)id, false); int tmpBonus = 0; if (tmpActor.BattleStatus.matkmaxbonus > tmpActor.BattleStatus.matkminbonus) { tmpBonus = Global.Random.Next(tmpActor.BattleStatus.matkminbonus, tmpActor.BattleStatus.matkmaxbonus); } return(tmpActor.BattleStatus.matkbonus + tmpActor.BattleStatus.matkskill + tmpBonus); }
/// <summary> /// Increase Players LP /// </summary> /// <param name="pc">Player</param> /// <param name="skillID">ID of the skill that caused the increasement of LP</param> /// <param name="point">Amount</param> public static void GainLP(ActorPC pc, SkillIDs skillID, byte point) { ActorEventHandlers.PC_EventHandler eh = (ActorEventHandlers.PC_EventHandler)pc.e; pc.LP += point; if (pc.LP > 5) { pc.LP = 5; } else { eh.C.SendSkillEffect(SkillFactory.GetSkill((uint)skillID).addition, SkillEffects.LP, point); } eh.C.SendCharStatus(0); }
public HeroItem Clone() { HeroItem item = new HeroItem(); item.Name = Name; item.Title = (Description)Title.Clone(); item.Description = (Description)Description.Clone(); item.IconPath = IconPath; item.DropCriteria = (DropCriteria)DropCriteria?.Clone(); item.AttackType = AttackType; item.WeaponType = WeaponType; item.Category = Category; item.SkillIDs = SkillIDs?.Clone(); item.Descriptors = Descriptors?.Clone(); return(item); }
/// <summary> /// Constructor for Addition: RapidRun /// </summary> /// <param name="id">Skill ID</param> /// <param name="actor">Actor, which this addition get attached to</param> public RapidRun(SkillIDs id, Actor actor) { this.Name = "RapidRun"; this.skillID = id; this.AttachedActor = actor; }
/// <summary> /// Constructor for Addition: Short Sword Mastery /// </summary> /// <param name="id">Skill ID</param> /// <param name="actor">Actor, which this addition get attached to</param> public Integritas(SkillIDs id, Actor actor) { this.Name = "Integritas"; this.skillID = id; this.AttachedActor = actor; }
/// <summary> /// Constructor for Addition: Short Sword Mastery /// </summary> /// <param name="id">Skill ID</param> /// <param name="actor">Actor, which this addition get attached to</param> public CloseOrderDrill(SkillIDs id, Actor actor) { this.Name = "CloseOrderDrill"; this.skillID = id; this.AttachedActor = actor; }
/// <summary> /// Constructor for Addition: Short Sword Mastery /// </summary> /// <param name="id">Skill ID</param> /// <param name="actor">Actor, which this addition get attached to</param> public DampRifleMastery(SkillIDs id, Actor actor) { this.Name = "DampRifleMastery"; this.skillID = id; this.AttachedActor = actor; }
/// <summary> /// Constructor for Addition: RapidRun /// </summary> /// <param name="id">Skill ID</param> /// <param name="actor">Actor, which this addition get attached to</param> public Designation(SkillIDs id, Actor actor) { this.Name = "Designation"; this.skillID = id; this.AttachedActor = actor; }
/// <summary> /// Increase Players LP /// </summary> /// <param name="pc">Player</param> /// <param name="skillID">ID of the skill that caused the increasement of LP</param> /// <param name="point">Amount</param> public static void GainLP(ActorPC pc, SkillIDs skillID, byte point) { ActorEventHandlers.PC_EventHandler eh = (ActorEventHandlers.PC_EventHandler)pc.e; pc.LP += point; if (pc.LP > 5) pc.LP = 5; else eh.C.SendSkillEffect(SkillFactory.GetSkill((uint)skillID).addition, SkillEffects.LP, point); eh.C.SendCharStatus(0); }
public static int GetSkillRAtkBonus(SkillIDs id) { Actor tmpActor = new Actor(); tmpActor.BattleStatus = new BattleStatus(); Bonus.BonusHandler.Instance.SkillAddAddition(tmpActor, (uint)id, false); int tmpBonus = 0; if(tmpActor.BattleStatus.ratkmaxbonus > tmpActor.BattleStatus.ratkminbonus) { tmpBonus = Global.Random.Next(tmpActor.BattleStatus.ratkminbonus, tmpActor.BattleStatus.ratkmaxbonus); } return tmpActor.BattleStatus.ratkbonus + tmpActor.BattleStatus.ratkskill + tmpBonus; }
public DefaultStance(SkillIDs id, Actor actor,string name) { this.Name = name; this.skillID = id; this.AttachedActor = actor; }
public DefaultStance(SkillIDs id, Actor actor, string name) { this.Name = name; this.skillID = id; this.AttachedActor = actor; }
public StarverSkill this[SkillIDs id] => this[(int)id];
/// <summary> /// Constructor for Addition: Short Sword Mastery /// </summary> /// <param name="id">Skill ID</param> /// <param name="actor">Actor, which this addition get attached to</param> public ShortSwordMastery(SkillIDs id, Actor actor) { this.Name = "ShortSwordMastery"; this.skillID = id; this.AttachedActor = actor; }
/// <summary> /// Check if the player has enough sp to cast skill, and decrease SP by the required amount /// </summary> /// <param name="pc">Player</param> /// <param name="skillid">Skill ID</param> /// <returns></returns> public static bool CheckSkillSP(ActorPC pc, SkillIDs skillid) { ActorEventHandlers.PC_EventHandler eh = (ActorEventHandlers.PC_EventHandler)pc.e; Skill skill = SkillFactory.GetSkill((uint)skillid); if (pc.SP < skill.sp) return false; pc.SP -= (ushort)skill.sp; eh.C.SendCharStatus(0); return true; }