Skip to content

Commit 1483f61

Browse files
committed
added additional parameter to engineLoadIFP for custom block name
1 parent 4fddf96 commit 1483f61

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

Client/mods/deathmatch/logic/luadefs/CLuaEngineDefs.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -281,13 +281,13 @@ int CLuaEngineDefs::EngineLoadTXD ( lua_State* luaVM )
281281

282282
int CLuaEngineDefs::EngineLoadIFP ( lua_State* luaVM )
283283
{
284-
SString strFile = "";
285-
bool bFilteringEnabled = true;
284+
SString strFile = "";
285+
SString strBlockName = "";
286+
286287
CScriptArgReader argStream ( luaVM );
287-
// Grab the TXD filename or data
288+
// Grab the IFP filename or data
288289
argStream.ReadString ( strFile );
289-
if ( argStream.NextIsBool() ) // Some scripts have a number here (in error)
290-
argStream.ReadBool ( bFilteringEnabled, true );
290+
argStream.ReadString ( strBlockName );
291291

292292
if ( !argStream.HasErrors ( ) )
293293
{
@@ -310,7 +310,7 @@ int CLuaEngineDefs::EngineLoadIFP ( lua_State* luaVM )
310310
CClientIFP* pIFP = new CClientIFP ( m_pManager, INVALID_ELEMENT_ID );
311311

312312
// Try to load the IFP file
313-
if ( pIFP->LoadIFP ( strPath ) )
313+
if ( pIFP->LoadIFP ( strPath, strBlockName ) )
314314
{
315315
// Success loading the file. Set parent to IFP root
316316
pIFP->SetParent ( pRoot );

0 commit comments

Comments
 (0)