[code]Animation("stand_weak")
{
AimType("FullBody");
}
Animation("stand_medium")
{
AimType("FullBody");
}
Animation("stand_strong")
{
AimType("FullBody");
}
Animation("stand_idle_weak")
{
AimType("FullBody");
}
Animation("stand_idle_medium")
{
AimType("FullBody");
}
Animation("stand_idle_strong")
{
AimType("FullBody");
}
State("IDLE")
{
Duration(0.0); // infinite duration
EnergyRestoreRate(); // (0.0, "FromSoldier")
InputLock(0.1, "Sprint", "Jump", "Crouch");
TurnOffLightsaber();
Transition("JUMPATTACK_FALL")
{
If()
{
Break(); // all transitions are breaking if Duration is 0
Posture("Jump", "Jet");
//The following should be true during a jetjump, jump, or fall
// unless we're more than 0.35 seconds from the apex
//NOTE: This may not allow luke to jump attack during longer falls
// or falling from a force jump when it could.
//VelocityY(">", -6.3);
Button("Fire", "Press");
}
}
Transition("FOCUS")
{
If()
{
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Crouch", "Press");
}
}
Transition("WEAKBLOW")
{
EnergyCost(5.0)
If()
{
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Fire", "Press");
}
}
}
//--------------------FOCUS LUKE! USE THE FORCE!----------
State("FOCUS")
{
Posture("Stand");
Deflect()
{
DeflectAngle(-360, 360); // deflect anything from forward arc
EnergyCost(0.0);
}
ThrustFactor(0.0)
StrafeFactor(0.0);
Duration(5.0, "Seconds");
TurnFactor(0.0);
InputLock(0.0, "All", "!Fire", "!Reload", "!FireSecondary"); // lock all controls for duration of state
Transition("FUNCTIONWEAK")
{
EnergyCost(5.0)
If()
{
TimeStart(0.0, "Seconds");
TimeEnd(5.0, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Fire", "Press");
}
}
Transition("FUNCTIONMEDIUM")
{
EnergyCost(10.0)
If()
{
TimeStart(0.0, "Seconds");
TimeEnd(5.0, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("FireSecondary", "Press");
}
}
Transition("FUNCTIONSTRONG")
{
EnergyCost(15.0)
If()
{
TimeStart(0.0, "Seconds");
TimeEnd(5.0, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Reload", "Press");
}
}
Transition("IDLE");
}
//----------------------------You've chosen the Weak stance!------------
State("FUNCTIONWEAK")
{
Posture("Stand");
Animation("stand_idle_weak")
{
AimType("FullBody");
}
Duration(0.0, "Seconds");
TurnFactor(1.0);
Transition("WEAKBLOW")
{
EnergyCost(5.0)
If()
{
TimeStart(0.0, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Fire", "Press");
}
}
Transition("FOCUS")
{
If()
{
TimeStart(0.0, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Crouch", "Press");
}
}
Transition("JUMPATTACK_FALL")
{
If()
{
Break(); // all transitions are breaking if Duration is 0
Posture("Jump", "Jet");
//The following should be true during a jetjump, jump, or fall
// unless we're more than 0.35 seconds from the apex
//NOTE: This may not allow luke to jump attack during longer falls
// or falling from a force jump when it could.
//VelocityY(">", -6.3);
Button("Fire", "Press");
}
}
Transition("IDLE");
{
If()
{
Energy("<", 0.0);
}
}
Transition("FUNCTIONWEAK");
}
State("WEAKBLOW")
{
Posture("Stand");
Animation("stand_weak")
{
// SyncType("attack1c", "ByTime");
AimType("None");
BlendInTime(0.15);
BlendOutTime(0.15);
}
Sound("com_weap_melee_swing", 15, "Frames");
//set a duration so we will go to state RECOVER3 before the animation ends
AlignedToThrust();
Duration(0.5, "Seconds");
StrafeFactor(0.5);
TurnFactor(0.5);
Deflect()
{
DeflectAngle(-360, 360); // deflect anything from forward arc
EnergyCost(5.0);
}
InputLock("All", "!Thrust", "!Crouch"); // lock all controls for duration of state
Attack()
{
DamageTime(0.1, 0.2, "Seconds");
DamageLength(1.5);
DamageWidth(1.25);
Damage(100);
Push(2.0);
}
Attack()
{
DamageTime(0.2, 0.3, "Seconds");
DamageLength(1.5);
DamageWidth(1.25);
Damage(100);
Push(2.0);
}
Transition("FOCUS")
{
If()
{
TimeStart(0.4, "Seconds");
TimeEnd(0.5, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Crouch", "Press");
}
}
Transition("IDLE");
{
If()
{
Energy("<", 0.0);
}
}
Transition("TRANSITION");
}
State("TRANSITION")
{
Posture("Stand");
Animation("stand_transition")
{
BlendInTime(0.10);
BlendOutTime(0.25);
}
AlignedToThrust();
TurnFactor(0.3);
InputLock("All", "!Thrust", "!Fire", "!FireSecondary", "!Reload",);
Transition("WEAKBLOW")
{
EnergyCost(10.0)
If()
{
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Fire", "Press");
}
}
Transition("MEDIUMBLOW")
{
EnergyCost(25.0)
If()
{
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("FireSecondary", "Press");
}
}
Transition("STRONGBLOW")
{
EnergyCost(45.0)
If()
{
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Reload", "Press");
}
}
Transition("IDLE");
}
//-------------------------------You've chosen the Medium stance!-------------------
State("FUNCTIONMEDIUM")
{
Posture("Stand");
Animation("stand_idle_medium")
{
AimType("FullBody");
}
Duration(0.0, "Seconds");
TurnFactor(1.0);
Transition("MEDIUMBLOW")
{
EnergyCost(10.0)
If()
{
TimeStart(0.0, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Fire", "Press");
}
}
Transition("FOCUS")
{
If()
{
TimeStart(0.0, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Crouch", "Press");
}
}
Transition("JUMPATTACK_FALL")
{
If()
{
Break(); // all transitions are breaking if Duration is 0
Posture("Jump", "Jet");
//The following should be true during a jetjump, jump, or fall
// unless we're more than 0.35 seconds from the apex
//NOTE: This may not allow luke to jump attack during longer falls
// or falling from a force jump when it could.
//VelocityY(">", -6.3);
Button("Fire", "Press");
}
}
Transition("IDLE");
{
If()
{
Energy("<", 0.0);
}
}
Transition("FUNCTIONMEDIUM");
}
State("MEDIUMBLOW")
{
Posture("Stand");
Animation("stand_medium")
{
// SyncType("attack1c", "ByTime");
AimType("None");
BlendInTime(0.15);
BlendOutTime(0.15);
}
Sound("com_weap_melee_swing", 15, "Frames");
//set a duration so we will go to state RECOVER3 before the animation ends
AlignedToThrust();
Duration(0.5, "Seconds");
StrafeFactor(0.5);
TurnFactor(0.5);
Deflect()
{
DeflectAngle(-360, 360); // deflect anything from forward arc
EnergyCost(5.0);
}
InputLock("All", "!Thrust", "!Crouch"); // lock all controls for duration of state
Attack()
{
DamageTime(0.1, 0.2, "Seconds");
DamageLength(1.5);
DamageWidth(1.25);
Damage(400);
Push(2.0);
}
Attack()
{
DamageTime(0.2, 0.3, "Seconds");
DamageLength(1.5);
DamageWidth(1.25);
Damage(400);
Push(2.0);
}
Transition("FOCUS")
{
If()
{
TimeStart(0.4, "Seconds");
TimeEnd(0.5, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Crouch", "Press");
}
}
Transition("JUMPATTACK_FALL")
{
If()
{
Break(); // all transitions are breaking if Duration is 0
Posture("Jump", "Jet");
//The following should be true during a jetjump, jump, or fall
// unless we're more than 0.35 seconds from the apex
//NOTE: This may not allow luke to jump attack during longer falls
// or falling from a force jump when it could.
//VelocityY(">", -6.3);
Button("Fire", "Press");
}
}
Transition("IDLE");
{
If()
{
Energy("<", 0.0);
}
}
Transition("TRANSITION");
}
//--------------------------------YOU HAVE GIVEN INTO YOUR HATE! OH NOES!!-----------
State("FUNCTIONSTRONG")
{
Posture("Stand");
Animation("stand_idle_strong")
{
AimType("FullBody");
}
Duration(0.0, "Seconds");
TurnFactor(1.0);
Transition("STRONGBLOW")
{
EnergyCost(15.0)
If()
{
TimeStart(0.0, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Fire", "Press");
}
}
Transition("FOCUS")
{
If()
{
TimeStart(0.0, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Crouch", "Press");
}
}
Transition("JUMPATTACK_FALL")
{
If()
{
Break(); // all transitions are breaking if Duration is 0
Posture("Jump", "Jet");
//The following should be true during a jetjump, jump, or fall
// unless we're more than 0.35 seconds from the apex
//NOTE: This may not allow luke to jump attack during longer falls
// or falling from a force jump when it could.
//VelocityY(">", -6.3);
Button("Fire", "Press");
}
}
Transition("IDLE");
{
If()
{
Energy("<", 0.0);
}
}
Transition("FUNCTIONSTRONG");
}
State("STRONGBLOW")
{
Posture("Stand");
Animation("stand_strong")
{
// SyncType("attack1c", "ByTime");
AimType("None");
BlendInTime(0.15);
BlendOutTime(0.15);
}
Sound("com_weap_melee_swing", 15, "Frames");
//set a duration so we will go to state RECOVER3 before the animation ends
AlignedToThrust();
Duration(1.0, "Seconds");
StrafeFactor(0.5);
TurnFactor(0.5);
Deflect()
{
DeflectAngle(-360, 360); // deflect anything from forward arc
EnergyCost(15.0);
}
InputLock("All", "!Thrust", "!FireSecondary", "!Crouch", "!Fire",); // lock all controls for duration of state
Attack()
{
DamageTime(0.1, 0.2, "Seconds");
DamageLength(1.5);
DamageWidth(1.25);
Damage(500);
Push(8.0);
}
Attack()
{
DamageTime(0.2, 0.6, "Seconds");
DamageLength(1.5);
DamageWidth(1.25);
Damage(500);
Push(8.0);
}
Attack()
{
DamageTime(0.5, 0.7, "Seconds");
DamageLength(1.5);
DamageWidth(1.25);
Damage(500);
Push(8.0);
}
Attack()
{
DamageTime(0.8, 0.9, "Seconds");
DamageLength(1.5);
DamageWidth(1.25);
Damage(900);
Push(8.0);
}
Transition("FOCUS")
{
If()
{
TimeStart(0.4, "Seconds");
TimeEnd(0.5, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Crouch", "Press");
}
}
Transition("STRONGBLOW")
{
EnergyCost(15.0)
If()
{
TimeStart(0.9, "Seconds");
TimeEnd(1.0, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Fire", "Press");
}
}
Transition("STRIKE")
{
EnergyCost(15.0)
If()
{
TimeStart(0.9, "Seconds");
TimeEnd(1.0, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("FireSecondary", "Press");
}
}
Transition("IDLE");
{
If()
{
Energy("<", 0.0);
}
}
Transition("FUNCTIONSTRONG");
}
State("STRIKE")
{
Posture("Stand");
Animation("stand_strike")
{
AimType("FullBody");
BlendInTime(0.10);
BlendOutTime(0.25);
BlendTimeTo("stand_medium", 0.4);
}
Sound("saber_swing");
AnimatedMove()
{
VelocityZ(5.0);
VelocityX(0.0);
VelocityFromThrust(0.5);
VelocityFromStrafe(0.5);
Until()
{
Break(0.5, "Seconds");
}
}
TurnFactor(0.6);
Duration(1.0, "Seconds");
InputLock("All", "!Thrust");
Attack()
{
DamageTime(0.1, 0.2, "Seconds");
DamageLength(1.5);
DamageWidth(1.25);
Damage(500);
Push(8.0);
}
Attack()
{
DamageTime(0.2, 0.6, "Seconds");
DamageLength(1.5);
DamageWidth(1.25);
Damage(500);
Push(8.0);
}
Attack()
{
DamageTime(0.5, 0.7, "Seconds");
DamageLength(1.5);
DamageWidth(1.25);
Damage(500);
Push(8.0);
}
Attack()
{
DamageTime(0.8, 0.9, "Seconds");
DamageLength(1.5);
DamageWidth(1.25);
Damage(900);
Push(8.0);
}
Transition("STRIKE2");
}
State("STRIKE2")
{
Posture("Stand");
Animation("stand_strike")
{
AimType("FullBody");
BlendInTime(0.10);
BlendOutTime(0.25);
BlendTimeTo("stand_strike", 0.4);
}
Duration(0.2, "Seconds");
AnimatedMove()
{
VelocityZ(0.0);
VelocityX(0.0);
VelocityFromThrust(0.5);
VelocityFromStrafe(0.5);
}
TurnFactor(0.3);
PlayExplosion();
InputLock("All", "!Fire", "!Crouch", "!Thrust");
Transition("FOCUS")
{
If()
{
TimeStart(0.0, "Seconds");
TimeEnd(0.2, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Crouch", "Press");
}
}
Transition("STRONGBLOW")
{
EnergyCost(15.0)
If()
{
TimeStart(0.0, "Seconds");
TimeEnd(0.2, "Seconds");
Break(); // all transitions are breaking if Duration is 0
Posture("Stand");
Button("Fire", "Press");
}
}
Transition("DASHATTACK_RECOVER");
}
State("DASHATTACK_RECOVER")
{
Posture("Stand");
Animation("stand_strike_end")
{
BlendInTime(0.10);
BlendOutTime(0.25);
}
AlignedToThrust();
TurnFactor(0.3);
InputLock("All", "!Thrust", "!Fire");
Transition("FUNCTIONSTRONG");
}
Animation("jumpattack_land");
State("JUMPATTACK_FALL")
{
Posture("Jump");
Animation("jumpattack_fall")
{
Loop("FinalFrame");
AimType("None");
BlendInTime(0.15);
BlendOutTime(0.80);
// BlendTimeTo("jumpattack_land", 0.15);
}
Sound("saber_swing", 3, "Frames");
Gravity(2.0);
GravityVelocityTarget(-20.0); // accelerate us to 20m/s down at 2 g's
AnimatedMove();
InputLock("All", "!Thrust"); // lock all buttons for duration of state
Attack()
{
AttackId("JUMPATTACK");
DamageTime(0.33, 1.0, "FromAnim");
DamageLength(1.75);
DamageWidth(1.25);
Damage(800);
Push(4.0);
}
Transition("JUMPATTACK_LAND")
{
If()
{
Break();
Posture("Stand");
}
}
Transition("IDLE")
{
If()
{
Break();
Posture("Any", "!Stand", "!Jump", "!Jet");
}
}
Transition("JUMPATTACK_END")
}
State("JUMPATTACK_END")
{
Posture("Jump");
Animation("jumpattack_land")
{
AimType("None");
SyncType("jumpattack_land", "ByTime");
BlendInTime(0.15);
BlendOutTime(0.80);
// BlendTimeTo("jumpattack_land", 0.15);
}
Gravity(2.0);
GravityVelocityTarget(-20.0); // accelerate us to 20m/s down at 2 g's
Duration(15, "Frames");
AnimatedMove();
InputLock("All", "!Thrust"); // lock all buttons for duration of state
Attack()
{
AttackId("JUMPATTACK");
DamageTime(0, 6, "Frames");
DamageLength(1.75);
DamageWidth(1.25);
Damage(800);
Push(4.0);
}
Transition("JUMPATTACK_LAND")
{
If()
{
Break();
Posture("Stand");
}
}
Transition("IDLE")
{
If()
{
Break();
Posture("Any", "!Stand", "!Jump", "!Jet");
}
}
Transition("IDLE");
}
State("JUMPATTACK_LAND")
{
Posture("Stand");
Animation("jumpattack_land")
{
AimType("FullBody");
SyncType("jumpattack_land", "ByTime");
BlendInTime(0.00);
BlendOutTime(0.20);
}
AnimatedMove();
InputLock("All");
Attack()
{
AttackId("JUMPATTACK");
DamageTime(0, 6, "Frames");
DamageLength(1.75);
DamageWidth(.75);
Damage(800);
Push(4.0);
}
Transition("IDLE")
{
If()
{
Break(0.4);
ButtonsPressed("Any");
}
Or()
{
Break(0.4);
Thrust(">", 0.54);
}
}
}[/code]