fix PlayCommand doesn't propogate

This commit is contained in:
Chris Danford
2004-02-01 04:41:48 +00:00
parent dc0201d576
commit dd78eb858f
4 changed files with 23 additions and 36 deletions
+10 -10
View File
@@ -93,11 +93,20 @@ void ActorFrame::Update( float fDeltaTime )
}
PropagateActorFrameCommand( SetDiffuse, RageColor )
PropagateActorFrameCommand( SetDiffuseAlpha, float )
PropagateActorFrameCommand( SetZTest, bool )
PropagateActorFrameCommand( SetZWrite, bool )
PropagateActorFrameCommand( HurryTweening, float )
void ActorFrame::SetDiffuseAlpha( float f )
{
Actor::SetDiffuseAlpha( f );
/* set all sub-Actors */
for( unsigned i=0; i<m_SubActors.size(); i++ )
m_SubActors[i]->SetDiffuseAlpha( f );
}
void ActorFrame::FinishTweening()
{
Actor::FinishTweening();
@@ -138,15 +147,6 @@ void ActorFrame::DeleteAllChildren()
void ActorFrame::HandleCommand( const ParsedCommand &command )
{
// pass "PlayCommand" on to children
if( command.vTokens[0].s=="playcommand" )
{
for( unsigned i=0; i<m_SubActors.size(); i++ )
m_SubActors[i]->HandleCommand( command );
return; // handled
}
// base class handles the rest...
Actor::HandleCommand( command );
}