Fixed transient animations not causing the avatar to get stuck.

master
ZiRee 2011-04-21 17:05:18 +02:00
parent 79306e7a97
commit 5542c33b78
3 changed files with 15 additions and 4 deletions

View File

@ -312,8 +312,12 @@ const LLUUID AOEngine::override(const LLUUID pMotion,BOOL start)
if(motion==ANIM_AGENT_SIT && mCurrentSet->getSmart())
mSitCancelTimer.oneShot();
// special treatment for ground sit, because the viewer needs the Linden animation to show "Stand Up"
else if(motion==ANIM_AGENT_SIT_GROUND)
// special treatment for "transient animations" because the viewer needs the Linden animation to know the agent's state
else if(motion==ANIM_AGENT_SIT_GROUND ||
motion==ANIM_AGENT_PRE_JUMP ||
motion==ANIM_AGENT_STANDUP ||
motion==ANIM_AGENT_LAND ||
motion==ANIM_AGENT_MEDIUM_LAND)
{
gAgent.sendAnimationRequest(animation,ANIM_REQUEST_START);
return LLUUID::null;
@ -337,8 +341,12 @@ const LLUUID AOEngine::override(const LLUUID pMotion,BOOL start)
mCurrentSet->setMotion(LLUUID::null);
// again, special treatment for ground sit to make sure our own animation gets stopped properly
if(motion==ANIM_AGENT_SIT_GROUND)
// again, special treatment for "transient" animations to make sure our own animation gets stopped properly
if( motion==ANIM_AGENT_SIT_GROUND ||
motion==ANIM_AGENT_PRE_JUMP ||
motion==ANIM_AGENT_STANDUP ||
motion==ANIM_AGENT_LAND ||
motion==ANIM_AGENT_MEDIUM_LAND)
{
gAgent.sendAnimationRequest(animation,ANIM_REQUEST_STOP);
return LLUUID::null;

View File

@ -51,6 +51,7 @@ AOSet::AOSet(const LLUUID inventoryID)
"Crouching",
"Crouch Walking",
"Landing",
"Soft Landing",
"Standing Up",
"Falling",
"Flying Down",
@ -80,6 +81,7 @@ AOSet::AOSet(const LLUUID inventoryID)
ANIM_AGENT_CROUCH,
ANIM_AGENT_CROUCHWALK,
ANIM_AGENT_LAND,
ANIM_AGENT_MEDIUM_LAND,
ANIM_AGENT_STANDUP,
ANIM_AGENT_FALLDOWN,
ANIM_AGENT_HOVER_DOWN,

View File

@ -46,6 +46,7 @@ class AOSet
Crouching,
CrouchWalking,
Landing,
SoftLanding,
StandingUp,
Falling,
FlyingDown,