mirror of
https://github.com/1dot13/source.git
synced 2026-08-19 14:20:30 +02:00
We can play external dialogue lines for NPC merchants via the lua function HandleNPCMerchantQuote(...)
For more info, see http://thepit.ja-galaxy-forum.com/index.php?t=msg&th=20611&goto=360388&#msg_360388 Requires GameDir >= r2550. git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@8821 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -13365,6 +13365,20 @@ void LuaHandleReplaceQuote( UINT8 ubProfile, UINT16 usQuoteNum )
|
||||
LuaFunction( _LS.L, "HandleReplaceQuote" ).Param<int>( ubProfile ).Param<int>( usQuoteNum ).Call( 2 );
|
||||
}
|
||||
|
||||
void LuaHandleNPCMerchantQuote( INT16 sSectorX, INT16 sSectorY, INT8 bSectorZ, UINT16 ubMerchantID, UINT8 ubBodyType, UINT16 usQuoteNum )
|
||||
{
|
||||
const char* filename = "scripts\\Overhead.lua";
|
||||
|
||||
LuaScopeState _LS( true );
|
||||
|
||||
IniFunction( _LS.L(), TRUE );
|
||||
IniGlobalGameSetting( _LS.L() );
|
||||
|
||||
SGP_THROW_IFFALSE( _LS.L.EvalFile( filename ), _BS( "Cannot open file: " ) << filename << _BS::cget );
|
||||
|
||||
LuaFunction( _LS.L, "HandleNPCMerchantQuote" ).Param<int>( sSectorX ).Param<int>( sSectorY ).Param<int>( bSectorZ ).Param<int>( ubMerchantID ).Param<int>( ubBodyType ).Param<int>( usQuoteNum ).Call( 6 );
|
||||
}
|
||||
|
||||
void LuaAddArmsDealerAdditionalIntelData()
|
||||
{
|
||||
const char* filename = "scripts\\Overhead.lua";
|
||||
|
||||
Reference in New Issue
Block a user