mirror of
https://github.com/SWG-Source/dsrc.git
synced 2026-07-31 00:15:54 -04:00
56 lines
1.4 KiB
Plaintext
56 lines
1.4 KiB
Plaintext
/**
|
|
* Copyright (c)2000-2002 Sony Online Entertainment Inc.
|
|
* All Rights Reserved
|
|
*
|
|
* Title: base terminal.script
|
|
* Description: script for handling basic terminal functions
|
|
* @author $Author:$
|
|
* @version $Revision:$
|
|
*/
|
|
|
|
/***** INCLUDES ********************************************************/
|
|
|
|
include library.utils;
|
|
include library.structure;
|
|
|
|
/***** CONSTANTS *******************************************************/
|
|
|
|
|
|
/***** TRIGGERS ********************************************************/
|
|
trigger OnInitialize()
|
|
{
|
|
if ( hasObjVar(self, structure.VAR_TERMINAL_HEADING) )
|
|
{
|
|
setYaw(self, getFloatObjVar(self, structure.VAR_TERMINAL_HEADING));
|
|
}
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
trigger OnObjectMenuRequest(obj_id player, menu_info mi)
|
|
{
|
|
if (isMob(self))
|
|
return SCRIPT_CONTINUE;
|
|
menu_info_data mid = mi.getMenuItemByType(menu_info_types.ITEM_USE);
|
|
if ( mid != null )
|
|
{
|
|
mid.setServerNotify(true);
|
|
}
|
|
|
|
return SCRIPT_CONTINUE;
|
|
}
|
|
|
|
/***** FUNCTIONS *******************************************************/
|
|
boolean playerMounted(obj_id player)
|
|
{
|
|
debugServerConsoleMsg( null, "+++ terminal.base.base_terminal playerMounted +++ entered playerMounted function" );
|
|
if ( isIdValid (getMountId (player)) )
|
|
{
|
|
debugServerConsoleMsg( null, "+++ terminal.base.base_terminal playerMounted +++ player IS mounted." );
|
|
return true;
|
|
}
|
|
|
|
return false;
|
|
}
|
|
|
|
/***** MESSAGEHANDLERS *************************************************/
|