mirror of
https://github.com/SWG-Source/dsrc.git
synced 2026-10-09 00:12:57 -04:00
54 lines
1.3 KiB
Plaintext
54 lines
1.3 KiB
Plaintext
/**
|
|
|
|
*
|
|
* Title: pirate.script
|
|
* Description: script for pirates: POI = factoryliberation
|
|
|
|
*/
|
|
|
|
//------------------------------------------------
|
|
// Includes
|
|
//------------------------------------------------
|
|
|
|
//------------------------------------------------
|
|
// Constants
|
|
//------------------------------------------------
|
|
|
|
const string pirateEmotes[] = { "scratch", "yawn", "fidget", "cough" };
|
|
|
|
//------------------------------------------------
|
|
// Methods
|
|
//------------------------------------------------
|
|
|
|
//------------------------------------------------
|
|
// OnLoiterWaiting
|
|
//------------------------------------------------
|
|
|
|
trigger OnLoiterWaiting( modifiable_float time )
|
|
{
|
|
stop( self );
|
|
messageTo( self, "emotePirate", null, 4, false );
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
//------------------------------------------------
|
|
// emotePirate
|
|
//------------------------------------------------
|
|
|
|
messageHandler emotePirate()
|
|
{
|
|
// There is a chance we'll do a social.
|
|
int dosocial = rand( 1, 4 );
|
|
if ( dosocial == 1 )
|
|
{
|
|
// Perform a social.
|
|
int whichsocial = rand( 0, 3 );
|
|
queueCommand( self, ##"social", null, pirateEmotes[whichsocial], COMMAND_PRIORITY_DEFAULT );
|
|
}
|
|
|
|
messageTo( self, "resumeDefaultCalmBehavior", null, 3, false );
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|