EgtExecutor 1.8c3 :
- aggiunte funzioni Exe e Lua GetFirstGhostPart e GetNextGhostPart.
This commit is contained in:
@@ -277,6 +277,40 @@ LuaGetPrevLayer( lua_State* L)
|
||||
return 1 ;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
static int
|
||||
LuaGetFirstGhostPart( lua_State* L)
|
||||
{
|
||||
// nessuno parametro
|
||||
LuaClearStack( L) ;
|
||||
// cerco primo pezzo messo in grezzo
|
||||
int nId = ExeGetFirstGhostPart() ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetParam( L, nId) ;
|
||||
else
|
||||
LuaSetParam( L) ;
|
||||
return 1 ;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
static int
|
||||
LuaGetNextGhostPart( lua_State* L)
|
||||
{
|
||||
// 1 parametro : nGhostPartId
|
||||
int nGhostPartId ;
|
||||
LuaCheckParam( L, 1, nGhostPartId)
|
||||
LuaClearStack( L) ;
|
||||
// cerco pezzo successivo messo in grezzo
|
||||
int nId = ExeGetNextGhostPart( nGhostPartId) ;
|
||||
// restituisco il risultato
|
||||
if ( nId != GDB_ID_NULL)
|
||||
LuaSetParam( L, nId) ;
|
||||
else
|
||||
LuaSetParam( L) ;
|
||||
return 1 ;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
static int
|
||||
LuaEraseEmptyParts( lua_State* L)
|
||||
@@ -387,6 +421,8 @@ LuaInstallGdbPartLayer( LuaMgr& luaMgr)
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetNextLayer", LuaGetNextLayer) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetLastLayer", LuaGetLastLayer) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetPrevLayer", LuaGetPrevLayer) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetFirstGhostPart", LuaGetFirstGhostPart) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetNextGhostPart", LuaGetNextGhostPart) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtEraseEmptyParts", LuaEraseEmptyParts) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtSelectPartObjs", LuaSelectPartObjs) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtDeselectPartObjs", LuaDeselectPartObjs) ;
|
||||
|
||||
Reference in New Issue
Block a user