Change the Airborn to mousedown?
by Robert Carroll · in Torque Game Builder · 10/30/2009 (12:13 am) · 1 replies
Hi, I was wondering how I could edit this code bit to make it play when the mouse is down and stop when the mouse is up.
================
================
if(%this.owner.airborne)
{
if(%yVelocity < 250)
%this.owner.playAnimation(playerJumpUp);
else
%this.owner.playAnimation(playerJumpDown);
}
else
{
if(%xVelocity == 0)
{
%this.owner.playAnimation(playerWait);
}
else
{
if(%this.owner.getAnimationName() $= "playerRun")
{
if(%this.owner.getIsAnimationFinished())
%this.owner.playAnimation(playerRun);
}
else
%this.owner.playAnimation(playerRun);
}
}
}About the author
Stay Up all night playing PS3 ;) add me PSN: RCBASEBALL13.
Torque Owner Robert Carroll