Pass ActorCommand structures to Actor instead of unparsed command strings.
This way, we can potentially do the parsing early and not parse inside of Actor as the command is executing.
This commit is contained in:
@@ -50,19 +50,22 @@ void ScoreDisplayBattle::Update( float fDelta )
|
||||
m_iLastSeenInventory[s] = sNewModifier;
|
||||
|
||||
if( sNewModifier == "" )
|
||||
m_ItemIcon[s].Command( "linear,0.25;zoom,0" );
|
||||
{
|
||||
m_ItemIcon[s].Command( ParseActorCommands("linear,0.25;zoom,0") );
|
||||
}
|
||||
else
|
||||
{
|
||||
// TODO: Cache all of the icon graphics so we don't load them dynamically from disk.
|
||||
m_ItemIcon[s].Load( THEME->GetPathToG("ScoreDisplayBattle icon "+sNewModifier) );
|
||||
m_ItemIcon[s].StopTweening();
|
||||
m_ItemIcon[s].Command( "diffuse,1,1,1,1;zoom,1;"
|
||||
m_ItemIcon[s].Command( ParseActorCommands(
|
||||
"diffuse,1,1,1,1;zoom,1;"
|
||||
"sleep,0.1;linear,0;diffusealpha,0;"
|
||||
"sleep,0.1;linear,0;diffusealpha,1;"
|
||||
"sleep,0.1;linear,0;diffusealpha,0;"
|
||||
"sleep,0.1;linear,0;diffusealpha,1;"
|
||||
"sleep,0.1;linear,0;diffusealpha,0;"
|
||||
"sleep,0.1;linear,0;diffusealpha,1;" );
|
||||
"sleep,0.1;linear,0;diffusealpha,1;" ) );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user