fix assertion. PushAttrValue always pushes something; if no value,
then it pushes nil (like lua_gettable)
This commit is contained in:
@@ -126,11 +126,12 @@ void ActorScroller::LoadFromNode( const XNode *pNode )
|
|||||||
ActorScroller::SetSecondsPerItem( fSecondsPerItem );
|
ActorScroller::SetSecondsPerItem( fSecondsPerItem );
|
||||||
|
|
||||||
Lua *L = LUA->Get();
|
Lua *L = LUA->Get();
|
||||||
if( pNode->PushAttrValue(L, "TransformFunction") )
|
pNode->PushAttrValue( L, "TransformFunction" );
|
||||||
{
|
{
|
||||||
LuaReference ref;
|
LuaReference ref;
|
||||||
ref.SetFromStack( L );
|
ref.SetFromStack( L );
|
||||||
SetTransformFromReference( ref );
|
if( !ref.IsNil() )
|
||||||
|
SetTransformFromReference( ref );
|
||||||
}
|
}
|
||||||
LUA->Release( L );
|
LUA->Release( L );
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user