本文整理汇总了C++中CScriptArgReader::NextIsUserData方法的典型用法代码示例。如果您正苦于以下问题:C++ CScriptArgReader::NextIsUserData方法的具体用法?C++ CScriptArgReader::NextIsUserData怎么用?C++ CScriptArgReader::NextIsUserData使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CScriptArgReader
的用法示例。
在下文中一共展示了CScriptArgReader::NextIsUserData方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: SetWeaponOwner
int CLuaFunctionDefs::SetWeaponOwner ( lua_State* luaVM )
{
CClientWeapon * pWeapon;
CClientPlayer * pPlayer;
CScriptArgReader argStream ( luaVM );
argStream.ReadUserData ( pWeapon );
if ( argStream.NextIsUserData() )
{
argStream.ReadUserData ( pPlayer );
if ( !argStream.HasErrors () )
{
pWeapon->SetOwner( pPlayer );
lua_pushboolean ( luaVM, true );
return 1;
}
}
else if ( argStream.NextIsNil() )
{
if ( !argStream.HasErrors () )
{
pWeapon->SetOwner( NULL );
lua_pushboolean ( luaVM, true );
return 1;
}
}
if ( argStream.HasErrors() )
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage() );
lua_pushnil ( luaVM );
return 1;
}
示例2: RemoveBan
int CLuaBanDefs::RemoveBan ( lua_State* luaVM )
{
CBan* pBan;
CPlayer* pResponsible = NULL;
CScriptArgReader argStream ( luaVM );
argStream.ReadUserData ( pBan );
if ( argStream.NextIsUserData () )
{
CElement* pResponsibleElement;
argStream.ReadUserData ( pResponsibleElement );
pResponsible = dynamic_cast <CPlayer*> ( pResponsibleElement );
}
if ( !argStream.HasErrors () )
{
if ( CStaticFunctionDefinitions::RemoveBan ( pBan, pResponsible ) )
{
lua_pushboolean ( luaVM, true );
return 1;
}
}
else
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage () );
lua_pushboolean ( luaVM, false );
return 1;
}
示例3: GetResourceConfig
int CLuaFunctionDefs::GetResourceConfig ( lua_State* luaVM )
{
CScriptArgReader argStream ( luaVM );
if ( argStream.NextIsUserData ( ) )
m_pScriptDebugging->LogCustom ( luaVM, "getResourceConfig may be using an outdated syntax. Please check and update." );
// Resource and config name
CResource* pResource = NULL;
SString strInput;
SString strAbsPath;
SString strMetaPath;
argStream.ReadString ( strInput );
if ( !argStream.HasErrors () )
{
// Grab our lua main
CLuaMain* pLuaMain = m_pLuaManager->GetVirtualMachine ( luaVM );
if ( pLuaMain )
{
// Grab resource and the config name from arg
pResource = pLuaMain->GetResource ();
// We have both a resource file to grab the config from and a config name?
if ( pResource )
{
if ( CResourceManager::ParseResourcePathInput ( strInput, pResource, strAbsPath, strMetaPath ) )
{
// Loop through the configs in that resource
list < CResourceConfigItem* >::iterator iter = pResource->ConfigIterBegin ();
for ( ; iter != pResource->ConfigIterEnd (); iter++ )
{
// Matching name?
if ( strcmp ( (*iter)->GetShortName(), strMetaPath.c_str() ) == 0 )
{
// Return it
CResourceConfigItem* pConfig = (CResourceConfigItem*) (*iter);
CXMLNode* pNode = pConfig->GetRoot ();
if ( pNode )
{
lua_pushxmlnode ( luaVM, pNode );
return 1;
}
}
}
}
}
}
else
m_pScriptDebugging->LogBadType ( luaVM );
}
else
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage() );
// Failed
lua_pushboolean ( luaVM, false );
return 1;
}
示例4: AddBan
int CLuaBanDefs::AddBan ( lua_State* luaVM )
{
// ban addBan ( [ string IP, string Username, string Serial, player responsibleElement, string reason, int seconds = 0 ] )
SString strIP = "";
SString strUsername = "";
SString strSerial = "";
SString strResponsible = "Console";
CPlayer * pResponsible = NULL;
SString strReason = "";
time_t tUnban;
CScriptArgReader argStream ( luaVM );
argStream.ReadString ( strIP, "" );
argStream.ReadString ( strUsername, "" );
argStream.ReadString ( strSerial, "" );
if ( argStream.NextIsUserData () )
{
CElement* pResponsibleElement;
argStream.ReadUserData ( pResponsibleElement );
if ( ( pResponsible = dynamic_cast <CPlayer*> ( pResponsibleElement ) ) )
strResponsible = pResponsible->GetNick ();
}
else
argStream.ReadString ( strResponsible, "Console" );
argStream.ReadString ( strReason, "" );
if ( argStream.NextIsString () )
{
SString strTime;
argStream.ReadString ( strTime );
tUnban = atoi ( strTime );
}
else
if ( argStream.NextIsNumber () )
argStream.ReadNumber ( tUnban );
else
tUnban = 0;
if ( tUnban > 0 )
tUnban += time ( NULL );
if ( !argStream.HasErrors () )
{
CBan* pBan = NULL;
if ( ( pBan = CStaticFunctionDefinitions::AddBan ( strIP, strUsername, strSerial, pResponsible, strResponsible, strReason, tUnban ) ) )
{
lua_pushban ( luaVM, pBan );
return 1;
}
}
else
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage () );
lua_pushboolean ( luaVM, false );
return 1;
}
示例5: fileDelete
int CLuaFileDefs::fileDelete ( lua_State* luaVM )
{
// bool fileDelete ( string filePath )
SString strFile;
CScriptArgReader argStream ( luaVM );
argStream.ReadString ( strFile );
if ( argStream.NextIsUserData () )
m_pScriptDebugging->LogCustom ( luaVM, "fileDelete may be using an outdated syntax. Please check and update." );
if ( !argStream.HasErrors () )
{
// Grab our lua VM
CLuaMain* pLuaMain = m_pLuaManager->GetVirtualMachine ( luaVM );
if ( pLuaMain )
{
std::string strPath;
// We have a resource argument?
CResource* pThisResource = pLuaMain->GetResource ();
CResource* pResource = pThisResource;
if ( CResourceManager::ParseResourcePathInput ( strFile, pResource, &strPath, NULL ) )
{
// Do we have permissions?
if ( pResource == pThisResource ||
m_pACLManager->CanObjectUseRight ( pThisResource->GetName ().c_str (),
CAccessControlListGroupObject::OBJECT_TYPE_RESOURCE,
"ModifyOtherObjects",
CAccessControlListRight::RIGHT_TYPE_GENERAL,
false ) )
{
// Make sure the dir exists so we can remove the file
MakeSureDirExists ( strPath.c_str () );
if ( remove ( strPath.c_str () ) == 0 )
{
// If file removed return success
lua_pushboolean ( luaVM, true );
return 1;
}
else
{
// Output error
m_pScriptDebugging->LogWarning ( luaVM, "%s; unable to delete file", lua_tostring ( luaVM, lua_upvalueindex ( 1 ) ) );
}
}
else
m_pScriptDebugging->LogError ( luaVM, "%s failed; ModifyOtherObjects in ACL denied resource %s to access %s", lua_tostring ( luaVM, lua_upvalueindex ( 1 ) ), pThisResource->GetName ().c_str (), pResource->GetName ().c_str () );
}
}
}
else
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage () );
lua_pushboolean ( luaVM, false );
return 1;
}
示例6: SetWeaponTarget
int CLuaFunctionDefs::SetWeaponTarget ( lua_State* luaVM )
{
CClientWeapon * pWeapon;
CClientEntity * pTarget;
CScriptArgReader argStream ( luaVM );
argStream.ReadUserData ( pWeapon );
if ( argStream.NextIsUserData() )
{
int targetBone;
argStream.ReadUserData ( pTarget );
argStream.ReadNumber ( targetBone, 255 );
if ( !argStream.HasErrors () )
{
if ( CStaticFunctionDefinitions::SetWeaponTarget ( pWeapon, pTarget, targetBone ) )
{
lua_pushboolean ( luaVM, true );
return 1;
}
}
}
else if ( argStream.NextIsNumber() )
{
CVector vecTarget;
argStream.ReadNumber( vecTarget.fX );
argStream.ReadNumber( vecTarget.fY );
argStream.ReadNumber( vecTarget.fZ );
if ( !argStream.HasErrors () )
{
if ( CStaticFunctionDefinitions::SetWeaponTarget ( pWeapon, vecTarget ) )
{
lua_pushboolean ( luaVM, true );
return 1;
}
}
}
else if ( argStream.NextIsNil() )
{
if ( !argStream.HasErrors () )
{
if ( CStaticFunctionDefinitions::ClearWeaponTarget ( pWeapon ) )
{
lua_pushboolean ( luaVM, true );
return 1;
}
}
}
else
argStream.SetCustomError( "Expected element, number or nil at argument 2" );
if ( argStream.HasErrors () )
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage() );
lua_pushboolean ( luaVM, false );
return 1;
}
示例7: Reference
int CLuaFunctionDefs::Reference ( lua_State* luaVM )
{
CScriptArgReader argStream ( luaVM );
if ( argStream.NextIsTable ( ) || argStream.NextIsFunction ( ) ||
argStream.NextIsUserData ( ) )
{
int iPointer = lua_ref ( luaVM, 1 );
lua_pushnumber ( luaVM, iPointer );
return 1;
}
lua_pushboolean ( luaVM, false );
return 1;
}
示例8: fileDelete
int CLuaFileDefs::fileDelete ( lua_State* luaVM )
{
// bool fileDelete ( string filePath )
SString strInputPath;
CScriptArgReader argStream ( luaVM );
argStream.ReadString ( strInputPath );
// This is only really necessary server side
if ( argStream.NextIsUserData () )
m_pScriptDebugging->LogCustom ( luaVM, "fileDelete may be using an outdated syntax. Please check and update." );
if ( !argStream.HasErrors () )
{
// Grab our lua VM
CLuaMain* pLuaMain = m_pLuaManager->GetVirtualMachine ( luaVM );
if ( pLuaMain )
{
SString strAbsPath;
CResource* pThisResource = pLuaMain->GetResource ();
CResource* pResource = pThisResource;
if ( CResourceManager::ParseResourcePathInput ( strInputPath, pResource, &strAbsPath ) )
{
CheckCanModifyOtherResource( argStream, pThisResource, pResource );
CheckCanAccessOtherResourceFile( argStream, pThisResource, pResource, strAbsPath );
if ( !argStream.HasErrors() )
{
#ifdef MTA_CLIENT
// Inform file verifier
g_pClientGame->GetResourceManager ()->OnFileModifedByScript ( strAbsPath, "fileDelete" );
#endif
if ( FileDelete ( strAbsPath ) )
{
// If file removed successfully, return true
lua_pushboolean ( luaVM, true );
return 1;
}
// Output error "Operation failed @ 'fileDelete' [strInputPath]"
argStream.SetCustomError ( strInputPath, "Operation failed" );
}
}
}
}
if ( argStream.HasErrors () )
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage () );
lua_pushboolean ( luaVM, false );
return 1;
}
示例9: SetCameraTarget
int CLuaFunctionDefs::SetCameraTarget ( lua_State* luaVM )
{
// bool setCameraTarget ( element target = nil ) or setCameraTarget ( float x, float y, float z )
CScriptArgReader argStream ( luaVM );
if ( argStream.NextIsUserData () )
{
CClientEntity* pTarget;
argStream.ReadUserData ( pTarget );
if ( !argStream.HasErrors () )
{
if ( CStaticFunctionDefinitions::SetCameraTarget ( pTarget ) )
{
lua_pushboolean ( luaVM, true );
return 1;
}
}
}
else
{
CVector vecTarget;
argStream.ReadNumber ( vecTarget.fX );
argStream.ReadNumber ( vecTarget.fY );
argStream.ReadNumber ( vecTarget.fZ );
if ( !argStream.HasErrors () )
{
if ( CStaticFunctionDefinitions::SetCameraTarget ( vecTarget ) )
{
lua_pushboolean ( luaVM, true );
return 1;
}
}
}
if ( argStream.HasErrors () )
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage () );
lua_pushboolean ( luaVM, false );
return 1;
}
示例10: fileCreate
int CLuaFileDefs::fileCreate ( lua_State* luaVM )
{
// file fileCreate ( string filePath )
SString strFile;
CScriptArgReader argStream ( luaVM );
argStream.ReadString ( strFile );
if ( argStream.NextIsUserData () )
m_pScriptDebugging->LogCustom ( luaVM, "fileCreate may be using an outdated syntax. Please check and update." );
if ( !argStream.HasErrors () )
{
// Grab our lua VM
CLuaMain* pLuaMain = m_pLuaManager->GetVirtualMachine ( luaVM );
if ( pLuaMain )
{
// Grab the filename
std::string strAbsPath;
std::string strSubPath;
// We have a resource argument?
CResource* pThisResource = pLuaMain->GetResource ();
CResource* pResource = pThisResource;
if ( CResourceManager::ParseResourcePathInput ( strFile, pResource, &strAbsPath, &strSubPath ) )
{
// Do we have permissions?
if ( pResource == pThisResource ||
m_pACLManager->CanObjectUseRight ( pThisResource->GetName ().c_str (),
CAccessControlListGroupObject::OBJECT_TYPE_RESOURCE,
"ModifyOtherObjects",
CAccessControlListRight::RIGHT_TYPE_GENERAL,
false ) )
{
// Make sure the destination folder exist so we can create the file
MakeSureDirExists ( strAbsPath.c_str () );
// Create the file to create
CScriptFile* pFile = new CScriptFile ( pThisResource->GetScriptID(), strSubPath.c_str (), DEFAULT_MAX_FILESIZE );
assert ( pFile );
// Try to load it
if ( pFile->Load ( pResource, CScriptFile::MODE_CREATE ) )
{
// Add it to the scrpt resource element group
CElementGroup* pGroup = pThisResource->GetElementGroup ();
if ( pGroup )
{
pGroup->Add ( pFile );
}
// Success. Return the file.
lua_pushelement ( luaVM, pFile );
return 1;
}
else
{
// Delete the file again
delete pFile;
// Output error
m_pScriptDebugging->LogWarning ( luaVM, "%s; unable to load file", lua_tostring ( luaVM, lua_upvalueindex ( 1 ) ) );
}
}
else
m_pScriptDebugging->LogError ( luaVM, "%s failed; ModifyOtherObjects in ACL denied resource %s to access %s", lua_tostring ( luaVM, lua_upvalueindex ( 1 ) ), pThisResource->GetName ().c_str (), pResource->GetName ().c_str () );
}
}
}
else
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage () );
// Failed
lua_pushboolean ( luaVM, false );
return 1;
}
示例11: SetWeaponProperty
int CLuaFunctionDefs::SetWeaponProperty ( lua_State* luaVM )
{
// bool setWeaponProperty ( int weaponID/string weaponName, string weaponSkill, string property/int property, int/float theValue )
eWeaponSkill eWepSkill = WEAPONSKILL_STD;
eWeaponType eWep = WEAPONTYPE_BRASSKNUCKLE;
eWeaponProperty eProp = WEAPON_ACCURACY;
CScriptArgReader argStream ( luaVM );
if ( argStream.NextIsUserData () )
{
CCustomWeapon * pWeapon;
eWeaponProperty weaponProperty;
CScriptArgReader argStream ( luaVM );
argStream.ReadUserData ( pWeapon );
argStream.ReadEnumString ( weaponProperty );
if ( !argStream.HasErrors () )
{
if ( weaponProperty == WEAPON_DAMAGE )
{
short sData = 0;
argStream.ReadNumber ( sData );
if ( !argStream.HasErrors () )
{
if ( CStaticFunctionDefinitions::SetWeaponProperty ( pWeapon, weaponProperty, sData ) )
{
lua_pushboolean ( luaVM, true );
return 1;
}
}
}
else
{
float fData = 0.0f;
argStream.ReadNumber ( fData );
if ( !argStream.HasErrors () )
{
if ( CStaticFunctionDefinitions::SetWeaponProperty ( pWeapon, weaponProperty, fData ) )
{
lua_pushboolean ( luaVM, true );
return 1;
}
}
}
}
if ( argStream.HasErrors () )
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage () );
}
else
{
argStream.ReadEnumStringOrNumber ( eWep );
argStream.ReadEnumStringOrNumber ( eWepSkill );
argStream.ReadEnumString ( eProp );
if ( !argStream.HasErrors () )
{
switch ( eProp )
{
case WEAPON_WEAPON_RANGE:
case WEAPON_TARGET_RANGE:
case WEAPON_ACCURACY:
case WEAPON_MOVE_SPEED:
case WEAPON_ANIM_LOOP_START:
case WEAPON_ANIM_LOOP_STOP:
case WEAPON_ANIM_LOOP_RELEASE_BULLET_TIME:
case WEAPON_ANIM2_LOOP_START:
case WEAPON_ANIM2_LOOP_STOP:
case WEAPON_ANIM2_LOOP_RELEASE_BULLET_TIME:
case WEAPON_ANIM_BREAKOUT_TIME:
{
float fWeaponInfo = 0.0f;
argStream.ReadNumber ( fWeaponInfo );
if ( !argStream.HasErrors () )
{
if ( CStaticFunctionDefinitions::SetWeaponProperty ( eProp, eWep, eWepSkill, fWeaponInfo ) )
{
lua_pushboolean ( luaVM, true );
return 1;
}
}
break;
}
case WEAPON_DAMAGE:
case WEAPON_MAX_CLIP_AMMO:
case WEAPON_FLAGS:
{
int sWeaponInfo = 0;
argStream.ReadNumber ( sWeaponInfo );
if ( !argStream.HasErrors () )
{
if ( CStaticFunctionDefinitions::SetWeaponProperty ( eProp, eWep, eWepSkill, sWeaponInfo ) )
{
lua_pushboolean ( luaVM, true );
return 1;
}
}
break;
}
case WEAPON_FLAG_AIM_NO_AUTO:
//.........这里部分代码省略.........
示例12: fileOpen
int CLuaFileDefs::fileOpen ( lua_State* luaVM )
{
// file fileOpen ( string filePath [, bool readOnly = false ] )
SString strInputPath; bool bReadOnly;
CScriptArgReader argStream ( luaVM );
argStream.ReadString ( strInputPath );
argStream.ReadBool ( bReadOnly, false );
if ( argStream.NextIsUserData () )
m_pScriptDebugging->LogCustom ( luaVM, "fileOpen may be using an outdated syntax. Please check and update." );
if ( !argStream.HasErrors () )
{
// Grab our lua VM
CLuaMain* pLuaMain = m_pLuaManager->GetVirtualMachine ( luaVM );
if ( pLuaMain )
{
SString strAbsPath;
SString strMetaPath;
CResource* pThisResource = pLuaMain->GetResource ();
CResource* pResource = pThisResource;
if ( CResourceManager::ParseResourcePathInput ( strInputPath, pResource, &strAbsPath, &strMetaPath ) )
{
CheckCanModifyOtherResource( argStream, pThisResource, pResource );
CheckCanAccessOtherResourceFile( argStream, pThisResource, pResource, strAbsPath, &bReadOnly );
if ( !argStream.HasErrors() )
{
#ifndef MTA_CLIENT // IF SERVER
// Create the file to create
CScriptFile* pFile = new CScriptFile ( pThisResource->GetScriptID (), strMetaPath, DEFAULT_MAX_FILESIZE );
#else
eAccessType accessType = strInputPath[0] == '@' ? eAccessType::ACCESS_PRIVATE : eAccessType::ACCESS_PUBLIC;
CScriptFile* pFile = new CScriptFile ( pThisResource->GetScriptID (), strMetaPath, DEFAULT_MAX_FILESIZE, accessType );
#endif
// Try to load it
if ( pFile->Load ( pResource, bReadOnly ? CScriptFile::MODE_READ : CScriptFile::MODE_READWRITE ) )
{
#ifdef MTA_CLIENT
// Make it a child of the resource's file root
pFile->SetParent ( pResource->GetResourceDynamicEntity () );
#endif
// Grab its owner resource
CResource* pParentResource = pLuaMain->GetResource ();
if ( pParentResource )
{
// Add it to the scrpt resource element group
CElementGroup* pGroup = pParentResource->GetElementGroup ();
if ( pGroup )
{
pGroup->Add ( pFile );
}
}
// Success. Return the file.
lua_pushelement ( luaVM, pFile );
return 1;
}
else
{
// Delete the file again
delete pFile;
// Output error
argStream.SetCustomError ( SString ( "unable to load file '%s'", *strInputPath ) );
}
}
}
}
}
if ( argStream.HasErrors () )
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage () );
// Failed
lua_pushboolean ( luaVM, false );
return 1;
}
示例13: fileCreate
int CLuaFileDefs::fileCreate ( lua_State* luaVM )
{
// file fileCreate ( string filePath )
SString strInputPath;
CScriptArgReader argStream ( luaVM );
argStream.ReadString ( strInputPath );
if ( argStream.NextIsUserData () )
m_pScriptDebugging->LogCustom ( luaVM, "fileCreate may be using an outdated syntax. Please check and update." );
if ( !argStream.HasErrors () )
{
// Grab our lua VM
CLuaMain* pLuaMain = m_pLuaManager->GetVirtualMachine ( luaVM );
if ( !pLuaMain )
{
// Failed
lua_pushboolean ( luaVM, false );
return 1;
}
#ifdef MTA_CLIENT
if ( !g_pNet->ValidateBinaryFileName ( strInputPath ) )
{
argStream.SetCustomError ( SString ( "Filename not allowed %s", *strInputPath ), "File error" );
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage () );
// Failed
lua_pushboolean ( luaVM, false );
return 1;
}
#endif // MTA_CLIENT
SString strAbsPath;
SString strMetaPath;
CResource* pThisResource = pLuaMain->GetResource ();
CResource* pResource = pThisResource;
if ( CResourceManager::ParseResourcePathInput ( strInputPath, pResource, &strAbsPath, &strMetaPath ) )
{
CheckCanModifyOtherResource( argStream, pThisResource, pResource );
CheckCanAccessOtherResourceFile( argStream, pThisResource, pResource, strAbsPath );
if ( !argStream.HasErrors() )
{
#ifdef MTA_CLIENT
// Inform file verifier
g_pClientGame->GetResourceManager ()->OnFileModifedByScript ( strAbsPath, "fileCreate" );
#endif
// Make sure the destination folder exist so we can create the file
MakeSureDirExists ( strAbsPath );
// Create the file to create
#ifdef MTA_CLIENT
eAccessType accessType = strInputPath[0] == '@' ? eAccessType::ACCESS_PRIVATE : eAccessType::ACCESS_PUBLIC;
CScriptFile* pFile = new CScriptFile ( pThisResource->GetScriptID (), strMetaPath, DEFAULT_MAX_FILESIZE, accessType );
#else
CScriptFile* pFile = new CScriptFile ( pThisResource->GetScriptID (), strMetaPath, DEFAULT_MAX_FILESIZE );
#endif
// Try to load it
if ( pFile->Load ( pResource, CScriptFile::MODE_CREATE ) )
{
#ifdef MTA_CLIENT
// Make it a child of the resource's file root
pFile->SetParent ( pResource->GetResourceDynamicEntity () );
#endif
// Add it to the scrpt resource element group
CElementGroup* pGroup = pThisResource->GetElementGroup ();
if ( pGroup )
{
pGroup->Add ( pFile );
}
// Success. Return the file.
lua_pushelement ( luaVM, pFile );
return 1;
}
else
{
// Delete the file again
delete pFile;
// Output error
argStream.SetCustomError ( SString ( "Unable to create %s", *strInputPath ), "File error" );
}
}
}
}
if ( argStream.HasErrors () )
m_pScriptDebugging->LogCustom ( luaVM, argStream.GetFullErrorMessage () );
// Failed
lua_pushboolean ( luaVM, false );
return 1;
}