User Tools

Site Tools



Global variables in Transcendence

  • gPlayer: Object representing the player.

Very useful for many functions, such as plyMessage and other player functions.

  • gPlayerShip: The id of the player's ship.
  • gScreen: The id of the DockScreen.

This is a static id that does not change throughout the game. It has one bug associated with it, and that is that it is not set at the very start of the game, until a dockscreen has been displayed via some other mechanism. After that it is used solely by the screen functions

  • gSource: The id of the object where a script function is currently running from.

This is used throghout Transcendence for referring to the current origin. It is used in weapons code to refer to the ship the weapon is installed on, it is used i dockscreens to refer to the object the screen is related to, it is used in ship events to refer to the ship the event exists on etc…

  • gTrans: Transcendence application object.
modding/function/globals.txt · Last modified: 2014/12/27 04:40 by