EgtExecutor 2.5a4 :
- aggiunta funzione Exe e Lua GetAllInfo.
This commit is contained in:
@@ -746,6 +746,16 @@ ExeRemoveInfo( int nId, const string& sKey)
|
||||
return bOk ;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
bool
|
||||
ExeGetAllInfo( int nId, STRVECTOR& vsInfo)
|
||||
{
|
||||
IGeomDB* pGeomDB = GetCurrGeomDB() ;
|
||||
VERIFY_GEOMDB( pGeomDB, false)
|
||||
// recupero tutte le info
|
||||
return pGeomDB->GetAllInfo( nId, vsInfo) ;
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
bool
|
||||
ExeSetTextureName( int nId, const string& sTxrName)
|
||||
|
||||
Binary file not shown.
@@ -682,6 +682,25 @@ LuaRemoveInfo( lua_State* L)
|
||||
return 1 ;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
static int
|
||||
LuaGetAllInfo( lua_State* L)
|
||||
{
|
||||
// 1 parametro : Id
|
||||
int nId ;
|
||||
LuaCheckParam( L, 1, nId)
|
||||
LuaClearStack( L) ;
|
||||
// recupero tutte le info
|
||||
STRVECTOR vsInfo ;
|
||||
bool bOk = ExeGetAllInfo( nId, vsInfo) ;
|
||||
// restituisco il risultato
|
||||
if ( bOk)
|
||||
LuaSetParam( L, vsInfo) ;
|
||||
else
|
||||
LuaSetParam( L) ;
|
||||
return 1 ;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
static int
|
||||
LuaSetTextureName( lua_State* L)
|
||||
@@ -809,6 +828,7 @@ LuaInstallGdbObjAttribs( LuaMgr& luaMgr)
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetInfo", LuaGetInfo) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtExistsInfo", LuaExistsInfo) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtRemoveInfo", LuaRemoveInfo) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtGetAllInfo", LuaGetAllInfo) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtSetTextureName", LuaSetTextureName) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtSetTextureFrame", LuaSetTextureFrame) ;
|
||||
bOk = bOk && luaMgr.RegisterFunction( "EgtRemoveTextureData", LuaRemoveTextureData) ;
|
||||
|
||||
Reference in New Issue
Block a user