Oolite 1.91.0.7644-241112-7f5034b
|
import "OOJSStation.h"
import "OOJSEntity.h"
import "OOJSShip.h"
import "OOJSPlayer.h"
import "PlayerEntityContracts.h"
import "OOJavaScriptEngine.h"
import "OOJSInterfaceDefinition.h"
import "OOCollectionExtractors.h"
import "OOEquipmentType.h"
import "OOShipRegistry.h"
import "OOConstToString.h"
import "StationEntity.h"
import "GameController.h"
Go to the source code of this file.
Functions | |
static BOOL | JSStationGetStationEntity (JSContext *context, JSObject *stationObj, StationEntity **outEntity) |
static JSBool | StationGetProperty (JSContext *context, JSObject *this, jsid propID, jsval *value) |
static JSBool | StationSetProperty (JSContext *context, JSObject *this, jsid propID, JSBool strict, jsval *value) |
static JSBool | StationAbortAllDockings (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationAbortDockingForShip (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationCanDockShip (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationDockPlayer (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationIncreaseAlertLevel (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationDecreaseAlertLevel (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationLaunchShipWithRole (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationLaunchDefenseShip (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationLaunchEscort (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationLaunchScavenger (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationLaunchMiner (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationLaunchPirateShip (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationLaunchShuttle (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationLaunchPatrol (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationLaunchPolice (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationSetInterface (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationSetMarketPrice (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationSetMarketQuantity (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationAddShipToShipyard (JSContext *context, uintN argc, jsval *vp) |
static JSBool | StationRemoveShipFromShipyard (JSContext *context, uintN argc, jsval *vp) |
void | InitOOJSStation (JSContext *context, JSObject *global) |
static BOOL | JSStationGetShipEntity (JSContext *context, JSObject *shipObj, ShipEntity **outEntity) |
Variables | |
static JSObject * | sStationPrototype |
static JSClass | sStationClass |
static JSPropertySpec | sStationProperties [] |
static JSFunctionSpec | sStationMethods [] |
anonymous enum |
Definition at line 86 of file OOJSStation.m.
void InitOOJSStation | ( | JSContext * | context, |
JSObject * | global ) |
Definition at line 162 of file OOJSStation.m.
References JSShipClass(), JSShipPrototype(), OOJSBasicPrivateObjectConverter(), OOJSRegisterObjectConverter(), OOJSRegisterSubclass(), OOJSUnconstructableConstruct(), sStationClass, sStationMethods, sStationProperties, and sStationPrototype.
|
static |
Definition at line 191 of file OOJSStation.m.
References nil, OOJS_PROFILE_ENTER, and OOJS_PROFILE_EXIT.
Referenced by StationAbortDockingForShip(), and StationCanDockShip().
|
static |
Definition at line 170 of file OOJSStation.m.
References nil, OOJS_PROFILE_ENTER, and OOJS_PROFILE_EXIT.
Referenced by StationEntity(OOJavaScriptExtensions)::getJSClass:andPrototype:, StationAbortAllDockings(), StationAbortDockingForShip(), StationAddShipToShipyard(), StationCanDockShip(), StationDecreaseAlertLevel(), StationDockPlayer(), StationGetProperty(), StationIncreaseAlertLevel(), StationLaunchDefenseShip(), StationLaunchEscort(), StationLaunchMiner(), StationLaunchPatrol(), StationLaunchPirateShip(), StationLaunchPolice(), StationLaunchScavenger(), StationLaunchShipWithRole(), StationLaunchShuttle(), StationSetInterface(), StationSetMarketPrice(), StationSetMarketQuantity(), and StationSetProperty().
|
static |
Definition at line 452 of file OOJSStation.m.
References StationEntity::abortAllDockings, JSStationGetStationEntity(), nil, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_VOID, and OOJS_THIS.
|
static |
Definition at line 465 of file OOJSStation.m.
References StationEntity::abortDockingForShip:, JSStationGetShipEntity(), JSStationGetStationEntity(), MIN, nil, OOJS_ARGV, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_VOID, OOJS_THIS, and OOJSReportBadArguments().
|
static |
Definition at line 945 of file OOJSStation.m.
References Random_Seed::a, Random_Seed::b, Random_Seed::c, count, Random_Seed::d, Random_Seed::e, Random_Seed::f, StationEntity::generateShipyard, isWeaponNone(), JSStationGetStationEntity(), KEY_SHORT_DESCRIPTION, StationEntity::localShipyard, MIN, nil, OOJS_ARGV, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_BOOL, OOJS_RETURN_VOID, OOJS_THIS, OOJSNativeObjectFromJSObject(), OOJSReportBadArguments(), OOJSReportWarningForCaller(), OOWeaponTypeFromEquipmentIdentifierSloppy(), PLAYER, Ranrot(), OOShipRegistry::sharedRegistry, OOShipRegistry::shipInfoForKey:, SHIPYARD_KEY_PERSONALITY, SHIPYARD_KEY_PRICE, SHIPYARD_KEY_SHIPDATA_KEY, OOShipRegistry::shipyardInfoForKey:, VALID_WEAPON_FACINGS, WEAPON_FACING_AFT, and WEAPON_FACING_FORWARD.
|
static |
Definition at line 491 of file OOJSStation.m.
References EXPECT_NOT, StationEntity::fitsInDock:andLogNoFit:, JSStationGetShipEntity(), JSStationGetStationEntity(), MIN, nil, OOJS_ARGV, OOJS_BEGIN_FULL_NATIVE, OOJS_END_FULL_NATIVE, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_BOOL, OOJS_RETURN_VOID, OOJS_THIS, and OOJSReportBadArguments().
|
static |
Definition at line 573 of file OOJSStation.m.
References StationEntity::decreaseAlertLevel, JSStationGetStationEntity(), nil, OOJS_BEGIN_FULL_NATIVE, OOJS_END_FULL_NATIVE, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_VOID, and OOJS_THIS.
|
static |
Definition at line 525 of file OOJSStation.m.
References PlayerEntity::enterDock:, EXPECT, EXPECT_NOT, JSStationGetStationEntity(), nil, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_VOID, OOJS_THIS, OOPlayerForScripting(), PlayerEntity::safeAllMissiles, PlayerEntity::setDockingClearanceStatus:, and GameController::setGamePaused:.
|
static |
Definition at line 230 of file OOJSStation.m.
References StationEntity::allegiance, StationEntity::generateShipyard, JSStationGetStationEntity(), kStation_alertCondition, kStation_allegiance, kStation_allowsAutoDocking, kStation_allowsFastDocking, kStation_breakPattern, kStation_dockedContractors, kStation_dockedDefenders, kStation_dockedPolice, kStation_equipmentPriceFactor, kStation_equivalentTechLevel, kStation_hasNPCTraffic, kStation_hasShipyard, kStation_isMainStation, kStation_market, kStation_requiresDockingClearance, kStation_roll, kStation_shipyard, kStation_suppressArrivalReports, StationEntity::localMarketForScripting, StationEntity::localShipyard, nil, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJSReportBadPropertySelector(), OOJSValueFromBOOL(), OOJSValueFromNativeObject(), sStationProperties, and UNIVERSE.
|
static |
Definition at line 556 of file OOJSStation.m.
References StationEntity::increaseAlertLevel, JSStationGetStationEntity(), nil, OOJS_BEGIN_FULL_NATIVE, OOJS_END_FULL_NATIVE, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_VOID, and OOJS_THIS.
|
static |
Definition at line 621 of file OOJSStation.m.
References JSStationGetStationEntity(), StationEntity::launchDefenseShip, nil, OOJS_BEGIN_FULL_NATIVE, OOJS_END_FULL_NATIVE, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_OBJECT, OOJS_RETURN_VOID, and OOJS_THIS.
|
static |
Definition at line 638 of file OOJSStation.m.
References JSStationGetStationEntity(), StationEntity::launchEscort, nil, OOJS_BEGIN_FULL_NATIVE, OOJS_END_FULL_NATIVE, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_OBJECT, OOJS_RETURN_VOID, and OOJS_THIS.
|
static |
Definition at line 672 of file OOJSStation.m.
References JSStationGetStationEntity(), StationEntity::launchMiner, nil, OOJS_BEGIN_FULL_NATIVE, OOJS_END_FULL_NATIVE, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_OBJECT, OOJS_RETURN_VOID, and OOJS_THIS.
|
static |
Definition at line 721 of file OOJSStation.m.
References JSStationGetStationEntity(), StationEntity::launchPatrol, nil, OOJS_BEGIN_FULL_NATIVE, OOJS_END_FULL_NATIVE, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_OBJECT, OOJS_RETURN_VOID, and OOJS_THIS.
|
static |
Definition at line 688 of file OOJSStation.m.
References JSStationGetStationEntity(), StationEntity::launchPirateShip, nil, OOJS_BEGIN_FULL_NATIVE, OOJS_END_FULL_NATIVE, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_OBJECT, OOJS_RETURN_VOID, and OOJS_THIS.
|
static |
Definition at line 737 of file OOJSStation.m.
References JSStationGetStationEntity(), StationEntity::launchPolice, nil, OOJS_BEGIN_FULL_NATIVE, OOJS_END_FULL_NATIVE, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_OBJECT, OOJS_RETURN_VOID, and OOJS_THIS.
|
static |
Definition at line 655 of file OOJSStation.m.
References JSStationGetStationEntity(), StationEntity::launchScavenger, nil, OOJS_BEGIN_FULL_NATIVE, OOJS_END_FULL_NATIVE, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_OBJECT, OOJS_RETURN_VOID, and OOJS_THIS.
|
static |
Definition at line 591 of file OOJSStation.m.
References StationEntity::abortAllDockings, EXPECT_NOT, JSStationGetStationEntity(), StationEntity::launchIndependentShip:, MIN, nil, OOJS_ARGV, OOJS_BEGIN_FULL_NATIVE, OOJS_END_FULL_NATIVE, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_OBJECT, OOJS_RETURN_VOID, OOJS_THIS, OOJSReportBadArguments(), and OOStringFromJSValue().
|
static |
Definition at line 705 of file OOJSStation.m.
References JSStationGetStationEntity(), StationEntity::launchShuttle, nil, OOJS_BEGIN_FULL_NATIVE, OOJS_END_FULL_NATIVE, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_OBJECT, OOJS_RETURN_VOID, and OOJS_THIS.
|
static |
Definition at line 1113 of file OOJSStation.m.
|
static |
Definition at line 752 of file OOJSStation.m.
References JSStationGetStationEntity(), MIN, nil, OOJS_ARGV, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_VOID, OOJS_THIS, OOJSReportBadArguments(), OOJSValueIsFunction(), OOStringFromJSValue(), OOJSInterfaceDefinition::setCallback:, OOJSInterfaceDefinition::setCallbackThis:, OOJSInterfaceDefinition::setCategory:, StationEntity::setInterfaceDefinition:forKey:, OOJSInterfaceDefinition::setSummary:, and OOJSInterfaceDefinition::setTitle:.
|
static |
Definition at line 863 of file OOJSStation.m.
References EXPECT_NOT, JSStationGetStationEntity(), MIN, nil, OOJS_ARGV, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_BOOL, OOJS_RETURN_VOID, OOJS_THIS, OOJSReportBadArguments(), OOStringFromJSValue(), PLAYER, StationEntity::setPrice:forCommodity:, and UNIVERSE.
|
static |
Definition at line 904 of file OOJSStation.m.
References EXPECT_NOT, JSStationGetStationEntity(), MIN, nil, OOJS_ARGV, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJS_RETURN_BOOL, OOJS_RETURN_VOID, OOJS_THIS, OOJSReportBadArguments(), OOStringFromJSValue(), PLAYER, StationEntity::setQuantity:forCommodity:, and UNIVERSE.
|
static |
Definition at line 341 of file OOJSStation.m.
References JSStationGetStationEntity(), kStation_alertCondition, kStation_allegiance, kStation_allowsAutoDocking, kStation_allowsFastDocking, kStation_breakPattern, kStation_hasNPCTraffic, kStation_requiresDockingClearance, kStation_roll, kStation_suppressArrivalReports, M_PI, nil, OOJS_NATIVE_ENTER, OOJS_NATIVE_EXIT, OOJSReportBadPropertySelector(), OOJSReportBadPropertyValue(), OOStringFromJSValue(), StationEntity::setAlertLevel:signallingScript:, StationEntity::setAllegiance:, StationEntity::setAllowsAutoDocking:, StationEntity::setAllowsFastDocking:, StationEntity::setHasBreakPattern:, StationEntity::setHasNPCTraffic:, ShipEntity::setRawRoll:, StationEntity::setRequiresDockingClearance:, StationEntity::setSuppressArrivalReports:, and sStationProperties.
|
static |
Definition at line 69 of file OOJSStation.m.
Referenced by InitOOJSStation().
|
static |
Definition at line 135 of file OOJSStation.m.
Referenced by InitOOJSStation().
|
static |
Definition at line 110 of file OOJSStation.m.
Referenced by InitOOJSStation(), StationGetProperty(), and StationSetProperty().
|
static |
Definition at line 40 of file OOJSStation.m.
Referenced by InitOOJSStation().