#W# Source and Scripts added. Added Scripts/Settings.cs to expose some basic tweak able settings.
This commit is contained in:
parent
b51c58f514
commit
3045c83799
3512 changed files with 627673 additions and 0 deletions
43
Scripts/Items/Weapons/Abilities/MovingShot.cs
Normal file
43
Scripts/Items/Weapons/Abilities/MovingShot.cs
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
using System;
|
||||
|
||||
namespace Server.Items
|
||||
{
|
||||
/// <summary>
|
||||
/// Available on some crossbows, this special move allows archers to fire while on the move.
|
||||
/// This shot is somewhat less accurate than normal, but the ability to fire while running is a clear advantage.
|
||||
/// </summary>
|
||||
public class MovingShot : WeaponAbility
|
||||
{
|
||||
public MovingShot()
|
||||
{
|
||||
}
|
||||
|
||||
public override int BaseMana{ get{ return 15; } }
|
||||
public override int AccuracyBonus{ get{ return -25; } }
|
||||
|
||||
public override bool OnBeforeSwing( Mobile attacker, Mobile defender )
|
||||
{
|
||||
return ( Validate( attacker ) && CheckMana( attacker, true ) );
|
||||
}
|
||||
|
||||
public override void OnMiss( Mobile attacker, Mobile defender )
|
||||
{
|
||||
//Validates in OnSwing for accuracy scalar
|
||||
|
||||
ClearCurrentAbility( attacker );
|
||||
|
||||
attacker.SendLocalizedMessage( 1060089 ); // You fail to execute your special move
|
||||
}
|
||||
|
||||
public override bool ValidatesDuringHit { get { return false; } }
|
||||
|
||||
public override void OnHit( Mobile attacker, Mobile defender, int damage )
|
||||
{
|
||||
//Validates in OnSwing for accuracy scalar
|
||||
|
||||
ClearCurrentAbility( attacker );
|
||||
|
||||
attacker.SendLocalizedMessage( 1060216 ); // Your shot was successful
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue