FS2_Open
Open source remastering of the Freespace 2 engine
lua.cpp File Reference
#include "ai/ai.h"
#include "ai/aigoals.h"
#include "asteroid/asteroid.h"
#include "camera/camera.h"
#include "cfile/cfilesystem.h"
#include "cmdline/cmdline.h"
#include "cutscene/movie.h"
#include "debris/debris.h"
#include "external_dll/trackirpublic.h"
#include "freespace2/freespace.h"
#include "gamesequence/gamesequence.h"
#include "globalincs/linklist.h"
#include "graphics/2d.h"
#include "graphics/font.h"
#include "graphics/gropenglpostprocessing.h"
#include "hud/hudbrackets.h"
#include "hud/hudconfig.h"
#include "hud/hudescort.h"
#include "hud/hudets.h"
#include "hud/hudgauges.h"
#include "hud/hudshield.h"
#include "iff_defs/iff_defs.h"
#include "io/joy.h"
#include "io/key.h"
#include "io/mouse.h"
#include "io/timer.h"
#include "jumpnode/jumpnode.h"
#include "lighting/lighting.h"
#include "menuui/credits.h"
#include "mission/missioncampaign.h"
#include "mission/missiongoals.h"
#include "mission/missionload.h"
#include "mission/missionlog.h"
#include "mission/missionmessage.h"
#include "mission/missiontraining.h"
#include "missionui/missionbrief.h"
#include "model/model.h"
#include "network/multi.h"
#include "network/multimsgs.h"
#include "object/objectshield.h"
#include "object/waypoint.h"
#include "parse/lua.h"
#include "parse/parselo.h"
#include "parse/scripting.h"
#include "particle/particle.h"
#include "playerman/player.h"
#include "render/3d.h"
#include "render/3dinternal.h"
#include "ship/ship.h"
#include "ship/shipfx.h"
#include "ship/shiphit.h"
#include "sound/audiostr.h"
#include "sound/ds.h"
#include "weapon/beam.h"
#include "weapon/weapon.h"
#include "bmpman/bm_internal.h"

Go to the source code of this file.

Classes

class  ade_lib
 
class  ade_func
 
class  ade_virtvar
 
class  ade_indexer
 
struct  string_conv
 
struct  matrix_h
 
struct  enum_h
 
class  gameevent_h
 
class  gamestate_h
 
struct  eye_h
 
class  model_h
 
class  modeltextures_h
 
class  eyepoints_h
 
class  thrusters_h
 
struct  thrusterbank_h
 
struct  glowpoint_h
 
class  dockingbays_h
 
class  dockingbay_h
 
struct  physics_info_h
 
struct  sexpvar_h
 
class  texture_map_h
 
class  mc_info_h
 
class  cockpit_disp_info_h
 
class  cockpit_display_h
 
class  cockpit_displays_info_h
 
struct  waypointlist_h
 
struct  ship_banktype_h
 
struct  ship_bank_h
 
struct  ship_subsys_h
 
struct  order_h
 
class  cockpit_displays_h
 
struct  sound_entry_h
 
struct  sound_h
 
class  particle_h
 

Macros

#define BMPMAN_INTERNAL
 
#define ADE_FUNC(name, parent, args, desc, ret_type, ret_desc)
 
#define ADE_VIRTVAR(name, parent, args, desc, ret_type, ret_desc)
 
#define ADE_INDEXER(parent, args, desc, ret_type, ret_desc)
 
#define ADE_FUNCNAME_UPVALUE_INDEX   1
 
#define ADE_SETTING_UPVALUE_INDEX   2
 
#define ADE_SETTING_VAR   lua_toboolean(L,lua_upvalueindex(ADE_SETTING_UPVALUE_INDEX))
 
#define ADE_RETURN_NIL   0
 
#define ADE_RETURN_TRUE   ade_set_args(L, "b", true)
 
#define ADE_RETURN_FALSE   ade_set_args(L, "b", false)
 
#define ade_set_error   ade_set_args
 
#define MH_FINE   0
 
#define MH_MATRIX_OUTOFDATE   1
 
#define MH_ANGLES_OUTOFDATE   2
 
#define LE_ALPHABLEND_FILTER   14
 
#define LE_ALPHABLEND_NONE   27
 
#define LE_CFILE_TYPE_NORMAL   20
 
#define LE_CFILE_TYPE_MEMORY_MAPPED   21
 
#define LE_MOUSE_LEFT_BUTTON   1
 
#define LE_MOUSE_RIGHT_BUTTON   2
 
#define LE_MOUSE_MIDDLE_BUTTON   3
 
#define LE_ORDER_ATTACK   28
 
#define LE_ORDER_ATTACK_ANY   29
 
#define LE_ORDER_DEPART   30
 
#define LE_ORDER_DISABLE   31
 
#define LE_ORDER_DISARM   32
 
#define LE_ORDER_DOCK   33
 
#define LE_ORDER_EVADE   34
 
#define LE_ORDER_FLY_TO   35
 
#define LE_ORDER_FORM_ON_WING   36
 
#define LE_ORDER_GUARD   37
 
#define LE_ORDER_IGNORE   38
 
#define LE_ORDER_KEEP_SAFE_DISTANCE   39
 
#define LE_ORDER_PLAY_DEAD   40
 
#define LE_ORDER_REARM   41
 
#define LE_ORDER_STAY_NEAR   42
 
#define LE_ORDER_STAY_STILL   43
 
#define LE_ORDER_UNDOCK   44
 
#define LE_ORDER_WAYPOINTS   45
 
#define LE_ORDER_WAYPOINTS_ONCE   46
 
#define LE_ORDER_ATTACK_WING   69
 
#define LE_ORDER_GUARD_WING   70
 
#define LE_PARTICLE_DEBUG   4
 
#define LE_PARTICLE_BITMAP   5
 
#define LE_PARTICLE_FIRE   6
 
#define LE_PARTICLE_SMOKE   7
 
#define LE_PARTICLE_SMOKE2   8
 
#define LE_PARTICLE_PERSISTENT_BITMAP   9
 
#define LE_SEXPVAR_CAMPAIGN_PERSISTENT   22
 
#define LE_SEXPVAR_NOT_PERSISTENT   23
 
#define LE_SEXPVAR_PLAYER_PERSISTENT   24
 
#define LE_SEXPVAR_TYPE_NUMBER   25
 
#define LE_SEXPVAR_TYPE_STRING   26
 
#define LE_TEXTURE_STATIC   10
 
#define LE_TEXTURE_DYNAMIC   11
 
#define LE_LOCK   12
 
#define LE_UNLOCK   13
 
#define LE_NONE   15
 
#define LE_SHIELD_FRONT   16
 
#define LE_SHIELD_LEFT   17
 
#define LE_SHIELD_RIGHT   18
 
#define LE_SHIELD_BACK   19
 
#define LE_MISSION_REPEAT   47
 
#define LE_NORMAL_CONTROLS   48
 
#define LE_LUA_STEERING_CONTROLS   49
 
#define LE_LUA_FULL_CONTROLS   50
 
#define LE_NORMAL_BUTTON_CONTROLS   51
 
#define LE_LUA_ADDITIVE_BUTTON_CONTROL   52
 
#define LE_LUA_OVERRIDE_BUTTON_CONTROL   53
 
#define LE_VM_INTERNAL   54
 
#define LE_VM_EXTERNAL   55
 
#define LE_VM_TRACK   56
 
#define LE_VM_DEAD_VIEW   57
 
#define LE_VM_CHASE   58
 
#define LE_VM_OTHER_SHIP   59
 
#define LE_VM_EXTERNAL_CAMERA_LOCKED   60
 
#define LE_VM_WARP_CHASE   61
 
#define LE_VM_PADLOCK_UP   62
 
#define LE_VM_PADLOCK_REAR   63
 
#define LE_VM_PADLOCK_LEFT   64
 
#define LE_VM_PADLOCK_RIGHT   65
 
#define LE_VM_WARPIN_ANCHOR   66
 
#define LE_VM_TOPDOWN   67
 
#define LE_VM_FREECAMERA   68
 
#define LE_MESSAGE_PRIORITY_LOW   71
 
#define LE_MESSAGE_PRIORITY_NORMAL   72
 
#define LE_MESSAGE_PRIORITY_HIGH   73
 
#define SWH_NONE   0
 
#define SWH_PRIMARY   1
 
#define SWH_SECONDARY   2
 
#define SWH_TERTIARY   3
 
#define MAX_TEXT_LINES   256
 

Functions

int ade_get_operator (char *tablename)
 
int ade_set_object_with_breed (lua_State *L, int obj_idx)
 
 if (!numargs||s[1]!= '\0') return ade_set_error(L
 
 if (s[0]=='p') idx = -2
 
else if (atoi(s)) idx
 
 if (idx< -3||idx==0||idx > 9) return ade_set_error(L
 
 if (idx< 0)
 
 if (ADE_SETTING_VAR &&*val!=newval)
 
return ade_set_args (L,"f",*val)
 
 ADE_FUNC (__mul, l_Matrix,"orientation","Multiplies two matrix objects)","orientation","matrix, or empty matrix if unsuccessful")
 
 ADE_FUNC (__tostring, l_Matrix, NULL,"Converts a matrix to a string with format \"[r1c1 r2c1 r3c1 | r1c2 r2c2 r3c2| r1c3 r2c3 r3c3]\"","string","Formatted string or \"<NULL\"")
 
 if (!ade_get_args(L,"oof", l_Matrix.GetPtr(&oriA), l_Matrix.GetPtr(&oriB),&factor)) return ade_set_error(L
 
l_Matrix Set (matrix_h()))
 
 for (int i=0;i< 9;i++)
 
return ade_set_args (L,"o", l_Matrix.Set(matrix_h(&final)))
 
 ADE_FUNC (getTranspose, l_Matrix, NULL,"Returns a transpose version of the specified orientation","orientation","Transpose matrix, or null orientation on failure")
 
 ADE_FUNC (rotateVector, l_Matrix,"vector Input","Returns rotated version of given vector","vector","Rotated vector, or empty vector on error")
 
 ADE_FUNC (unrotateVector, l_Matrix,"vector Input","Returns unrotated version of given vector","vector","Unrotated vector, or empty vector on error")
 
 if (!ade_get_args(L,"o", l_Matrix.GetPtr(&mh))) return ade_set_error(L
 
l_Vector Set (vmd_zero_vector))
 
return ade_set_args (L,"o", l_Vector.Set(mh->GetMatrix() ->vec.uvec))
 
return ade_set_args (L,"o", l_Vector.Set(mh->GetMatrix() ->vec.fvec))
 
return ade_set_args (L,"o", l_Vector.Set(mh->GetMatrix() ->vec.rvec))
 
 ADE_FUNC (__newindex, l_Enum,"enumeration","Sets enumeration to specified value (if it is not a global","enumeration","enumeration")
 
 ADE_FUNC (__tostring, l_Enum, NULL,"Returns enumeration name","string","Enumeration name, or \"<INVALID>\" if invalid")
 
 ADE_FUNC (__eq, l_Enum,"enumeration","Compares the two enumerations for equality","boolean","true if equal, false otherwise")
 
 ADE_VIRTVAR (Name, l_Event,"string","Mission event name","string", NULL)
 
 ADE_VIRTVAR (DirectiveText, l_Event,"string","Directive text","string", NULL)
 
 ADE_VIRTVAR (DirectiveKeypressText, l_Event,"string","Raw directive keypress text, as seen in FRED.","string", NULL)
 
 if (!ade_get_args(L,"o|i", l_Event.Get(&idx),&newinterval)) return ade_set_error(L
 
 if (idx< 0||idx >=Num_mission_events) return ade_set_error(L
 
 if (ADE_SETTING_VAR)
 
return ade_set_args (L,"i", mep->interval)
 
 ADE_VIRTVAR (ObjectCount, l_Event,"number","Number of objects left for event","number","Repeat count, or 0 if invalid handle")
 
 ADE_VIRTVAR (RepeatCount, l_Event,"number","Event repeat count","number","Repeat count, or 0 if invalid handle")
 
 ADE_VIRTVAR (Score, l_Event,"number","Event score","number","Event score, or 0 if invalid handle")
 
 ADE_FUNC (isValid, l_Event, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (isValid, l_File, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (close, l_File, NULL,"Instantly closes file and invalidates all file handles", NULL, NULL)
 
 ADE_FUNC (flush, l_File, NULL,"Flushes file buffer to disk.","boolean","True for success, false on failure")
 
 ADE_FUNC (getPath, l_File, NULL,"Determines path of the given file","string","Path string of the file handle, or an empty string if it doesn't have one, or the handle is invalid")
 
int cfread_lua_number (double *buf, CFILE *cfile)
 
 ADE_FUNC (read, l_File,"number or string, ...","Reads part of or all of a file, depending on arguments passed. Based on basic Lua file:read function.""Returns nil when the end of the file is reached.""<br><ul><li>\"*n\" - Reads a number.</li>""<li>\"*a\" - Reads the rest of the file and returns it as a string.</li>""<li>\"*l\" - Reads a line. Skips the end of line markers.</li>""<li>(number) - Reads given number of characters, then returns them as a string.</li></ul>","number or string, ...","Requested data, or nil if the function fails")
 
 ADE_FUNC (seek, l_File,"[string Whence=\"cur\", number Offset=0]","Changes position of file, or gets location.""Whence can be:""<li>\"set\" - File start.</li>""<li>\"cur\" - Current position in file.</li>""<li>\"end\" - File end.</li></ul>","number","new offset, or false or nil on failure")
 
 ADE_FUNC (write, l_File,"string or number, ...","Writes a series of Lua strings or numbers to the current file.","number","Number of items successfully written.")
 
 ADE_FUNC (__tostring, l_Font, NULL,"Filename of font","string","Font filename, or an empty string if the handle is invalid")
 
 if (!ade_get_args(L,"o|s", l_Font.Get(&font_num),&newname)) return ade_set_error(L
 
 if (font_num< 0||font_num >=Num_fonts) return ade_set_error(L
 
return ade_set_args (L,"s", Fonts[font_num].filename)
 
 if (!ade_get_args(L,"o|i", l_Font.Get(&font_num),&newheight)) return ade_set_error(L
 
 if (ADE_SETTING_VAR &&newheight > 0)
 
return ade_set_args (L,"i", Fonts[font_num].h)
 
 ADE_FUNC (isValid, l_Font, NULL,"True if valid, false or nil if not","boolean","Detects whether handle is valid")
 
 ADE_FUNC (__tostring, l_GameEvent, NULL,"Game event name","string","Game event name, or empty string if handle is invalid")
 
 ADE_VIRTVAR (Name, l_GameEvent,"string","Game event name","string","Game event name, or empty string if handle is invalid")
 
 ADE_FUNC (__tostring, l_GameState, NULL,"Game state name","string","Game state name, or empty string if handle is invalid")
 
 ADE_VIRTVAR (Name, l_GameState,"string","Game state name","string","Game state name, or empty string if handle is invalid")
 
 ADE_VIRTVAR (Name, l_HudGauge,"string","Custom HUD Gauge name","string","Custom HUD Gauge name, or nil if handle is invalid")
 
 ADE_VIRTVAR (Text, l_HudGauge,"string","Custom HUD Gauge text","string","Custom HUD Gauge text, or nil if handle is invalid")
 
 ADE_VIRTVAR (Normal, l_Eyepoint,"vector","Eyepoint normal","vector","Eyepoint normal, or null vector if handle is invalid")
 
 if (!ade_get_args(L,"o|o", l_Eyepoint.GetPtr(&eh), l_Vector.GetPtr(&v))) return ade_set_error(L
 
 if (!eh->IsValid()) return ade_set_error(L
 
 if (ADE_SETTING_VAR &&v!=NULL)
 
return ade_set_args (L,"o", l_Vector.Set(pm->view_positions[eh->eye_idx].pnt))
 
 ADE_FUNC (IsValid, l_Eyepoint, NULL,"Detect whether this handle is valid","boolean","true if valid false otherwise")
 
 ADE_VIRTVAR (Textures, l_Model,"modeltextures_h","Model textures","modeltextures_h","Model textures, or an invalid modeltextures handle if the model handle is invalid")
 
 ADE_VIRTVAR (Thrusters, l_Model,"thrusters","Model thrusters","thrusters","Thrusters of the model or invalid handle")
 
 ADE_VIRTVAR (Eyepoints, l_Model,"eyepoints","Model eyepoints","eyepoints","Array of eyepoints or invalid handle on error")
 
 ADE_VIRTVAR (Dockingbays, l_Model,"dockingbays","Docking bays handle of model","dockingbays","Array of docking bays on this model, or invalid handle on error")
 
void model_calc_bound_box (vec3d *box, vec3d *big_mn, vec3d *big_mx)
 
 ADE_VIRTVAR (BoundingBoxMax, l_Model,"vector","Model bounding box maximum","vector","Model bounding box, or an empty vector if the handle is invalid")
 
 ADE_VIRTVAR (BoundingBoxMin, l_Model,"vector","Model bounding box minimum","vector","Model bounding box, or an empty vector if the handle is invalid")
 
 ADE_VIRTVAR (Filename, l_Model,"string","Model filename","string","Model filename, or an empty string if the handle is invalid")
 
 ADE_VIRTVAR (Mass, l_Model,"number","Model mass","number","Model mass, or 0 if the model handle is invalid")
 
 ADE_VIRTVAR (MomentOfInertia, l_Model,"orientation","Model moment of inertia","orientation","Moment of Inertia matrix or identity matrix if invalid")
 
 if (!ade_get_args(L,"o|f", l_Model.GetPtr(&mdl),&nr)) return ade_set_error(L
 
 if (pm==NULL) return ade_set_error(L
 
return ade_set_args (L,"f", pm->rad)
 
 ADE_FUNC (isValid, l_Model, NULL,"True if valid, false or nil if not","boolean","Detects whether handle is valid")
 
 ADE_FUNC (__len, l_Eyepoints, NULL,"Gets the number of eyepoints on this model","number","Number of eyepoints on this model or 0 on error")
 
 ADE_INDEXER (l_Eyepoints,"eyepoint","Gets en eyepoint handle","eyepoint","eye handle or invalid handle on error")
 
 ADE_FUNC (isValid, l_Eyepoints, NULL,"Detects whether handle is valid or not","boolean","true if valid false otherwise")
 
 ADE_FUNC (__len, l_Thrusters, NULL,"Number of thruster banks on the model","number","Number of thrusterbanks")
 
 ADE_INDEXER (l_Thrusters,"number Index","Array of all thrusterbanks on this thruster","thrusterbank","Handle to the thrusterbank or invalid handle if index is invalid")
 
 ADE_FUNC (isValid, l_Thrusters, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (__len, l_Thrusterbank, NULL,"Number of thrusters on this thrusterbank","number","Number of thrusters on this bank or 0 if handle is invalid")
 
 ADE_INDEXER (l_Thrusterbank,"number Index","Array of glowpoint","glowpoint","Glowpoint, or invalid glowpoint handle on failure")
 
 ADE_FUNC (isValid, l_Thrusterbank, NULL,"Detectes if this handle is valid","boolean","true if this handle is valid, false otherwise")
 
 if (!ade_get_args(L,"o|o", l_Glowpoint.GetPtr(&glh), l_Vector.Get(&newVec))) return ADE_RETURN_NIL
 
 if (!glh->isValid()) return ADE_RETURN_NIL
 
return ade_set_args (L,"o", l_Vector.Set(vec))
 
 ADE_VIRTVAR (Radius, l_Glowpoint, NULL,"The radius of the glowpoint","number","The radius of the glowpoint or -1 of invalid")
 
 ADE_FUNC (isValid, l_Glowpoint, NULL,"Returns wether this handle is valid or not","boolean","True if handle is valid, false otherwise")
 
 ADE_INDEXER (l_Dockingbays,"dockingbay","Gets a dockingbay handle from this model. If a string is given then a dockingbay with that name is searched.","dockingbay","Handle or invalid handle on error")
 
 ADE_FUNC (__len, l_Dockingbays, NULL,"Retrieves the number of dockingbays on this model","number","number of docking bays or 0 on error")
 
 ADE_FUNC (__len, l_Dockingbay, NULL,"Gets the number of docking points in this bay","number","The number of docking points or 0 on error")
 
 ADE_FUNC (getName, l_Dockingbay, NULL,"Gets the name of this docking bay","string","The name or an empty string on error")
 
 ADE_FUNC (getPoint, l_Dockingbay,"number index","Gets the location of a docking point in this bay","vector","The local location or null vector on error")
 
 ADE_FUNC (getNormal, l_Dockingbay,"number index","Gets the normal of a docking point in this bay","vector","The normal vector or null vector on error")
 
 ADE_FUNC (computeDocker, l_Dockingbay,"dockingbay","Computes the final position and orientation of a docker bay that docks with this bay.","vector, orientation","The local location and orientation of the docker vessel in the reference to the vessel of the docking bay handle, or a nil value on error")
 
 ADE_FUNC (isValid, l_Dockingbay, NULL,"Detects whether is valid or not","number","<i>true</i> if valid, <i>false</i> otherwise")
 
 ADE_VIRTVAR (AfterburnerAccelerationTime, l_Physics,"number","Afterburner acceleration time","number","Afterburner acceleration time, or 0 if handle is invalid")
 
 if (!ade_get_args(L,"o|o", l_Physics.GetPtr(&pih), l_Vector.GetPtr(&v3))) return ade_set_error(L
 
 if (!pih->IsValid()) return ade_set_error(L
 
 if (ADE_SETTING_VAR &&v3!=NULL)
 
return ade_set_args (L,"o", l_Vector.Set(pih->pi->afterburner_max_vel))
 
 ADE_VIRTVAR (BankingConstant, l_Physics,"number","Banking constant","number","Banking constant, or 0 if handle is invalid")
 
 ADE_VIRTVAR (ForwardAccelerationTime, l_Physics,"number","Forward acceleration time","number","Forward acceleration time, or 0 if handle is invalid")
 
 ADE_VIRTVAR (ForwardDecelerationTime, l_Physics,"number","Forward deceleration time","number","Forward decleration time, or 0 if handle is invalid")
 
 if (!ade_get_args(L,"o|f", l_Physics.GetPtr(&pih),&f)) return ade_set_error(L
 
return ade_set_args (L,"f", pih->pi->forward_thrust)
 
 ADE_VIRTVAR (Mass, l_Physics,"number","Object mass","number","Object mass, or 0 if handle is invalid")
 
return ade_set_args (L,"o", l_Vector.Set(pih->pi->rotvel))
 
 ADE_VIRTVAR (RotationalVelocityDamping, l_Physics,"number","Rotational damping, ie derivative of rotational speed","number","Rotational damping, or 0 if handle is invalid")
 
 ADE_VIRTVAR (RotationalVelocityDesired, l_Physics,"vector","Desired rotational velocity","vector","Desired rotational velocity, or null vector if handle is invalid")
 
return ade_set_args (L,"o", l_Vector.Set(pih->pi->max_rotvel))
 
 ADE_VIRTVAR (ShockwaveShakeAmplitude, l_Physics,"number","How much shaking from shockwaves is applied to object","number","Shockwave shake amplitude, or 0 if handle is invalid")
 
 ADE_VIRTVAR (SlideAccelerationTime, l_Physics,"number","Time to accelerate to maximum slide velocity","number","Sliding acceleration time, or 0 if handle is invalid")
 
 ADE_VIRTVAR (SlideDecelerationTime, l_Physics,"number","Time to decelerate from maximum slide speed","number","Sliding deceleration time, or 0 if handle is invalid")
 
return ade_set_args (L,"o", l_Vector.Set(pih->pi->vel))
 
return ade_set_args (L,"o", l_Vector.Set(pih->pi->desired_vel))
 
return ade_set_args (L,"o", l_Vector.Set(pih->pi->max_vel))
 
 ADE_VIRTVAR (AfterburnerActive, l_Physics,"boolean","Specifies if the afterburner is active or not","boolean","true if afterburner is active false otherwise")
 
 ADE_FUNC (isValid, l_Physics, NULL,"True if valid, false or nil if not","boolean","Detects whether handle is valid")
 
 ADE_FUNC (getSpeed, l_Physics, NULL,"Gets total speed as of last frame","number","Total speed, or 0 if handle is invalid")
 
 ADE_FUNC (getForwardSpeed, l_Physics, NULL,"Gets total speed in the ship's 'forward' direction as of last frame","number","Total forward speed, or 0 if handle is invalid")
 
 ADE_FUNC (isAfterburnerActive, l_Physics, NULL,"True if Afterburners are on, false or nil if not","boolean","Detects whether afterburner is active")
 
 ADE_FUNC (isGliding, l_Physics, NULL,"True if glide mode is on, false or nil if not","boolean","Detects if ship is gliding")
 
 ADE_FUNC (applyWhack, l_Physics,"vector Impulse, [ vector Position]","Applies a whack to an object at a position (a local vector) based on impulse supplied (a world vector). If no position is supplied, an empty vector is used.","boolean","true if it succeeded, false otherwise")
 
 ADE_VIRTVAR (Persistence, l_SEXPVariable,"enumeration","SEXP Variable persistance, uses SEXPVAR_*_PERSISTENT enumerations","enumeration","SEXPVAR_*_PERSISTENT enumeration, or invalid numeration if handle is invalid")
 
 ADE_VIRTVAR (Type, l_SEXPVariable,"enumeration","SEXP Variable type, uses SEXPVAR_TYPE_* enumerations","enumeration","SEXPVAR_TYPE_* enumeration, or invalid numeration if handle is invalid")
 
 ADE_VIRTVAR (Value, l_SEXPVariable,"number/string","SEXP variable value","string","SEXP variable contents, or nil if the variable is of an invalid type or the handle is invalid")
 
 ADE_FUNC (__tostring, l_SEXPVariable, NULL,"Returns SEXP name","string","SEXP name, or empty string if handle is invalid")
 
 ADE_FUNC (isValid, l_SEXPVariable, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (delete, l_SEXPVariable, NULL,"Deletes a SEXP Variable","boolean","True if successful, false if the handle is invalid")
 
 ADE_FUNC (__len, l_Shields, NULL,"Number of shield segments","number","Number of shield segments or 0 if handle is invalid")
 
 if (lua_isstring(L, 2))
 
 if (!ade_get_args(L,"oo|f", l_Shields.GetPtr(&objh), l_Enum.GetPtr(&qd),&nval)) return 0
 
 if (!objh->IsValid()) return ade_set_error(L
 
 switch (qd->index)
 
 if (qdx==-1)
 
 if (ADE_SETTING_VAR &&nval >=0.0f) shield_set_quad(objp
 
return ade_set_args (L,"f", shield_get_quad(objp, qdx))
 
 if (!ade_get_args(L,"o|f", l_Shields.GetPtr(&objh),&nval)) return ade_set_error(L
 
return ade_set_args (L,"f", shield_get_strength(objh->objp))
 
return ade_set_args (L,"f", shield_get_max_strength(objh->objp))
 
 ADE_FUNC (isValid, l_Shields, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_VIRTVAR (Name, l_Shiptype,"string","Ship type name","string","Ship type name, or empty string if handle is invalid")
 
 ADE_FUNC (isValid, l_Shiptype, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_VIRTVAR (Name, l_Species,"string","Species name","string","Species name, or empty string if handle is invalid")
 
 ADE_FUNC (isValid, l_Species, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (__eq, l_Team,"team, team","Checks whether two teams are the same team","boolean","true if equal")
 
 ADE_VIRTVAR (Name, l_Team,"string","Team name","string","Team name, or empty string if handle is invalid")
 
 ADE_FUNC (getColor, l_Team, NULL,"Gets the IFF color of the specified Team","number, number, number","rgb color for the specified team or nil if invalid")
 
 ADE_FUNC (isValid, l_Team, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (__gc, l_Texture, NULL,"Auto-deletes texture", NULL, NULL)
 
 ADE_FUNC (__eq, l_Texture,"texture, texture","Checks if two texture handles refer to the same texture","boolean","True if textures are equal")
 
 ADE_INDEXER (l_Texture,"number","Returns texture handle to specified frame number in current texture's animation.""This means that [1] will always return the first frame in an animation, no matter what frame an animation is.""You cannot change a texture animation frame.","texture","Texture handle, or invalid texture handle if index is invalid")
 
 ADE_FUNC (isValid, l_Texture, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (unload, l_Texture, NULL,"Unloads a texture from memory", NULL, NULL)
 
 ADE_FUNC (getFilename, l_Texture, NULL,"Returns filename for texture","string","Filename, or empty string if handle is invalid")
 
 ADE_FUNC (getWidth, l_Texture, NULL,"Gets texture width","number","Texture width, or 0 if handle is invalid")
 
 ADE_FUNC (getHeight, l_Texture, NULL,"Gets texture height","number","Texture height, or 0 if handle is invalid")
 
 ADE_FUNC (getFPS, l_Texture, NULL,"Gets frames-per-second of texture","number","Texture FPS, or 0 if handle is invalid")
 
 ADE_FUNC (getFramesLeft, l_Texture, NULL,"Gets number of frames left, from handle's position in animation","number","Frames left, or 0 if handle is invalid")
 
 ADE_INDEXER (l_Vector,"x,y,z or 1-3","Vector component","number","Value at index, or 0 if vector handle is invalid")
 
 ADE_FUNC (__add, l_Vector,"number/vector","Adds vector by another vector, or adds all axes by value","vector","Final vector, or null vector if error occurs")
 
 ADE_FUNC (__sub, l_Vector,"number/vector","Subtracts vector from another vector, or subtracts all axes by value","vector","Final vector, or null vector if error occurs")
 
 if (lua_isnumber(L, 1)||lua_isnumber(L, 2))
 
 if (!ade_get_args(L,"oo", l_Vector.GetPtr(&v1), l_Vector.GetPtr(&v2))) return ade_set_args(L
 
return ade_set_args (L,"o", l_Vector.Set(v3))
 
 if (!ade_get_args(L,"o", l_Vector.GetPtr(&v3))) return ade_set_error(L
 
 sprintf (buf,"(%f,%f,%f)", v3->xyz.x, v3->xyz.y, v3->xyz.z)
 
return ade_set_args (L,"s", buf)
 
 ADE_FUNC (getOrientation, l_Vector, NULL,"Returns orientation object representing the direction of the vector. Does not require vector to be normalized.","orientation","Orientation object, or null orientation object if handle is invalid")
 
return ade_set_args (L,"f", vm_vec_mag(v3))
 
 ADE_FUNC (getDistance, l_Vector,"Vector","Distance","number","Returns distance from another vector")
 
 ADE_FUNC (getDotProduct, l_Vector,"vector OtherVector","Returns dot product of vector object with vector argument","number","Dot product, or 0 if a handle is invalid")
 
 ADE_FUNC (getCrossProduct, l_Vector,"vector OtherVector","Returns cross product of vector object with vector argument","vector","Cross product, or null vector if a handle is invalid")
 
 ADE_FUNC (getScreenCoords, l_Vector, NULL,"Gets screen cordinates of a world vector","number,number","X (number), Y (number), or false if off-screen")
 
 ADE_FUNC (getNormalized, l_Vector, NULL,"Returns a normalized version of the vector","vector","Normalized Vector, or NIL if invalid")
 
 ADE_VIRTVAR (BaseMap, l_TextureMap,"texture","Base texture","texture","Base texture, or invalid texture handle if material handle is invalid")
 
 ADE_VIRTVAR (GlowMap, l_TextureMap,"texture","Glow texture","texture","Glow texture, or invalid texture handle if material handle is invalid")
 
 ADE_VIRTVAR (SpecularMap, l_TextureMap,"texture","Specular texture","texture","Texture handle, or invalid texture handle if material handle is invalid")
 
 ADE_FUNC (__tostring, l_Weaponclass, NULL,"Weapon class name","string","Weapon class name, or an empty string if handle is invalid")
 
 ADE_FUNC (__eq, l_Weaponclass,"weaponclass, weaponclass","Checks if the two classes are equal","boolean","true if equal false otherwise")
 
 ADE_VIRTVAR (Name, l_Weaponclass,"string","Weapon class name","string","Weapon class name, or empty string if handle is invalid")
 
 ADE_VIRTVAR (Title, l_Weaponclass,"string","Weapon class title","string","Weapon class title, or empty string if handle is invalid")
 
 ADE_VIRTVAR (Description, l_Weaponclass,"string","Weapon class description string","string","Description string, or empty string if handle is invalid")
 
 ADE_VIRTVAR (TechTitle, l_Weaponclass,"string","Weapon class tech title","string","Tech title, or empty string if handle is invalid")
 
 ADE_VIRTVAR (TechAnimationFilename, l_Weaponclass,"string","Weapon class animation filename","string","Filename, or empty string if handle is invalid")
 
 ADE_VIRTVAR (TechDescription, l_Weaponclass,"string","Weapon class tech description string","string","Description string, or empty string if handle is invalid")
 
 ADE_VIRTVAR (Model, l_Weaponclass,"model","Model","model","Weapon class model, or invalid model handle if weaponclass handle is invalid")
 
 if (!ade_get_args(L,"o|f", l_Weaponclass.Get(&idx),&f)) return ade_set_error(L
 
return ade_set_args (L,"f", Weapon_info[idx].armor_factor)
 
 ADE_VIRTVAR (Damage, l_Weaponclass,"number","Amount of damage that weapon deals","number","Damage amount, or 0 if handle is invalid")
 
 ADE_VIRTVAR (FreeFlightTime, l_Weaponclass,"number","The time the weapon will fly before turing onto its target","number","Free flight time or emty string if invalid")
 
 ADE_VIRTVAR (LifeMax, l_Weaponclass,"number","Life of weapon in seconds","number","Life of weapon, or 0 if handle is invalid")
 
 ADE_VIRTVAR (Range, l_Weaponclass,"number","Range of weapon in meters","number","Weapon Range, or 0 if handle is invalid")
 
 ADE_VIRTVAR (Mass, l_Weaponclass,"number","Weapon mass","number","Weapon mass, or 0 if handle is invalid")
 
 ADE_VIRTVAR (TargetLOD, l_Weaponclass,"number","LOD used for weapon model in the targeting computer","number","LOD number, or 0 if handle is invalid")
 
 ADE_VIRTVAR (Speed, l_Weaponclass,"number","Weapon max speed, aka $Velocity in weapons.tbl","number","Weapon speed, or 0 if handle is invalid")
 
 ADE_VIRTVAR (Bomb, l_Weaponclass,"boolean","Is weapon class flagged as bomb","boolean","New flag")
 
 ADE_VIRTVAR (CargoSize, l_Weaponclass,"number","The cargo size of this weapon class","number","The new cargo size or -1 on error")
 
 ADE_FUNC (isValid, l_Weaponclass, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (getWeaponClassIndex, l_Weaponclass, NULL,"Gets the index value of the weapon class","number","index value of the weapon class")
 
 if (!ade_get_args(L,"o", l_Weaponclass.Get(&idx))) return ADE_RETURN_NIL
 
 if (Weapon_info[idx].subtype==WP_LASER) return ADE_RETURN_TRUE
 
 ADE_FUNC (isMissile, l_Weaponclass, NULL,"Return true if the weapon is a secondary weapon. This function is deprecated, use isSecondary instead.","boolean","true if the weapon is a secondary, false otherwise")
 
 ADE_FUNC (isSecondary, l_Weaponclass, NULL,"Return true if the weapon is a secondary weapon","boolean","true if the weapon is a secondary, false otherwise")
 
 ADE_FUNC (isBeam, l_Weaponclass, NULL,"Return true if the weapon is a beam","boolean","true if the weapon is a beam, false otherwise")
 
 ADE_FUNC (__gc, l_ColInfo, NULL,"Removes the allocated reference of this handle", NULL, NULL)
 
 ADE_VIRTVAR (Model, l_ColInfo,"model","The model this collision info is about","model","The model")
 
 ADE_FUNC (getCollisionDistance, l_ColInfo, NULL,"The distance to the closest collision point","number","distance or -1 on error")
 
 if (!ade_get_args(L,"o|b", l_ColInfo.GetPtr(&info),&local)) return ADE_RETURN_NIL
 
 if (!info->IsValid()) return ADE_RETURN_NIL
 
 if (collide->num_hits<=0)
 
else return ade_set_args (L,"o", l_Vector.Set(collide->hit_point_world))
 
 ADE_FUNC (__eq, l_Object,"object, object","Checks whether two object handles are for the same object","boolean","True if equal, false if not or a handle is invalid")
 
 if (!ade_get_args(L,"o", l_Object.GetPtr(&objh))) return ade_set_error(L
 
 switch (objh->objp->type)
 
 ADE_VIRTVAR (Parent, l_Object,"object","Parent of the object. Value may also be a deriviative of the 'object' class, such as 'ship'.","object","Parent handle, or invalid handle if object is invalid")
 
 if (!ade_get_args(L,"o|o", l_Object.GetPtr(&objh), l_Vector.GetPtr(&v3))) return ade_set_error(L
 
return ade_set_args (L,"o", l_Vector.Set(objh->objp->pos))
 
return ade_set_args (L,"o", l_Vector.Set(objh->objp->last_pos))
 
 if (!ade_get_args(L,"o|o", l_Object.GetPtr(&objh), l_Matrix.GetPtr(&mh))) return ade_set_error(L
 
l_Matrix Set (matrix_h(&vmd_identity_matrix)))
 
 if (ADE_SETTING_VAR &&mh!=NULL)
 
return ade_set_args (L,"o", l_Matrix.Set(matrix_h(&objh->objp->orient)))
 
return ade_set_args (L,"o", l_Matrix.Set(matrix_h(&objh->objp->last_orient)))
 
 ADE_VIRTVAR (Physics, l_Object,"physics","Physics data used to move ship between frames","physics","Physics data, or invalid physics handle if object handle is invalid")
 
 ADE_VIRTVAR (HitpointsLeft, l_Object,"number","Hitpoints an object has left","number","Hitpoints left, or 0 if handle is invalid")
 
 ADE_VIRTVAR (Shields, l_Object,"shields","Shields","shields","Shields handle, or invalid shields handle if object handle is invalid")
 
 ADE_FUNC (getSignature, l_Object, NULL,"Gets the object's unique signature","number","Returns the object's unique numeric signature, or -1 if invalid. Useful for creating a metadata system")
 
 ADE_FUNC (isValid, l_Object, NULL,"Detects whether handle is valid","boolean","true if handle is valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (getBreedName, l_Object, NULL,"Gets object type","string","Object type name, or empty string if handle is invalid")
 
 ADE_VIRTVAR (CollisionGroups, l_Object,"number","Collision group data","number","Current collision group signature. NOTE: This is a bitfield, NOT a normal number.")
 
 ADE_FUNC (getfvec, l_Object,"[boolean normalize]","Returns the objects' current fvec.","vector","Objects' forward vector, or nil if invalid. If called with a true argument, vector will be normalized.")
 
 ADE_FUNC (getuvec, l_Object,"[boolean normalize]","Returns the objects' current uvec.","vector","Objects' up vector, or nil if invalid. If called with a true argument, vector will be normalized.")
 
 ADE_FUNC (getrvec, l_Object,"[boolean normalize]","Returns the objects' current rvec.","vector","Objects' rvec, or nil if invalid. If called with a true argument, vector will be normalized.")
 
 if (!ade_get_args(L,"ooo|b", l_Object.GetPtr(&objh), l_Vector.GetPtr(&v3a), l_Vector.GetPtr(&v3b),&local)) return ADE_RETURN_NIL
 
 switch (obj->type)
 
 if (obj->type==OBJ_SHIP)
 
 if (!model_collide(&hull_check))
 
 if (local) return ade_set_args(L
 
l_Vector Set (hull_check.hit_point)
 
l_Vector l_ColInfo Set (mc_info_h(new mc_info(hull_check))))
 
else return ade_set_args (L,"oo", l_Vector.Set(hull_check.hit_point_world), l_ColInfo.Set(mc_info_h(new mc_info(hull_check))))
 
 ADE_VIRTVAR (Target, l_Asteroid,"object","Asteroid target object; may be object derivative, such as ship.","object","Target object, or invalid handle if asteroid handle is invalid")
 
 ADE_FUNC (kill, l_Asteroid,"[ship killer=nil, wvector hitpos=nil]","Kills the asteroid. Set \"killer\" to designate a specific ship as having been the killer, and \"hitpos\" to specify the world position of the hit location; if nil, the asteroid center is used.","boolean","True if successful, false or nil otherwise")
 
 ADE_FUNC (getName, l_DisplayInfo, NULL,"Gets the name of this cockpit display as defined in ships.tbl","string","Name string or empty string on error")
 
 ADE_FUNC (getFileName, l_DisplayInfo, NULL,"Gets the file name of the target texture of this cockpit display","string","Texture name string or empty string on error")
 
 ADE_FUNC (getForegroundFileName, l_DisplayInfo, NULL,"Gets the file name of the foreground texture of this cockpit display","string","Foreground texture name string or nil if texture is not set or on error")
 
 ADE_FUNC (getBackgroundFileName, l_DisplayInfo, NULL,"Gets the file name of the background texture of this cockpit display","string","Background texture name string or nil if texture is not set or on error")
 
 ADE_FUNC (getSize, l_DisplayInfo, NULL,"Gets the size of this cockpit display","number, number","Width and height of the display or -1, -1 on error")
 
 ADE_FUNC (getOffset, l_DisplayInfo, NULL,"Gets the offset of this cockpit display","number, number","x and y offset of the display or -1, -1 on error")
 
 ADE_FUNC (isValid, l_DisplayInfo, NULL,"Detects whether this handle is valid","boolean","true if valid false otherwise")
 
 ADE_FUNC (startRendering, l_CockpitDisplay,"[boolean setClip = true]","Starts rendering to this cockpit display. That means if you get a valid texture handle from this function then the rendering system is ready to do a render to texture. If setClip is true then the clipping region will be set to the region of the cockpit display.<br><b>Important:</b> You have to call stopRendering after you're done or this render target will never be released!","texture","texture handle that is being drawn to or invalid handle on error")
 
 ADE_FUNC (stopRendering, l_CockpitDisplay, NULL,"Stops rendering to this cockpit display","boolean","true if successfull, false otherwise")
 
 ADE_FUNC (getBackgroundTexture, l_CockpitDisplay, NULL,"Gets the background texture handle of this cockpit display","texture","texture handle or invalid handle if no background texture or an error happened")
 
 ADE_FUNC (getForegroundTexture, l_CockpitDisplay, NULL,"Gets the foreground texture handle of this cockpit display<br>""<b>Important:</b> If you want to do render to texture then you have to use startRendering/stopRendering","texture","texture handle or invalid handle if no foreground texture or an error happened")
 
 ADE_FUNC (getSize, l_CockpitDisplay, NULL,"Gets the size of this cockpit display","number, number","Width and height of the display or -1, -1 on error")
 
 ADE_FUNC (getOffset, l_CockpitDisplay, NULL,"Gets the offset of this cockpit display","number, number","x and y offset of the display or -1, -1 on error")
 
 ADE_FUNC (isValid, l_CockpitDisplay, NULL,"Detects whether this handle is valid or not","boolean","true if valid, false otherwise")
 
 ADE_FUNC (__len, l_CockpitDisplayInfos, NULL,"Number of cockpit displays for this ship class","number","number of cockpit displays or -1 on error")
 
 ADE_INDEXER (l_CockpitDisplayInfos,"number/string","Returns the handle at the requested index or the handle with the specified name","display info","display handle or invalid handle on error")
 
 ADE_FUNC (isValid, l_CockpitDisplayInfos, NULL,"Detects whether this handle is valid","boolean","true if valid, false otehrwise")
 
 ADE_FUNC (__tostring, l_Shipclass, NULL,"Ship class name","string","Ship class name, or an empty string if handle is invalid")
 
 ADE_FUNC (__eq, l_Shipclass,"shipclass, shipclass","Checks if the two classes are equal","boolean","true if equal false otherwise")
 
 ADE_VIRTVAR (Name, l_Shipclass,"string","Ship class name","string","Ship class name, or an empty string if handle is invalid")
 
 ADE_VIRTVAR (ShortName, l_Shipclass,"string","Ship class short name","string","Ship short name, or empty string if handle is invalid")
 
 ADE_VIRTVAR (TypeString, l_Shipclass,"string","Ship class type string","string","Type string, or empty string if handle is invalid")
 
 ADE_VIRTVAR (ManeuverabilityString, l_Shipclass,"string","Ship class maneuverability string","string","Maneuverability string, or empty string if handle is invalid")
 
 ADE_VIRTVAR (ArmorString, l_Shipclass,"string","Ship class armor string","string","Armor string, or empty string if handle is invalid")
 
 ADE_VIRTVAR (ManufacturerString, l_Shipclass,"string","Ship class manufacturer","string","Manufacturer, or empty string if handle is invalid")
 
 ADE_VIRTVAR (Description, l_Shipclass,"string","Ship class description","string","Description, or empty string if handle is invalid")
 
 ADE_VIRTVAR (TechDescription, l_Shipclass,"string","Ship class tech description","string","Tech description, or empty string if handle is invalid")
 
 ADE_VIRTVAR (AfterburnerFuelMax, l_Shipclass,"number","Afterburner fuel capacity","number","Afterburner capacity, or 0 if handle is invalid")
 
 ADE_VIRTVAR (CountermeasuresMax, l_Shipclass,"number","Maximum number of countermeasures the ship can carry","number","Countermeasure capacity, or 0 if handle is invalid")
 
 ADE_VIRTVAR (Model, l_Shipclass,"model","Model","model","Ship class model, or invalid model handle if shipclass handle is invalid")
 
 ADE_VIRTVAR (CockpitModel, l_Shipclass,"model","Model used for first-person cockpit","model","Cockpit model")
 
 ADE_VIRTVAR (CockpitDisplays, l_Shipclass,"cockpitdisplays","Gets the cockpit display information array of this ship class","cockpitdisplays","Array handle containing the information or invalid handle on error")
 
 ADE_VIRTVAR (HitpointsMax, l_Shipclass,"number","Ship class hitpoints","number","Hitpoints, or 0 if handle is invalid")
 
 ADE_VIRTVAR (Species, l_Shipclass,"Species","Ship class species","species","Ship class species, or invalid species handle if shipclass handle is invalid")
 
 ADE_VIRTVAR (Type, l_Shipclass,"shiptype","Ship class type","shiptype","Ship type, or invalid handle if shipclass handle is invalid")
 
 ADE_VIRTVAR (AltName, l_Shipclass,"string","Alternate name for ship class","string","Alternate string or empty string if handle is invalid")
 
 ADE_FUNC (isValid, l_Shipclass, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (isInTechroom, l_Shipclass, NULL,"Gets whether or not the ship class is available in the techroom","boolean","Whether ship has been revealed in the techroom, false if handle is invalid")
 
 ADE_FUNC (renderTechModel, l_Shipclass,"X1, Y1, X2, Y2, [Rotation %=0, Pitch %=0, Bank %=40, number Zoom=1.3]","Draws ship model as if in techroom","boolean","Whether ship was rendered")
 
 ADE_FUNC (renderTechModel2, l_Shipclass,"X1, Y1, X2, Y2, [orientation Orientation=nil, number Zoom=1.3]","Draws ship model as if in techroom","boolean","Whether ship was rendered")
 
 ADE_FUNC (isModelLoaded, l_Shipclass,"[boolean Load = false]","Checks if the model used for this shipclass is loaded or not and optionally loads the model, which might be a slow operation.","boolean","If the model is loaded or not")
 
 ADE_FUNC (getShipClassIndex, l_Shipclass, NULL,"Gets the index valus of the ship class","number","index value of the ship class")
 
 ADE_VIRTVAR (IsHull, l_Debris,"boolean","Whether or not debris is a piece of hull","boolean","Whether debris is a hull fragment, or false if handle is invalid")
 
 ADE_VIRTVAR (OriginClass, l_Debris,"shipclass","The shipclass of the ship this debris originates from","shipclass","The shipclass of the ship that created this debris")
 
 ADE_FUNC (getDebrisRadius, l_Debris, NULL,"The radius of this debris piece","number","The radius of this debris piece or -1 if invalid")
 
 ADE_FUNC (isValid, l_Debris, NULL,"Return if this debris handle is valid","boolean","true if valid false otherwise")
 
 ADE_INDEXER (l_WaypointList,"number Index","Array of waypoints that are part of the waypoint list","waypoint","Waypoint, or invalid handle if the index or waypointlist handle is invalid")
 
 ADE_FUNC (__len, l_WaypointList, NULL,"Number of waypoints in the list. ""Note that the value returned cannot be relied on for more than one frame.","number","Number of waypoints in the list, or 0 if handle is invalid")
 
 ADE_VIRTVAR (Name, l_WaypointList,"string","Name of WaypointList","string","Waypointlist name, or empty string if handle is invalid")
 
 ADE_FUNC (isValid, l_WaypointList, NULL,"Return if this waypointlist handle is valid","boolean","true if valid false otherwise")
 
 ADE_FUNC (getList, l_Waypoint, NULL,"Returns the waypoint list","waypointlist","waypointlist handle or invalid handle if waypoint was invalid")
 
 ADE_VIRTVAR (WeaponClass, l_WeaponBank,"weaponclass","Class of weapon mounted in the bank","weaponclass","Weapon class, or an invalid weaponclass handle if bank handle is invalid")
 
 ADE_VIRTVAR (AmmoLeft, l_WeaponBank,"number","Ammo left for the current bank","number","Ammo left, or 0 if handle is invalid")
 
 ADE_VIRTVAR (AmmoMax, l_WeaponBank,"number","Maximum ammo for the current bank<br>""<b>Note:</b> Setting this value actually sets the <i>capacity</i> of the weapon bank. To set the actual maximum ammunition use <tt>AmmoMax = <amount> * class.CargoSize</tt>","number","Ammo capacity, or 0 if handle is invalid")
 
 ADE_VIRTVAR (Armed, l_WeaponBank,"boolean","Weapon armed status. Does not take linking into account.","boolean","True if armed, false if unarmed or handle is invalid")
 
 ADE_VIRTVAR (Capacity, l_WeaponBank,"number","The actual capacity of a weapon bank as specified in the table","number","The capacity or -1 if handle is invalid")
 
 ADE_FUNC (isValid, l_WeaponBank, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_INDEXER (l_WeaponBankType,"number Index","Array of weapon banks","weaponbank","Weapon bank, or invalid handle on failure")
 
 if (!numargs) return ade_set_error(L
 
 if (!bh->IsValid()) return ade_set_error(L
 
 switch (bh->type)
 
return ade_set_error (L,"b", false)
 
 ADE_FUNC (isValid, l_WeaponBankType, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (__len, l_WeaponBankType, NULL,"Number of weapons in the mounted bank","number","Number of bank weapons, or 0 if handle is invalid")
 
 ADE_FUNC (__tostring, l_Subsystem, NULL,"Returns name of subsystem","string","Subsystem name, or empty string if handle is invalid")
 
 ADE_VIRTVAR (ArmorClass, l_Subsystem,"string","Current Armor class","string","Armor class name, or empty string if none is set")
 
 ADE_VIRTVAR (AWACSIntensity, l_Subsystem,"number","Subsystem AWACS intensity","number","AWACS intensity, or 0 if handle is invalid")
 
 ADE_VIRTVAR (AWACSRadius, l_Subsystem,"number","Subsystem AWACS radius","number","AWACS radius, or 0 if handle is invalid")
 
 ADE_VIRTVAR (Orientation, l_Subsystem,"orientation","Orientation of subobject or turret base","orientation","Subsystem orientation, or null orientation if handle is invalid")
 
 ADE_VIRTVAR (GunOrientation, l_Subsystem,"orientation","Orientation of turret gun","orientation","Gun orientation, or null orientation if handle is invalid")
 
 ADE_VIRTVAR (HitpointsLeft, l_Subsystem,"number","Subsystem hitpoints left","number","Hitpoints left, or 0 if handle is invalid. Setting a value of 0 will disable it - set a value of -1 or lower to actually blow it up.")
 
 ADE_VIRTVAR (HitpointsMax, l_Subsystem,"number","Subsystem hitpoints max","number","Max hitpoints, or 0 if handle is invalid")
 
 if (!ade_get_args(L,"o|o", l_Subsystem.GetPtr(&sso), l_Vector.GetPtr(&v))) return ade_set_error(L
 
 if (!sso->IsValid()) return ade_set_error(L
 
return ade_set_args (L,"o", l_Vector.Set(sso->ss->system_info->pnt))
 
 Assert (pm!=NULL)
 
return ade_set_args (L,"o", l_Vector.Set(sm->offset))
 
 ADE_VIRTVAR (Name, l_Subsystem,"string","Subsystem name","string","Subsystem name, or an empty string if handle is invalid")
 
 ADE_FUNC (getModelName, l_Subsystem, NULL,"Returns the original name of the subsystem in the model file","string","name or empty string on error")
 
 ADE_VIRTVAR (PrimaryBanks, l_Subsystem,"weaponbanktype","Array of primary weapon banks","weaponbanktype","Primary banks, or invalid weaponbanktype handle if subsystem handle is invalid")
 
 ADE_VIRTVAR (SecondaryBanks, l_Subsystem,"weaponbanktype","Array of secondary weapon banks","weaponbanktype","Secondary banks, or invalid weaponbanktype handle if subsystem handle is invalid")
 
 ADE_VIRTVAR (Target, l_Subsystem,"object","Object targeted by this subsystem. If used to set a new target, AI targeting will be switched off.","object","Targeted object, or invalid object handle if subsystem handle is invalid")
 
 ADE_VIRTVAR (TurretResets, l_Subsystem,"boolean","Specifies wether this turrets resets after a certain time of inactivity","boolean","true if turret resets, false otherwise")
 
 if (!ade_get_args(L,"o|i", l_Subsystem.GetPtr(&sso),&newVal)) return ade_set_error(L
 
 if (!(sso->ss->system_info->flags &MSS_FLAG_TURRET_RESET_IDLE)) return ade_set_error(L
 
return ade_set_args (L,"i", sso->ss->system_info->turret_reset_delay)
 
 ADE_VIRTVAR (TurnRate, l_Subsystem,"number","The turn rate","number","Turnrate or -1 on error")
 
 ADE_VIRTVAR (Targetable, l_Subsystem,"boolean","Targetability of this subsystem","boolean","true if targetable, false otherwise or on error")
 
 ADE_VIRTVAR (Radius, l_Subsystem,"number","The radius of this subsystem","number","The radius or 0 on error")
 
 ADE_VIRTVAR (TurretLocked, l_Subsystem,"boolean","Whether the turret is locked. Setting to true locks the turret, setting to false frees it.","boolean","True if turret is locked, false otherwise")
 
 if (!ade_get_args(L,"o|f", l_Subsystem.GetPtr(&sso),&newVal)) return ade_set_error(L
 
return ade_set_args (L,"f", sso->ss->turret_next_fire_stamp/1000.0f)
 
 ADE_FUNC (targetingOverride, l_Subsystem,"boolean","If set to true, AI targeting for this turret is switched off. If set to false, the AI will take over again.","boolean","Returns true if successful, false otherwise")
 
 ADE_FUNC (hasFired, l_Subsystem, NULL,"Determine if a subsystem has fired","boolean","true if if fired, false if not fired, or nil if invalid. resets fired flag when called.")
 
 ADE_FUNC (isTurret, l_Subsystem, NULL,"Determines if this subsystem is a turret","boolean","true if subsystem is turret, false otherwise or nil on error")
 
 ADE_FUNC (isTargetInFOV, l_Subsystem,"object Target","Determines if the object is in the turrets FOV","boolean","true if in FOV, false if not, nil on error or if subsystem is not a turret ")
 
bool turret_fire_weapon (int weapon_num, ship_subsys *turret, int parent_objnum, vec3d *turret_pos, vec3d *turret_fvec, vec3d *predicted_pos=NULL, float flak_range_override=100.0f)
 
 ADE_FUNC (fireWeapon, l_Subsystem,"[Turret weapon index = 1, Flak range = 100]","Fires weapon on turret", NULL, NULL)
 
 ADE_FUNC (rotateTurret, l_Subsystem,"vector Pos[, boolean reset=false","Rotates the turret to face Pos or resets the turret to its original state","boolean","true on success false otherwise")
 
 ADE_FUNC (getTurretHeading, l_Subsystem, NULL,"Returns the turrets forward vector","vector","Returns a normalized version of the forward vector or null vector on error")
 
 ADE_FUNC (getFOVs, l_Subsystem, NULL,"Returns current turrets FOVs","number, number, number","Standard FOV, maximum barrel elevation, turret base fov.")
 
 ADE_FUNC (getNextFiringPosition, l_Subsystem, NULL,"Retrieves the next position and firing normal this turret will fire from. This function returns a world position","vector, vector","vector or null vector on error")
 
 ADE_FUNC (getTurretMatrix, l_Subsystem, NULL,"Returns current subsystems turret matrix","matrix","Turret matrix.")
 
 ADE_FUNC (getParent, l_Subsystem, NULL,"The object parent of this subsystem, is of type ship","object","object handle or invalid handle on error")
 
 ADE_FUNC (isValid, l_Subsystem, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_VIRTVAR (Priority, l_Order,"number","Priority of the given order","number","Order priority or 0 if invalid")
 
 ADE_FUNC (remove, l_Order, NULL,"Removes the given order from the ship's priority queue.","boolean","True if order was successfully removed, otherwise false or nil.")
 
 ADE_FUNC (getType, l_Order, NULL,"Gets the type of the order.","enumeration","The type of the order as one of the ORDER_* enumerations.")
 
 ADE_VIRTVAR (Target, l_Order,"object","Target of the order. Value may also be a deriviative of the 'object' class, such as 'ship'.","object","Target object or invalid object handle if order handle is invalid or order requires no target.")
 
 ADE_VIRTVAR (TargetSubsystem, l_Order,"subsystem","Target subsystem of the order.","subsystem","Target subsystem, or invalid subsystem handle if order handle is invalid or order requires no subsystem target.")
 
 ADE_FUNC (isValid, l_Order, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (__len, l_ShipOrders, NULL,"Number of ship orders","number","Number of ship orders, or 0 if handle is invalid")
 
 ADE_INDEXER (l_ShipOrders,"number Index","Array of ship orders","order","Order, or invalid order handle on failure")
 
 ADE_FUNC (isValid, l_ShipOrders, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (__len, l_ShipTextures, NULL,"Number of textures on ship","number","Number of textures on ship, or 0 if handle is invalid")
 
 ADE_INDEXER (l_ShipTextures,"number Index/string TextureFilename","Array of ship textures","texture","Texture, or invalid texture handle on failure")
 
 ADE_FUNC (isValid, l_ShipTextures, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (__len, l_CockpitDisplays, NULL,"Gets the number of cockpit displays for the player ship","number","number of displays or -1 on error")
 
 ADE_INDEXER (l_CockpitDisplays,"number/string","Gets a cockpit display from the present player displays by either the index or the name of the display","display","Display handle or invalid handle on error")
 
 ADE_FUNC (isValid, l_CockpitDisplays, NULL,"Detects whether this handle is valid or not","boolean","true if valid, false otherwise")
 
 ADE_VIRTVAR (DefaultVolume, l_SoundEntry,"number","The default volume of this game sound","number","Volume in the range from 1 to 0 or -1 on error")
 
 ADE_FUNC (getFilename, l_SoundEntry, NULL,"Returns the filename of this sound","string","filename or empty string on error")
 
 ADE_FUNC (getDuration, l_SoundEntry, NULL,"Gives the length of the sound in seconds.","number","the length, or -1 on error")
 
 ADE_FUNC (get3DValues, l_SoundEntry,"vector Postion[, number radius=0.0]","Computes the volume and the panning of the sound when it would be played from the specified position.<br>""If range is given then the volume will diminish when the listener is withing that distance to the source.<br>""The position of the listener is always the the current viewing position.","number, number","The volume and the panning, in that sequence, or both -1 on error")
 
 ADE_FUNC (isValid, l_SoundEntry, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_VIRTVAR (Pitch, l_Sound,"number","Pitch of sound, from 100 to 100000","number","Pitch, or 0 if handle is invalid")
 
 ADE_FUNC (getRemainingTime, l_Sound, NULL,"The remaining time of this sound handle","number","Remaining time, or -1 on error")
 
 ADE_FUNC (setVolume, l_Sound,"number","Sets the volume of this sound instance","boolean","true if succeeded, false otherwise")
 
 ADE_FUNC (setPanning, l_Sound,"number","Sets the panning of this sound. Argument ranges from -1 for left to 1 for right","boolean","true if succeeded, false otherwise")
 
 ADE_FUNC (setPosition, l_Sound,"number[,boolean = true]","Sets the absolute position of the sound. If boolean argument is true then the value is given as a percentage<br>""This operation fails if there is no backing soundentry!","boolean","true if successfull, false otherwise")
 
 ADE_FUNC (rewind, l_Sound,"number","Rewinds the sound by the given number of seconds<br>""This operation fails if there is no backing soundentry!","boolean","true if succeeded, false otherwise")
 
 ADE_FUNC (skip, l_Sound,"number","Skips the given number of seconds of the sound<br>""This operation fails if there is no backing soundentry!","boolean","true if succeeded, false otherwise")
 
 ADE_FUNC (isPlaying, l_Sound, NULL,"Specifies if this handle is currently playing","boolean","true if playing, false if otherwise")
 
 ADE_FUNC (stop, l_Sound, NULL,"Stops the sound of this handle","boolean","true if succeeded, false otherwise")
 
 ADE_FUNC (isValid, l_Sound, NULL,"Detects whether the whole handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (isSoundValid, l_Sound, NULL,"Checks if only the sound is valid, should be used for non soundentry sounds","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (updatePosition, l_Sound3D,"vector Position[, number radius = 0.0]","Updates the given 3D sound with the specified position and an optional range value","boolean","true if succeesed, false otherwise")
 
 ADE_VIRTVAR (Duration, l_Soundfile,"number","The duration of the sound file, in seconds","number","The duration or -1 on error")
 
 ADE_VIRTVAR (Filename, l_Soundfile,"string","The filename of the file","string","The file name or empty string on error")
 
 ADE_FUNC (play, l_Soundfile,"[number volume = 1.0[, number panning = 0.0]]","Plays the sound","sound","A sound handle or invalid handle on error")
 
 ADE_FUNC (isValid, l_Soundfile, NULL,"Checks if the soundfile handle is valid","boolean","true if valid, false otherwise")
 
 ADE_VIRTVAR (Name, l_Persona,"string","The name of the persona","string","The name or empty string on error")
 
 ADE_FUNC (isValid, l_Persona, NULL,"Detect if the handle is valid","boolean","true if valid, false otherwise")
 
 ADE_VIRTVAR (Name, l_Message,"string","The name of the message as specified in the mission file","string","The name or an empty string if handle is invalid")
 
 ADE_VIRTVAR (Message, l_Message,"string","The unaltered text of the message, see getMessage() for options to replace variables<br>""<b>NOTE:</b> Changing the text will also change the text for messages not yet played but already in the message queue!","string","The message or an empty string if handle is invalid")
 
int add_wave (const char *wave_name)
 
 ADE_VIRTVAR (VoiceFile, l_Message,"soundfile","The voice file of the message","soundfile","The voice file handle or invalid handle when not present")
 
 ADE_VIRTVAR (Persona, l_Message,"persona","The persona of the message","persona","The persona handle or invalid handle if not present")
 
 ADE_FUNC (getMessage, l_Message,"[boolean replaceVars = true]","Gets the text of the message and optionally replaces SEXP variables with their respective values.","string","The message or an empty string if handle is invalid")
 
 ADE_FUNC (isValid, l_Message, NULL,"Checks if the message handle is valid","boolean","true if valid, false otherwise")
 
 ADE_INDEXER (l_Wing,"number Index","Array of ships in the wing","ship","Ship handle, or invalid ship handle if index is invalid or wing handle is invalid")
 
 ADE_FUNC (__len, l_Wing, NULL,"Gets the number of ships in the wing","number","Number of ships in wing, or 0 if invalid handle")
 
 ADE_VIRTVAR (Name, l_Wing,"string","Name of Wing","string","Wing name, or empty string if handle is invalid")
 
 ADE_FUNC (isValid, l_Wing, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_INDEXER (l_Ship,"string Name/number Index","Array of ship subsystems","subsystem","Subsystem handle, or invalid subsystem handle if index or ship handle is invalid")
 
 ADE_FUNC (__len, l_Ship, NULL,"Number of subsystems on ship","number","Subsystem number, or 0 if handle is invalid")
 
 ADE_VIRTVAR (ShieldArmorClass, l_Ship,"string","Current Armor class of the ships' shield","string","Armor class name, or empty string if none is set")
 
 ADE_VIRTVAR (ArmorClass, l_Ship,"string","Current Armor class","string","Armor class name, or empty string if none is set")
 
 ADE_VIRTVAR (Name, l_Ship,"string","Ship name","string","Ship name, or empty string if handle is invalid")
 
 ADE_VIRTVAR (AfterburnerFuelLeft, l_Ship,"number","Afterburner fuel left","number","Afterburner fuel left, or 0 if handle is invalid")
 
 ADE_VIRTVAR (AfterburnerFuelMax, l_Ship,"number","Afterburner fuel capacity","number","Afterburner fuel capacity, or 0 if handle is invalid")
 
 ADE_VIRTVAR (Class, l_Ship,"shipclass","Ship class","shipclass","Ship class, or invalid shipclass handle if ship handle is invalid")
 
 ADE_VIRTVAR (CountermeasuresLeft, l_Ship,"number","Number of countermeasures left","number","Countermeasures left, or 0 if ship handle is invalid")
 
 ADE_VIRTVAR (CockpitDisplays, l_Ship,"displays","An array of the cockpit displays on this ship.<br>NOTE: Only the ship of the player has these","displays","displays handle or invalid handle on error")
 
 ADE_VIRTVAR (CountermeasureClass, l_Ship,"weaponclass","Weapon class mounted on this ship's countermeasure point","weaponclass","Countermeasure hardpoint weapon class, or invalid weaponclass handle if no countermeasure class or ship handle is invalid")
 
 ADE_VIRTVAR (HitpointsMax, l_Ship,"number","Total hitpoints","number","Ship maximum hitpoints, or 0 if handle is invalid")
 
 ADE_VIRTVAR (WeaponEnergyLeft, l_Ship,"number","Current weapon energy reserves","number","Ship current weapon energy reserve level, or 0 if invalid")
 
 ADE_VIRTVAR (WeaponEnergyMax, l_Ship,"number","Maximum weapon energy","number","Ship maximum weapon energy reserve level, or 0 if invalid")
 
 if (!ade_get_args(L,"o|f", l_Ship.GetPtr(&objh),&fov)) return ade_set_error(L
 
 if (ADE_SETTING_VAR &&fov >=0.0f)
 
return ade_set_args (L,"f", shipp->autoaim_fov *180.0f/PI)
 
 ADE_VIRTVAR (PrimaryTriggerDown, l_Ship,"boolean","Determines if primary trigger is pressed or not","boolean","True if pressed, false if not, nil if ship handle is invalid")
 
 ADE_VIRTVAR (PrimaryBanks, l_Ship,"weaponbanktype","Array of primary weapon banks","weaponbanktype","Primary weapon banks, or invalid weaponbanktype handle if ship handle is invalid")
 
 ADE_VIRTVAR (SecondaryBanks, l_Ship,"weaponbanktype","Array of secondary weapon banks","weaponbanktype","Secondary weapon banks, or invalid weaponbanktype handle if ship handle is invalid")
 
 ADE_VIRTVAR (TertiaryBanks, l_Ship,"weaponbanktype","Array of tertiary weapon banks","weaponbanktype","Tertiary weapon banks, or invalid weaponbanktype handle if ship handle is invalid")
 
 ADE_VIRTVAR (Target, l_Ship,"object","Target of ship. Value may also be a deriviative of the 'object' class, such as 'ship'.","object","Target object, or invalid object handle if no target or ship handle is invalid")
 
 ADE_VIRTVAR (TargetSubsystem, l_Ship,"subsystem","Target subsystem of ship.","subsystem","Target subsystem, or invalid subsystem handle if no target or ship handle is invalid")
 
 ADE_VIRTVAR (Team, l_Ship,"team","Ship's team","team","Ship team, or invalid team handle if ship handle is invalid")
 
 ADE_VIRTVAR (Textures, l_Ship,"shiptextures","Gets ship textures","shiptextures","Ship textures, or invalid shiptextures handle if ship handle is invalid")
 
 ADE_VIRTVAR (FlagAffectedByGravity, l_Ship,"boolean","Checks for the \"affected-by-gravity\" flag","boolean","True if flag is set, false if flag is not set and nil on error")
 
void ship_reset_disabled_physics (object *objp, int ship_class)
 
 ADE_VIRTVAR (Disabled, l_Ship,"boolean","The disabled state of this ship","boolean","true if ship is diabled, false otherwise")
 
 ADE_VIRTVAR (Stealthed, l_Ship,"boolean","Stealth status of this ship","boolean","true if stealthed, false otherwise or on error")
 
 ADE_VIRTVAR (HiddenFromSensors, l_Ship,"boolean","Hidden from sensors status of this ship","boolean","true if invisible to hidden from sensors, false otherwise or on error")
 
 ADE_VIRTVAR (Gliding, l_Ship,"boolean","Specifies whether this ship is currently gliding or not.","boolean","true if gliding, false otherwise or in case of error")
 
 if (!ade_get_args(L,"o|i", l_Ship.GetPtr(&objh),&ets_idx)) return ade_set_error(L
 
return ade_set_args (L,"i", Ships[objh->objp->instance].engine_recharge_index)
 
 ADE_VIRTVAR (Orders, l_Ship,"shiporders","Array of ship orders","shiporders","Ship orders, or invalid handle if ship handle is invalid")
 
 ADE_FUNC (kill, l_Ship,"[object Killer]","Kills the ship. Set \"Killer\" to the ship you are killing to self-destruct","boolean","True if successful, false or nil otherwise")
 
 ADE_FUNC (addShipEffect, l_Ship,"string name, int duration (in milliseconds)","Activates an effect for this ship. Effect names are defined in Post_processing.tbl, and need to be implemented in the main shader. This functions analogous to the ship-effect sexp. NOTE: only one effect can be active at any time, adding new effects will override effects already in progress.\n","boolean","Returns true if the effect was successfully added, false otherwise")
 
 ADE_FUNC (hasShipExploded, l_Ship, NULL,"Checks if the ship explosion event has already happened","number","Returns 1 if first explosion timestamp is passed, 2 if second is passed, 0 otherwise")
 
 ADE_FUNC (fireCountermeasure, l_Ship, NULL,"Launches a countermeasure from the ship","boolean","Whether countermeasure was launched or not")
 
 if (!ade_get_args(L,"o", l_Ship.GetPtr(&objh))) return ade_set_error(L
 
return ade_set_args (L,"i", i)
 
return ade_set_args (L,"i", ship_fire_secondary(objh->objp, 0))
 
 if (!ade_get_args(L,"o|si", l_Ship.GetPtr(&objh),&s,&subtype)) return ade_set_error(L
 
return ade_set_args (L,"f", time_s)
 
 ADE_FUNC (clearOrders, l_Ship, NULL,"Clears a ship's orders list","boolean","True if successful, otherwise false or nil")
 
 ADE_FUNC (giveOrder, l_Ship,"enumeration Order, [object Target=nil, subsystem TargetSubsystem=nil, number Priority=1.0]","Uses the goal code to execute orders","boolean","True if order was given, otherwise false or nil")
 
 ADE_FUNC (doManeuver, l_Ship,"number Duration, number Heading, number Pitch, number Bank, boolean Force Rotation, number Vertical, number Horizontal, number Forward, boolean Force Movement","Sets ship maneuver over the defined time period","boolean","True if maneuver order was given, otherwise false or nil")
 
 ADE_FUNC (triggerAnimation, l_Ship,"string Type, [number Subtype, boolean Forwards]","Triggers an animation. Type is the string name of the animation type, ""Subtype is the subtype number, such as weapon bank #, and Forwards is boolean.""<br><strong>IMPORTANT: Function is in testing and should not be used with official mod releases</strong>","boolean","True if successful, false or nil otherwise")
 
 ADE_FUNC (warpIn, l_Ship, NULL,"Warps ship in","boolean","True if successful, or nil if ship handle is invalid")
 
 ADE_FUNC (warpOut, l_Ship, NULL,"Warps ship out","boolean","True if successful, or nil if ship handle is invalid")
 
 ADE_FUNC (canWarp, l_Ship, NULL,"Checks whether ship has a working subspace drive and is allowed to use it","boolean","True if successful, or nil if ship handle is invalid")
 
 ADE_FUNC (isWarpingIn, l_Ship, NULL,"Checks if ship is warping in","boolean","True if the ship is warping in, false or nil otherwise")
 
 ADE_FUNC (getEMP, l_Ship, NULL,"Returns the current emp effect strength acting on the object","number","Current EMP effect strength or NIL if object is invalid")
 
 ADE_FUNC (getTimeUntilExplosion, l_Ship, NULL,"Returns the time in seconds until the ship explodes","number","Time until explosion or -1, if invalid handle or ship isn't exploding")
 
 ADE_FUNC (getCallsign, l_Ship, NULL,"Gets the callsign of the ship in the current mission","string","The callsign or an empty string if the ship doesn't have a callsign or an error occurs")
 
 ADE_FUNC (getAltClassName, l_Ship, NULL,"Gets the alternate class name of the ship","string","The alternate class name or an empty string if the ship doesn't have such a thing or an error occurs")
 
 ADE_FUNC (getMaximumSpeed, l_Ship,"[number energy = 0.333]","Gets the maximum speed of the ship with the given energy on the engines","number","The maximum speed or -1 on error")
 
 ADE_FUNC (EtsSetIndexes, l_Ship,"number Engine Index, number Shield Index, number Weapon Index","Sets ships ETS systems to specified values","boolean","True if successful, false if target ships ETS was missing, or only has one system")
 
 ADE_FUNC (getWing, l_Ship, NULL,"Returns the ship's wing","wing","Wing handle, or invalid wing handle if ship is not part of a wing")
 
 ADE_VIRTVAR (Class, l_Weapon,"weaponclass","Weapon's class","weaponclass","Weapon class, or invalid weaponclass handle if weapon handle is invalid")
 
 ADE_VIRTVAR (DestroyedByWeapon, l_Weapon,"boolean","Whether weapon was destroyed by another weapon","boolean","True if weapon was destroyed by another weapon, false if weapon was destroyed by another object or if weapon handle is invalid")
 
 ADE_VIRTVAR (LifeLeft, l_Weapon,"number","Weapon life left (in seconds)","number","Life left (seconds) or 0 if weapon handle is invalid")
 
 ADE_VIRTVAR (FlakDetonationRange, l_Weapon,"number","Range at which flak will detonate (meters)","number","Detonation range (meters) or 0 if weapon handle is invalid")
 
 ADE_VIRTVAR (Target, l_Weapon,"object","Target of weapon. Value may also be a deriviative of the 'object' class, such as 'ship'.","object","Weapon target, or invalid object handle if weapon handle is invalid")
 
 ADE_VIRTVAR (ParentTurret, l_Weapon,"subsystem","Turret which fired this weapon.","subsystem","Turret subsystem handle, or an invalid handle if the weapon not fired from a turret")
 
 ADE_VIRTVAR (HomingObject, l_Weapon,"object","Object that weapon will home in on. Value may also be a deriviative of the 'object' class, such as 'ship'","object","Object that weapon is homing in on, or an invalid object handle if weapon is not homing or the weapon handle is invalid")
 
 ADE_VIRTVAR (HomingPosition, l_Weapon,"vector","Position that weapon will home in on (World vector), setting this without a homing object in place will not have any effect!","vector","Homing point, or null vector if weapon handle is invalid")
 
 ADE_VIRTVAR (HomingSubsystem, l_Weapon,"subsystem","Subsystem that weapon will home in on.","subsystem","Homing subsystem, or invalid subsystem handle if weapon is not homing or weapon handle is invalid")
 
 ADE_VIRTVAR (Team, l_Weapon,"team","Weapon's team","team","Weapon team, or invalid team handle if weapon handle is invalid")
 
 ADE_FUNC (isArmed, l_Weapon,"[boolean Hit target]","Checks if the weapon is armed.","boolean","boolean value of the weapon arming status")
 
 ADE_FUNC (getCollisionInformation, l_Weapon, NULL,"Returns the collision information for this weapon","collision info","The collision information or invalid handle if none")
 
 ADE_VIRTVAR (Class, l_Beam,"weaponclass","Weapon's class","weaponclass","Weapon class, or invalid weaponclass handle if beam handle is invalid")
 
 ADE_VIRTVAR (LastShot, l_Beam,"vector","End point of the beam","vector","vector or null vector if beam handle is not valid")
 
 ADE_VIRTVAR (LastStart, l_Beam,"vector","Start point of the beam","vector","vector or null vector if beam handle is not valid")
 
 ADE_VIRTVAR (Target, l_Beam,"object","Target of beam. Value may also be a deriviative of the 'object' class, such as 'ship'.","object","Beam target, or invalid object handle if beam handle is invalid")
 
 ADE_VIRTVAR (TargetSubsystem, l_Beam,"subsystem","Subsystem that beam is targeting.","subsystem","Target subsystem, or invalid subsystem handle if beam handle is invalid")
 
 ADE_VIRTVAR (ParentShip, l_Beam,"object","Parent of the beam.","object","Beam parent, or invalid object handle if beam handle is invalid")
 
 ADE_VIRTVAR (ParentSubsystem, l_Beam,"subsystem","Subsystem that beam is fired from.","subsystem","Parent subsystem, or invalid subsystem handle if beam handle is invalid")
 
 ADE_FUNC (getCollisionCount, l_Beam, NULL,"Get the number of collisions in frame.","number","Number of beam collisions")
 
 ADE_FUNC (getCollisionPosition, l_Beam,"number","Get the position of the defined collision.","vector","World vector")
 
 ADE_FUNC (getCollisionInformation, l_Beam,"number","Get the collision information of the specified collision","collision info","handle to information or invalid handle on error")
 
 ADE_FUNC (getCollisionObject, l_Beam,"number","Get the target of the defined collision.","object","Object the beam collided with")
 
 ADE_FUNC (isExitCollision, l_Beam,"number","Checks if the defined collision was exit collision.","boolean","True if the collision was exit collision, false if entry, nil otherwise")
 
 ADE_FUNC (getStartDirectionInfo, l_Beam, NULL,"Gets the start information about the direction. The vector is a normalized vector from LastStart showing the start direction of a slashing beam","vector","The start direction or null vector if invalid")
 
 ADE_FUNC (getEndDirectionInfo, l_Beam, NULL,"Gets the end information about the direction. The vector is a normalized vector from LastStart showing the end direction of a slashing beam","vector","The start direction or null vector if invalid")
 
 ADE_FUNC (isValid, l_Player, NULL,"Detects whether handle is valid","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_FUNC (getName, l_Player, NULL,"Gets current player name","string","Player name, or empty string if handle is invalid")
 
 ADE_FUNC (getCampaignFilename, l_Player, NULL,"Gets current player campaign filename","string","Campaign name, or empty string if handle is invalid")
 
 ADE_FUNC (getImageFilename, l_Player, NULL,"Gets current player image filename","string","Player image filename, or empty string if handle is invalid")
 
 ADE_FUNC (getMainHallName, l_Player, NULL,"Gets player's current main hall name","string","Main hall name, or name of first mainhall in campaign if something goes wrong")
 
 ADE_FUNC (getMainHallIndex, l_Player, NULL,"Gets player's current main hall number","number","Main hall index, or index of first mainhall in campaign if something goes wrong")
 
 ADE_FUNC (getSquadronName, l_Player, NULL,"Gets current player squad name","string","Squadron name, or empty string if handle is invalid")
 
 ADE_FUNC (getMultiSquadronName, l_Player, NULL,"Gets current player multi squad name","string","Squadron name, or empty string if handle is invalid")
 
 ADE_FUNC (__tostring, l_Camera, NULL,"Camera name","string","Camera name, or an empty string if handle is invalid")
 
 ADE_FUNC (isValid, l_Camera, NULL,"True if valid, false or nil if not","boolean","true if valid, false if handle is invalid, nil if a syntax/type error occurs")
 
 ADE_VIRTVAR (Name, l_Camera,"string","New camera name","string","Camera name")
 
 ADE_VIRTVAR (FOV, l_Camera,"number","New camera FOV (in radians)","number","Camera FOV (in radians)")
 
 ADE_VIRTVAR (Orientation, l_Camera,"orientation","New camera orientation","orientation","Camera orientation")
 
 ADE_VIRTVAR (Position, l_Camera,"vector","New camera position","vector","Camera position")
 
 ADE_VIRTVAR (Self, l_Camera,"object","New mount object","object","Camera object")
 
 ADE_VIRTVAR (SelfSubsystem, l_Camera,"subsystem","New mount object subsystem","subsystem","Subsystem that the camera is mounted on")
 
 ADE_VIRTVAR (Target, l_Camera,"object","New target object","object","Camera target object")
 
 ADE_VIRTVAR (TargetSubsystem, l_Camera,"subsystem","New target subsystem","subsystem","Subsystem that the camera is pointed at")
 
 ADE_FUNC (setFOV, l_Camera,"[number FOV, number Zoom Time, number Zoom Acceleration Time, number Zoom deceleration Time]","Sets camera FOV""<br>FOV is the final field of view, in radians, of the camera.""<br>Zoom Time is the total time to take zooming in or out.""<br>Acceleration Time is the total time it should take the camera to get up to full zoom speed.""<br>Deceleration Time is the total time it should take the camera to slow down from full zoom speed.","boolean","true if successful, false or nil otherwise")
 
 ADE_FUNC (setOrientation, l_Camera,"[world orientation Orientation, number Rotation Time, number Acceleration Time, number Deceleration time]","Sets camera orientation and velocity data.""<br>Orientation is the final orientation for the camera, after it has finished moving. If not specified, the camera will simply stop at its current orientation.""<br>Rotation time (seconds) is how long total, including acceleration, the camera should take to rotate. If it is not specified, the camera will jump to the specified orientation.""<br>Acceleration time (seconds) is how long it should take the camera to get 'up to speed'. If not specified, the camera will instantly start moving.""<br>Deceleration time (seconds) is how long it should take the camera to slow down. If not specified, the camera will instantly stop moving.","boolean","true if successful, false or nil otherwise")
 
 ADE_FUNC (setPosition, l_Camera,"[wvector Position, number Translation Time, number Acceleration Time, number Deceleration Time]","Sets camera position and velocity data.""<br>Position is the final position for the camera. If not specified, the camera will simply stop at its current position.""<br>Translation time (seconds) is how long total, including acceleration, the camera should take to move. If it is not specified, the camera will jump to the specified position.""<br>Acceleration time (seconds) is how long it should take the camera to get 'up to speed'. If not specified, the camera will instantly start moving.""<br>Deceleration time (seconds) is how long it should take the camera to slow down. If not specified, the camera will instantly stop moving.","boolean","true if successful, false or nil otherwise")
 
 ADE_VIRTVAR (Pitch, l_Control_Info,"number","Pitch of the player ship","number","Pitch")
 
 ADE_VIRTVAR (Heading, l_Control_Info,"number","Heading of the player ship","number","Heading")
 
 ADE_VIRTVAR (Bank, l_Control_Info,"number","Bank of the player ship","number","Bank")
 
 ADE_VIRTVAR (Vertical, l_Control_Info,"number","Vertical control of the player ship","number","Vertical control")
 
 ADE_VIRTVAR (Sideways, l_Control_Info,"number","Sideways control of the player ship","number","Sideways control")
 
 ADE_VIRTVAR (Forward, l_Control_Info,"number","Forward control of the player ship","number","Forward")
 
 ADE_VIRTVAR (ForwardCruise, l_Control_Info,"number","Forward control of the player ship","number","Forward")
 
 ADE_VIRTVAR (PrimaryCount, l_Control_Info,"number","Number of primary weapons that will fire","number","Number of weapons to fire, or 0 if handle is invalid")
 
 ADE_VIRTVAR (SecondaryCount, l_Control_Info,"number","Number of secondary weapons that will fire","number","Number of weapons to fire, or 0 if handle is invalid")
 
 ADE_VIRTVAR (CountermeasureCount, l_Control_Info,"number","Number of countermeasures that will launch","number","Number of countermeasures to launch, or 0 if handle is invalid")
 
 ADE_FUNC (clearLuaButtonInfo, l_Control_Info, NULL,"Clears the lua button control info", NULL, NULL)
 
 ADE_FUNC (getButtonInfo, l_Control_Info, NULL,"Access the four bitfields containing the button info","number, number, number,number","Four bitfields")
 
 ADE_FUNC (accessButtonInfo, l_Control_Info,"number, number, number, number","Access the four bitfields containing the button info","number, number, number,number","Four bitfields")
 
 ADE_FUNC (useButtonControl, l_Control_Info,"number, string","Adds the defined button control to lua button control data, if number is -1 it tries to use the string", NULL, NULL)
 
 ADE_FUNC (getButtonControlName, l_Control_Info,"number","Gives the name of the command corresponding with the given number","string","Name of the command")
 
 ADE_FUNC (getButtonControlNumber, l_Control_Info,"string","Gives the number of the command corresponding with the given string","number","Number of the command")
 
 ADE_VIRTVAR (AllButtonPolling, l_Control_Info,"boolean","Toggles the all button polling for lua","boolean","If the all button polling is enabled or not")
 
 ADE_FUNC (pollAllButtons, l_Control_Info, NULL,"Access the four bitfields containing the button info","number, number, number,number","Four bitfields")
 
 if (!ade_get_args(L,"o|o", l_Particle.GetPtr(&ph), l_Vector.Get(&newVec))) return ade_set_error(L
 
 if (ph==NULL) return ade_set_error(L
 
 if (!ph->isValid()) return ade_set_error(L
 
return ade_set_args (L,"o", l_Vector.Set(ph->Get() ->pos))
 
return ade_set_args (L,"o", l_Vector.Set(ph->Get() ->velocity))
 
 ADE_VIRTVAR (Age, l_Particle,"number","The time this particle already lives","number","The current age or -1 on error")
 
 ADE_VIRTVAR (MaximumLife, l_Particle,"number","The time this particle can live","number","The maximal life or -1 on error")
 
 ADE_VIRTVAR (Radius, l_Particle,"number","The radius of the particle","number","The radius or -1 on error")
 
 ADE_VIRTVAR (TracerLength, l_Particle,"number","The tracer legth of the particle","number","The radius or -1 on error")
 
 ADE_VIRTVAR (AttachedObject, l_Particle,"object","The object this particle is attached to. If valid the position will be relativ to this object and the velocity will be ignored.","object","Attached object or invalid object handle on error")
 
 ADE_FUNC (isValid, l_Particle, NULL,"Detects whether this handle is valid","boolean","true if valid false if not")
 
 ADE_FUNC (getSoundentry, l_Audio,"string/number","Return a sound entry matching the specified index or name. If you are using a number then the first valid index is 1","soundentry","soundentry or invalid handle on error")
 
 ADE_FUNC (loadSoundfile, l_Audio,"string filename","Loads the specified sound file","soundfile","A soundfile handle")
 
 ADE_FUNC (playSound, l_Audio,"soundentry","Plays the specified sound entry handle","sound","A handle to the playing sound")
 
 ADE_FUNC (playLoopingSound, l_Audio,"soundentry","Plays the specified sound as a looping sound","sound","A handle to the playing sound or invalid handle if playback failed")
 
 ADE_FUNC (play3DSound, l_Audio,"soundentry[, vector source[, vector listener]]","Plays the specified sound entry handle. Source if by default 0, 0, 0 and listener is by default the current viewposition","3Dsound","A handle to the playing sound")
 
 ADE_FUNC (playGameSound, l_Audio,"Sound index, [Panning (-1.0 left to 1.0 right), Volume %, Priority 0-3, Voice Message?]","Plays a sound from #Game Sounds in sounds.tbl. A priority of 0 indicates that the song must play; 1-3 will specify the maximum number of that sound that can be played","boolean","True if sound was played, false if not (Replaced with a sound instance object in the future)")
 
 ADE_FUNC (playInterfaceSound, l_Audio,"Sound index","Plays a sound from #Interface Sounds in sounds.tbl","boolean","True if sound was played, false if not")
 
 ADE_FUNC (playMusic, l_Audio,"string Filename, [float volume = 1.0, bool looping = true]","Plays a music file using FS2Open's builtin music system. Volume is currently ignored, uses players music volume setting. Files passed to this function are looped by default.","number","Audiohandle of the created audiostream, or -1 on failure")
 
 ADE_FUNC (stopMusic, l_Audio,"int audiohandle, [bool fade = false], [string 'briefing|credits|mainhall']","Stops a playing music file, provided audiohandle is valid. If the 3rd arg is set to one of briefing,credits,mainhall then that music will be stopped despite the audiohandle given.", NULL, NULL)
 
 ADE_FUNC (pauseMusic, l_Audio,"int audiohandle, bool pause","Pauses or unpauses a playing music file, provided audiohandle is valid. The boolean argument should be true to pause and false to unpause. If the audiohandle is -1, *all* audio streams are paused or unpaused.", NULL, NULL)
 
 ADE_FUNC (print, l_Base,"string Message","Prints a string", NULL, NULL)
 
 ADE_FUNC (error, l_Base,"string Message","Displays a FreeSpace error message with the string provided", NULL, NULL)
 
 ADE_FUNC (createOrientation, l_Base,"[p/r1c1, b/r1c2, h/r1c3, r2c1, r2c2, r2c3, r3c1, r3c2, r3c3]","Given 0, 3, or 9 arguments, creates an orientation object with that orientation.","orientation","New orientation object, or null orientation on failure")
 
 ADE_FUNC (createVector, l_Base,"[x, y, z]","Creates a vector object","vector","Vector object")
 
 ADE_FUNC (getFrametime, l_Base,"[Do not adjust for time compression (Boolean)]","Gets how long this frame is calculated to take. Use it to for animations, physics, etc to make incremental changes.","number","Frame time (seconds)")
 
 ade_get_args (L,"|i",&depth)
 
 if (depth > gameseq_get_depth()) return ade_set_args(L
 
l_GameState Set (gamestate_h()))
 
return ade_set_args (L,"o", l_GameState.Set(gamestate_h(gameseq_get_state(depth))))
 
 ADE_FUNC (getCurrentMPStatus, l_Base,"NIL","Gets this computers current MP status","string","Current MP status")
 
 ADE_FUNC (getCurrentPlayer, l_Base, NULL,"Gets a handle of the currently used player.<br><b>Note:</b> If there is no current player then the first player will be returned, check the game state to make sure you have a valid player handle.","player","Player handle")
 
 ADE_FUNC (setControlMode, l_Base,"NIL or enumeration LE_*_CONTROL","Sets the current control mode for the game.","string","Current control mode")
 
 ADE_FUNC (setButtonControlMode, l_Base,"NIL or enumeration LE_*_BUTTON_CONTROL","Sets the current control mode for the game.","string","Current control mode")
 
 ADE_FUNC (getControlInfo, l_Base, NULL,"Gets the control info handle.","control info","control info handle")
 
 ADE_FUNC (setTips, l_Base,"True or false","Sets whether to display tips of the day the next time the current pilot enters the mainhall.", NULL, NULL)
 
 ADE_FUNC (getGameDifficulty, l_Base, NULL,"Returns the difficulty level from 1-5, 1 being the lowest, (Very Easy) and 5 being the highest (Insane)","integer","Difficulty level as integer")
 
 ADE_FUNC (postGameEvent, l_Base,"gameevent Event","Sets current game event. Note that you can crash FreeSpace 2 by posting an event at an improper time, so test extensively if you use it.","boolean","True if event was posted, false if passed event was invalid")
 
 ADE_INDEXER (l_Base_Events,"number Index/string Name","Array of game events","gameevent","Game event, or invalid gameevent handle if index is invalid")
 
 ADE_FUNC (__len, l_Base_Events, NULL,"Number of events","number","Number of events")
 
 ADE_INDEXER (l_Base_States,"number Index/string Name","Array of game states","gamestate","Game state, or invalid gamestate handle if index is invalid")
 
 ADE_FUNC (__len, l_Base_States, NULL,"Number of states","number","Number of states")
 
int l_cf_get_path_id (char *n_path)
 
 ADE_FUNC (deleteFile, l_CFile,"string Filename, string Path","Deletes given file. Path must be specified. Use a slash for the root directory.","boolean","True if deleted, false")
 
 ADE_FUNC (fileExists, l_CFile,"string Filename, [string Path = \"\", boolean CheckVPs = false]","Checks if a file exists. Use a blank string for path for any directory, or a slash for the root directory.","boolean","True if file exists, false or nil otherwise")
 
 ADE_FUNC (openFile, l_CFile,"string Filename, [string Mode=\"r\", string Path = \"\"]","Opens a file. 'Mode' uses standard C fopen arguments. Use a blank string for path for any directory, or a slash for the root directory.""Be EXTREMELY CAREFUL when using this function, as you may PERMANENTLY delete any file by accident","file","File handle, or invalid file handle if the specified file couldn't be opened")
 
 ADE_FUNC (openTempFile, l_CFile, NULL,"Opens a temp file that is automatically deleted when closed","file","File handle, or invalid file handle if tempfile couldn't be created")
 
 ADE_FUNC (renameFile, l_CFile,"string CurrentFilename, string NewFilename, string Path","Renames given file. Path must be specified. Use a slash for the root directory.","boolean","True if file was renamed, otherwise false")
 
 ADE_FUNC (getMouseX, l_Mouse, NULL,"Gets Mouse X pos","number","Mouse x position, or 0 if mouse is not initialized yet")
 
 ADE_FUNC (getMouseY, l_Mouse, NULL,"Gets Mouse Y pos","number","Mouse y position, or 0 if mouse is not initialized yet")
 
 ADE_FUNC (isMouseButtonDown, l_Mouse,"{MOUSE_*_BUTTON enumeration}, [..., ...]","Returns whether the specified mouse buttons are up or down","boolean","Whether specified mouse buttons are down, or false if mouse is not initialized yet")
 
 if (!ade_get_args(L,"s|o",&s, l_Enum.GetPtr(&u))) return ADE_RETURN_NIL
 
 if (u!=NULL)
 
 gr_set_cursor_bitmap (bm_load(s), ul)
 
 ADE_FUNC (setCursorHidden, l_Mouse,"True to hide mouse, false to show it","Shows or hides mouse cursor", NULL, NULL)
 
 if (!(ade_get_args(L,"ii",&x,&y))) return ADE_RETURN_FALSE
 
 if (!((x >=0)&&(x<=gr_screen.max_w))) return ADE_RETURN_FALSE
 
 if (!((y >=0)&&(y<=gr_screen.max_h))) return ADE_RETURN_FALSE
 
 mouse_set_pos (x, y)
 
 ADE_VIRTVAR (MouseControlStatus, l_Mouse,"boolean","Gets and sets the retail mouse control status","boolean","if the retail mouse is on or off")
 
 ADE_FUNC (getMouseSensitivity, l_Mouse, NULL,"Gets mouse sensitivity setting","number","Mouse sensitivity in range of 0-9")
 
 ADE_FUNC (getJoySensitivity, l_Mouse, NULL,"Gets joystick sensitivity setting","number","Joystick sensitivity in range of 0-9")
 
 ADE_FUNC (getJoyDeadzone, l_Mouse, NULL,"Gets joystick deadzone setting","number","Joystick deadzone in range of 0-9")
 
 ADE_FUNC (updateTrackIR, l_Mouse, NULL,"Updates Tracking Data. Call before using get functions","boolean","Checks if trackir is available and updates variables, returns true if successful, otherwise false")
 
 ADE_FUNC (getTrackIRPitch, l_Mouse, NULL,"Gets pitch axis from last update","number","Pitch value -1 to 1, or 0 on failure")
 
 ADE_FUNC (getTrackIRYaw, l_Mouse, NULL,"Gets yaw axis from last update","number","Yaw value -1 to 1, or 0 on failure")
 
 ADE_FUNC (getTrackIRRoll, l_Mouse, NULL,"Gets roll axis from last update","number","Roll value -1 to 1, or 0 on failure")
 
 ADE_FUNC (getTrackIRX, l_Mouse, NULL,"Gets x position from last update","number","X value -1 to 1, or 0 on failure")
 
 ADE_FUNC (getTrackIRY, l_Mouse, NULL,"Gets y position from last update","number","Y value -1 to 1, or 0 on failure")
 
 ADE_FUNC (getTrackIRZ, l_Mouse, NULL,"Gets z position from last update","number","Z value -1 to 1, or 0 on failure")
 
 ADE_VIRTVAR (HUDDrawn, l_HUD,"boolean","Current HUD draw status","boolean","If the HUD is drawn or not")
 
 ADE_VIRTVAR (HUDDisabledExceptMessages, l_HUD,"boolean","Specifies if only the messages gauges of the hud are drawn","boolean","true if only the message gauges are drawn, false otherwise")
 
 if (!ade_get_args(L,"i|iiii",&idx,&r,&g,&b,&a)) return ADE_RETURN_FALSE
 
 if ((idx< 0)||(idx >=NUM_HUD_GAUGES)) return ADE_RETURN_FALSE
 
 if (!ade_get_args(L,"i",&idx)) return ADE_RETURN_NIL
 
return ade_set_args (L,"iiii",(int) c.red,(int) c.green,(int) c.blue,(int) c.alpha)
 
 ADE_FUNC (getHUDGaugeHandle, l_HUD,"string Name","Returns a handle to a specified HUD gauge","HudGauge","HUD Gauge handle, or nil if invalid")
 
 ADE_INDEXER (l_Graphics_Cameras,"number Index/string Name","Gets camera","camera","Ship handle, or invalid ship handle if index was invalid")
 
 ADE_FUNC (__len, l_Graphics_Cameras, NULL,"Gets number of cameras","number","Number of cameras")
 
 ADE_FUNC (__len, l_Graphics_Fonts, NULL,"Number of loaded fonts","number","Number of loaded fonts")
 
 ADE_INDEXER (l_Graphics_Fonts,"number Index/string Filename","Array of loaded fonts","font","Font handle, or invalid font handle if index is invalid")
 
 ADE_VIRTVAR (CurrentFont, l_Graphics,"font","Current font","font", NULL)
 
 ADE_INDEXER (l_Graphics_Posteffects,"number index","Gets the name of the specified post processing index","string","post processing name or empty string on error")
 
 ADE_FUNC (__len, l_Graphics_Posteffects, NULL,"Gets the number or available post processing effects","number","number of post processing effects or 0 on error")
 
 ADE_FUNC (setPostEffect, l_Graphics,"string name, [number value=0]","Sets the intensity of the specified post processing effect","boolean","true when successful, false otherwise")
 
 ADE_FUNC (resetPostEffects, l_Graphics, NULL,"Resets all post effects to their default values","boolean","true if successful, false otherwise")
 
 ADE_VIRTVAR (CurrentOpacityType, l_Graphics,"enumeration","Current alpha blending type; uses ALPHABLEND_* enumerations","enumeration", NULL)
 
 ADE_VIRTVAR (CurrentRenderTarget, l_Graphics,"texture","Current rendering target","texture","Current rendering target, or invalid texture handle if screen is render target")
 
 ADE_FUNC (clearScreen, l_Graphics,"[integer red, number green, number blue, number alpha]","Clears the screen to black, or the color specified.", NULL, NULL)
 
 ADE_FUNC (createCamera, l_Graphics,"string Name, [wvector Position, orientation Orientation]","Creates a new camera using the specified position and orientation (World)","camera","Camera handle, or invalid camera handle if camera couldn't be created")
 
 ADE_FUNC (isMenuStretched, l_Graphics, NULL,"Returns whether the standard interface is stretched","boolean","True if stretched, false if aspect ratio is maintained")
 
 ADE_FUNC (getScreenWidth, l_Graphics, NULL,"Gets screen width","number","Width in pixels, or 0 if graphics are not initialized yet")
 
 ADE_FUNC (getScreenHeight, l_Graphics, NULL,"Gets screen height","number","Height in pixels, or 0 if graphics are not initialized yet")
 
return ade_set_args (L,"i", gr_screen.center_w)
 
 ADE_FUNC (getCenterOffsetX, l_Graphics, NULL,"Gets X offset of center monitor","number","X offset of center monitor in pixels")
 
 ADE_FUNC (getCenterOffsetY, l_Graphics, NULL,"Gets Y offset of center monitor","number","Y offset of center monitor in pixels")
 
 ADE_FUNC (getCurrentCamera, l_Graphics,"[boolean]","Gets the current camera handle, if argument is <i>true</i> then it will also return the main camera when no custom camera is in use","camera","camera handle or invalid handle on error")
 
 ADE_FUNC (getVectorFromCoords, l_Graphics,"[number X=center, number Y=center, number Depth, boolean normalize = false]","Returns a vector through screen coordinates x and y. ""If depth is specified, vector is extended to Depth units into space""If normalize is true, vector will be normalized.","vector","Vector, or zero vector on failure")
 
 ADE_FUNC (setTarget, l_Graphics,"[texture Texture]","If texture is specified, sets current rendering surface to a texture.""Otherwise, sets rendering surface back to screen.","boolean","True if successful, false otherwise")
 
 ADE_FUNC (setCamera, l_Graphics,"[camera handle Camera]","Sets current camera, or resets camera if none specified","boolean","true if successful, false or nil otherwise")
 
 ADE_FUNC (setColor, l_Graphics,"integer Red, number Green, number Blue, [integer Alpha]","Sets 2D drawing color; each color number should be from 0 (darkest) to 255 (brightest)", NULL, NULL)
 
 ADE_FUNC (setLineWidth, l_Graphics,"[number width=1.0]","Sets the line width for lines. This call might fail if the specified width is not supported by the graphics implementation. Then the width will be the nearest supported value.","boolean","true if succeeded, false otherwise")
 
 ADE_FUNC (drawCircle, l_Graphics,"number Radius, number X, number Y, [boolean Filled=true]","Draws a circle", NULL, NULL)
 
 ADE_FUNC (drawArc, l_Graphics,"number Radius, number X, number Y, number StartAngle, number EndAngle, [boolean Filled=true]","Draws an arc", NULL, NULL)
 
 ADE_FUNC (drawCurve, l_Graphics,"number X, number Y, number Radius","Draws a curve", NULL, NULL)
 
 ADE_FUNC (drawGradientLine, l_Graphics,"number X1, number Y1, number X2, number Y2","Draws a line from (x1,y1) to (x2,y2) with the CurrentColor that steadily fades out", NULL, NULL)
 
 ADE_FUNC (drawLine, l_Graphics,"number X1, number Y1, number X2, number Y2","Draws a line from (x1,y1) to (x2,y2) with CurrentColor", NULL, NULL)
 
 ADE_FUNC (drawPixel, l_Graphics,"number X, number Y","Sets pixel to CurrentColor", NULL, NULL)
 
 ADE_FUNC (drawPolygon, l_Graphics,"texture Texture, [vector Position={0,0,0}, orientation Orientation=nil, number Width=1.0, number Height=1.0]","Draws a polygon. May not work properly in hooks other than On Object Render.", NULL, NULL)
 
 ADE_FUNC (drawRectangle, l_Graphics,"number X1, number Y1, number X2, number Y2, [boolean Filled=true]","Draws a rectangle with CurrentColor", NULL, NULL)
 
 ADE_FUNC (drawSphere, l_Graphics,"[number Radius = 1.0, vector Position]","Draws a sphere with radius Radius at world vector Position. May not work properly in hooks other than On Object Render.","boolean","True if successful, false or nil otherwise")
 
 ADE_FUNC (drawModel, l_Graphics,"model, position, orientation","Draws the given model with the specified position and orientation - Use with extreme care, may not work properly in all scripting hooks.","int","Zero if successful, otherwise an integer error code")
 
 ADE_FUNC (drawModelOOR, l_Graphics,"model Model, vector Position, matrix Orientation, [integer Flags]","Draws the given model with the specified position and orientation - Use with extreme care, designed to operate properly only in On Object Render hooks.","int","Zero if successful, otherwise an integer error code")
 
 ADE_FUNC (drawTargetingBrackets, l_Graphics,"object Object, [boolean draw=true, int padding=5]","Gets the edge positions of targeting brackets for the specified object. The brackets will only be drawn if draw is true or the default value of draw is used. Brackets are drawn with the current color. The brackets will have a padding (distance from the actual bounding box); the default value (used elsewhere in FS2) is 5.","number,number,number,number","Left, top, right, and bottom positions of the brackets, or nil if invalid")
 
 ADE_FUNC (drawSubsystemTargetingBrackets, l_Graphics,"subsystem subsys, [boolean draw=true, boolean setColor=false]","Gets the edge position of the targeting brackets drawn for a subsystem as if they were drawn on the HUD. Only actually draws the brackets if <i>draw</i> is true, optionally sets the color the as if it was drawn on the HUD","number,number,number,number","Left, top, right, and bottom positions of the brackets, or nil if invalid or off-screen")
 
 ADE_FUNC (drawOffscreenIndicator, l_Graphics,"object Object, [boolean draw=true, boolean setColor=false]","Draws an off-screen indicator for the given object. The indicator will not be drawn if draw=false, but the coordinates will be returned in either case. The indicator will be drawn using the current color if setColor=true and using the IFF color of the object if setColor=false.","number,number","Coordinates of the indicator (at the very edge of the screen), or nil if object is on-screen")
 
 ADE_FUNC (drawString, l_Graphics,"string Message, [number X1, number Y1, number X2, number Y2]","Draws a string. Use x1/y1 to control position, x2/y2 to limit textbox size.""Text will automatically move onto new lines, if x2/y2 is specified.""Additionally, calling drawString with only a string argument will automatically""draw that string below the previously drawn string (or 0,0 if no strings""have been drawn yet","number","Number of lines drawn, or 0 on failure")
 
 ADE_FUNC (getStringWidth, l_Graphics,"string String","Gets string width","number","String width, or 0 on failure")
 
 ADE_FUNC (createTexture, l_Graphics,"[number Width=512, number Height=512, enumeration Type=TEXTURE_DYNAMIC]","Creates a texture for rendering to.""Types are TEXTURE_STATIC - for infrequent rendering - and TEXTURE_DYNAMIC - for frequent rendering.","texture","New texture handle, or invalid texture handle if texture couldn't be created")
 
 ADE_FUNC (loadTexture, l_Graphics,"string Filename, [boolean LoadIfAnimation, boolean NoDropFrames]","Gets a handle to a texture. If second argument is set to true, animations will also be loaded.""If third argument is set to true, every other animation frame will not be loaded if system has less than 48 MB memory.""<br><strong>IMPORTANT:</strong> Textures will not be unload themselves unless you explicitly tell them to do so.""When you are done with a texture, call the Unload() function to free up memory.","texture","Texture handle, or invalid texture handle if texture couldn't be loaded")
 
 ADE_FUNC (drawImage, l_Graphics,"string Filename/texture Texture, [number X1=0, Y1=0, number X2, number Y2, number UVX1 = 0.0, number UVY1 = 0.0, number UVX2=1.0, number UVY2=1.0, number alpha=1.0]","Draws an image or texture. Any image extension passed will be ignored.""The UV variables specify the UV value for each corner of the image. ""In UV coordinates, (0,0) is the top left of the image; (1,1) is the lower right.","boolean","Whether image was drawn")
 
 ADE_FUNC (drawMonochromeImage, l_Graphics,"string Filename/texture Texture, number X1, number Y1, [number X2, number Y2, number alpha=1.0]","Draws a monochrome image using the current color","boolean","Whether image was drawn")
 
 ADE_FUNC (getImageWidth, l_Graphics,"string Filename","Gets image width","number","Image width, or 0 if filename is invalid")
 
 ADE_FUNC (getImageHeight, l_Graphics,"Image name","Gets image height","number","Image height, or 0 if filename is invalid")
 
 ADE_FUNC (flashScreen, l_Graphics,"number Red, number Green, number Blue","Flashes the screen", NULL, NULL)
 
 ADE_FUNC (loadModel, l_Graphics,"string Filename","Loads the model - will not setup subsystem data, DO NOT USE FOR LOADING SHIP MODELS","model","Handle to a model")
 
 ADE_FUNC (hasViewmode, l_Graphics,"enumeration","Specifies if the current viemode has the specified flag, see VM_* enumeration","boolean","true if flag is present, false otherwise")
 
 ADE_FUNC (setClip, l_Graphics,"x, y, width, height","Sets the clipping region to the specified rectangle. Most drawing functions are able to handle the offset.","boolean","true if successful, false otherwise")
 
 ADE_FUNC (resetClip, l_Graphics, NULL,"Resets the clipping region that might have been set","boolean","true if successful, false otherwise")
 
 ADE_INDEXER (l_HookVar_Globals,"number Index","Array of current HookVariable names","string","Hookvariable name, or empty string if invalid index specified")
 
 ADE_FUNC (__len, l_HookVar_Globals, NULL,"Number of HookVariables","number","Number of HookVariables")
 
 ADE_FUNC (getObjectFromSignature, l_Mission,"number Signature","Gets a handle of an object from its signature","object","Handle of object with signaure, invalid handle if signature is not in use")
 
 ADE_FUNC (evaluateSEXP, l_Mission,"string","Runs the defined SEXP script","boolean","if the operation was successful")
 
 ADE_FUNC (runSEXP, l_Mission,"string","Runs the defined SEXP script","boolean","if the operation was successful")
 
 ADE_INDEXER (l_Mission_Asteroids,"number Index","Gets asteroid","asteroid","Asteroid handle, or invalid handle if invalid index specified")
 
 ADE_FUNC (__len, l_Mission_Asteroids, NULL,"Number of asteroids in mission. Note that the value returned is only good until an asteroid is destroyed, and so cannot be relied on for more than one frame.","number","Number of asteroids in the mission, or 0 if asteroids are not enabled")
 
 ADE_INDEXER (l_Mission_Debris,"number Index","Array of debris in the current mission","debris","Debris handle, or invalid debris handle if index wasn't valid")
 
 ADE_FUNC (__len, l_Mission_Debris, NULL,"Number of debris pieces in the mission. ""Note that the value returned is only good until a piece of debris is destroyed, and so cannot be relied on for more than one frame.","number","Current number of debris particles")
 
 ADE_INDEXER (l_Mission_EscortShips,"number Index","Gets escort ship at specified index on escort list","ship","Specified ship, or invalid ship handle if invalid index")
 
 ADE_FUNC (__len, l_Mission_EscortShips, NULL,"Current number of escort ships","number","Current number of escort ships")
 
 ADE_INDEXER (l_Mission_Events,"number Index/string Name","Indexes events list","event","Event handle, or invalid event handle if index was invalid")
 
 ADE_FUNC (__len, l_Mission_Events, NULL,"Number of events in mission","number","Number of events in mission")
 
 ADE_INDEXER (l_Mission_SEXPVariables,"number Index/string Name","Array of SEXP variables. Note that you can set a sexp variable using the array, eg \'SEXPVariables[\"newvariable\"] = \"newvalue\"\'","sexpvariable","Handle to SEXP variable, or invalid sexpvariable handle if index was invalid")
 
 ADE_FUNC (__len, l_Mission_SEXPVariables, NULL,"Current number of SEXP variables","number","Counts number of loaded SEXP Variables. May be slow.")
 
 ADE_INDEXER (l_Mission_Ships,"number Index/string Name","Gets ship","ship","Ship handle, or invalid ship handle if index was invalid")
 
 ADE_FUNC (__len, l_Mission_Ships, NULL,"Number of ships in the mission. ""This function is somewhat slow, and should be set to a variable for use in looping situations. ""Note that the value returned is only good until a ship is destroyed, and so cannot be relied on for more than one frame.","number","Number of ships in the mission, or 0 if ships haven't been initialized yet")
 
 ADE_INDEXER (l_Mission_Waypoints,"number Index","Array of waypoints in the current mission","waypoint","Waypoint handle, or invalid waypoint handle if index was invalid")
 
 ADE_FUNC (__len, l_Mission_Waypoints, NULL,"Gets number of waypoints in mission. Note that this is only accurate for one frame.","number","Number of waypoints in the mission")
 
 ADE_INDEXER (l_Mission_WaypointLists,"number Index/string WaypointListName","Array of waypoint lists","waypointlist","Gets waypointlist handle")
 
 ADE_FUNC (__len, l_Mission_WaypointLists, NULL,"Number of waypoint lists in mission. Note that this is only accurate for one frame.","number","Number of waypoint lists in the mission")
 
 ADE_INDEXER (l_Mission_Weapons,"number Index","Gets handle to a weapon object in the mission.","weapon","Weapon handle, or invalid weapon handle if index is invalid")
 
 ADE_FUNC (__len, l_Mission_Weapons, NULL,"Number of weapon objects in mission. Note that this is only accurate for one frame.","number","Number of weapon objects in mission")
 
 ADE_INDEXER (l_Mission_Beams,"number Index","Gets handle to a beam object in the mission.","beam","Beam handle, or invalid beam handle if index is invalid")
 
 ADE_FUNC (__len, l_Mission_Beams, NULL,"Number of beam objects in mission. Note that this is only accurate for one frame.","number","Number of beam objects in mission")
 
 ADE_FUNC (getNextMissionFilename, l_Campaign, NULL,"Gets next mission filename","string","Next mission filename, or nil if the next mission is invalid")
 
 ADE_FUNC (getPrevMissionFilename, l_Campaign, NULL,"Gets previous mission filename","string","Previous mission filename, or nil if the previous mission is invalid")
 
 ADE_FUNC (jumpToMission, l_Campaign,"string filename, [boolean hub]","Jumps to a mission based on the filename. Optionally, the player can be sent to a hub mission without setting missions to skipped.","boolean","Jumps to a mission, or returns nil.")
 
 ADE_INDEXER (l_Mission_Wings,"number Index/string WingName","Wings in the mission","wing","Wing handle, or invalid wing handle if index or name was invalid")
 
 ADE_FUNC (__len, l_Mission_Wings, NULL,"Number of wings in mission","number","Number of wings in mission")
 
 ADE_INDEXER (l_Mission_Teams,"number Index/string TeamName","Teams in the mission","team","Team handle or invalid team handle if the requested team could not be found")
 
 ADE_FUNC (__len, l_Mission_Teams, NULL,"Number of teams in mission","number","Number of teams in mission")
 
 ADE_INDEXER (l_Mission_Messages,"number Index/string messageName","Messages of the mission","message","Message handle or invalid handle on error")
 
 ADE_FUNC (__len, l_Mission_Messages, NULL,"Number of messages in the mission","number","Number of messages in mission")
 
 ADE_INDEXER (l_Mission_BuiltinMessages,"number Index/string messageName","Built-in messages of the mission","message","Message handle or invalid handle on error")
 
 ADE_FUNC (__len, l_Mission_BuiltinMessages, NULL,"Number of built-in messages in the mission","number","Number of messages in mission")
 
 ADE_INDEXER (l_Mission_Personas,"number Index/string name","Personas of the mission","persona","Persona handle or invalid handle on error")
 
 ADE_FUNC (__len, l_Mission_Personas, NULL,"Number of personas in the mission","number","Number of messages in mission")
 
 ADE_FUNC (addMessage, l_Mission,"string name, string text[, persona persona]","Adds a message","message","The new message or invalid handle on error")
 
 ADE_FUNC (sendMessage, l_Mission,"string sender, message message[, number delay=0.0[, enumeration priority = MESSAGE_PRIORITY_NORMAL[, boolean fromCommand = false]]]","Sends a message from the given source (not from a ship!) with the given priority or optionally sends it from the missions command source.<br>""If delay is specified the message will be delayed by the specified time in seconds<br>""If you pass <i>nil</i> as the sender then the message will not have a sender.","boolean","true if successfull, false otherwise")
 
 ADE_FUNC (sendTrainingMessage, l_Mission,"message message, number time[, number delay=0.0]","Sends a training message to the player. <i>time</i> is the amount in seconds to display the message, only whole seconds are used!","boolean","true if successfull, false otherwise")
 
 ADE_FUNC (createShip, l_Mission,"[string Name, shipclass Class=Shipclass[1], orientation Orientation=null, vector Position={0,0,0}]","Creates a ship and returns a handle to it using the specified name, class, world orientation, and world position","ship","Ship handle, or invalid ship handle if ship couldn't be created")
 
 ADE_FUNC (createWaypoint, l_Mission,"[vector Position, waypointlist List]","Creates a waypoint","waypoint","Waypoint handle, or invalid waypoint handle if waypoint couldn't be created")
 
 ADE_FUNC (createWeapon, l_Mission,"[weaponclass Class=WeaponClass[1], orientation Orientation=null, world vector Position={0,0,0}, object Parent = nil, number Group = -1","Creates a weapon and returns a handle to it. 'Group' is used for lighting grouping purposes;"" for example, quad lasers would only need to act as one light source.","weapon","Weapon handle, or invalid weapon handle if weapon couldn't be created.")
 
 ADE_FUNC (getMissionFilename, l_Mission, NULL,"Gets mission filename","string","Mission filename, or empty string if game is not in a mission")
 
 ADE_FUNC (startMission, l_Mission,"[Filename or MISSION_* enumeration, Briefing = true]","Starts the defined mission","boolean","True, or false if the function fails")
 
return ade_set_args (L,"x", Missiontime)
 
 ADE_FUNC (loadMission, l_Mission,"Mission name","Loads a mission","boolean","True if mission was loaded, otherwise false")
 
 ADE_FUNC (unloadMission, l_Mission, NULL,"Stops the current mission and unloads it", NULL, NULL)
 
 ADE_FUNC (simulateFrame, l_Mission, NULL,"Simulates mission frame", NULL, NULL)
 
 ADE_FUNC (renderFrame, l_Mission, NULL,"Renders mission frame, but does not move anything", NULL, NULL)
 
 ADE_FUNC (applyShudder, l_Mission,"number time, number intesity","Applies a shudder effects to the camera. Time is in seconds. Intensity specifies the shudder effect strength, the Maxim has a value of 1440.","boolean","true if successfull, false otherwise")
 
 if (Game_mode &GM_CAMPAIGN_MODE)
 
return ade_set_args (L,"b", b)
 
 ADE_FUNC (AND, l_BitOps,"number, number","Values for which bitwise boolean AND operation is performed","number","Result of the AND operation")
 
 ADE_FUNC (OR, l_BitOps,"number, number","Values for which bitwise boolean OR operation is performed","number","Result of the OR operation")
 
 ADE_FUNC (XOR, l_BitOps,"number, number","Values for which bitwise boolean XOR operation is performed","number","Result of the XOR operation")
 
 if (!ade_get_args(L,"ii",&a,&b)) return ade_set_error(L
 
 if (!((b >=0)&&(b< 32))) return ade_set_error(L
 
 if (a &(1<< b)) c
 
return ade_set_args (L,"i", c)
 
 ADE_FUNC (addBit, l_BitOps,"number, number (bit)","Performs inclusive or (OR) operation on the set bit of the value","number","Result of the operation")
 
 ADE_INDEXER (l_Tables_ShipClasses,"number Index/string Name","Array of ship classes","shipclass","Ship handle, or invalid ship handle if index is invalid")
 
 ADE_FUNC (__len, l_Tables_ShipClasses, NULL,"Number of ship classes","number","Number of ship classes, or 0 if ship classes haven't been loaded yet")
 
 ADE_INDEXER (l_Tables_WeaponClasses,"number Index/string WeaponName","Array of weapon classes","weapon","Weapon class handle, or invalid weaponclass handle if index is invalid")
 
 ADE_FUNC (__len, l_Tables_WeaponClasses, NULL,"Number of weapon classes","number","Number of weapon classes, or 0 if weapon classes haven't been loaded yet")
 
 ADE_FUNC (avdTest, l_Testing, NULL,"Test the AVD Physics code", NULL, NULL)
 
 ADE_FUNC (createParticle, l_Testing,"vector Position, vector Velocity, number Lifetime, number Radius, enumeration Type, [number Tracer length=-1, boolean Reverse=false, texture Texture=Nil, object Attached Object=Nil]","Creates a particle. Use PARTICLE_* enumerations for type.""Reverse reverse animation, if one is specified""Attached object specifies object that Position will be (and always be) relative to.","particle","Handle to the created particle")
 
 ADE_FUNC (getStack, l_Testing, NULL,"Generates an ADE stackdump","string","Current Lua stack")
 
 ADE_FUNC (isCurrentPlayerMulti, l_Testing, NULL,"Returns whether current player is a multiplayer pilot or not.","boolean","Whether current player is a multiplayer pilot or not")
 
 ADE_FUNC (isPXOEnabled, l_Testing, NULL,"Returns whether PXO is currently enabled in the configuration.","boolean","Whether PXO is enabled or not")
 
 if (!ade_get_args(L,"s",&filename)) return ADE_RETURN_FALSE
 
 movie_play (filename)
 
void ade_debug_call (lua_State *L, lua_Debug *ar)
 
void ade_debug_ret (lua_State *L, lua_Debug *ar)
 
void ade_stackdump (lua_State *L, char *stackdump)
 
const char * ade_get_type_string (lua_State *L, int argnum)
 
int ade_get_args (lua_State *L, const char *fmt,...)
 
int ade_set_args (lua_State *L, const char *fmt,...)
 
int ade_friendly_error (lua_State *L)
 
char * ade_concat_helper (lua_State *L, int obj_ldx)
 
void ade_output_type_link (FILE *fp, char *typestr)
 
void ade_output_toc (FILE *fp, ade_table_entry *ate)
 

Variables

SCP_vector< ade_table_entryAde_table_entries
 
string_conv ade_Operators []
 
int ade_Num_operators = sizeof(ade_Operators)/sizeof(string_conv)
 
const size_t INVALID_ID = (size_t) -1
 
ade_obj< vec3dl_Vector ("vector","Vector object")
 
ade_obj< matrix_hl_Matrix ("orientation","Orientation matrix object")
 
char * s = NULL
 
float newval = 0.0f
 
int numargs = ade_get_args(L, "os|f", l_Matrix.GetPtr(&mh), &s, &newval)
 
 f = 0.0f
 
int idx =0
 
floatval = NULL
 
 else
 
matrix_horiB = NULL
 
float factor = 0.0f
 
 o
 
matrixA = oriA->GetMatrix()
 
matrixB = oriB->GetMatrix()
 
matrix final = vmd_identity_matrix
 
flag_def_list plr_commands []
 
int num_plr_commands = sizeof(plr_commands)/sizeof(flag_def_list)
 
ade_obj< enum_hl_Enum ("enumeration","Enumeration object")
 
ade_obj< intl_Event ("event","Mission event handle")
 
int newinterval = 0
 
 i = 0
 
mission_eventmep = &Mission_events[idx]
 
ade_obj< CFILE * > l_File ("file","File handle")
 
ade_obj< intl_Font ("font","font handle")
 
char * newname = NULL
 
int newheight = -1
 
ade_obj< gameevent_hl_GameEvent ("gameevent","Game event")
 
ade_obj< gamestate_hl_GameState ("gamestate","Game state")
 
ade_obj< HudGaugel_HudGauge ("HudGauge","HUD Gauge handle")
 
ade_obj< eye_hl_Eyepoint ("eyepoint","Eyepoint handle")
 
vec3dv
 
polymodelpm = model_get(eh->model)
 
ade_obj< model_hl_Model ("model","3D Model (POF) handle")
 
ade_obj< modeltextures_hl_ModelTextures ("modeltextures_h","Array of materials")
 
ade_obj< eyepoints_hl_Eyepoints ("eyepoints","Array of model eye points")
 
ade_obj< thrusters_hl_Thrusters ("thrusters","The thrusters of a model")
 
ade_obj< thrusterbank_hl_Thrusterbank ("thrusterbank","A model thrusterbank")
 
ade_obj< glowpoint_hl_Glowpoint ("glowpoint","A model glowpoint")
 
ade_obj< dockingbays_hl_Dockingbays ("dockingbays","The docking bays of a model")
 
float nr = 0.0f
 
vec3d newVec
 
vec3d vec = glh->point->pnt
 
ade_obj< dockingbay_hl_Dockingbay ("dockingbay","Handle to a model docking bay")
 
ade_obj< physics_info_hl_Physics ("physics","Physics handle")
 
vec3dv3 =NULL
 
ade_obj< sexpvar_hl_SEXPVariable ("sexpvariable","SEXP Variable handle")
 
ade_obj< object_hl_Shields ("shields","Shields handle")
 
float nval = -1.0f
 
objectobjp = NULL
 
int qdx = -1
 
ade_obj< intl_Shiptype ("shiptype","Ship type handle")
 
int Species_initted
 
ade_obj< intl_Species ("species","Species handle")
 
ade_obj< intl_Team ("team","Team handle")
 
ade_obj< intl_Texture ("texture","Texture handle")
 
vec3dv2 = NULL
 
v3 xyz x = v1->xyz.x * v2->xyz.x
 
v3 xyz y = v1->xyz.y * v2->xyz.y
 
v3 xyz z = v1->xyz.z * v2->xyz.z
 
char buf [128]
 
ade_obj< texture_map_hl_TextureMap ("material","Texture map, including diffuse, glow, and specular textures")
 
ade_obj< intl_Weaponclass ("weaponclass","Weapon class handle")
 
else return ADE_RETURN_FALSE
 
ade_obj< mc_info_hl_ColInfo ("collision info","Information about a collision")
 
bool local = false
 
mc_infocollide = info->Get()
 
matrix_hmh =NULL
 
objectobj = NULL
 
int model_num = -1
 
int model_instance_num = -1
 
int temp = 0
 
vec3dv3a
 
vec3dv3b
 
int flags = 0
 
int submodel = -1
 
mc_info hull_check
 
hull_check submodel_num = submodel
 
hull_check orient = &obj->orient
 
hull_check pos = &obj->pos
 
hull_check p0 = v3a
 
hull_check p1 = v3b
 
 oo
 
ade_obj< object_hl_Asteroid ("asteroid","Asteroid handle",&l_Object)
 
ade_obj< cockpit_disp_info_hl_DisplayInfo ("display info","Ship cockpit display information handle")
 
ade_obj< cockpit_display_hl_CockpitDisplay ("display","Cockpit display handle")
 
ade_obj< cockpit_displays_info_hl_CockpitDisplayInfos ("cockpitdisplays","Array of cockpit display information")
 
ade_obj< intl_Shipclass ("shipclass","Ship class handle")
 
ade_obj< object_hl_Debris ("debris","Debris handle",&l_Object)
 
ade_obj< object_hl_Waypoint ("waypoint","waypoint handle",&l_Object)
 
ade_obj< waypointlist_hl_WaypointList ("waypointlist","waypointlist handle")
 
ade_obj< ship_bank_hl_WeaponBank ("weaponbank","Ship/subystem weapons bank handle")
 
ade_obj< ship_banktype_hl_WeaponBankType ("weaponbanktype","Ship/subsystem weapons bank type handle")
 
bool newlink = false
 
 b = 0
 
 false
 
bool newfire = false
 
ade_obj< ship_subsys_hl_Subsystem ("subsystem","Ship subsystem handle")
 
bsp_infosm = &pm->submodel[sso->ss->system_info->turret_gun_sobj]
 
int newVal = -1
 
ade_obj< order_hl_Order ("order","order handle")
 
ade_obj< object_hl_ShipOrders ("shiporders","Ship orders")
 
ade_obj< object_hl_ShipTextures ("shiptextures","Ship textures handle")
 
ade_obj< cockpit_displays_hl_CockpitDisplays ("displays","Player cockpit displays array handle")
 
ade_obj< sound_entry_hl_SoundEntry ("soundentry","sounds.tbl table entry handle")
 
ade_obj< sound_hl_Sound ("sound","sound instance handle")
 
ade_obj< sound_hl_Sound3D ("3Dsound","3D sound instance handle",&l_Sound)
 
ade_obj< intl_Soundfile ("soundfile","Handle to a sound file")
 
ade_obj< intl_Persona ("persona","Persona handle")
 
ade_obj< intl_Message ("message","Handle to a mission message")
 
ade_obj< intl_Wing ("wing","Wing handle")
 
ade_obj< object_hl_Ship ("ship","Ship handle",&l_Object)
 
float fov = -1
 
shipshipp = &Ships[objh->objp->instance]
 
int ets_idx = 0
 
Attempted to set incomplete feature
 
int subtype =-1
 
int type = model_anim_match_type(s)
 
int time_ms = model_anim_get_time_type(&Ships[objh->objp->instance], type, subtype)
 
float time_s = (float)time_ms / 1000.0f
 
ade_obj< object_hl_Weapon ("weapon","Weapon handle",&l_Object)
 
ade_obj< object_hl_Beam ("beam","Beam handle",&l_Object)
 
ade_obj< intl_Player ("player","Player handle")
 
ade_obj< camidl_Camera ("camera","Camera handle")
 
ade_obj< intl_Control_Info ("control info","control info handle")
 
ade_obj< particle_hl_Particle ("particle","Handle to a particle")
 
ade_lib l_Audio ("Audio", NULL,"ad","Sound/Music Library")
 
float Master_event_music_volume
 
ade_lib l_Base ("Base", NULL,"ba","Base FreeSpace 2 functions")
 
return ADE_RETURN_NIL
 
ade_lib l_Base_Events ("GameEvents",&l_Base, NULL,"Freespace 2 game events")
 
ade_lib l_Base_States ("GameStates",&l_Base, NULL,"Freespace 2 states")
 
ade_lib l_CFile ("CFile", NULL,"cf","CFile FS2 filesystem access")
 
ade_lib l_Mouse ("Controls", NULL,"io","Controls library")
 
int mouse_inited
 
enum_hu = NULL
 
int ul = 0
 
return ADE_RETURN_TRUE
 
ade_lib l_HUD ("HUD", NULL,"hu","HUD library")
 
int r = 0
 
int g = 0
 
int a = 0
 
gr_init_alphacolor &[idxHUD_config
 
color c = HUD_config.clr[idx]
 
ade_lib l_Graphics ("Graphics", NULL,"gr","Graphics Library")
 
ade_lib l_Graphics_Cameras ("Cameras",&l_Graphics, NULL,"Cameras")
 
ade_lib l_Graphics_Fonts ("Fonts",&l_Graphics, NULL,"Font library")
 
ade_lib l_Graphics_Posteffects ("PostEffects",&l_Graphics, NULL,"Post processing effects")
 
ade_lib l_HookVar ("HookVariables", NULL,"hv","Hook variables repository")
 
ade_lib l_HookVar_Globals ("Globals",&l_HookVar)
 
ade_lib l_Mission ("Mission", NULL,"mn","Mission library")
 
ade_lib l_Mission_Asteroids ("Asteroids",&l_Mission, NULL,"Asteroids in the mission")
 
ade_lib l_Mission_Debris ("Debris",&l_Mission, NULL,"debris in the mission")
 
ade_lib l_Mission_EscortShips ("EscortShips",&l_Mission, NULL, NULL)
 
ade_lib l_Mission_Events ("Events",&l_Mission, NULL,"Events")
 
ade_lib l_Mission_SEXPVariables ("SEXPVariables",&l_Mission, NULL,"SEXP Variables")
 
ade_lib l_Mission_Ships ("Ships",&l_Mission, NULL,"Ships in the mission")
 
int ships_inited
 
ade_lib l_Mission_Waypoints ("Waypoints",&l_Mission, NULL, NULL)
 
ade_lib l_Mission_WaypointLists ("WaypointLists",&l_Mission, NULL, NULL)
 
ade_lib l_Mission_Weapons ("Weapons",&l_Mission, NULL, NULL)
 
ade_lib l_Mission_Beams ("Beams",&l_Mission, NULL, NULL)
 
ade_lib l_Campaign ("Campaign", NULL,"ca","Campaign Library")
 
ade_lib l_Mission_Wings ("Wings",&l_Mission, NULL, NULL)
 
ade_lib l_Mission_Teams ("Teams",&l_Mission, NULL, NULL)
 
ade_lib l_Mission_Messages ("Messages",&l_Mission, NULL, NULL)
 
ade_lib l_Mission_BuiltinMessages ("BuiltinMessages",&l_Mission, NULL, NULL)
 
ade_lib l_Mission_Personas ("Personas",&l_Mission, NULL, NULL)
 
ade_lib l_BitOps ("BitOps", NULL,"bit","Bitwise Operations library")
 
ade_lib l_Tables ("Tables", NULL,"tb","Tables library")
 
ade_lib l_Tables_ShipClasses ("ShipClasses",&l_Tables, NULL, NULL)
 
ade_lib l_Tables_WeaponClasses ("WeaponClasses",&l_Tables, NULL, NULL)
 
int Weapons_inited
 
ade_lib l_Testing ("Testing", NULL,"ts","Experimental or testing stuff")
 
int Om_tracker_flag
 
lua_Debug Ade_debug_info
 
char debug_stack [4][32]
 
int Ade_get_args_skip = 0
 
bool Ade_get_args_lfunction = false
 

Macro Definition Documentation

#define ADE_FUNC (   name,
  parent,
  args,
  desc,
  ret_type,
  ret_desc 
)
Value:
static int parent##_##name##_f(lua_State *L); \
ade_func parent##_##name(#name, parent##_##name##_f, parent, args, desc, ret_type, ret_desc); \
static int parent##_##name##_f(lua_State *L)
GLuint const GLchar * name
Definition: Glext.h:5608

Definition at line 220 of file lua.cpp.

#define ADE_FUNCNAME_UPVALUE_INDEX   1

Definition at line 240 of file lua.cpp.

#define ADE_INDEXER (   parent,
  args,
  desc,
  ret_type,
  ret_desc 
)
Value:
static int parent##___indexer_f(lua_State *L); \
ade_indexer parent##___indexer(parent##___indexer_f, parent, args, desc, ret_type, ret_desc); \
static int parent##___indexer_f(lua_State *L)

Definition at line 234 of file lua.cpp.

else return ADE_RETURN_FALSE   ade_set_args(L, "b", false)

Definition at line 247 of file lua.cpp.

return ADE_RETURN_NIL   0

Definition at line 245 of file lua.cpp.

return ADE_RETURN_TRUE   ade_set_args(L, "b", true)

Definition at line 246 of file lua.cpp.

#define ade_set_error   ade_set_args

Definition at line 248 of file lua.cpp.

#define ADE_SETTING_UPVALUE_INDEX   2

Definition at line 241 of file lua.cpp.

#define ADE_SETTING_VAR   lua_toboolean(L,lua_upvalueindex(ADE_SETTING_UPVALUE_INDEX))

Definition at line 242 of file lua.cpp.

#define ADE_VIRTVAR (   name,
  parent,
  args,
  desc,
  ret_type,
  ret_desc 
)
Value:
static int parent##_##name##_f(lua_State *L); \
ade_virtvar parent##_##name(#name, parent##_##name##_f, parent, args, desc, ret_type, ret_desc); \
static int parent##_##name##_f(lua_State *L)
GLuint const GLchar * name
Definition: Glext.h:5608

Definition at line 227 of file lua.cpp.

#define BMPMAN_INTERNAL

Definition at line 57 of file lua.cpp.

#define LE_ALPHABLEND_FILTER   14
#define LE_ALPHABLEND_NONE   27
#define LE_CFILE_TYPE_MEMORY_MAPPED   21
#define LE_CFILE_TYPE_NORMAL   20
#define LE_LOCK   12
#define LE_LUA_ADDITIVE_BUTTON_CONTROL   52
#define LE_LUA_FULL_CONTROLS   50
#define LE_LUA_OVERRIDE_BUTTON_CONTROL   53
#define LE_LUA_STEERING_CONTROLS   49
#define LE_MESSAGE_PRIORITY_HIGH   73
#define LE_MESSAGE_PRIORITY_LOW   71
#define LE_MESSAGE_PRIORITY_NORMAL   72
#define LE_MISSION_REPEAT   47
#define LE_MOUSE_LEFT_BUTTON   1
#define LE_MOUSE_MIDDLE_BUTTON   3
#define LE_MOUSE_RIGHT_BUTTON   2
#define LE_NONE   15
#define LE_NORMAL_BUTTON_CONTROLS   51
#define LE_NORMAL_CONTROLS   48
#define LE_ORDER_ATTACK   28
#define LE_ORDER_ATTACK_ANY   29
#define LE_ORDER_ATTACK_WING   69
#define LE_ORDER_DEPART   30
#define LE_ORDER_DISABLE   31
#define LE_ORDER_DISARM   32
#define LE_ORDER_DOCK   33
#define LE_ORDER_EVADE   34
#define LE_ORDER_FLY_TO   35
#define LE_ORDER_FORM_ON_WING   36
#define LE_ORDER_GUARD   37
#define LE_ORDER_GUARD_WING   70
#define LE_ORDER_IGNORE   38
#define LE_ORDER_KEEP_SAFE_DISTANCE   39
#define LE_ORDER_PLAY_DEAD   40
#define LE_ORDER_REARM   41
#define LE_ORDER_STAY_NEAR   42
#define LE_ORDER_STAY_STILL   43
#define LE_ORDER_UNDOCK   44
#define LE_ORDER_WAYPOINTS   45
#define LE_ORDER_WAYPOINTS_ONCE   46
#define LE_PARTICLE_BITMAP   5
#define LE_PARTICLE_DEBUG   4
#define LE_PARTICLE_FIRE   6
#define LE_PARTICLE_PERSISTENT_BITMAP   9
#define LE_PARTICLE_SMOKE   7
#define LE_PARTICLE_SMOKE2   8
#define LE_SEXPVAR_CAMPAIGN_PERSISTENT   22
#define LE_SEXPVAR_NOT_PERSISTENT   23
#define LE_SEXPVAR_PLAYER_PERSISTENT   24
#define LE_SEXPVAR_TYPE_NUMBER   25
#define LE_SEXPVAR_TYPE_STRING   26
#define LE_SHIELD_BACK   19
#define LE_SHIELD_FRONT   16
#define LE_SHIELD_LEFT   17
#define LE_SHIELD_RIGHT   18
#define LE_TEXTURE_DYNAMIC   11
#define LE_TEXTURE_STATIC   10
#define LE_UNLOCK   13
#define LE_VM_CHASE   58
#define LE_VM_DEAD_VIEW   57
#define LE_VM_EXTERNAL   55
#define LE_VM_EXTERNAL_CAMERA_LOCKED   60
#define LE_VM_FREECAMERA   68
#define LE_VM_INTERNAL   54
#define LE_VM_OTHER_SHIP   59
#define LE_VM_PADLOCK_LEFT   64
#define LE_VM_PADLOCK_REAR   63
#define LE_VM_PADLOCK_RIGHT   65
#define LE_VM_PADLOCK_UP   62
#define LE_VM_TOPDOWN   67
#define LE_VM_TRACK   56
#define LE_VM_WARP_CHASE   61
#define LE_VM_WARPIN_ANCHOR   66
#define MAX_TEXT_LINES   256

Definition at line 13874 of file lua.cpp.

#define MH_ANGLES_OUTOFDATE   2

Definition at line 298 of file lua.cpp.

#define MH_FINE   0

Definition at line 296 of file lua.cpp.

#define MH_MATRIX_OUTOFDATE   1

Definition at line 297 of file lua.cpp.

#define SWH_NONE   0

Definition at line 6465 of file lua.cpp.

#define SWH_PRIMARY   1

Definition at line 6466 of file lua.cpp.

#define SWH_SECONDARY   2

Definition at line 6467 of file lua.cpp.

#define SWH_TERTIARY   3

Definition at line 6468 of file lua.cpp.

Function Documentation

int add_wave ( const char *  wave_name)

Definition at line 333 of file missionmessage.cpp.

char* ade_concat_helper ( lua_State *  L,
int  obj_ldx 
)

Definition at line 16403 of file lua.cpp.

void ade_debug_call ( lua_State *  L,
lua_Debug *  ar 
)

Definition at line 15810 of file lua.cpp.

void ade_debug_ret ( lua_State *  L,
lua_Debug *  ar 
)

Definition at line 15833 of file lua.cpp.

int ade_friendly_error ( lua_State *  L)

Definition at line 16392 of file lua.cpp.

ADE_FUNC ( __mul  ,
l_Matrix  ,
"orientation"  ,
"Multiplies two matrix  objects 
)

Definition at line 410 of file lua.cpp.

ADE_FUNC ( __tostring  ,
l_Matrix  ,
NULL  ,
"Converts a matrix to a string with format \"\""  [r1c1 r2c1 r3c1|r1c2 r2c2 r3c2|r1c3 r2c3 r3c3],
"string"   
)

Definition at line 423 of file lua.cpp.

ADE_FUNC ( getTranspose  ,
l_Matrix  ,
NULL  ,
"Returns a transpose version of the specified orientation"  ,
"orientation"  ,
"Transpose  matrix,
or null orientation on failure"   
)

Definition at line 457 of file lua.cpp.

ADE_FUNC ( rotateVector  ,
l_Matrix  ,
"vector Input"  ,
"Returns rotated version of given vector"  ,
"vector"  ,
"Rotated  vector,
or empty vector on error"   
)

Definition at line 470 of file lua.cpp.

ADE_FUNC ( unrotateVector  ,
l_Matrix  ,
"vector Input"  ,
"Returns unrotated version of given vector"  ,
"vector"  ,
"Unrotated  vector,
or empty vector on error"   
)

Definition at line 483 of file lua.cpp.

ADE_FUNC ( __newindex  ,
l_Enum  ,
"enumeration"   
)

Definition at line 890 of file lua.cpp.

ADE_FUNC ( __tostring  ,
l_Enum  ,
NULL  ,
"Returns enumeration name ,
"string"  ,
"Enumeration  name,
or\"<INVALID>\" if invalid"   
)

Definition at line 902 of file lua.cpp.

ADE_FUNC ( __eq  ,
l_Enum  ,
"enumeration"  ,
"Compares the two enumerations for equality"  ,
"boolean"  ,
"true if  equal,
false otherwise"   
)

Definition at line 921 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Event  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 1083 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_File  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 1099 of file lua.cpp.

ADE_FUNC ( close  ,
l_File  ,
NULL  ,
"Instantly closes file and invalidates all file handles"  ,
NULL  ,
NULL   
)

Definition at line 1111 of file lua.cpp.

ADE_FUNC ( flush  ,
l_File  ,
NULL  ,
"Flushes file buffer to disk."  ,
"boolean"  ,
"True for  success,
false on failure"   
)

Definition at line 1129 of file lua.cpp.

ADE_FUNC ( getPath  ,
l_File  ,
NULL  ,
"Determines path of the given file"  ,
"string"  ,
"Path string of the file  handle,
or an empty string if it doesn't have  one,
or the handle is invalid"   
)

Definition at line 1143 of file lua.cpp.

ADE_FUNC ( read  ,
l_File  ,
"number or  string,
..."  ,
"Reads part of or all of a  file,
depending on arguments passed.Based on basic Lua file:read function." "Returns nil when the end of the file is reached." "< br >< ul >< li >\"*n\" - Reads a number.</li>""<li>\"*a\" - Reads the rest of the file and returns it as a string.</li>""<li>\"*l\" - Reads a line. Skips the end of line markers.</li>""<li>(number) - Reads given number of  characters,
then returns them as a string.</li ></ul >"  ,
"number or  string,
..."  ,
"Requested  data,
or nil if the function fails"   
)

Definition at line 1160 of file lua.cpp.

ADE_FUNC ( seek  ,
l_File  ,
""  [string Whence=\"cur\", number Offset=0],
"Changes position of  file,
or gets location." "Whence can be:" "< li >\"set\" - File start.</li>""<li>\"cur\" - Current position in file.</li>""<li>\"end\" - File end.</li></ul>"  ,
"number"  ,
"new  offset,
or false or nil on failure"   
)

Definition at line 1279 of file lua.cpp.

ADE_FUNC ( write  ,
l_File  ,
"string or  number,
..."  ,
"Writes a series of Lua strings or numbers to the current file."  ,
"number"  ,
"Number of items successfully written."   
)

Definition at line 1321 of file lua.cpp.

ADE_FUNC ( __tostring  ,
l_Font  ,
NULL  ,
"Filename of font ,
"string"  ,
"Font  filename,
or an empty string if the handle is invalid"   
)

Definition at line 1361 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Font  ,
NULL  ,
"True if  valid,
false or nil if not"  ,
"boolean"  ,
"Detects whether handle is valid"   
)

Definition at line 1407 of file lua.cpp.

ADE_FUNC ( __tostring  ,
l_GameEvent  ,
NULL  ,
"Game event name ,
"string"  ,
"Game event  name,
or empty string if handle is invalid"   
)

Definition at line 1435 of file lua.cpp.

ADE_FUNC ( __tostring  ,
l_GameState  ,
NULL  ,
"Game state name ,
"string"  ,
"Game state  name,
or empty string if handle is invalid"   
)

Definition at line 1483 of file lua.cpp.

ADE_FUNC ( IsValid  ,
l_Eyepoint  ,
NULL  ,
"Detect whether this handle is valid"  ,
"boolean"  ,
"true if valid false otherwise"   
)

Definition at line 1608 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Model  ,
NULL  ,
"True if  valid,
false or nil if not"  ,
"boolean"  ,
"Detects whether handle is valid"   
)

Definition at line 1961 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Eyepoints  ,
NULL  ,
"Gets the number of eyepoints on this model"  ,
"number"  ,
"Number of eyepoints on this model or 0 on error"   
)

Definition at line 1971 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Eyepoints  ,
NULL  ,
"Detects whether handle is valid or not"  ,
"boolean"  ,
"true if valid false otherwise"   
)

Definition at line 2032 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Thrusters  ,
NULL  ,
"Number of thruster banks on the model"  ,
"number"  ,
"Number of thrusterbanks"   
)

Definition at line 2042 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Thrusters  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 2092 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Thrusterbank  ,
NULL  ,
"Number of thrusters on this thrusterbank"  ,
"number"  ,
"Number of thrusters on this bank or 0 if handle is invalid"   
)

Definition at line 2102 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Thrusterbank  ,
NULL  ,
"Detectes if this handle is valid"  ,
"boolean"  ,
"true if this handle is  valid,
false otherwise"   
)

Definition at line 2149 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Glowpoint  ,
NULL  ,
"Returns wether this handle is valid or not"  ,
"boolean"  ,
"True if handle is  valid,
false otherwise"   
)

Definition at line 2204 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Dockingbays  ,
NULL  ,
"Retrieves the number of dockingbays on this model"  ,
"number"  ,
"number of docking bays or 0 on error"   
)

Definition at line 2289 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Dockingbay  ,
NULL  ,
"Gets the number of docking points in this bay"  ,
"number"  ,
"The number of docking points or 0 on error"   
)

Definition at line 2303 of file lua.cpp.

ADE_FUNC ( getName  ,
l_Dockingbay  ,
NULL  ,
"Gets the name of this docking bay"  ,
"string"  ,
"The name or an empty string on error"   
)

Definition at line 2320 of file lua.cpp.

ADE_FUNC ( getPoint  ,
l_Dockingbay  ,
"number index ,
"Gets the location of a docking point in this bay"  ,
"vector"  ,
"The local location or null vector on error"   
)

Definition at line 2338 of file lua.cpp.

ADE_FUNC ( getNormal  ,
l_Dockingbay  ,
"number index ,
"Gets the normal of a docking point in this bay"  ,
"vector"  ,
"The normal vector or null vector on error"   
)

Definition at line 2366 of file lua.cpp.

ADE_FUNC ( computeDocker  ,
l_Dockingbay  ,
"dockingbay"  ,
"Computes the final position and orientation of a docker bay that docks with this bay."  ,
vector,
orientation"  ,
"The local location and orientation of the docker vessel in the reference to the vessel of the docking bay  handle,
or a nil value on error"   
)

Definition at line 2394 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Dockingbay  ,
NULL  ,
"Detects whether is valid or not"  ,
"number"  ,
"<i>true</i> if  valid,
< i >false</i > otherwise"   
)

Definition at line 2439 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Physics  ,
NULL  ,
"True if  valid,
false or nil if not"  ,
"boolean"  ,
"Detects whether handle is valid"   
)

Definition at line 2829 of file lua.cpp.

ADE_FUNC ( getSpeed  ,
l_Physics  ,
NULL  ,
"Gets total speed as of last frame"  ,
"number"  ,
"Total  speed,
or 0 if handle is invalid"   
)

Definition at line 2838 of file lua.cpp.

ADE_FUNC ( getForwardSpeed  ,
l_Physics  ,
NULL  ,
"Gets total speed in the ship's 'forward' direction as of last frame"  ,
"number"  ,
"Total forward  speed,
or 0 if handle is invalid"   
)

Definition at line 2850 of file lua.cpp.

ADE_FUNC ( isAfterburnerActive  ,
l_Physics  ,
NULL  ,
"True if Afterburners are  on,
false or nil if not"  ,
"boolean"  ,
"Detects whether afterburner is active"   
)

Definition at line 2863 of file lua.cpp.

ADE_FUNC ( isGliding  ,
l_Physics  ,
NULL  ,
"True if glide mode is  on,
false or nil if not"  ,
"boolean"  ,
"Detects if ship is gliding"   
)

Definition at line 2879 of file lua.cpp.

ADE_FUNC ( applyWhack  ,
l_Physics  ,
"vector  Impulse,
[ vector Position] "  ,
"Applies a whack to an object at a position (a local vector) based on impulse supplied (a world vector). If no position is  supplied,
an empty vector is used."  ,
"boolean"  ,
"true if it  succeeded,
false otherwise"   
)

Definition at line 2894 of file lua.cpp.

ADE_FUNC ( __tostring  ,
l_SEXPVariable  ,
NULL  ,
"Returns SEXP name ,
"string"  ,
"SEXP  name,
or empty string if handle is invalid"   
)

Definition at line 3046 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_SEXPVariable  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 3058 of file lua.cpp.

ADE_FUNC ( delete  ,
l_SEXPVariable  ,
NULL  ,
"Deletes a SEXP Variable"  ,
"boolean"  ,
"True if  successful,
false if the handle is invalid"   
)

Definition at line 3070 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Shields  ,
NULL  ,
"Number of shield segments"  ,
"number"  ,
"Number of shield segments or 0 if handle is invalid"   
)

Definition at line 3087 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Shields  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 3212 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Shiptype  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 3245 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Species  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 3281 of file lua.cpp.

ADE_FUNC ( __eq  ,
l_Team  ,
team,
team ,
"Checks whether two teams are the same team ,
"boolean"  ,
"true if equal"   
)

Definition at line 3296 of file lua.cpp.

ADE_FUNC ( getColor  ,
l_Team  ,
NULL  ,
"Gets the IFF color of the specified Team"  ,
number,
number  ,
number"  ,
"rgb color for the specified team or nil if invalid"   
)

Definition at line 3322 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Team  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 3340 of file lua.cpp.

ADE_FUNC ( __gc  ,
l_Texture  ,
NULL  ,
"Auto-deletes texture ,
NULL  ,
NULL   
)

Definition at line 3359 of file lua.cpp.

ADE_FUNC ( __eq  ,
l_Texture  ,
texture,
texture ,
"Checks if two texture handles refer to the same texture ,
"boolean"  ,
"True if textures are equal"   
)

Definition at line 3376 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Texture  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 3422 of file lua.cpp.

ADE_FUNC ( unload  ,
l_Texture  ,
NULL  ,
"Unloads a texture from memory"  ,
NULL  ,
NULL   
)

Definition at line 3431 of file lua.cpp.

ADE_FUNC ( getFilename  ,
l_Texture  ,
NULL  ,
"Returns filename for texture ,
"string"  ,
Filename,
or empty string if handle is invalid"   
)

Definition at line 3449 of file lua.cpp.

ADE_FUNC ( getWidth  ,
l_Texture  ,
NULL  ,
"Gets texture width ,
"number"  ,
"Texture  width,
or 0 if handle is invalid"   
)

Definition at line 3461 of file lua.cpp.

ADE_FUNC ( getHeight  ,
l_Texture  ,
NULL  ,
"Gets texture height ,
"number"  ,
"Texture  height,
or 0 if handle is invalid"   
)

Definition at line 3478 of file lua.cpp.

ADE_FUNC ( getFPS  ,
l_Texture  ,
NULL  ,
"Gets frames-per-second of texture ,
"number"  ,
"Texture  FPS,
or 0 if handle is invalid"   
)

Definition at line 3495 of file lua.cpp.

ADE_FUNC ( getFramesLeft  ,
l_Texture  ,
NULL  ,
"Gets number of frames  left,
from handle's position in animation"  ,
"number"  ,
"Frames  left,
or 0 if handle is invalid"   
)

Definition at line 3512 of file lua.cpp.

ADE_FUNC ( __add  ,
l_Vector  ,
"number/vector"  ,
"Adds vector by another  vector,
or adds all axes by value ,
"vector"  ,
"Final  vector,
or null vector if error occurs"   
)

Definition at line 3560 of file lua.cpp.

ADE_FUNC ( __sub  ,
l_Vector  ,
"number/vector"  ,
"Subtracts vector from another  vector,
or subtracts all axes by value ,
"vector"  ,
"Final  vector,
or null vector if error occurs"   
)

Definition at line 3586 of file lua.cpp.

ADE_FUNC ( getOrientation  ,
l_Vector  ,
NULL  ,
"Returns orientation object representing the direction of the vector. Does not require vector to be normalized."  ,
"orientation"  ,
"Orientation  object,
or null orientation object if handle is invalid"   
)

Definition at line 3680 of file lua.cpp.

ADE_FUNC ( getDistance  ,
l_Vector  ,
"Vector"  ,
"Distance"  ,
"number"  ,
"Returns distance from another vector"   
)

Definition at line 3707 of file lua.cpp.

ADE_FUNC ( getDotProduct  ,
l_Vector  ,
"vector OtherVector"  ,
"Returns dot product of vector object with vector argument"  ,
"number"  ,
"Dot  product,
or 0 if a handle is invalid"   
)

Definition at line 3716 of file lua.cpp.

ADE_FUNC ( getCrossProduct  ,
l_Vector  ,
"vector OtherVector"  ,
"Returns cross product of vector object with vector argument"  ,
"vector"  ,
"Cross  product,
or null vector if a handle is invalid"   
)

Definition at line 3725 of file lua.cpp.

ADE_FUNC ( getScreenCoords  ,
l_Vector  ,
NULL  ,
"Gets screen cordinates of a world vector"  ,
number,
number"  ,
"X   number,
Y(number)  ,
or false if off-screen  
)

Definition at line 3737 of file lua.cpp.

ADE_FUNC ( getNormalized  ,
l_Vector  ,
NULL  ,
"Returns a normalized version of the vector"  ,
"vector"  ,
"Normalized  Vector,
or NIL if invalid"   
)

Definition at line 3760 of file lua.cpp.

ADE_FUNC ( __tostring  ,
l_Weaponclass  ,
NULL  ,
"Weapon class name ,
"string"  ,
"Weapon class  name,
or an empty string if handle is invalid"   
)

Definition at line 3909 of file lua.cpp.

ADE_FUNC ( __eq  ,
l_Weaponclass  ,
weaponclass,
weaponclass"  ,
"Checks if the two classes are equal"  ,
"boolean"  ,
"true if equal false otherwise"   
)

Definition at line 3922 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Weaponclass  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 4328 of file lua.cpp.

ADE_FUNC ( getWeaponClassIndex  ,
l_Weaponclass  ,
NULL  ,
"Gets the index value of the weapon class"  ,
"number"  ,
"index value of the weapon class"   
)

Definition at line 4340 of file lua.cpp.

ADE_FUNC ( isMissile  ,
l_Weaponclass  ,
NULL  ,
"Return true if the weapon is a secondary weapon. This function is  deprecated,
use isSecondary instead."  ,
"boolean"  ,
"true if the weapon is a  secondary,
false otherwise"   
)

Definition at line 4367 of file lua.cpp.

ADE_FUNC ( isSecondary  ,
l_Weaponclass  ,
NULL  ,
"Return true if the weapon is a secondary weapon ,
"boolean"  ,
"true if the weapon is a  secondary,
false otherwise"   
)

Definition at line 4397 of file lua.cpp.

ADE_FUNC ( isBeam  ,
l_Weaponclass  ,
NULL  ,
"Return true if the weapon is a beam ,
"boolean"  ,
"true if the weapon is a  beam,
false otherwise"   
)

Definition at line 4412 of file lua.cpp.

ADE_FUNC ( __gc  ,
l_ColInfo  ,
NULL  ,
"Removes the allocated reference of this handle"  ,
NULL  ,
NULL   
)

Definition at line 4460 of file lua.cpp.

ADE_FUNC ( getCollisionDistance  ,
l_ColInfo  ,
NULL  ,
"The distance to the closest collision point"  ,
"number"  ,
"distance or -1 on error"   
)

Definition at line 4499 of file lua.cpp.

ADE_FUNC ( __eq  ,
l_Object  ,
object,
object ,
"Checks whether two object handles are for the same object ,
"boolean"  ,
"True if  equal,
false if not or a handle is invalid"   
)

Definition at line 4678 of file lua.cpp.

ADE_FUNC ( getSignature  ,
l_Object  ,
NULL  ,
"Gets the object's unique signature"  ,
"number"  ,
"Returns the object's unique numeric  signature,
or-1 if invalid.Useful for creating a metadata system"   
)

Definition at line 4875 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Object  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if handle is  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 4890 of file lua.cpp.

ADE_FUNC ( getBreedName  ,
l_Object  ,
NULL  ,
"Gets object type ,
"string"  ,
"Object type  name,
or empty string if handle is invalid"   
)

Definition at line 4899 of file lua.cpp.

ADE_FUNC ( getfvec  ,
l_Object  ,
""  [boolean normalize],
"Returns the objects' current fvec."  ,
"vector"  ,
"Objects' forward  vector,
or nil if invalid.If called with a true  argument,
vector will be normalized."   
)

Definition at line 4929 of file lua.cpp.

ADE_FUNC ( getuvec  ,
l_Object  ,
""  [boolean normalize],
"Returns the objects' current uvec."  ,
"vector"  ,
"Objects' up  vector,
or nil if invalid.If called with a true  argument,
vector will be normalized."   
)

Definition at line 4950 of file lua.cpp.

ADE_FUNC ( getrvec  ,
l_Object  ,
""  [boolean normalize],
"Returns the objects' current rvec."  ,
"vector"  ,
"Objects'  rvec,
or nil if invalid.If called with a true  argument,
vector will be normalized."   
)

Definition at line 4971 of file lua.cpp.

ADE_FUNC ( kill  ,
l_Asteroid  ,
""  [ship killer=nil, wvector hitpos=nil],
"Kills the asteroid. Set \"killer\" to designate a specific ship as having been the  killer,
and\"hitpos\" to specify the world position of the hit location; if  nil,
the asteroid center is used."  ,
"boolean"  ,
"True if  successful,
false or nil otherwise"   
)

Definition at line 5094 of file lua.cpp.

ADE_FUNC ( getName  ,
l_DisplayInfo  ,
NULL  ,
"Gets the name of this cockpit display as defined in ships.tbl"  ,
"string"  ,
"Name string or empty string on error"   
)

Definition at line 5169 of file lua.cpp.

ADE_FUNC ( getFileName  ,
l_DisplayInfo  ,
NULL  ,
"Gets the file name of the target texture of this cockpit display"  ,
"string"  ,
"Texture name string or empty string on error"   
)

Definition at line 5187 of file lua.cpp.

ADE_FUNC ( getForegroundFileName  ,
l_DisplayInfo  ,
NULL  ,
"Gets the file name of the foreground texture of this cockpit display"  ,
"string"  ,
"Foreground texture name string or nil if texture is not set or on error"   
)

Definition at line 5205 of file lua.cpp.

ADE_FUNC ( getBackgroundFileName  ,
l_DisplayInfo  ,
NULL  ,
"Gets the file name of the background texture of this cockpit display"  ,
"string"  ,
"Background texture name string or nil if texture is not set or on error"   
)

Definition at line 5226 of file lua.cpp.

ADE_FUNC ( getSize  ,
l_DisplayInfo  ,
NULL  ,
"Gets the size of this cockpit display"  ,
number,
number"  ,
"Width and height of the display or -  1,
-1 on error"   
)

Definition at line 5247 of file lua.cpp.

ADE_FUNC ( getOffset  ,
l_DisplayInfo  ,
NULL  ,
"Gets the offset of this cockpit display"  ,
number,
number"  ,
"x and y offset of the display or -  1,
-1 on error"   
)

Definition at line 5265 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_DisplayInfo  ,
NULL  ,
"Detects whether this handle is valid"  ,
"boolean"  ,
"true if valid false otherwise"   
)

Definition at line 5283 of file lua.cpp.

ADE_FUNC ( startRendering  ,
l_CockpitDisplay  ,
""  [boolean setClip=true],
"Starts rendering to this cockpit display. That means if you get a valid texture handle from this function then the rendering system is ready to do a render to texture. If setClip is true then the clipping region will be set to the region of the cockpit display.<br><b>Important:</b> You have to call stopRendering after you're done or this render target will never be released!"  ,
"texture"  ,
"texture handle that is being drawn to or invalid handle on error"   
)

Definition at line 5363 of file lua.cpp.

ADE_FUNC ( stopRendering  ,
l_CockpitDisplay  ,
NULL  ,
"Stops rendering to this cockpit display"  ,
"boolean"  ,
"true if  successfull,
false otherwise"   
)

Definition at line 5385 of file lua.cpp.

ADE_FUNC ( getBackgroundTexture  ,
l_CockpitDisplay  ,
NULL  ,
"Gets the background texture handle of this cockpit display"  ,
"texture"  ,
"texture handle or invalid handle if no background texture or an error happened"   
)

Definition at line 5401 of file lua.cpp.

ADE_FUNC ( getForegroundTexture  ,
l_CockpitDisplay  ,
NULL  ,
"Gets the foreground texture handle of this cockpit display<br>""<b>Important:</b> If you want to do render to texture then you have to use startRendering/stopRendering"  ,
"texture"  ,
"texture handle or invalid handle if no foreground texture or an error happened"   
)

Definition at line 5419 of file lua.cpp.

ADE_FUNC ( getSize  ,
l_CockpitDisplay  ,
NULL  ,
"Gets the size of this cockpit display"  ,
number,
number"  ,
"Width and height of the display or -  1,
-1 on error"   
)

Definition at line 5438 of file lua.cpp.

ADE_FUNC ( getOffset  ,
l_CockpitDisplay  ,
NULL  ,
"Gets the offset of this cockpit display"  ,
number,
number"  ,
"x and y offset of the display or -  1,
-1 on error"   
)

Definition at line 5456 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_CockpitDisplay  ,
NULL  ,
"Detects whether this handle is valid or not"  ,
"boolean"  ,
"true if  valid,
false otherwise"   
)

Definition at line 5474 of file lua.cpp.

ADE_FUNC ( __len  ,
l_CockpitDisplayInfos  ,
NULL  ,
"Number of cockpit displays for this ship class"  ,
"number"  ,
"number of cockpit displays or -1 on error"   
)

Definition at line 5521 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_CockpitDisplayInfos  ,
NULL  ,
"Detects whether this handle is valid"  ,
"boolean"  ,
"true if  valid,
false otehrwise"   
)

Definition at line 5605 of file lua.cpp.

ADE_FUNC ( __tostring  ,
l_Shipclass  ,
NULL  ,
"Ship class name ,
"string"  ,
"Ship class  name,
or an empty string if handle is invalid"   
)

Definition at line 5617 of file lua.cpp.

ADE_FUNC ( __eq  ,
l_Shipclass  ,
shipclass,
shipclass"  ,
"Checks if the two classes are equal"  ,
"boolean"  ,
"true if equal false otherwise"   
)

Definition at line 5630 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Shipclass  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 6014 of file lua.cpp.

ADE_FUNC ( isInTechroom  ,
l_Shipclass  ,
NULL  ,
"Gets whether or not the ship class is available in the techroom"  ,
"boolean"  ,
"Whether ship has been revealed in the  techroom,
false if handle is invalid"   
)

Definition at line 6026 of file lua.cpp.

ADE_FUNC ( renderTechModel  ,
l_Shipclass  ,
X1,
Y1  ,
X2  ,
Y2  ,
[Rotation %=0, Pitch %=0, Bank %=40, number Zoom=1.3] "  ,
"Draws ship model as if in techroom"  ,
"boolean"  ,
"Whether ship was rendered"   
)

Definition at line 6045 of file lua.cpp.

ADE_FUNC ( renderTechModel2  ,
l_Shipclass  ,
X1,
Y1  ,
X2  ,
Y2  ,
[orientation Orientation=nil, number Zoom=1.3] "  ,
"Draws ship model as if in techroom"  ,
"boolean"  ,
"Whether ship was rendered"   
)

Definition at line 6129 of file lua.cpp.

ADE_FUNC ( isModelLoaded  ,
l_Shipclass  ,
""  [boolean Load=false],
"Checks if the model used for this shipclass is loaded or not and optionally loads the  model,
which might be a slow operation."  ,
"boolean"  ,
"If the model is loaded or not"   
)

Definition at line 6201 of file lua.cpp.

ADE_FUNC ( getShipClassIndex  ,
l_Shipclass  ,
NULL  ,
"Gets the index valus of the ship class"  ,
"number"  ,
"index value of the ship class"   
)

Definition at line 6223 of file lua.cpp.

ADE_FUNC ( getDebrisRadius  ,
l_Debris  ,
NULL  ,
"The radius of this debris piece"  ,
"number"  ,
"The radius of this debris piece or -1 if invalid"   
)

Definition at line 6278 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Debris  ,
NULL  ,
"Return if this debris handle is valid"  ,
"boolean"  ,
"true if valid false otherwise"   
)

Definition at line 6300 of file lua.cpp.

ADE_FUNC ( __len  ,
l_WaypointList  ,
NULL  ,
"Number of waypoints in the list. ""Note that the value returned cannot be relied on for more than one frame."  ,
"number"  ,
"Number of waypoints in the  list,
or 0 if handle is invalid"   
)

Definition at line 6361 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_WaypointList  ,
NULL  ,
"Return if this waypointlist handle is valid"  ,
"boolean"  ,
"true if valid false otherwise"   
)

Definition at line 6391 of file lua.cpp.

ADE_FUNC ( getList  ,
l_Waypoint  ,
NULL  ,
"Returns the waypoint list"  ,
"waypointlist"  ,
"waypointlist handle or invalid handle if waypoint was invalid"   
)

Definition at line 6443 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_WeaponBank  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 6710 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_WeaponBankType  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 6846 of file lua.cpp.

ADE_FUNC ( __len  ,
l_WeaponBankType  ,
NULL  ,
"Number of weapons in the mounted bank"  ,
"number"  ,
"Number of bank  weapons,
or 0 if handle is invalid"   
)

Definition at line 6855 of file lua.cpp.

ADE_FUNC ( __tostring  ,
l_Subsystem  ,
NULL  ,
"Returns name of subsystem"  ,
"string"  ,
"Subsystem  name,
or empty string if handle is invalid"   
)

Definition at line 6892 of file lua.cpp.

ADE_FUNC ( getModelName  ,
l_Subsystem  ,
NULL  ,
"Returns the original name of the subsystem in the model file"  ,
"string"  ,
"name or empty string on error"   
)

Definition at line 7105 of file lua.cpp.

ADE_FUNC ( targetingOverride  ,
l_Subsystem  ,
"boolean"  ,
"If set to  true,
AI targeting for this turret is switched off.If set to  false,
the AI will take over again."  ,
"boolean"  ,
"Returns true if  successful,
false otherwise"   
)

Definition at line 7348 of file lua.cpp.

ADE_FUNC ( hasFired  ,
l_Subsystem  ,
NULL  ,
"Determine if a subsystem has fired"  ,
"boolean"  ,
"true if if  fired,
false if not  fired,
or nil if invalid.resets fired flag when called."   
)

Definition at line 7364 of file lua.cpp.

ADE_FUNC ( isTurret  ,
l_Subsystem  ,
NULL  ,
"Determines if this subsystem is a turret"  ,
"boolean"  ,
"true if subsystem is  turret,
false otherwise or nil on error"   
)

Definition at line 7380 of file lua.cpp.

ADE_FUNC ( isTargetInFOV  ,
l_Subsystem  ,
"object Target"  ,
"Determines if the object is in the turrets FOV"  ,
"boolean"  ,
"true if in  FOV,
false if  not,
nil on error or if subsystem is not a turret"   
)

Definition at line 7392 of file lua.cpp.

ADE_FUNC ( fireWeapon  ,
l_Subsystem  ,
""  [Turret weapon index=1, Flak range=100],
"Fires weapon on turret"  ,
NULL  ,
NULL   
)

Definition at line 7414 of file lua.cpp.

ADE_FUNC ( rotateTurret  ,
l_Subsystem  ,
"vector Pos[   
)

Definition at line 7444 of file lua.cpp.

ADE_FUNC ( getTurretHeading  ,
l_Subsystem  ,
NULL  ,
"Returns the turrets forward vector"  ,
"vector"  ,
"Returns a normalized version of the forward vector or null vector on error"   
)

Definition at line 7474 of file lua.cpp.

ADE_FUNC ( getFOVs  ,
l_Subsystem  ,
NULL  ,
"Returns current turrets FOVs"  ,
number,
number  ,
number"  ,
"Standard  FOV,
maximum barrel  elevation,
turret base fov."   
)

Definition at line 7494 of file lua.cpp.

ADE_FUNC ( getNextFiringPosition  ,
l_Subsystem  ,
NULL  ,
"Retrieves the next position and firing normal this turret will fire from. This function returns a world position"  ,
vector,
vector"  ,
"vector or null vector on error"   
)

Definition at line 7513 of file lua.cpp.

ADE_FUNC ( getTurretMatrix  ,
l_Subsystem  ,
NULL  ,
"Returns current subsystems turret matrix ,
"matrix"  ,
"Turret matrix."   
)

Definition at line 7529 of file lua.cpp.

ADE_FUNC ( getParent  ,
l_Subsystem  ,
NULL  ,
"The object parent of this  subsystem,
is of type ship ,
"object"  ,
"object handle or invalid handle on error"   
)

Definition at line 7546 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Subsystem  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 7559 of file lua.cpp.

ADE_FUNC ( remove  ,
l_Order  ,
NULL  ,
"Removes the given order from the ship's priority queue."  ,
"boolean"  ,
"True if order was successfully  removed,
otherwise false or nil."   
)

Definition at line 7629 of file lua.cpp.

ADE_FUNC ( getType  ,
l_Order  ,
NULL  ,
"Gets the type of the order."  ,
"enumeration"  ,
"The type of the order as one of the ORDER_* enumerations."   
)

Definition at line 7645 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Order  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 7917 of file lua.cpp.

ADE_FUNC ( __len  ,
l_ShipOrders  ,
NULL  ,
"Number of ship orders"  ,
"number"  ,
"Number of ship  orders,
or 0 if handle is invalid"   
)

Definition at line 7929 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_ShipOrders  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 7962 of file lua.cpp.

ADE_FUNC ( __len  ,
l_ShipTextures  ,
NULL  ,
"Number of textures on ship ,
"number"  ,
"Number of textures on  ship,
or 0 if handle is invalid"   
)

Definition at line 7976 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_ShipTextures  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 8064 of file lua.cpp.

ADE_FUNC ( __len  ,
l_CockpitDisplays  ,
NULL  ,
"Gets the number of cockpit displays for the player ship ,
"number"  ,
"number of displays or -1 on error"   
)

Definition at line 8110 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_CockpitDisplays  ,
NULL  ,
"Detects whether this handle is valid or not"  ,
"boolean"  ,
"true if  valid,
false otherwise"   
)

Definition at line 8187 of file lua.cpp.

ADE_FUNC ( getFilename  ,
l_SoundEntry  ,
NULL  ,
"Returns the filename of this sound ,
"string"  ,
"filename or empty string on error"   
)

Definition at line 8269 of file lua.cpp.

ADE_FUNC ( getDuration  ,
l_SoundEntry  ,
NULL  ,
"Gives the length of the sound in seconds."  ,
"number"  ,
"the  length,
or-1 on error"   
)

Definition at line 8282 of file lua.cpp.

ADE_FUNC ( get3DValues  ,
l_SoundEntry  ,
"vector Postion"  [, number radius=0.0],
"Computes the volume and the panning of the sound when it would be played from the specified position.<br>""If range is given then the volume will diminish when the listener is withing that distance to the source.<br>""The position of the listener is always the the current viewing position."  ,
number,
number"  ,
"The volume and the  panning,
in that  sequence,
or both-1 on error"   
)

Definition at line 8295 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_SoundEntry  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 8324 of file lua.cpp.

ADE_FUNC ( getRemainingTime  ,
l_Sound  ,
NULL  ,
"The remaining time of this sound handle"  ,
"number"  ,
"Remaining  time,
or-1 on error"   
)

Definition at line 8401 of file lua.cpp.

ADE_FUNC ( setVolume  ,
l_Sound  ,
"number"  ,
"Sets the volume of this sound instance"  ,
"boolean"  ,
"true if  succeeded,
false otherwise"   
)

Definition at line 8415 of file lua.cpp.

ADE_FUNC ( setPanning  ,
l_Sound  ,
"number"  ,
"Sets the panning of this sound. Argument ranges from -1 for left to 1 for right ,
"boolean"  ,
"true if  succeeded,
false otherwise"   
)

Definition at line 8432 of file lua.cpp.

ADE_FUNC ( setPosition  ,
l_Sound  ,
"number"  [, boolean=true],
"Sets the absolute position of the sound. If boolean argument is true then the value is given as a percentage<br>""This operation fails if there is no backing soundentry!"  ,
"boolean"  ,
"true if  successfull,
false otherwise"   
)

Definition at line 8450 of file lua.cpp.

ADE_FUNC ( rewind  ,
l_Sound  ,
"number"  ,
"Rewinds the sound by the given number of seconds<br>""This operation fails if there is no backing soundentry!"  ,
"boolean"  ,
"true if  succeeded,
false otherwise"   
)

Definition at line 8472 of file lua.cpp.

ADE_FUNC ( skip  ,
l_Sound  ,
"number"  ,
"Skips the given number of seconds of the sound<br>""This operation fails if there is no backing soundentry!"  ,
"boolean"  ,
"true if  succeeded,
false otherwise"   
)

Definition at line 8491 of file lua.cpp.

ADE_FUNC ( isPlaying  ,
l_Sound  ,
NULL  ,
"Specifies if this handle is currently playing"  ,
"boolean"  ,
"true if  playing,
false if otherwise"   
)

Definition at line 8510 of file lua.cpp.

ADE_FUNC ( stop  ,
l_Sound  ,
NULL  ,
"Stops the sound of this handle"  ,
"boolean"  ,
"true if  succeeded,
false otherwise"   
)

Definition at line 8522 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Sound  ,
NULL  ,
"Detects whether the whole handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 8536 of file lua.cpp.

ADE_FUNC ( isSoundValid  ,
l_Sound  ,
NULL  ,
"Checks if only the sound is  valid,
should be used for non soundentry sounds"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 8545 of file lua.cpp.

ADE_FUNC ( updatePosition  ,
l_Sound3D  ,
"vector Position"  [, number radius=0.0],
"Updates the given 3D sound with the specified position and an optional range value"  ,
"boolean"  ,
"true if  succeesed,
false otherwise"   
)

Definition at line 8557 of file lua.cpp.

ADE_FUNC ( play  ,
l_Soundfile  ,
"]"  [number volume=1.0[, number panning=0.0],
"Plays the sound ,
"sound"  ,
"A sound handle or invalid handle on error"   
)

Definition at line 8608 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Soundfile  ,
NULL  ,
"Checks if the soundfile handle is valid"  ,
"boolean"  ,
"true if  valid,
false otherwise"   
)

Definition at line 8631 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Persona  ,
NULL  ,
"Detect if the handle is valid"  ,
"boolean"  ,
"true if  valid,
false otherwise"   
)

Definition at line 8659 of file lua.cpp.

ADE_FUNC ( getMessage  ,
l_Message  ,
""  [boolean replaceVars=true],
"Gets the text of the message and optionally replaces SEXP variables with their respective values."  ,
"string"  ,
"The message or an empty string if handle is invalid"   
)

Definition at line 8769 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Message  ,
NULL  ,
"Checks if the message handle is valid"  ,
"boolean"  ,
"true if  valid,
false otherwise"   
)

Definition at line 8792 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Wing  ,
NULL  ,
"Gets the number of ships in the wing ,
"number"  ,
"Number of ships in  wing,
or 0 if invalid handle"   
)

Definition at line 8826 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Wing  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 8849 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Ship  ,
NULL  ,
"Number of subsystems on ship ,
"number"  ,
"Subsystem  number,
or 0 if handle is invalid"   
)

Definition at line 8894 of file lua.cpp.

ADE_FUNC ( kill  ,
l_Ship  ,
""  [object Killer],
"Kills the ship. Set \"Killer\" to the ship you are killing to self-destruct"  ,
"boolean"  ,
"True if  successful,
false or nil otherwise"   
)

Definition at line 9646 of file lua.cpp.

ADE_FUNC ( addShipEffect  ,
l_Ship  ,
"string  name,
int duration(in milliseconds)"  ,
"Activates an effect for this ship. Effect names are defined in Post_processing.  tbl,
and need to be implemented in the main shader.This functions analogous to the ship-effect sexp.NOTE:only one effect can be active at any  time,
adding new effects will override effects already in progress.\n ,
"boolean"  ,
"Returns true if the effect was successfully  added,
false otherwise"   
)

Definition at line 9669 of file lua.cpp.

ADE_FUNC ( hasShipExploded  ,
l_Ship  ,
NULL  ,
"Checks if the ship explosion event has already happened"  ,
"number"  ,
"Returns 1 if first explosion timestamp is  passed,
2 if second is  passed,
0 otherwise"   
)

Definition at line 9695 of file lua.cpp.

ADE_FUNC ( fireCountermeasure  ,
l_Ship  ,
NULL  ,
"Launches a countermeasure from the ship ,
"boolean"  ,
"Whether countermeasure was launched or not"   
)

Definition at line 9719 of file lua.cpp.

ADE_FUNC ( clearOrders  ,
l_Ship  ,
NULL  ,
"Clears a ship's orders list"  ,
"boolean"  ,
"True if  successful,
otherwise false or nil"   
)

Definition at line 9780 of file lua.cpp.

ADE_FUNC ( giveOrder  ,
l_Ship  ,
"enumeration  Order,
[object Target=nil, subsystem TargetSubsystem=nil, number Priority=1.0] "  ,
"Uses the goal code to execute orders"  ,
"boolean"  ,
"True if order was  given,
otherwise false or nil"   
)

Definition at line 9794 of file lua.cpp.

ADE_FUNC ( doManeuver  ,
l_Ship  ,
"number  Duration,
number  Heading,
number  Pitch,
number  Bank,
boolean Force  Rotation,
number  Vertical,
number  Horizontal,
number  Forward,
boolean Force Movement"  ,
"Sets ship maneuver over the defined time period"  ,
"boolean"  ,
"True if maneuver order was  given,
otherwise false or nil"   
)

Definition at line 10048 of file lua.cpp.

ADE_FUNC ( triggerAnimation  ,
l_Ship  ,
"string  Type,
[number Subtype, boolean Forwards] "  ,
"Triggers an animation. Type is the string name of the animation  type,
" "Subtype is the subtype  number,
such as weapon bank#  ,
and Forwards is boolean." "< br >< strong >IMPORTANT:Function is in testing and should not be used with official mod releases</strong >"  ,
"boolean"  ,
"True if  successful,
false or nil otherwise"   
)

Definition at line 10113 of file lua.cpp.

ADE_FUNC ( warpIn  ,
l_Ship  ,
NULL  ,
"Warps ship in ,
"boolean"  ,
"True if  successful,
or nil if ship handle is invalid"   
)

Definition at line 10143 of file lua.cpp.

ADE_FUNC ( warpOut  ,
l_Ship  ,
NULL  ,
"Warps ship out"  ,
"boolean"  ,
"True if  successful,
or nil if ship handle is invalid"   
)

Definition at line 10157 of file lua.cpp.

ADE_FUNC ( canWarp  ,
l_Ship  ,
NULL  ,
"Checks whether ship has a working subspace drive and is allowed to use it"  ,
"boolean"  ,
"True if  successful,
or nil if ship handle is invalid"   
)

Definition at line 10171 of file lua.cpp.

ADE_FUNC ( isWarpingIn  ,
l_Ship  ,
NULL  ,
"Checks if ship is warping in ,
"boolean"  ,
"True if the ship is warping  in,
false or nil otherwise"   
)

Definition at line 10189 of file lua.cpp.

ADE_FUNC ( getEMP  ,
l_Ship  ,
NULL  ,
"Returns the current emp effect strength acting on the object ,
"number"  ,
"Current EMP effect strength or NIL if object is invalid"   
)

Definition at line 10206 of file lua.cpp.

ADE_FUNC ( getTimeUntilExplosion  ,
l_Ship  ,
NULL  ,
"Returns the time in seconds until the ship explodes"  ,
"number"  ,
"Time until explosion or -  1,
if invalid handle or ship isn't exploding"   
)

Definition at line 10225 of file lua.cpp.

ADE_FUNC ( getCallsign  ,
l_Ship  ,
NULL  ,
"Gets the callsign of the ship in the current mission ,
"string"  ,
"The callsign or an empty string if the ship doesn't have a callsign or an error occurs"   
)

Definition at line 10248 of file lua.cpp.

ADE_FUNC ( getAltClassName  ,
l_Ship  ,
NULL  ,
"Gets the alternate class name of the ship ,
"string"  ,
"The alternate class name or an empty string if the ship doesn't have such a thing or an error occurs"   
)

Definition at line 10275 of file lua.cpp.

ADE_FUNC ( getMaximumSpeed  ,
l_Ship  ,
""  [number energy=0.333],
"Gets the maximum speed of the ship with the given energy on the engines"  ,
"number"  ,
"The maximum speed or -1 on error"   
)

Definition at line 10302 of file lua.cpp.

ADE_FUNC ( EtsSetIndexes  ,
l_Ship  ,
"number Engine  Index,
number Shield  Index,
number Weapon Index"  ,
"Sets ships ETS systems to specified values ,
"boolean"  ,
"True if  successful,
false if target ships ETS was  missing,
or only has one system"   
)

Definition at line 10326 of file lua.cpp.

ADE_FUNC ( getWing  ,
l_Ship  ,
NULL  ,
"Returns the ship's wing ,
"wing"  ,
"Wing  handle,
or invalid wing handle if ship is not part of a wing  
)

Definition at line 10353 of file lua.cpp.

ADE_FUNC ( isArmed  ,
l_Weapon  ,
""  [boolean Hit target],
"Checks if the weapon is armed."  ,
"boolean"  ,
"boolean value of the weapon arming status"   
)

Definition at line 10650 of file lua.cpp.

ADE_FUNC ( getCollisionInformation  ,
l_Weapon  ,
NULL  ,
"Returns the collision information for this weapon ,
"collision info"  ,
"The collision information or invalid handle if none"   
)

Definition at line 10668 of file lua.cpp.

ADE_FUNC ( getCollisionCount  ,
l_Beam  ,
NULL  ,
"Get the number of collisions in frame."  ,
"number"  ,
"Number of beam collisions"   
)

Definition at line 10891 of file lua.cpp.

ADE_FUNC ( getCollisionPosition  ,
l_Beam  ,
"number"  ,
"Get the position of the defined collision."  ,
"vector"  ,
"World vector"   
)

Definition at line 10906 of file lua.cpp.

ADE_FUNC ( getCollisionInformation  ,
l_Beam  ,
"number"  ,
"Get the collision information of the specified collision"  ,
"collision info"  ,
"handle to information or invalid handle on error"   
)

Definition at line 10928 of file lua.cpp.

ADE_FUNC ( getCollisionObject  ,
l_Beam  ,
"number"  ,
"Get the target of the defined collision."  ,
"object"  ,
"Object the beam collided with"   
)

Definition at line 10950 of file lua.cpp.

ADE_FUNC ( isExitCollision  ,
l_Beam  ,
"number"  ,
"Checks if the defined collision was exit collision."  ,
"boolean"  ,
"True if the collision was exit  collision,
false if  entry,
nil otherwise"   
)

Definition at line 10972 of file lua.cpp.

ADE_FUNC ( getStartDirectionInfo  ,
l_Beam  ,
NULL  ,
"Gets the start information about the direction. The vector is a normalized vector from LastStart showing the start direction of a slashing beam ,
"vector"  ,
"The start direction or null vector if invalid"   
)

Definition at line 10997 of file lua.cpp.

ADE_FUNC ( getEndDirectionInfo  ,
l_Beam  ,
NULL  ,
"Gets the end information about the direction. The vector is a normalized vector from LastStart showing the end direction of a slashing beam ,
"vector"  ,
"The start direction or null vector if invalid"   
)

Definition at line 11014 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Player  ,
NULL  ,
"Detects whether handle is valid"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 11034 of file lua.cpp.

ADE_FUNC ( getName  ,
l_Player  ,
NULL  ,
"Gets current player name ,
"string"  ,
"Player  name,
or empty string if handle is invalid"   
)

Definition at line 11046 of file lua.cpp.

ADE_FUNC ( getCampaignFilename  ,
l_Player  ,
NULL  ,
"Gets current player campaign filename ,
"string"  ,
"Campaign  name,
or empty string if handle is invalid"   
)

Definition at line 11058 of file lua.cpp.

ADE_FUNC ( getImageFilename  ,
l_Player  ,
NULL  ,
"Gets current player image filename ,
"string"  ,
"Player image  filename,
or empty string if handle is invalid"   
)

Definition at line 11070 of file lua.cpp.

ADE_FUNC ( getMainHallName  ,
l_Player  ,
NULL  ,
"Gets player's current main hall name ,
"string"  ,
"Main hall  name,
or name of first mainhall in campaign if something goes wrong"   
)

Definition at line 11082 of file lua.cpp.

ADE_FUNC ( getMainHallIndex  ,
l_Player  ,
NULL  ,
"Gets player's current main hall number"  ,
"number"  ,
"Main hall  index,
or index of first mainhall in campaign if something goes wrong"   
)

Definition at line 11096 of file lua.cpp.

ADE_FUNC ( getSquadronName  ,
l_Player  ,
NULL  ,
"Gets current player squad name ,
"string"  ,
"Squadron  name,
or empty string if handle is invalid"   
)

Definition at line 11109 of file lua.cpp.

ADE_FUNC ( getMultiSquadronName  ,
l_Player  ,
NULL  ,
"Gets current player multi squad name ,
"string"  ,
"Squadron  name,
or empty string if handle is invalid"   
)

Definition at line 11121 of file lua.cpp.

ADE_FUNC ( __tostring  ,
l_Camera  ,
NULL  ,
"Camera name ,
"string"  ,
"Camera  name,
or an empty string if handle is invalid"   
)

Definition at line 11146 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Camera  ,
NULL  ,
"True if  valid,
false or nil if not"  ,
"boolean"  ,
"true if  valid,
false if handle is  invalid,
nil if a syntax/type error occurs"   
)

Definition at line 11158 of file lua.cpp.

ADE_FUNC ( setFOV  ,
l_Camera  ,
""  [number FOV, number Zoom Time, number Zoom Acceleration Time, number Zoom deceleration Time],
"Sets camera FOV""<br>FOV is the final field of  view,
in  radians,
of the camera." "< br >Zoom Time is the total time to take zooming in or out." "< br >Acceleration Time is the total time it should take the camera to get up to full zoom speed." "< br >Deceleration Time is the total time it should take the camera to slow down from full zoom speed."  ,
"boolean"  ,
"true if  successful,
false or nil otherwise"   
)

Definition at line 11352 of file lua.cpp.

ADE_FUNC ( setOrientation  ,
l_Camera  ,
""  [world orientation Orientation, number Rotation Time, number Acceleration Time, number Deceleration time],
"Sets camera orientation and velocity data.""<br>Orientation is the final orientation for the  camera,
after it has finished moving.If not  specified,
the camera will simply stop at its current orientation." "< br >Rotation time(seconds) is how long  total,
including  acceleration,
the camera should take to rotate.If it is not  specified,
the camera will jump to the specified orientation." "< br >Acceleration time(seconds) is how long it should take the camera to get 'up to speed'.If not  specified,
the camera will instantly start moving." "< br >Deceleration time(seconds) is how long it should take the camera to slow down.If not  specified,
the camera will instantly stop moving."  ,
"boolean"  ,
"true if  successful,
false or nil otherwise"   
)

Definition at line 11376 of file lua.cpp.

ADE_FUNC ( setPosition  ,
l_Camera  ,
""  [wvector Position, number Translation Time, number Acceleration Time, number Deceleration Time],
"Sets camera position and velocity data.""<br>Position is the final position for the camera. If not  specified,
the camera will simply stop at its current position." "< br >Translation time(seconds) is how long  total,
including  acceleration,
the camera should take to move.If it is not  specified,
the camera will jump to the specified position." "< br >Acceleration time(seconds) is how long it should take the camera to get 'up to speed'.If not  specified,
the camera will instantly start moving." "< br >Deceleration time(seconds) is how long it should take the camera to slow down.If not  specified,
the camera will instantly stop moving."  ,
"boolean"  ,
"true if  successful,
false or nil otherwise"   
)

Definition at line 11409 of file lua.cpp.

ADE_FUNC ( clearLuaButtonInfo  ,
l_Control_Info  ,
NULL  ,
"Clears the lua button control info"  ,
NULL  ,
NULL   
)

Definition at line 11586 of file lua.cpp.

ADE_FUNC ( getButtonInfo  ,
l_Control_Info  ,
NULL  ,
"Access the four bitfields containing the button info"  ,
number,
number  ,
number  ,
number"  ,
"Four bitfields"   
)

Definition at line 11593 of file lua.cpp.

ADE_FUNC ( accessButtonInfo  ,
l_Control_Info  ,
number,
number  ,
number  ,
number"  ,
"Access the four bitfields containing the button info"  ,
number,
number  ,
number  ,
number"  ,
"Four bitfields"   
)

Definition at line 11604 of file lua.cpp.

ADE_FUNC ( useButtonControl  ,
l_Control_Info  ,
number,
string ,
"Adds the defined button control to lua button control  data,
if number is-1 it tries to use the string ,
NULL  ,
NULL   
)

Definition at line 11626 of file lua.cpp.

ADE_FUNC ( getButtonControlName  ,
l_Control_Info  ,
"number"  ,
"Gives the name of the command corresponding with the given number"  ,
"string"  ,
"Name of the command"   
)

Definition at line 11660 of file lua.cpp.

ADE_FUNC ( getButtonControlNumber  ,
l_Control_Info  ,
"string"  ,
"Gives the number of the command corresponding with the given string ,
"number"  ,
"Number of the command"   
)

Definition at line 11673 of file lua.cpp.

ADE_FUNC ( pollAllButtons  ,
l_Control_Info  ,
NULL  ,
"Access the four bitfields containing the button info"  ,
number,
number  ,
number  ,
number"  ,
"Four bitfields"   
)

Definition at line 11711 of file lua.cpp.

ADE_FUNC ( isValid  ,
l_Particle  ,
NULL  ,
"Detects whether this handle is valid"  ,
"boolean"  ,
"true if valid false if not"   
)

Definition at line 11916 of file lua.cpp.

ADE_FUNC ( getSoundentry  ,
l_Audio  ,
"string/number"  ,
"Return a sound entry matching the specified index or name. If you are using a number then the first valid index is 1"  ,
"soundentry"  ,
"soundentry or invalid handle on error"   
)

Definition at line 11931 of file lua.cpp.

ADE_FUNC ( loadSoundfile  ,
l_Audio  ,
"string filename ,
"Loads the specified sound file"  ,
"soundfile"  ,
"A soundfile handle"   
)

Definition at line 11965 of file lua.cpp.

ADE_FUNC ( playSound  ,
l_Audio  ,
"soundentry"  ,
"Plays the specified sound entry handle"  ,
"sound"  ,
"A handle to the playing sound  
)

Definition at line 11979 of file lua.cpp.

ADE_FUNC ( playLoopingSound  ,
l_Audio  ,
"soundentry"  ,
"Plays the specified sound as a looping sound ,
"sound"  ,
"A handle to the playing sound or invalid handle if playback failed"   
)

Definition at line 12001 of file lua.cpp.

ADE_FUNC ( play3DSound  ,
l_Audio  ,
"soundentry]"  [, vector source[, vector listener],
"Plays the specified sound entry handle. Source if by default  0,
,
0 and listener is by default the current viewposition"  ,
"3Dsound"  ,
"A handle to the playing sound  
)

Definition at line 12023 of file lua.cpp.

ADE_FUNC ( playGameSound  ,
l_Audio  ,
"Sound  index,
[Panning (-1.0 left to 1.0 right), Volume %, Priority 0-3, Voice Message?] "  ,
"Plays a sound from #Game Sounds in sounds.tbl. A priority of 0 indicates that the song must play; 1-3 will specify the maximum number of that sound that can be played"  ,
"boolean"  ,
"True if sound was  played,
false if not(Replaced with a sound instance object in the future)"   
)

Definition at line 12047 of file lua.cpp.

ADE_FUNC ( playInterfaceSound  ,
l_Audio  ,
"Sound index ,
"Plays a sound from #Interface Sounds in sounds.tbl"  ,
"boolean"  ,
"True if sound was  played,
false if not"   
)

Definition at line 12077 of file lua.cpp.

ADE_FUNC ( playMusic  ,
l_Audio  ,
"string  Filename,
[float volume = 1.0, bool looping = true] "  ,
"Plays a music file using FS2Open's builtin music system. Volume is currently  ignored,
uses players music volume setting.Files passed to this function are looped by default."  ,
"number"  ,
"Audiohandle of the created  audiostream,
or-1 on failure"   
)

Definition at line 12095 of file lua.cpp.

ADE_FUNC ( stopMusic  ,
l_Audio  ,
"int  audiohandle,
[string 'briefing|credits|mainhall'] "  ,
"Stops a playing music  file,
provided audiohandle is valid.If the 3rd arg is set to one of  briefing,
credits  ,
mainhall then that music will be stopped despite the audiohandle given."  ,
NULL  ,
NULL   
)

Definition at line 12114 of file lua.cpp.

ADE_FUNC ( pauseMusic  ,
l_Audio  ,
"int  audiohandle,
bool pause"  ,
"Pauses or unpauses a playing music  file,
provided audiohandle is valid.The boolean argument should be true to pause and false to unpause.If the audiohandle is-  1,
*all *audio streams are paused or unpaused."  ,
NULL  ,
NULL   
)

Definition at line 12143 of file lua.cpp.

ADE_FUNC ( print  ,
l_Base  ,
"string Message"  ,
"Prints a string ,
NULL  ,
NULL   
)

Definition at line 12173 of file lua.cpp.

ADE_FUNC ( error  ,
l_Base  ,
"string Message"  ,
"Displays a FreeSpace error message with the string provided"  ,
NULL  ,
NULL   
)

Definition at line 12187 of file lua.cpp.

ADE_FUNC ( createOrientation  ,
l_Base  ,
""  [p/r1c1, b/r1c2, h/r1c3, r2c1, r2c2, r2c3, r3c1, r3c2, r3c3],
"Given  0,
,
or 9  arguments,
creates an orientation object with that orientation."  ,
"orientation"  ,
"New orientation  object,
or null orientation on failure"   
)

Definition at line 12194 of file lua.cpp.

ADE_FUNC ( createVector  ,
l_Base  ,
""  [x, y, z],
"Creates a vector object ,
"vector"  ,
"Vector object  
)

Definition at line 12215 of file lua.cpp.

ADE_FUNC ( getFrametime  ,
l_Base  ,
""  [Do not adjust for time compression(Boolean)],
"Gets how long this frame is calculated to take. Use it to for  animations,
physics  ,
etc to make incremental changes."  ,
"number"  ,
"Frame time (seconds)"   
)

Definition at line 12228 of file lua.cpp.

ADE_FUNC ( getCurrentMPStatus  ,
l_Base  ,
"NIL"  ,
"Gets this computers current MP status"  ,
"string"  ,
"Current MP status"   
)

Definition at line 12247 of file lua.cpp.

ADE_FUNC ( getCurrentPlayer  ,
l_Base  ,
NULL  ,
"Gets a handle of the currently used player.<br><b>Note:</b> If there is no current player then the first player will be  returned,
check the game state to make sure you have a valid player handle."  ,
"player"  ,
"Player handle"   
)

Definition at line 12264 of file lua.cpp.

ADE_FUNC ( setControlMode  ,
l_Base  ,
"NIL or enumeration LE_*_CONTROL"  ,
"Sets the current control mode for the game."  ,
"string"  ,
"Current control mode  
)

Definition at line 12269 of file lua.cpp.

ADE_FUNC ( setButtonControlMode  ,
l_Base  ,
"NIL or enumeration LE_*_BUTTON_CONTROL"  ,
"Sets the current control mode for the game."  ,
"string"  ,
"Current control mode  
)

Definition at line 12305 of file lua.cpp.

ADE_FUNC ( getControlInfo  ,
l_Base  ,
NULL  ,
"Gets the control info handle."  ,
"control info"  ,
"control info handle"   
)

Definition at line 12341 of file lua.cpp.

ADE_FUNC ( setTips  ,
l_Base  ,
"True or false ,
"Sets whether to display tips of the day the next time the current pilot enters the mainhall."  ,
NULL  ,
NULL   
)

Definition at line 12346 of file lua.cpp.

ADE_FUNC ( getGameDifficulty  ,
l_Base  ,
NULL  ,
"Returns the difficulty level from 1-  5,
1 being the  lowest,
(Very Easy) and 5 being the highest(Insane)"  ,
"integer"  ,
"Difficulty level as integer"   
)

Definition at line 12363 of file lua.cpp.

ADE_FUNC ( postGameEvent  ,
l_Base  ,
"gameevent Event"  ,
"Sets current game event. Note that you can crash FreeSpace 2 by posting an event at an improper  time,
so test extensively if you use it."  ,
"boolean"  ,
"True if event was  posted,
false if passed event was invalid"   
)

Definition at line 12368 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Base_Events  ,
NULL  ,
"Number of events"  ,
"number"  ,
"Number of events"   
)

Definition at line 12411 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Base_States  ,
NULL  ,
"Number of states"  ,
"number"  ,
"Number of states"   
)

Definition at line 12441 of file lua.cpp.

ADE_FUNC ( deleteFile  ,
l_CFile  ,
"string  Filename,
string Path"  ,
"Deletes given file. Path must be specified. Use a slash for the root directory."  ,
"boolean"  ,
"True if  deleted,
false  
)

Definition at line 12494 of file lua.cpp.

ADE_FUNC ( fileExists  ,
l_CFile  ,
"string  Filename,
[string Path = \"\", boolean CheckVPs = false] "  ,
"Checks if a file exists. Use a blank string for path for any  directory,
or a slash for the root directory."  ,
"boolean"  ,
"True if file  exists,
false or nil otherwise"   
)

Definition at line 12511 of file lua.cpp.

ADE_FUNC ( openFile  ,
l_CFile  ,
"string  Filename,
[string Mode=\"r\", string Path = \"\"] "  ,
"Opens a file. 'Mode' uses standard C fopen arguments. Use a blank string for path for any  directory,
or a slash for the root directory." "Be EXTREMELY CAREFUL when using this  function,
as you may PERMANENTLY delete any file by accident"  ,
"file"  ,
"File  handle,
or invalid file handle if the specified file couldn't be opened"   
)

Definition at line 12532 of file lua.cpp.

ADE_FUNC ( openTempFile  ,
l_CFile  ,
NULL  ,
"Opens a temp file that is automatically deleted when closed"  ,
"file"  ,
"File  handle,
or invalid file handle if tempfile couldn't be created"   
)

Definition at line 12561 of file lua.cpp.

ADE_FUNC ( renameFile  ,
l_CFile  ,
"string  CurrentFilename,
string  NewFilename,
string Path"  ,
"Renames given file. Path must be specified. Use a slash for the root directory."  ,
"boolean"  ,
"True if file was  renamed,
otherwise false  
)

Definition at line 12566 of file lua.cpp.

ADE_FUNC ( getMouseX  ,
l_Mouse  ,
NULL  ,
"Gets Mouse X pos ,
"number"  ,
"Mouse x  position,
or 0 if mouse is not initialized yet"   
)

Definition at line 12589 of file lua.cpp.

ADE_FUNC ( getMouseY  ,
l_Mouse  ,
NULL  ,
"Gets Mouse Y pos ,
"number"  ,
"Mouse y  position,
or 0 if mouse is not initialized yet"   
)

Definition at line 12601 of file lua.cpp.

ADE_FUNC ( isMouseButtonDown  ,
l_Mouse  ,
"{MOUSE_*_BUTTON enumeration}  ,
[..., ...] "  ,
"Returns whether the specified mouse buttons are up or down"  ,
"boolean"  ,
"Whether specified mouse buttons are  down,
or false if mouse is not initialized yet"   
)

Definition at line 12613 of file lua.cpp.

ADE_FUNC ( setCursorHidden  ,
l_Mouse  ,
"True to hide  mouse,
false to show it"  ,
"Shows or hides mouse cursor"  ,
NULL  ,
NULL   
)

Definition at line 12667 of file lua.cpp.

ADE_FUNC ( getMouseSensitivity  ,
l_Mouse  ,
NULL  ,
"Gets mouse sensitivity setting"  ,
"number"  ,
"Mouse sensitivity in range of 0-9"   
)

Definition at line 12733 of file lua.cpp.

ADE_FUNC ( getJoySensitivity  ,
l_Mouse  ,
NULL  ,
"Gets joystick sensitivity setting"  ,
"number"  ,
"Joystick sensitivity in range of 0-9"   
)

Definition at line 12738 of file lua.cpp.

ADE_FUNC ( getJoyDeadzone  ,
l_Mouse  ,
NULL  ,
"Gets joystick deadzone setting"  ,
"number"  ,
"Joystick deadzone in range of 0-9"   
)

Definition at line 12743 of file lua.cpp.

ADE_FUNC ( updateTrackIR  ,
l_Mouse  ,
NULL  ,
"Updates Tracking Data. Call before using get functions"  ,
"boolean"  ,
"Checks if trackir is available and updates  variables,
returns true if  successful,
otherwise false  
)

Definition at line 12749 of file lua.cpp.

ADE_FUNC ( getTrackIRPitch  ,
l_Mouse  ,
NULL  ,
"Gets pitch axis from last update"  ,
"number"  ,
"Pitch value -1 to  1,
or 0 on failure"   
)

Definition at line 12760 of file lua.cpp.

ADE_FUNC ( getTrackIRYaw  ,
l_Mouse  ,
NULL  ,
"Gets yaw axis from last update"  ,
"number"  ,
"Yaw value -1 to  1,
or 0 on failure"   
)

Definition at line 12768 of file lua.cpp.

ADE_FUNC ( getTrackIRRoll  ,
l_Mouse  ,
NULL  ,
"Gets roll axis from last update"  ,
"number"  ,
"Roll value -1 to  1,
or 0 on failure"   
)

Definition at line 12776 of file lua.cpp.

ADE_FUNC ( getTrackIRX  ,
l_Mouse  ,
NULL  ,
"Gets x position from last update"  ,
"number"  ,
"X value -1 to  1,
or 0 on failure"   
)

Definition at line 12784 of file lua.cpp.

ADE_FUNC ( getTrackIRY  ,
l_Mouse  ,
NULL  ,
"Gets y position from last update"  ,
"number"  ,
"Y value -1 to  1,
or 0 on failure"   
)

Definition at line 12792 of file lua.cpp.

ADE_FUNC ( getTrackIRZ  ,
l_Mouse  ,
NULL  ,
"Gets z position from last update"  ,
"number"  ,
"Z value -1 to  1,
or 0 on failure"   
)

Definition at line 12800 of file lua.cpp.

ADE_FUNC ( getHUDGaugeHandle  ,
l_HUD  ,
"string Name"  ,
"Returns a handle to a specified HUD gauge"  ,
"HudGauge"  ,
"HUD Gauge  handle,
or nil if invalid"   
)

Definition at line 12884 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Graphics_Cameras  ,
NULL  ,
"Gets number of cameras"  ,
"number"  ,
"Number of cameras"   
)

Definition at line 12926 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Graphics_Fonts  ,
NULL  ,
"Number of loaded fonts"  ,
"number"  ,
"Number of loaded fonts"   
)

Definition at line 12934 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Graphics_Posteffects  ,
NULL  ,
"Gets the number or available post processing effects"  ,
"number"  ,
"number of post processing effects or 0 on error"   
)

Definition at line 13003 of file lua.cpp.

ADE_FUNC ( setPostEffect  ,
l_Graphics  ,
"string  name,
[number value=0] "  ,
"Sets the intensity of the specified post processing effect"  ,
"boolean"  ,
"true when  successful,
false otherwise"   
)

Definition at line 13012 of file lua.cpp.

ADE_FUNC ( resetPostEffects  ,
l_Graphics  ,
NULL  ,
"Resets all post effects to their default values ,
"boolean"  ,
"true if  successful,
false otherwise"   
)

Definition at line 13028 of file lua.cpp.

ADE_FUNC ( clearScreen  ,
l_Graphics  ,
""  [integer red, number green, number blue, number alpha],
"Clears the screen to  black,
or the color specified."  ,
NULL  ,
NULL   
)

Definition at line 13089 of file lua.cpp.

ADE_FUNC ( createCamera  ,
l_Graphics  ,
"string  Name,
[wvector Position, orientation Orientation] "  ,
"Creates a new camera using the specified position and orientation (World)"  ,
"camera"  ,
"Camera  handle,
or invalid camera handle if camera couldn't be created"   
)

Definition at line 13115 of file lua.cpp.

ADE_FUNC ( isMenuStretched  ,
l_Graphics  ,
NULL  ,
"Returns whether the standard interface is stretched"  ,
"boolean"  ,
"True if  stretched,
false if aspect ratio is maintained"   
)

Definition at line 13136 of file lua.cpp.

ADE_FUNC ( getScreenWidth  ,
l_Graphics  ,
NULL  ,
"Gets screen width ,
"number"  ,
"Width in  pixels,
or 0 if graphics are not initialized yet"   
)

Definition at line 13144 of file lua.cpp.

ADE_FUNC ( getScreenHeight  ,
l_Graphics  ,
NULL  ,
"Gets screen height ,
"number"  ,
"Height in  pixels,
or 0 if graphics are not initialized yet"   
)

Definition at line 13152 of file lua.cpp.

ADE_FUNC ( getCenterOffsetX  ,
l_Graphics  ,
NULL  ,
"Gets X offset of center monitor ,
"number"  ,
"X offset of center monitor in pixels  
)

Definition at line 13176 of file lua.cpp.

ADE_FUNC ( getCenterOffsetY  ,
l_Graphics  ,
NULL  ,
"Gets Y offset of center monitor ,
"number"  ,
"Y offset of center monitor in pixels  
)

Definition at line 13184 of file lua.cpp.

ADE_FUNC ( getCurrentCamera  ,
l_Graphics  ,
""  [boolean],
"Gets the current camera  handle,
if argument is< i >true</i > then it will also return the main camera when no custom camera is in use"  ,
"camera"  ,
"camera handle or invalid handle on error"   
)

Definition at line 13192 of file lua.cpp.

ADE_FUNC ( getVectorFromCoords  ,
l_Graphics  ,
""  [number X=center, number Y=center, number Depth, boolean normalize=false],
"Returns a vector through screen coordinates x and y. ""If depth is  specified,
vector is extended to Depth units into space" "If normalize is  true,
vector will be normalized."  ,
"vector"  ,
Vector,
or zero vector on failure"   
)

Definition at line 13208 of file lua.cpp.

ADE_FUNC ( setTarget  ,
l_Graphics  ,
""  [texture Texture],
"If texture is  specified,
sets current rendering surface to a texture." "  Otherwise,
sets rendering surface back to screen."  ,
"boolean"  ,
"True if  successful,
false otherwise"   
)

Definition at line 13269 of file lua.cpp.

ADE_FUNC ( setCamera  ,
l_Graphics  ,
""  [camera handle Camera],
"Sets current  camera,
or resets camera if none specified"  ,
"boolean"  ,
"true if  successful,
false or nil otherwise"   
)

Definition at line 13284 of file lua.cpp.

ADE_FUNC ( setColor  ,
l_Graphics  ,
"integer  Red,
number  Green,
number  Blue,
[integer Alpha] "  ,
"Sets 2D drawing color; each color number should be from 0 (darkest) to 255 (brightest)"  ,
NULL  ,
NULL   
)

Definition at line 13301 of file lua.cpp.

ADE_FUNC ( setLineWidth  ,
l_Graphics  ,
""  [number width=1.0],
"Sets the line width for lines. This call might fail if the specified width is not supported by the graphics implementation. Then the width will be the nearest supported value."  ,
"boolean"  ,
"true if  succeeded,
false otherwise"   
)

Definition at line 13318 of file lua.cpp.

ADE_FUNC ( drawCircle  ,
l_Graphics  ,
"number  Radius,
number  X,
number  Y,
[boolean Filled=true] "  ,
"Draws a circle"  ,
NULL  ,
NULL   
)

Definition at line 13337 of file lua.cpp.

ADE_FUNC ( drawArc  ,
l_Graphics  ,
"number  Radius,
number  X,
number  Y,
number  StartAngle,
number  EndAngle,
[boolean Filled=true] "  ,
"Draws an arc"  ,
NULL  ,
NULL   
)

Definition at line 13358 of file lua.cpp.

ADE_FUNC ( drawCurve  ,
l_Graphics  ,
"number  X,
number  Y,
number Radius"  ,
"Draws a curve"  ,
NULL  ,
NULL   
)

Definition at line 13376 of file lua.cpp.

ADE_FUNC ( drawGradientLine  ,
l_Graphics  ,
"number  X1,
number  Y1,
number  X2,
number Y2"  ,
"Draws a line from (x1,y1) to (x2,y2) with the CurrentColor that steadily fades out"  ,
NULL  ,
NULL   
)

Definition at line 13393 of file lua.cpp.

ADE_FUNC ( drawLine  ,
l_Graphics  ,
"number  X1,
number  Y1,
number  X2,
number Y2"  ,
"Draws a line from (x1,y1) to (x2,y2) with CurrentColor"  ,
NULL  ,
NULL   
)

Definition at line 13408 of file lua.cpp.

ADE_FUNC ( drawPixel  ,
l_Graphics  ,
"number  X,
number Y"  ,
"Sets pixel to CurrentColor"  ,
NULL  ,
NULL   
)

Definition at line 13423 of file lua.cpp.

ADE_FUNC ( drawPolygon  ,
l_Graphics  ,
"texture  Texture,
[vector Position={0,0,0}, orientation Orientation=nil, number Width=1.0, number Height=1.0] "  ,
"Draws a polygon. May not work properly in hooks other than On Object Render."  ,
NULL  ,
NULL   
)

Definition at line 13438 of file lua.cpp.

ADE_FUNC ( drawRectangle  ,
l_Graphics  ,
"number  X1,
number  Y1,
number  X2,
number  Y2,
[boolean Filled=true] "  ,
"Draws a rectangle with CurrentColor"  ,
NULL  ,
NULL   
)

Definition at line 13469 of file lua.cpp.

ADE_FUNC ( drawSphere  ,
l_Graphics  ,
""  [number Radius=1.0, vector Position],
"Draws a sphere with radius Radius at world vector Position. May not work properly in hooks other than On Object Render."  ,
"boolean"  ,
"True if  successful,
false or nil otherwise"   
)

Definition at line 13496 of file lua.cpp.

ADE_FUNC ( drawModel  ,
l_Graphics  ,
model,
position  ,
orientation"  ,
"Draws the given model with the specified position and orientation - Use with extreme  care,
may not work properly in all scripting hooks."  ,
"int"  ,
"Zero if  successful,
otherwise an integer error code  
)

Definition at line 13543 of file lua.cpp.

ADE_FUNC ( drawModelOOR  ,
l_Graphics  ,
"model  Model,
vector  Position,
matrix  Orientation,
[integer Flags] "  ,
"Draws the given model with the specified position and orientation - Use with extreme  care,
designed to operate properly only in On Object Render hooks."  ,
"int"  ,
"Zero if  successful,
otherwise an integer error code  
)

Definition at line 13609 of file lua.cpp.

ADE_FUNC ( drawTargetingBrackets  ,
l_Graphics  ,
"object  Object,
[boolean draw=true, int padding=5] "  ,
"Gets the edge positions of targeting brackets for the specified object. The brackets will only be drawn if draw is true or the default value of draw is used. Brackets are drawn with the current color. The brackets will have a padding (distance from the actual bounding box); the default value (used elsewhere in FS2) is 5."  ,
number,
number  ,
number  ,
number"  ,
Left,
top  ,
right  ,
and bottom positions of the  brackets,
or nil if invalid"   
)

Definition at line 13646 of file lua.cpp.

ADE_FUNC ( drawSubsystemTargetingBrackets  ,
l_Graphics  ,
"subsystem  subsys,
[boolean draw=true, boolean setColor=false] "  ,
"Gets the edge position of the targeting brackets drawn for a subsystem as if they were drawn on the HUD. Only actually draws the brackets if <i>draw</i> is  true,
optionally sets the color the as if it was drawn on the HUD"  ,
number,
number  ,
number  ,
number"  ,
Left,
top  ,
right  ,
and bottom positions of the  brackets,
or nil if invalid or off-screen  
)

Definition at line 13744 of file lua.cpp.

ADE_FUNC ( drawOffscreenIndicator  ,
l_Graphics  ,
"object  Object,
[boolean draw=true, boolean setColor=false] "  ,
"Draws an off-screen indicator for the given object. The indicator will not be drawn if  draw = false,
but the coordinates will be returned in either case.The indicator will be drawn using the current color if  setColor = true and using the IFF color of the object if setColor=false.", "number,
number"  ,
"Coordinates of the indicator   at the very edge of the screen,
or nil if object is on-screen  
)

Definition at line 13791 of file lua.cpp.

ADE_FUNC ( drawString  ,
l_Graphics  ,
"string  Message,
[number X1, number Y1, number X2, number Y2] "  ,
"Draws a string. Use x1/y1 to control  position,
x2/y2 to limit textbox size." "Text will automatically move onto new  lines,
if x2/y2 is specified." "  Additionally 
)

Definition at line 13878 of file lua.cpp.

ADE_FUNC ( getStringWidth  ,
l_Graphics  ,
"string String"  ,
"Gets string width ,
"number"  ,
"String  width,
or 0 on failure"   
)

Definition at line 13980 of file lua.cpp.

ADE_FUNC ( createTexture  ,
l_Graphics  ,
""  [number Width=512, number Height=512, enumeration Type=TEXTURE_DYNAMIC],
"Creates a texture for rendering to.""Types are TEXTURE_STATIC - for infrequent rendering - and TEXTURE_DYNAMIC - for frequent rendering."  ,
"texture"  ,
"New texture  handle,
or invalid texture handle if texture couldn't be created"   
)

Definition at line 13996 of file lua.cpp.

ADE_FUNC ( loadTexture  ,
l_Graphics  ,
"string  Filename,
[boolean LoadIfAnimation, boolean NoDropFrames] "  ,
"Gets a handle to a texture. If second argument is set to  true,
animations will also be loaded." "If third argument is set to  true,
every other animation frame will not be loaded if system has less than 48 MB memory." "< br >< strong >IMPORTANT:</strong > Textures will not be unload themselves unless you explicitly tell them to do so." "When you are done with a  texture,
call the Unload() function to free up memory."  ,
"texture"  ,
"Texture  handle,
or invalid texture handle if texture couldn't be loaded"   
)

Definition at line 14026 of file lua.cpp.

ADE_FUNC ( drawImage  ,
l_Graphics  ,
"string Filename/texture  Texture,
[number X1=0, Y1=0, number X2, number Y2, number UVX1 = 0.0, number UVY1 = 0.0, number UVX2=1.0, number UVY2=1.0, number alpha=1.0] "  ,
"Draws an image or texture. Any image extension passed will be ignored.""The UV variables specify the UV value for each corner of the image. ""In UV  coordinates,
(0, 0) is the top left of the image;(1, 1) is the lower right."  ,
"boolean"  ,
"Whether image was drawn"   
)

Definition at line 14053 of file lua.cpp.

ADE_FUNC ( drawMonochromeImage  ,
l_Graphics  ,
"string Filename/texture  Texture,
number  X1,
number  Y1,
[number X2, number Y2, number alpha=1.0] "  ,
"Draws a monochrome image using the current color ,
"boolean"  ,
"Whether image was drawn"   
)

Definition at line 14111 of file lua.cpp.

ADE_FUNC ( getImageWidth  ,
l_Graphics  ,
"string Filename"  ,
"Gets image width ,
"number"  ,
"Image  width,
or 0 if filename is invalid"   
)

Definition at line 14167 of file lua.cpp.

ADE_FUNC ( getImageHeight  ,
l_Graphics  ,
"Image name ,
"Gets image height ,
"number"  ,
"Image  height,
or 0 if filename is invalid"   
)

Definition at line 14184 of file lua.cpp.

ADE_FUNC ( flashScreen  ,
l_Graphics  ,
"number  Red,
number  Green,
number Blue"  ,
"Flashes the screen ,
NULL  ,
NULL   
)

Definition at line 14201 of file lua.cpp.

ADE_FUNC ( loadModel  ,
l_Graphics  ,
"string Filename"  ,
"Loads the model - will not setup subsystem  data,
DO NOT USE FOR LOADING SHIP MODELS"  ,
"model"  ,
"Handle to a model"   
)

Definition at line 14216 of file lua.cpp.

ADE_FUNC ( hasViewmode  ,
l_Graphics  ,
"enumeration"  ,
"Specifies if the current viemode has the specified  flag,
see VM_ *enumeration"  ,
"boolean"  ,
"true if flag is  present,
false otherwise"   
)

Definition at line 14232 of file lua.cpp.

ADE_FUNC ( setClip  ,
l_Graphics  ,
x,
y  ,
width  ,
height ,
"Sets the clipping region to the specified rectangle. Most drawing functions are able to handle the offset."  ,
"boolean"  ,
"true if  successful,
false otherwise"   
)

Definition at line 14315 of file lua.cpp.

ADE_FUNC ( resetClip  ,
l_Graphics  ,
NULL  ,
"Resets the clipping region that might have been set"  ,
"boolean"  ,
"true if  successful,
false otherwise"   
)

Definition at line 14327 of file lua.cpp.

ADE_FUNC ( __len  ,
l_HookVar_Globals  ,
NULL  ,
"Number of HookVariables"  ,
"number"  ,
"Number of HookVariables"   
)

Definition at line 14406 of file lua.cpp.

ADE_FUNC ( getObjectFromSignature  ,
l_Mission  ,
"number Signature"  ,
"Gets a handle of an object from its signature"  ,
"object"  ,
"Handle of object with  signaure,
invalid handle if signature is not in use"   
)

Definition at line 14454 of file lua.cpp.

ADE_FUNC ( evaluateSEXP  ,
l_Mission  ,
"string"  ,
"Runs the defined SEXP script"  ,
"boolean"  ,
"if the operation was successful"   
)

Definition at line 14470 of file lua.cpp.

ADE_FUNC ( runSEXP  ,
l_Mission  ,
"string"  ,
"Runs the defined SEXP script"  ,
"boolean"  ,
"if the operation was successful"   
)

Definition at line 14486 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_Asteroids  ,
NULL  ,
"Number of asteroids in mission. Note that the value returned is only good until an asteroid is  destroyed,
and so cannot be relied on for more than one frame."  ,
"number"  ,
"Number of asteroids in the  mission,
or 0 if asteroids are not enabled  
)

Definition at line 14539 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_Debris  ,
NULL  ,
"Number of debris pieces in the mission. ""Note that the value returned is only good until a piece of debris is  destroyed,
and so cannot be relied on for more than one frame."  ,
"number"  ,
"Current number of debris particles"   
)

Definition at line 14569 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_EscortShips  ,
NULL  ,
"Current number of escort ships"  ,
"number"  ,
"Current number of escort ships"   
)

Definition at line 14601 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_Events  ,
NULL  ,
"Number of events in mission ,
"number"  ,
"Number of events in mission  
)

Definition at line 14633 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_SEXPVariables  ,
NULL  ,
"Current number of SEXP variables"  ,
"number"  ,
"Counts number of loaded SEXP Variables. May be slow."   
)

Definition at line 14681 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_Ships  ,
NULL  ,
"Number of ships in the mission. ""This function is somewhat  slow,
and should be set to a variable for use in looping situations." "Note that the value returned is only good until a ship is  destroyed,
and so cannot be relied on for more than one frame."  ,
"number"  ,
"Number of ships in the  mission,
or 0 if ships haven't been initialized yet"   
)

Definition at line 14726 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_Waypoints  ,
NULL  ,
"Gets number of waypoints in mission. Note that this is only accurate for one frame."  ,
"number"  ,
"Number of waypoints in the mission  
)

Definition at line 14767 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_WaypointLists  ,
NULL  ,
"Number of waypoint lists in mission. Note that this is only accurate for one frame."  ,
"number"  ,
"Number of waypoint lists in the mission  
)

Definition at line 14803 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_Weapons  ,
NULL  ,
"Number of weapon objects in mission. Note that this is only accurate for one frame."  ,
"number"  ,
"Number of weapon objects in mission  
)

Definition at line 14834 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_Beams  ,
NULL  ,
"Number of beam objects in mission. Note that this is only accurate for one frame."  ,
"number"  ,
"Number of beam objects in mission  
)

Definition at line 14865 of file lua.cpp.

ADE_FUNC ( getNextMissionFilename  ,
l_Campaign  ,
NULL  ,
"Gets next mission filename ,
"string"  ,
"Next mission  filename,
or nil if the next mission is invalid"   
)

Definition at line 14873 of file lua.cpp.

ADE_FUNC ( getPrevMissionFilename  ,
l_Campaign  ,
NULL  ,
"Gets previous mission filename ,
"string"  ,
"Previous mission  filename,
or nil if the previous mission is invalid"   
)

Definition at line 14881 of file lua.cpp.

ADE_FUNC ( jumpToMission  ,
l_Campaign  ,
"string  filename,
[boolean hub] "  ,
"Jumps to a mission based on the filename.  Optionally,
the player can be sent to a hub mission without setting missions to skipped."  ,
"boolean"  ,
"Jumps to a  mission,
or returns nil."   
)

Definition at line 14890 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_Wings  ,
NULL  ,
"Number of wings in mission ,
"number"  ,
"Number of wings in mission  
)

Definition at line 14929 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_Teams  ,
NULL  ,
"Number of teams in mission ,
"number"  ,
"Number of teams in mission  
)

Definition at line 14958 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_Messages  ,
NULL  ,
"Number of messages in the mission ,
"number"  ,
"Number of messages in mission  
)

Definition at line 15005 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_BuiltinMessages  ,
NULL  ,
"Number of built-in messages in the mission ,
"number"  ,
"Number of messages in mission  
)

Definition at line 15050 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Mission_Personas  ,
NULL  ,
"Number of personas in the mission ,
"number"  ,
"Number of messages in mission  
)

Definition at line 15088 of file lua.cpp.

ADE_FUNC ( addMessage  ,
l_Mission  ,
"string  name,
string text"  [, persona persona],
"Adds a message ,
"message"  ,
"The new message or invalid handle on error"   
)

Definition at line 15093 of file lua.cpp.

ADE_FUNC ( sendMessage  ,
l_Mission  ,
"string  sender,
message message]]"  [, number delay=0.0[, enumeration priority=MESSAGE_PRIORITY_NORMAL[, boolean fromCommand=false],
"Sends a message from the given source (not from a ship!) with the given priority or optionally sends it from the missions command source.<br>""If delay is specified the message will be delayed by the specified time in seconds<br>""If you pass <i>nil</i> as the sender then the message will not have a sender."  ,
"boolean"  ,
"true if  successfull,
false otherwise"   
)

Definition at line 15113 of file lua.cpp.

ADE_FUNC ( sendTrainingMessage  ,
l_Mission  ,
"message  message,
number time"  [, number delay=0.0],
"Sends a training message to the player. <i>time</i> is the amount in seconds to display the  message,
only whole seconds are used!"  ,
"boolean"  ,
"true if  successfull,
false otherwise"   
)

Definition at line 15190 of file lua.cpp.

ADE_FUNC ( createShip  ,
l_Mission  ,
[string Name, shipclass Class=Shipclass[1],
orientation  Orientation = null,
vector  Position = {0,0,0}]", "Creates a ship and returns a handle to it using the specified name,
class  ,
world  orientation,
and world position"  ,
"ship"  ,
"Ship  handle,
or invalid ship handle if ship couldn't be created"   
)

Definition at line 15221 of file lua.cpp.

ADE_FUNC ( createWaypoint  ,
l_Mission  ,
""  [vector Position, waypointlist List],
"Creates a waypoint ,
"waypoint"  ,
"Waypoint  handle,
or invalid waypoint handle if waypoint couldn't be created"   
)

Definition at line 15245 of file lua.cpp.

ADE_FUNC ( createWeapon  ,
l_Mission  ,
[weaponclass Class=WeaponClass[1],
orientation  Orientation = null,
world vector  Position = {0,0,0},
object  Parent = nil,
number  Group = -1", "Creates a weapon and returns a handle to it. 'Group' is used for lighting grouping purposes;" " for example,
quad lasers would only need to act as one light source."  ,
"weapon"  ,
"Weapon  handle,
or invalid weapon handle if weapon couldn't be created."   
)

Definition at line 15271 of file lua.cpp.

ADE_FUNC ( getMissionFilename  ,
l_Mission  ,
NULL  ,
"Gets mission filename ,
"string"  ,
"Mission  filename,
or empty string if game is not in a mission  
)

Definition at line 15300 of file lua.cpp.

ADE_FUNC ( startMission  ,
l_Mission  ,
""  [Filename or MISSION_ *enumeration, Briefing=true],
"Starts the defined mission ,
"boolean"  ,
True,
or false if the function fails"   
)

Definition at line 15305 of file lua.cpp.

ADE_FUNC ( loadMission  ,
l_Mission  ,
"Mission name ,
"Loads a mission ,
"boolean"  ,
"True if mission was  loaded,
otherwise false  
)

Definition at line 15382 of file lua.cpp.

ADE_FUNC ( unloadMission  ,
l_Mission  ,
NULL  ,
"Stops the current mission and unloads it"  ,
NULL  ,
NULL   
)

Definition at line 15406 of file lua.cpp.

ADE_FUNC ( simulateFrame  ,
l_Mission  ,
NULL  ,
"Simulates mission frame"  ,
NULL  ,
NULL   
)

Definition at line 15418 of file lua.cpp.

ADE_FUNC ( renderFrame  ,
l_Mission  ,
NULL  ,
"Renders mission  frame,
but does not move anything"  ,
NULL  ,
NULL   
)

Definition at line 15426 of file lua.cpp.

ADE_FUNC ( applyShudder  ,
l_Mission  ,
"number  time,
number intesity"  ,
"Applies a shudder effects to the camera. Time is in seconds. Intensity specifies the shudder effect  strength,
the Maxim has a value of 1440."  ,
"boolean"  ,
"true if  successfull,
false otherwise"   
)

Definition at line 15435 of file lua.cpp.

ADE_FUNC ( AND  ,
l_BitOps  ,
number,
number"  ,
"Values for which bitwise boolean AND operation is performed"  ,
"number"  ,
"Result of the AND operation"   
)

Definition at line 15470 of file lua.cpp.

ADE_FUNC ( OR  ,
l_BitOps  ,
number,
number"  ,
"Values for which bitwise boolean OR operation is performed"  ,
"number"  ,
"Result of the OR operation"   
)

Definition at line 15481 of file lua.cpp.

ADE_FUNC ( XOR  ,
l_BitOps  ,
number,
number"  ,
"Values for which bitwise boolean XOR operation is performed"  ,
"number"  ,
"Result of the XOR operation"   
)

Definition at line 15492 of file lua.cpp.

ADE_FUNC ( addBit  ,
l_BitOps  ,
number,
number(bit)"  ,
"Performs inclusive or (OR) operation on the set bit of the value ,
"number"  ,
"Result of the operation"   
)

Definition at line 15535 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Tables_ShipClasses  ,
NULL  ,
"Number of ship classes"  ,
"number"  ,
"Number of ship  classes,
or 0 if ship classes haven't been loaded yet"   
)

Definition at line 15577 of file lua.cpp.

ADE_FUNC ( __len  ,
l_Tables_WeaponClasses  ,
NULL  ,
"Number of weapon classes"  ,
"number"  ,
"Number of weapon  classes,
or 0 if weapon classes haven't been loaded yet"   
)

Definition at line 15618 of file lua.cpp.

ADE_FUNC ( avdTest  ,
l_Testing  ,
NULL  ,
"Test the AVD Physics code ,
NULL  ,
NULL   
)

Definition at line 15630 of file lua.cpp.

ADE_FUNC ( createParticle  ,
l_Testing  ,
"vector  Position,
vector  Velocity,
number  Lifetime,
number  Radius,
enumeration  Type,
[number Tracer length=-1, boolean Reverse=false, texture Texture=Nil, object Attached Object=Nil] "  ,
"Creates a particle. Use PARTICLE_* enumerations for type.""Reverse reverse  animation,
if one is specified" "Attached object specifies object that Position will be(and always be) relative to."  ,
"particle"  ,
"Handle to the created particle  
)

Definition at line 15658 of file lua.cpp.

ADE_FUNC ( getStack  ,
l_Testing  ,
NULL  ,
"Generates an ADE stackdump"  ,
"string"  ,
"Current Lua stack"   
)

Definition at line 15723 of file lua.cpp.

ADE_FUNC ( isCurrentPlayerMulti  ,
l_Testing  ,
NULL  ,
"Returns whether current player is a multiplayer pilot or not."  ,
"boolean"  ,
"Whether current player is a multiplayer pilot or not"   
)

Definition at line 15730 of file lua.cpp.

ADE_FUNC ( isPXOEnabled  ,
l_Testing  ,
NULL  ,
"Returns whether PXO is currently enabled in the configuration."  ,
"boolean"  ,
"Whether PXO is enabled or not"   
)

Definition at line 15744 of file lua.cpp.

ade_get_args ( ,
"|i"  ,
depth 
)
int ade_get_args ( lua_State *  L,
const char *  fmt,
  ... 
)

Definition at line 16113 of file lua.cpp.

int ade_get_operator ( char *  tablename)

Definition at line 204 of file lua.cpp.

const char* ade_get_type_string ( lua_State *  L,
int  argnum 
)

Definition at line 16085 of file lua.cpp.

ADE_INDEXER ( l_Eyepoints  ,
"eyepoint"  ,
"Gets en eyepoint handle"  ,
"eyepoint"  ,
"eye handle or invalid handle on error"   
)

Definition at line 1994 of file lua.cpp.

ADE_INDEXER ( l_Thrusters  ,
"number Index"  ,
"Array of all thrusterbanks on this thruster"  ,
"thrusterbank"  ,
"Handle to the thrusterbank or invalid handle if index is invalid"   
)

Definition at line 2059 of file lua.cpp.

ADE_INDEXER ( l_Thrusterbank  ,
"number Index"  ,
"Array of glowpoint"  ,
"glowpoint"  ,
Glowpoint,
or invalid glowpoint handle on failure"   
)

Definition at line 2116 of file lua.cpp.

ADE_INDEXER ( l_Dockingbays  ,
"dockingbay"  ,
"Gets a dockingbay handle from this model. If a string is given then a dockingbay with that name is searched."  ,
"dockingbay"  ,
"Handle or invalid handle on error"   
)

Definition at line 2248 of file lua.cpp.

ADE_INDEXER ( l_Texture  ,
"number"  ,
"Returns texture handle to specified frame number in current texture's animation.""This means that will always return the first frame in an  animation[1],
no matter what frame an animation is." "You cannot change a texture animation frame."  ,
"texture"  ,
"Texture  handle,
or invalid texture handle if index is invalid"   
)

Definition at line 3389 of file lua.cpp.

ADE_INDEXER ( l_Vector  ,
x,
y  ,
z or 1-3"  ,
"Vector component"  ,
"number"  ,
"Value at  index,
or 0 if vector handle is invalid"   
)

Definition at line 3532 of file lua.cpp.

ADE_INDEXER ( l_CockpitDisplayInfos  ,
"number/string ,
"Returns the handle at the requested index or the handle with the specified name ,
"display info"  ,
"display handle or invalid handle on error"   
)

Definition at line 5533 of file lua.cpp.

ADE_INDEXER ( l_WaypointList  ,
"number Index"  ,
"Array of waypoints that are part of the waypoint list"  ,
"waypoint"  ,
Waypoint,
or invalid handle if the index or waypointlist handle is invalid"   
)

Definition at line 6337 of file lua.cpp.

ADE_INDEXER ( l_WeaponBankType  ,
"number Index"  ,
"Array of weapon banks"  ,
"weaponbank"  ,
"Weapon  bank,
or invalid handle on failure"   
)

Definition at line 6722 of file lua.cpp.

ADE_INDEXER ( l_ShipOrders  ,
"number Index"  ,
"Array of ship orders"  ,
"order"  ,
Order,
or invalid order handle on failure"   
)

Definition at line 7941 of file lua.cpp.

ADE_INDEXER ( l_ShipTextures  ,
"number Index/string TextureFilename"  ,
"Array of ship textures ,
"texture"  ,
Texture,
or invalid texture handle on failure"   
)

Definition at line 7993 of file lua.cpp.

ADE_INDEXER ( l_CockpitDisplays  ,
"number/string ,
"Gets a cockpit display from the present player displays by either the index or the name of the display"  ,
"display"  ,
"Display handle or invalid handle on error"   
)

Definition at line 8122 of file lua.cpp.

ADE_INDEXER ( l_Wing  ,
"number Index"  ,
"Array of ships in the wing ,
"ship"  ,
"Ship  handle,
or invalid ship handle if index is invalid or wing handle is invalid"   
)

Definition at line 8804 of file lua.cpp.

ADE_INDEXER ( l_Ship  ,
"string Name/number Index"  ,
"Array of ship subsystems"  ,
"subsystem"  ,
"Subsystem  handle,
or invalid subsystem handle if index or ship handle is invalid"   
)

Definition at line 8864 of file lua.cpp.

ADE_INDEXER ( l_Base_Events  ,
"number Index/string Name"  ,
"Array of game events"  ,
"gameevent"  ,
"Game  event,
or invalid gameevent handle if index is invalid"   
)

Definition at line 12389 of file lua.cpp.

ADE_INDEXER ( l_Base_States  ,
"number Index/string Name"  ,
"Array of game states"  ,
"gamestate"  ,
"Game  state,
or invalid gamestate handle if index is invalid"   
)

Definition at line 12419 of file lua.cpp.

ADE_INDEXER ( l_Graphics_Cameras  ,
"number Index/string Name"  ,
"Gets camera ,
"camera"  ,
"Ship  handle,
or invalid ship handle if index was invalid"   
)

Definition at line 12905 of file lua.cpp.

ADE_INDEXER ( l_Graphics_Fonts  ,
"number Index/string Filename"  ,
"Array of loaded fonts"  ,
"font"  ,
"Font  handle,
or invalid font handle if index is invalid"   
)

Definition at line 12939 of file lua.cpp.

ADE_INDEXER ( l_Graphics_Posteffects  ,
"number index ,
"Gets the name of the specified post processing index ,
"string"  ,
"post processing name or empty string on error"   
)

Definition at line 12982 of file lua.cpp.

ADE_INDEXER ( l_HookVar_Globals  ,
"number Index"  ,
"Array of current HookVariable names ,
"string"  ,
"Hookvariable  name,
or empty string if invalid index specified"   
)

Definition at line 14345 of file lua.cpp.

ADE_INDEXER ( l_Mission_Asteroids  ,
"number Index"  ,
"Gets asteroid ,
"asteroid"  ,
"Asteroid  handle,
or invalid handle if invalid index specified"   
)

Definition at line 14525 of file lua.cpp.

ADE_INDEXER ( l_Mission_Debris  ,
"number Index"  ,
"Array of debris in the current mission ,
"debris"  ,
"Debris  handle,
or invalid debris handle if index wasn't valid"   
)

Definition at line 14553 of file lua.cpp.

ADE_INDEXER ( l_Mission_EscortShips  ,
"number Index"  ,
"Gets escort ship at specified index on escort list"  ,
"ship"  ,
"Specified  ship,
or invalid ship handle if invalid index  
)

Definition at line 14581 of file lua.cpp.

ADE_INDEXER ( l_Mission_Events  ,
"number Index/string Name"  ,
"Indexes events list"  ,
"event"  ,
"Event  handle,
or invalid event handle if index was invalid"   
)

Definition at line 14609 of file lua.cpp.

ADE_INDEXER ( l_Mission_SEXPVariables  ,
"number Index/string Name"  ,
"Array of SEXP variables. Note that you can set a sexp variable using the  array,
eg\'  SEXPVariables[\"newvariable\"] = \"newvalue\"\'",
"sexpvariable"  ,
"Handle to SEXP  variable,
or invalid sexpvariable handle if index was invalid"   
)

Definition at line 14641 of file lua.cpp.

ADE_INDEXER ( l_Mission_Ships  ,
"number Index/string Name"  ,
"Gets ship ,
"ship"  ,
"Ship  handle,
or invalid ship handle if index was invalid"   
)

Definition at line 14689 of file lua.cpp.

ADE_INDEXER ( l_Mission_Waypoints  ,
"number Index"  ,
"Array of waypoints in the current mission ,
"waypoint"  ,
"Waypoint  handle,
or invalid waypoint handle if index was invalid"   
)

Definition at line 14742 of file lua.cpp.

ADE_INDEXER ( l_Mission_WaypointLists  ,
"number Index/string WaypointListName"  ,
"Array of waypoint lists"  ,
"waypointlist"  ,
"Gets waypointlist handle"   
)

Definition at line 14782 of file lua.cpp.

ADE_INDEXER ( l_Mission_Weapons  ,
"number Index"  ,
"Gets handle to a weapon object in the mission."  ,
"weapon"  ,
"Weapon  handle,
or invalid weapon handle if index is invalid"   
)

Definition at line 14811 of file lua.cpp.

ADE_INDEXER ( l_Mission_Beams  ,
"number Index"  ,
"Gets handle to a beam object in the mission."  ,
"beam"  ,
"Beam  handle,
or invalid beam handle if index is invalid"   
)

Definition at line 14842 of file lua.cpp.

ADE_INDEXER ( l_Mission_Wings  ,
"number Index/string WingName"  ,
"Wings in the mission ,
"wing"  ,
"Wing  handle,
or invalid wing handle if index or name was invalid"   
)

Definition at line 14908 of file lua.cpp.

ADE_INDEXER ( l_Mission_Teams  ,
"number Index/string TeamName"  ,
"Teams in the mission ,
"team"  ,
"Team handle or invalid team handle if the requested team could not be found"   
)

Definition at line 14937 of file lua.cpp.

ADE_INDEXER ( l_Mission_Messages  ,
"number Index/string messageName"  ,
"Messages of the mission ,
"message"  ,
"Message handle or invalid handle on error"   
)

Definition at line 14966 of file lua.cpp.

ADE_INDEXER ( l_Mission_BuiltinMessages  ,
"number Index/string messageName"  ,
"Built-in messages of the mission ,
"message"  ,
"Message handle or invalid handle on error"   
)

Definition at line 15013 of file lua.cpp.

ADE_INDEXER ( l_Mission_Personas  ,
"number Index/string name ,
"Personas of the mission ,
"persona"  ,
"Persona handle or invalid handle on error"   
)

Definition at line 15058 of file lua.cpp.

ADE_INDEXER ( l_Tables_ShipClasses  ,
"number Index/string Name"  ,
"Array of ship classes"  ,
"shipclass"  ,
"Ship  handle,
or invalid ship handle if index is invalid"   
)

Definition at line 15555 of file lua.cpp.

ADE_INDEXER ( l_Tables_WeaponClasses  ,
"number Index/string WeaponName"  ,
"Array of weapon classes"  ,
"weapon"  ,
"Weapon class  handle,
or invalid weaponclass handle if index is invalid"   
)

Definition at line 15590 of file lua.cpp.

void ade_output_toc ( FILE *  fp,
ade_table_entry ate 
)

Definition at line 17079 of file lua.cpp.

void ade_output_type_link ( FILE *  fp,
char *  typestr 
)

Definition at line 16861 of file lua.cpp.

return ade_set_args ( ,
"f"  ,
val 
)
return ade_set_args ( ,
"o"  ,
l_Matrix.  Setmatrix_h(&final) 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setmh->GetMatrix() ->vec.uvec 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setmh->GetMatrix() ->vec.fvec 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setmh->GetMatrix() ->vec.rvec 
)
return ade_set_args ( ,
"i"  ,
mep->  interval 
)
return ade_set_args ( ,
"s"  ,
Fonts.  filename[font_num] 
)
return ade_set_args ( ,
"i"  ,
Fonts.  h[font_num] 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setpm->view_positions[eh->eye_idx].pnt 
)
return ade_set_args ( ,
"f"  ,
pm->  rad 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setvec 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setpih->pi->afterburner_max_vel 
)
return ade_set_args ( ,
"f"  ,
pih->pi->  forward_thrust 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setpih->pi->rotvel 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setpih->pi->max_rotvel 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setpih->pi->vel 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setpih->pi->desired_vel 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setpih->pi->max_vel 
)
return ade_set_args ( ,
"f"  ,
shield_get_quad(objp, qdx  
)
return ade_set_args ( ,
"f"  ,
shield_get_strength(objh->objp  
)
return ade_set_args ( ,
"f"  ,
shield_get_max_strength(objh->objp  
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setv3 
)
return ade_set_args ( ,
"s"  ,
buf   
)
return ade_set_args ( ,
"f"  ,
vm_vec_mag(v3  
)
return ade_set_args ( ,
"f"  ,
Weapon_info.  armor_factor[idx] 
)
else return ade_set_args ( ,
"o"  ,
l_Vector.  Setcollide->hit_point_world 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setobjh->objp->pos 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setobjh->objp->last_pos 
)
return ade_set_args ( ,
"o"  ,
l_Matrix.  Setmatrix_h(&objh->objp->orient) 
)
return ade_set_args ( ,
"o"  ,
l_Matrix.  Setmatrix_h(&objh->objp->last_orient) 
)
else return ade_set_args ( ,
"oo"  ,
l_Vector.  Sethull_check.hit_point_world,
l_ColInfo.  Setmc_info_h(new mc_info(hull_check)) 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setsso->ss->system_info->pnt 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setsm->offset 
)
return ade_set_args ( ,
"i"  ,
sso->ss->system_info->  turret_reset_delay 
)
return ade_set_args ( ,
"f"  ,
sso->ss->turret_next_fire_stamp/1000.  0f 
)
return ade_set_args ( ,
"f"  ,
shipp->autoaim_fov *180.0f/  PI 
)
return ade_set_args ( ,
"i"  ,
Ships.  engine_recharge_index[objh->objp->instance] 
)
return ade_set_args ( ,
"i"  ,
i   
)
return ade_set_args ( ,
"i"  ,
ship_fire_secondary(objh->objp, 0)   
)
return ade_set_args ( ,
"f"  ,
time_s   
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setph->Get() ->pos 
)
return ade_set_args ( ,
"o"  ,
l_Vector.  Setph->Get() ->velocity 
)
return ade_set_args ( ,
"o"  ,
l_GameState.  Setgamestate_h(gameseq_get_state(depth)) 
)
return ade_set_args ( ,
"iiii"  ,
(int) c.  red,
(int) c.  green,
(int) c.  blue,
(int) c.  alpha 
)
return ade_set_args ( ,
"i"  ,
gr_screen.  center_w 
)
Initial value:
{
if(!Gr_inited)
return ade_set_error(L, "i", 0)
int Gr_inited
Definition: 2d.cpp:63
#define ade_set_error
Definition: lua.cpp:248
return ade_set_args ( ,
"x"  ,
Missiontime   
)
return ade_set_args ( ,
"b"  ,
b   
)
return ade_set_args ( ,
"i"  ,
c   
)
int ade_set_args ( lua_State *  L,
const char *  fmt,
  ... 
)

Definition at line 16313 of file lua.cpp.

return ade_set_error ( ,
"b"  ,
false   
)
int ade_set_object_with_breed ( lua_State *  L,
int  obj_idx 
)

Definition at line 15770 of file lua.cpp.

void ade_stackdump ( lua_State *  L,
char *  stackdump 
)

Definition at line 15953 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_Event  ,
"string"  ,
"Mission event name ,
"string"  ,
NULL   
)

Definition at line 938 of file lua.cpp.

ADE_VIRTVAR ( DirectiveText  ,
l_Event  ,
"string"  ,
"Directive text"  ,
"string"  ,
NULL   
)

Definition at line 957 of file lua.cpp.

ADE_VIRTVAR ( DirectiveKeypressText  ,
l_Event  ,
"string"  ,
"Raw directive keypress  text,
as seen in FRED."  ,
"string"  ,
NULL   
)

Definition at line 982 of file lua.cpp.

ADE_VIRTVAR ( ObjectCount  ,
l_Event  ,
"number"  ,
"Number of objects left for event ,
"number"  ,
"Repeat  count,
or 0 if invalid handle"   
)

Definition at line 1026 of file lua.cpp.

ADE_VIRTVAR ( RepeatCount  ,
l_Event  ,
"number"  ,
"Event repeat count ,
"number"  ,
"Repeat  count,
or 0 if invalid handle"   
)

Definition at line 1045 of file lua.cpp.

ADE_VIRTVAR ( Score  ,
l_Event  ,
"number"  ,
"Event score"  ,
"number"  ,
"Event  score,
or 0 if invalid handle"   
)

Definition at line 1064 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_GameEvent  ,
"string"  ,
"Game event name ,
"string"  ,
"Game event  name,
or empty string if handle is invalid"   
)

Definition at line 1447 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_GameState  ,
"string"  ,
"Game state name ,
"string"  ,
"Game state  name,
or empty string if handle is invalid"   
)

Definition at line 1495 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_HudGauge  ,
"string"  ,
"Custom HUD Gauge name ,
"string"  ,
"Custom HUD Gauge  name,
or nil if handle is invalid"   
)

Definition at line 1518 of file lua.cpp.

ADE_VIRTVAR ( Text  ,
l_HudGauge  ,
"string"  ,
"Custom HUD Gauge text"  ,
"string"  ,
"Custom HUD Gauge  text,
or nil if handle is invalid"   
)

Definition at line 1531 of file lua.cpp.

ADE_VIRTVAR ( Normal  ,
l_Eyepoint  ,
"vector"  ,
"Eyepoint normal"  ,
"vector"  ,
"Eyepoint  normal,
or null vector if handle is invalid"   
)

Definition at line 1568 of file lua.cpp.

ADE_VIRTVAR ( Textures  ,
l_Model  ,
"modeltextures_h"  ,
"Model textures ,
"modeltextures_h"  ,
"Model  textures,
or an invalid modeltextures handle if the model handle is invalid"   
)

Definition at line 1765 of file lua.cpp.

ADE_VIRTVAR ( Thrusters  ,
l_Model  ,
"thrusters"  ,
"Model thrusters"  ,
"thrusters"  ,
"Thrusters of the model or invalid handle"   
)

Definition at line 1784 of file lua.cpp.

ADE_VIRTVAR ( Eyepoints  ,
l_Model  ,
"eyepoints"  ,
"Model eyepoints"  ,
"eyepoints"  ,
"Array of eyepoints or invalid handle on error"   
)

Definition at line 1802 of file lua.cpp.

ADE_VIRTVAR ( Dockingbays  ,
l_Model  ,
"dockingbays"  ,
"Docking bays handle of model"  ,
"dockingbays"  ,
"Array of docking bays on this  model,
or invalid handle on error"   
)

Definition at line 1820 of file lua.cpp.

ADE_VIRTVAR ( BoundingBoxMax  ,
l_Model  ,
"vector"  ,
"Model bounding box maximum"  ,
"vector"  ,
"Model bounding  box,
or an empty vector if the handle is invalid"   
)

Definition at line 1840 of file lua.cpp.

ADE_VIRTVAR ( BoundingBoxMin  ,
l_Model  ,
"vector"  ,
"Model bounding box minimum"  ,
"vector"  ,
"Model bounding  box,
or an empty vector if the handle is invalid"   
)

Definition at line 1862 of file lua.cpp.

ADE_VIRTVAR ( Filename  ,
l_Model  ,
"string"  ,
"Model filename ,
"string"  ,
"Model  filename,
or an empty string if the handle is invalid"   
)

Definition at line 1884 of file lua.cpp.

ADE_VIRTVAR ( Mass  ,
l_Model  ,
"number"  ,
"Model mass"  ,
"number"  ,
"Model  mass,
or 0 if the model handle is invalid"   
)

Definition at line 1903 of file lua.cpp.

ADE_VIRTVAR ( MomentOfInertia  ,
l_Model  ,
"orientation"  ,
"Model moment of inertia"  ,
"orientation"  ,
"Moment of Inertia matrix or identity matrix if invalid"   
)

Definition at line 1922 of file lua.cpp.

ADE_VIRTVAR ( Radius  ,
l_Glowpoint  ,
NULL  ,
"The radius of the glowpoint"  ,
"number"  ,
"The radius of the glowpoint or -1 of invalid"   
)

Definition at line 2183 of file lua.cpp.

ADE_VIRTVAR ( AfterburnerAccelerationTime  ,
l_Physics  ,
"number"  ,
"Afterburner acceleration time"  ,
"number"  ,
"Afterburner acceleration  time,
or 0 if handle is invalid"   
)

Definition at line 2481 of file lua.cpp.

ADE_VIRTVAR ( BankingConstant  ,
l_Physics  ,
"number"  ,
"Banking constant"  ,
"number"  ,
"Banking  constant,
or 0 if handle is invalid"   
)

Definition at line 2515 of file lua.cpp.

ADE_VIRTVAR ( ForwardAccelerationTime  ,
l_Physics  ,
"number"  ,
"Forward acceleration time"  ,
"number"  ,
"Forward acceleration  time,
or 0 if handle is invalid"   
)

Definition at line 2532 of file lua.cpp.

ADE_VIRTVAR ( ForwardDecelerationTime  ,
l_Physics  ,
"number"  ,
"Forward deceleration time"  ,
"number"  ,
"Forward decleration  time,
or 0 if handle is invalid"   
)

Definition at line 2549 of file lua.cpp.

ADE_VIRTVAR ( Mass  ,
l_Physics  ,
"number"  ,
"Object mass"  ,
"number"  ,
"Object  mass,
or 0 if handle is invalid"   
)

Definition at line 2583 of file lua.cpp.

ADE_VIRTVAR ( RotationalVelocityDamping  ,
l_Physics  ,
"number"  ,
"Rotational  damping,
ie derivative of rotational speed"  ,
"number"  ,
"Rotational  damping,
or 0 if handle is invalid"   
)

Definition at line 2617 of file lua.cpp.

ADE_VIRTVAR ( RotationalVelocityDesired  ,
l_Physics  ,
"vector"  ,
"Desired rotational velocity"  ,
"vector"  ,
"Desired rotational  velocity,
or null vector if handle is invalid"   
)

Definition at line 2634 of file lua.cpp.

ADE_VIRTVAR ( ShockwaveShakeAmplitude  ,
l_Physics  ,
"number"  ,
"How much shaking from shockwaves is applied to object ,
"number"  ,
"Shockwave shake  amplitude,
or 0 if handle is invalid"   
)

Definition at line 2668 of file lua.cpp.

ADE_VIRTVAR ( SlideAccelerationTime  ,
l_Physics  ,
"number"  ,
"Time to accelerate to maximum slide velocity"  ,
"number"  ,
"Sliding acceleration  time,
or 0 if handle is invalid"   
)

Definition at line 2702 of file lua.cpp.

ADE_VIRTVAR ( SlideDecelerationTime  ,
l_Physics  ,
"number"  ,
"Time to decelerate from maximum slide speed"  ,
"number"  ,
"Sliding deceleration  time,
or 0 if handle is invalid"   
)

Definition at line 2719 of file lua.cpp.

ADE_VIRTVAR ( AfterburnerActive  ,
l_Physics  ,
"boolean"  ,
"Specifies if the afterburner is active or not"  ,
"boolean"  ,
"true if afterburner is active false otherwise"   
)

Definition at line 2804 of file lua.cpp.

ADE_VIRTVAR ( Persistence  ,
l_SEXPVariable  ,
"enumeration"  ,
"SEXP Variable  persistance,
uses SEXPVAR_ *_PERSISTENT enumerations"  ,
"enumeration"  ,
"SEXPVAR_*_PERSISTENT  enumeration,
or invalid numeration if handle is invalid"   
)

Definition at line 2930 of file lua.cpp.

ADE_VIRTVAR ( Type  ,
l_SEXPVariable  ,
"enumeration"  ,
"SEXP Variable  type,
uses SEXPVAR_TYPE_ *enumerations"  ,
"enumeration"  ,
"SEXPVAR_TYPE_*  enumeration,
or invalid numeration if handle is invalid"   
)

Definition at line 2972 of file lua.cpp.

ADE_VIRTVAR ( Value  ,
l_SEXPVariable  ,
"number/string ,
"SEXP variable value ,
"string"  ,
"SEXP variable  contents,
or nil if the variable is of an invalid type or the handle is invalid"   
)

Definition at line 3007 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_Shiptype  ,
"string"  ,
"Ship type name ,
"string"  ,
"Ship type  name,
or empty string if handle is invalid"   
)

Definition at line 3225 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_Species  ,
"string"  ,
"Species name ,
"string"  ,
"Species  name,
or empty string if handle is invalid"   
)

Definition at line 3261 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_Team  ,
"string"  ,
"Team name ,
"string"  ,
"Team  name,
or empty string if handle is invalid"   
)

Definition at line 3305 of file lua.cpp.

ADE_VIRTVAR ( BaseMap  ,
l_TextureMap  ,
"texture"  ,
"Base texture ,
"texture"  ,
"Base  texture,
or invalid texture handle if material handle is invalid"   
)

Definition at line 3852 of file lua.cpp.

ADE_VIRTVAR ( GlowMap  ,
l_TextureMap  ,
"texture"  ,
"Glow texture ,
"texture"  ,
"Glow  texture,
or invalid texture handle if material handle is invalid"   
)

Definition at line 3870 of file lua.cpp.

ADE_VIRTVAR ( SpecularMap  ,
l_TextureMap  ,
"texture"  ,
"Specular texture ,
"texture"  ,
"Texture  handle,
or invalid texture handle if material handle is invalid"   
)

Definition at line 3888 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_Weaponclass  ,
"string"  ,
"Weapon class name ,
"string"  ,
"Weapon class  name,
or empty string if handle is invalid"   
)

Definition at line 3937 of file lua.cpp.

ADE_VIRTVAR ( Title  ,
l_Weaponclass  ,
"string"  ,
"Weapon class title"  ,
"string"  ,
"Weapon class  title,
or empty string if handle is invalid"   
)

Definition at line 3955 of file lua.cpp.

ADE_VIRTVAR ( Description  ,
l_Weaponclass  ,
"string"  ,
"Weapon class description string ,
"string"  ,
"Description  string,
or empty string if handle is invalid"   
)

Definition at line 3972 of file lua.cpp.

ADE_VIRTVAR ( TechTitle  ,
l_Weaponclass  ,
"string"  ,
"Weapon class tech title"  ,
"string"  ,
"Tech  title,
or empty string if handle is invalid"   
)

Definition at line 4000 of file lua.cpp.

ADE_VIRTVAR ( TechAnimationFilename  ,
l_Weaponclass  ,
"string"  ,
"Weapon class animation filename ,
"string"  ,
Filename,
or empty string if handle is invalid"   
)

Definition at line 4017 of file lua.cpp.

ADE_VIRTVAR ( TechDescription  ,
l_Weaponclass  ,
"string"  ,
"Weapon class tech description string ,
"string"  ,
"Description  string,
or empty string if handle is invalid"   
)

Definition at line 4034 of file lua.cpp.

ADE_VIRTVAR ( Model  ,
l_Weaponclass  ,
"model"  ,
"Model"  ,
"model"  ,
"Weapon class  model,
or invalid model handle if weaponclass handle is invalid"   
)

Definition at line 4062 of file lua.cpp.

ADE_VIRTVAR ( Damage  ,
l_Weaponclass  ,
"number"  ,
"Amount of damage that weapon deals"  ,
"number"  ,
"Damage  amount,
or 0 if handle is invalid"   
)

Definition at line 4100 of file lua.cpp.

ADE_VIRTVAR ( FreeFlightTime  ,
l_Weaponclass  ,
"number"  ,
"The time the weapon will fly before turing onto its target ,
"number"  ,
"Free flight time or emty string if invalid"   
)

Definition at line 4134 of file lua.cpp.

ADE_VIRTVAR ( LifeMax  ,
l_Weaponclass  ,
"number"  ,
"Life of weapon in seconds"  ,
"number"  ,
"Life of  weapon,
or 0 if handle is invalid"   
)

Definition at line 4151 of file lua.cpp.

ADE_VIRTVAR ( Range  ,
l_Weaponclass  ,
"number"  ,
"Range of weapon in meters"  ,
"number"  ,
"Weapon  Range,
or 0 if handle is invalid"   
)

Definition at line 4168 of file lua.cpp.

ADE_VIRTVAR ( Mass  ,
l_Weaponclass  ,
"number"  ,
"Weapon mass"  ,
"number"  ,
"Weapon  mass,
or 0 if handle is invalid"   
)

Definition at line 4185 of file lua.cpp.

ADE_VIRTVAR ( TargetLOD  ,
l_Weaponclass  ,
"number"  ,
"LOD used for weapon model in the targeting computer"  ,
"number"  ,
"LOD  number,
or 0 if handle is invalid"   
)

Definition at line 4236 of file lua.cpp.

ADE_VIRTVAR ( Speed  ,
l_Weaponclass  ,
"number"  ,
"Weapon max  speed,
aka $Velocity in weapons.tbl"  ,
"number"  ,
"Weapon  speed,
or 0 if handle is invalid"   
)

Definition at line 4253 of file lua.cpp.

ADE_VIRTVAR ( Bomb  ,
l_Weaponclass  ,
"boolean"  ,
"Is weapon class flagged as bomb"  ,
"boolean"  ,
"New flag"   
)

Definition at line 4270 of file lua.cpp.

ADE_VIRTVAR ( CargoSize  ,
l_Weaponclass  ,
"number"  ,
"The cargo size of this weapon class"  ,
"number"  ,
"The new cargo size or -1 on error"   
)

Definition at line 4301 of file lua.cpp.

ADE_VIRTVAR ( Model  ,
l_ColInfo  ,
"model"  ,
"The model this collision info is about"  ,
"model"  ,
"The model"   
)

Definition at line 4473 of file lua.cpp.

ADE_VIRTVAR ( Parent  ,
l_Object  ,
"object"  ,
"Parent of the object. Value may also be a deriviative of the 'object class,
such as 'ship'."  ,
"object"  ,
"Parent  handle,
or invalid handle if object is invalid"   
)

Definition at line 4716 of file lua.cpp.

ADE_VIRTVAR ( Physics  ,
l_Object  ,
"physics"  ,
"Physics data used to move ship between frames"  ,
"physics"  ,
"Physics  data,
or invalid physics handle if object handle is invalid"   
)

Definition at line 4820 of file lua.cpp.

ADE_VIRTVAR ( HitpointsLeft  ,
l_Object  ,
"number"  ,
"Hitpoints an object has left ,
"number"  ,
"Hitpoints  left,
or 0 if handle is invalid"   
)

Definition at line 4837 of file lua.cpp.

ADE_VIRTVAR ( Shields  ,
l_Object  ,
"shields"  ,
"Shields"  ,
"shields"  ,
"Shields  handle,
or invalid shields handle if object handle is invalid"   
)

Definition at line 4855 of file lua.cpp.

ADE_VIRTVAR ( CollisionGroups  ,
l_Object  ,
"number"  ,
"Collision group data ,
"number"  ,
"Current collision group signature. NOTE: This is a  bitfield,
NOT a normal number."   
)

Definition at line 4911 of file lua.cpp.

ADE_VIRTVAR ( Target  ,
l_Asteroid  ,
"object"  ,
"Asteroid target object; may be object  derivative,
such as ship."  ,
"object"  ,
"Target  object,
or invalid handle if asteroid handle is invalid"   
)

Definition at line 5068 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_Shipclass  ,
"string"  ,
"Ship class name ,
"string"  ,
"Ship class  name,
or an empty string if handle is invalid"   
)

Definition at line 5645 of file lua.cpp.

ADE_VIRTVAR ( ShortName  ,
l_Shipclass  ,
"string"  ,
"Ship class short name ,
"string"  ,
"Ship short  name,
or empty string if handle is invalid"   
)

Definition at line 5662 of file lua.cpp.

ADE_VIRTVAR ( TypeString  ,
l_Shipclass  ,
"string"  ,
"Ship class type string ,
"string"  ,
"Type  string,
or empty string if handle is invalid"   
)

Definition at line 5679 of file lua.cpp.

ADE_VIRTVAR ( ManeuverabilityString  ,
l_Shipclass  ,
"string"  ,
"Ship class maneuverability string ,
"string"  ,
"Maneuverability  string,
or empty string if handle is invalid"   
)

Definition at line 5707 of file lua.cpp.

ADE_VIRTVAR ( ArmorString  ,
l_Shipclass  ,
"string"  ,
"Ship class armor string ,
"string"  ,
"Armor  string,
or empty string if handle is invalid"   
)

Definition at line 5735 of file lua.cpp.

ADE_VIRTVAR ( ManufacturerString  ,
l_Shipclass  ,
"string"  ,
"Ship class manufacturer"  ,
"string"  ,
Manufacturer,
or empty string if handle is invalid"   
)

Definition at line 5763 of file lua.cpp.

ADE_VIRTVAR ( Description  ,
l_Shipclass  ,
"string"  ,
"Ship class description"  ,
"string"  ,
Description,
or empty string if handle is invalid"   
)

Definition at line 5792 of file lua.cpp.

ADE_VIRTVAR ( TechDescription  ,
l_Shipclass  ,
"string"  ,
"Ship class tech description"  ,
"string"  ,
"Tech  description,
or empty string if handle is invalid"   
)

Definition at line 5820 of file lua.cpp.

ADE_VIRTVAR ( AfterburnerFuelMax  ,
l_Shipclass  ,
"number"  ,
"Afterburner fuel capacity"  ,
"number"  ,
"Afterburner  capacity,
or 0 if handle is invalid"   
)

Definition at line 5848 of file lua.cpp.

ADE_VIRTVAR ( CountermeasuresMax  ,
l_Shipclass  ,
"number"  ,
"Maximum number of countermeasures the ship can carry"  ,
"number"  ,
"Countermeasure  capacity,
or 0 if handle is invalid"   
)

Definition at line 5864 of file lua.cpp.

ADE_VIRTVAR ( Model  ,
l_Shipclass  ,
"model"  ,
"Model"  ,
"model"  ,
"Ship class  model,
or invalid model handle if shipclass handle is invalid"   
)

Definition at line 5881 of file lua.cpp.

ADE_VIRTVAR ( CockpitModel  ,
l_Shipclass  ,
"model"  ,
"Model used for first-person cockpit"  ,
"model"  ,
"Cockpit model"   
)

Definition at line 5902 of file lua.cpp.

ADE_VIRTVAR ( CockpitDisplays  ,
l_Shipclass  ,
"cockpitdisplays"  ,
"Gets the cockpit display information array of this ship class"  ,
"cockpitdisplays"  ,
"Array handle containing the information or invalid handle on error"   
)

Definition at line 5923 of file lua.cpp.

ADE_VIRTVAR ( HitpointsMax  ,
l_Shipclass  ,
"number"  ,
"Ship class hitpoints"  ,
"number"  ,
Hitpoints,
or 0 if handle is invalid"   
)

Definition at line 5940 of file lua.cpp.

ADE_VIRTVAR ( Species  ,
l_Shipclass  ,
"Species"  ,
"Ship class species"  ,
"species"  ,
"Ship class  species,
or invalid species handle if shipclass handle is invalid"   
)

Definition at line 5957 of file lua.cpp.

ADE_VIRTVAR ( Type  ,
l_Shipclass  ,
"shiptype"  ,
"Ship class type ,
"shiptype"  ,
"Ship  type,
or invalid handle if shipclass handle is invalid"   
)

Definition at line 5974 of file lua.cpp.

ADE_VIRTVAR ( AltName  ,
l_Shipclass  ,
"string"  ,
"Alternate name for ship class"  ,
"string"  ,
"Alternate string or empty string if handle is invalid"   
)

Definition at line 5991 of file lua.cpp.

ADE_VIRTVAR ( IsHull  ,
l_Debris  ,
"boolean"  ,
"Whether or not debris is a piece of hull"  ,
"boolean"  ,
"Whether debris is a hull  fragment,
or false if handle is invalid"   
)

Definition at line 6238 of file lua.cpp.

ADE_VIRTVAR ( OriginClass  ,
l_Debris  ,
"shipclass"  ,
"The shipclass of the ship this debris originates from"  ,
"shipclass"  ,
"The shipclass of the ship that created this debris  
)

Definition at line 6258 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_WaypointList  ,
"string"  ,
"Name of WaypointList"  ,
"string"  ,
"Waypointlist  name,
or empty string if handle is invalid"   
)

Definition at line 6375 of file lua.cpp.

ADE_VIRTVAR ( WeaponClass  ,
l_WeaponBank  ,
"weaponclass"  ,
"Class of weapon mounted in the bank"  ,
"weaponclass"  ,
"Weapon  class,
or an invalid weaponclass handle if bank handle is invalid"   
)

Definition at line 6522 of file lua.cpp.

ADE_VIRTVAR ( AmmoLeft  ,
l_WeaponBank  ,
"number"  ,
"Ammo left for the current bank"  ,
"number"  ,
"Ammo  left,
or 0 if handle is invalid"   
)

Definition at line 6560 of file lua.cpp.

ADE_VIRTVAR ( AmmoMax  ,
l_WeaponBank  ,
"number"  ,
"Maximum ammo for the current bank<br>""<b>Note:</b> Setting this value actually sets the <i>capacity</i> of the weapon bank. To set the actual maximum ammunition use <tt>  AmmoMax = <amount> * class.CargoSize</tt>", "number", "Ammo capacity,
or 0 if handle is invalid"   
)

Definition at line 6594 of file lua.cpp.

ADE_VIRTVAR ( Armed  ,
l_WeaponBank  ,
"boolean"  ,
"Weapon armed status. Does not take linking into account."  ,
"boolean"  ,
"True if  armed,
false if unarmed or handle is invalid"   
)

Definition at line 6642 of file lua.cpp.

ADE_VIRTVAR ( Capacity  ,
l_WeaponBank  ,
"number"  ,
"The actual capacity of a weapon bank as specified in the table ,
"number"  ,
"The capacity or -1 if handle is invalid"   
)

Definition at line 6678 of file lua.cpp.

ADE_VIRTVAR ( ArmorClass  ,
l_Subsystem  ,
"string"  ,
"Current Armor class"  ,
"string"  ,
"Armor class  name,
or empty string if none is set"   
)

Definition at line 6904 of file lua.cpp.

ADE_VIRTVAR ( AWACSIntensity  ,
l_Subsystem  ,
"number"  ,
"Subsystem AWACS intensity"  ,
"number"  ,
"AWACS  intensity,
or 0 if handle is invalid"   
)

Definition at line 6932 of file lua.cpp.

ADE_VIRTVAR ( AWACSRadius  ,
l_Subsystem  ,
"number"  ,
"Subsystem AWACS radius"  ,
"number"  ,
"AWACS  radius,
or 0 if handle is invalid"   
)

Definition at line 6948 of file lua.cpp.

ADE_VIRTVAR ( Orientation  ,
l_Subsystem  ,
"orientation"  ,
"Orientation of subobject or turret base"  ,
"orientation"  ,
"Subsystem  orientation,
or null orientation if handle is invalid"   
)

Definition at line 6964 of file lua.cpp.

ADE_VIRTVAR ( GunOrientation  ,
l_Subsystem  ,
"orientation"  ,
"Orientation of turret gun"  ,
"orientation"  ,
"Gun  orientation,
or null orientation if handle is invalid"   
)

Definition at line 6982 of file lua.cpp.

ADE_VIRTVAR ( HitpointsLeft  ,
l_Subsystem  ,
"number"  ,
"Subsystem hitpoints left ,
"number"  ,
"Hitpoints  left,
or 0 if handle is invalid.Setting a value of 0 will disable it-set a value of-1 or lower to actually blow it up."   
)

Definition at line 7000 of file lua.cpp.

ADE_VIRTVAR ( HitpointsMax  ,
l_Subsystem  ,
"number"  ,
"Subsystem hitpoints max"  ,
"number"  ,
"Max  hitpoints,
or 0 if handle is invalid"   
)

Definition at line 7025 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_Subsystem  ,
"string"  ,
"Subsystem name ,
"string"  ,
"Subsystem  name,
or an empty string if handle is invalid"   
)

Definition at line 7087 of file lua.cpp.

ADE_VIRTVAR ( PrimaryBanks  ,
l_Subsystem  ,
"weaponbanktype"  ,
"Array of primary weapon banks"  ,
"weaponbanktype"  ,
"Primary  banks,
or invalid weaponbanktype handle if subsystem handle is invalid"   
)

Definition at line 7117 of file lua.cpp.

ADE_VIRTVAR ( SecondaryBanks  ,
l_Subsystem  ,
"weaponbanktype"  ,
"Array of secondary weapon banks"  ,
"weaponbanktype"  ,
"Secondary  banks,
or invalid weaponbanktype handle if subsystem handle is invalid"   
)

Definition at line 7147 of file lua.cpp.

ADE_VIRTVAR ( Target  ,
l_Subsystem  ,
"object"  ,
"Object targeted by this subsystem. If used to set a new  target,
AI targeting will be switched off."  ,
"object"  ,
"Targeted  object,
or invalid object handle if subsystem handle is invalid"   
)

Definition at line 7179 of file lua.cpp.

ADE_VIRTVAR ( TurretResets  ,
l_Subsystem  ,
"boolean"  ,
"Specifies wether this turrets resets after a certain time of inactivity"  ,
"boolean"  ,
"true if turret  resets,
false otherwise"   
)

Definition at line 7202 of file lua.cpp.

ADE_VIRTVAR ( TurnRate  ,
l_Subsystem  ,
"number"  ,
"The turn rate"  ,
"number"  ,
"Turnrate or -1 on error"   
)

Definition at line 7252 of file lua.cpp.

ADE_VIRTVAR ( Targetable  ,
l_Subsystem  ,
"boolean"  ,
"Targetability of this subsystem"  ,
"boolean"  ,
"true if  targetable,
false otherwise or on error"   
)

Definition at line 7270 of file lua.cpp.

ADE_VIRTVAR ( Radius  ,
l_Subsystem  ,
"number"  ,
"The radius of this subsystem"  ,
"number"  ,
"The radius or 0 on error"   
)

Definition at line 7291 of file lua.cpp.

ADE_VIRTVAR ( TurretLocked  ,
l_Subsystem  ,
"boolean"  ,
"Whether the turret is locked. Setting to true locks the  turret,
setting to false frees it."  ,
"boolean"  ,
"True if turret is  locked,
false otherwise"   
)

Definition at line 7308 of file lua.cpp.

ADE_VIRTVAR ( Priority  ,
l_Order  ,
"number"  ,
"Priority of the given order ,
"number"  ,
"Order priority or 0 if invalid"   
)

Definition at line 7611 of file lua.cpp.

ADE_VIRTVAR ( Target  ,
l_Order  ,
"object"  ,
"Target of the order. Value may also be a deriviative of the 'object class,
such as 'ship'."  ,
"object"  ,
"Target object or invalid object handle if order handle is invalid or order requires no target."   
)

Definition at line 7727 of file lua.cpp.

ADE_VIRTVAR ( TargetSubsystem  ,
l_Order  ,
"subsystem"  ,
"Target subsystem of the order."  ,
"subsystem"  ,
"Target  subsystem,
or invalid subsystem handle if order handle is invalid or order requires no subsystem target."   
)

Definition at line 7873 of file lua.cpp.

ADE_VIRTVAR ( DefaultVolume  ,
l_SoundEntry  ,
"number"  ,
"The default volume of this game sound ,
"number"  ,
"Volume in the range from 1 to 0 or -1 on error"   
)

Definition at line 8245 of file lua.cpp.

ADE_VIRTVAR ( Pitch  ,
l_Sound  ,
"number"  ,
"Pitch of  sound,
from 100 to 100000"  ,
"number"  ,
Pitch,
or 0 if handle is invalid"   
)

Definition at line 8378 of file lua.cpp.

ADE_VIRTVAR ( Duration  ,
l_Soundfile  ,
"number"  ,
"The duration of the sound  file,
in seconds"  ,
"number"  ,
"The duration or -1 on error"   
)

Definition at line 8577 of file lua.cpp.

ADE_VIRTVAR ( Filename  ,
l_Soundfile  ,
"string"  ,
"The filename of the file"  ,
"string"  ,
"The file name or empty string on error"   
)

Definition at line 8592 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_Persona  ,
"string"  ,
"The name of the persona"  ,
"string"  ,
"The name or empty string on error"   
)

Definition at line 8643 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_Message  ,
"string"  ,
"The name of the message as specified in the mission file"  ,
"string"  ,
"The name or an empty string if handle is invalid"   
)

Definition at line 8672 of file lua.cpp.

ADE_VIRTVAR ( Message  ,
l_Message  ,
"string"  ,
"The unaltered text of the  message,
see getMessage() for options to replace variables< br >" "< b >NOTE:</b > Changing the text will also change the text for messages not yet played but already in the message queue!"  ,
"string"  ,
"The message or an empty string if handle is invalid"   
)

Definition at line 8684 of file lua.cpp.

ADE_VIRTVAR ( VoiceFile  ,
l_Message  ,
"soundfile"  ,
"The voice file of the message ,
"soundfile"  ,
"The voice file handle or invalid handle when not present"   
)

Definition at line 8709 of file lua.cpp.

ADE_VIRTVAR ( Persona  ,
l_Message  ,
"persona"  ,
"The persona of the message ,
"persona"  ,
"The persona handle or invalid handle if not present"   
)

Definition at line 8750 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_Wing  ,
"string"  ,
"Name of Wing"  ,
"string"  ,
"Wing  name,
or empty string if handle is invalid"   
)

Definition at line 8835 of file lua.cpp.

ADE_VIRTVAR ( ShieldArmorClass  ,
l_Ship  ,
"string"  ,
"Current Armor class of the ships' shield"  ,
"string"  ,
"Armor class  name,
or empty string if none is set"   
)

Definition at line 8906 of file lua.cpp.

ADE_VIRTVAR ( ArmorClass  ,
l_Ship  ,
"string"  ,
"Current Armor class"  ,
"string"  ,
"Armor class  name,
or empty string if none is set"   
)

Definition at line 8933 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_Ship  ,
"string"  ,
"Ship name ,
"string"  ,
"Ship  name,
or empty string if handle is invalid"   
)

Definition at line 8960 of file lua.cpp.

ADE_VIRTVAR ( AfterburnerFuelLeft  ,
l_Ship  ,
"number"  ,
"Afterburner fuel left ,
"number"  ,
"Afterburner fuel  left,
or 0 if handle is invalid"   
)

Definition at line 8979 of file lua.cpp.

ADE_VIRTVAR ( AfterburnerFuelMax  ,
l_Ship  ,
"number"  ,
"Afterburner fuel capacity"  ,
"number"  ,
"Afterburner fuel  capacity,
or 0 if handle is invalid"   
)

Definition at line 8997 of file lua.cpp.

ADE_VIRTVAR ( Class  ,
l_Ship  ,
"shipclass"  ,
"Ship class"  ,
"shipclass"  ,
"Ship  class,
or invalid shipclass handle if ship handle is invalid"   
)

Definition at line 9015 of file lua.cpp.

ADE_VIRTVAR ( CountermeasuresLeft  ,
l_Ship  ,
"number"  ,
"Number of countermeasures left ,
"number"  ,
"Countermeasures  left,
or 0 if ship handle is invalid"   
)

Definition at line 9040 of file lua.cpp.

ADE_VIRTVAR ( CockpitDisplays  ,
l_Ship  ,
"displays"  ,
"An array of the cockpit displays on this ship.<br>NOTE: Only the ship of the player has these"  ,
"displays"  ,
"displays handle or invalid handle on error"   
)

Definition at line 9058 of file lua.cpp.

ADE_VIRTVAR ( CountermeasureClass  ,
l_Ship  ,
"weaponclass"  ,
"Weapon class mounted on this ship's countermeasure point"  ,
"weaponclass"  ,
"Countermeasure hardpoint weapon  class,
or invalid weaponclass handle if no countermeasure class or ship handle is invalid"   
)

Definition at line 9076 of file lua.cpp.

ADE_VIRTVAR ( HitpointsMax  ,
l_Ship  ,
"number"  ,
"Total hitpoints"  ,
"number"  ,
"Ship maximum  hitpoints,
or 0 if handle is invalid"   
)

Definition at line 9098 of file lua.cpp.

ADE_VIRTVAR ( WeaponEnergyLeft  ,
l_Ship  ,
"number"  ,
"Current weapon energy reserves"  ,
"number"  ,
"Ship current weapon energy reserve  level,
or 0 if invalid"   
)

Definition at line 9116 of file lua.cpp.

ADE_VIRTVAR ( WeaponEnergyMax  ,
l_Ship  ,
"number"  ,
"Maximum weapon energy"  ,
"number"  ,
"Ship maximum weapon energy reserve  level,
or 0 if invalid"   
)

Definition at line 9134 of file lua.cpp.

ADE_VIRTVAR ( PrimaryTriggerDown  ,
l_Ship  ,
"boolean"  ,
"Determines if primary trigger is pressed or not"  ,
"boolean"  ,
"True if  pressed,
false if  not,
nil if ship handle is invalid"   
)

Definition at line 9174 of file lua.cpp.

ADE_VIRTVAR ( PrimaryBanks  ,
l_Ship  ,
"weaponbanktype"  ,
"Array of primary weapon banks"  ,
"weaponbanktype"  ,
"Primary weapon  banks,
or invalid weaponbanktype handle if ship handle is invalid"   
)

Definition at line 9201 of file lua.cpp.

ADE_VIRTVAR ( SecondaryBanks  ,
l_Ship  ,
"weaponbanktype"  ,
"Array of secondary weapon banks"  ,
"weaponbanktype"  ,
"Secondary weapon  banks,
or invalid weaponbanktype handle if ship handle is invalid"   
)

Definition at line 9232 of file lua.cpp.

ADE_VIRTVAR ( TertiaryBanks  ,
l_Ship  ,
"weaponbanktype"  ,
"Array of tertiary weapon banks"  ,
"weaponbanktype"  ,
"Tertiary weapon  banks,
or invalid weaponbanktype handle if ship handle is invalid"   
)

Definition at line 9264 of file lua.cpp.

ADE_VIRTVAR ( Target  ,
l_Ship  ,
"object"  ,
"Target of ship. Value may also be a deriviative of the 'object class,
such as 'ship'."  ,
"object"  ,
"Target  object,
or invalid object handle if no target or ship handle is invalid"   
)

Definition at line 9292 of file lua.cpp.

ADE_VIRTVAR ( TargetSubsystem  ,
l_Ship  ,
"subsystem"  ,
"Target subsystem of ship."  ,
"subsystem"  ,
"Target  subsystem,
or invalid subsystem handle if no target or ship handle is invalid"   
)

Definition at line 9336 of file lua.cpp.

ADE_VIRTVAR ( Team  ,
l_Ship  ,
"team"  ,
"Ship's team ,
"team"  ,
"Ship  team,
or invalid team handle if ship handle is invalid"   
)

Definition at line 9382 of file lua.cpp.

ADE_VIRTVAR ( Textures  ,
l_Ship  ,
"shiptextures"  ,
"Gets ship textures ,
"shiptextures"  ,
"Ship  textures,
or invalid shiptextures handle if ship handle is invalid"   
)

Definition at line 9401 of file lua.cpp.

ADE_VIRTVAR ( FlagAffectedByGravity  ,
l_Ship  ,
"boolean"  ,
"Checks for the \"affected-by-gravity\" flag"  ,
"boolean"  ,
"True if flag is  set,
false if flag is not set and nil on error"   
)

Definition at line 9427 of file lua.cpp.

ADE_VIRTVAR ( Disabled  ,
l_Ship  ,
"boolean"  ,
"The disabled state of this ship ,
"boolean"  ,
"true if ship is  diabled,
false otherwise"   
)

Definition at line 9455 of file lua.cpp.

ADE_VIRTVAR ( Stealthed  ,
l_Ship  ,
"boolean"  ,
"Stealth status of this ship ,
"boolean"  ,
"true if  stealthed,
false otherwise or on error"   
)

Definition at line 9488 of file lua.cpp.

ADE_VIRTVAR ( HiddenFromSensors  ,
l_Ship  ,
"boolean"  ,
"Hidden from sensors status of this ship ,
"boolean"  ,
"true if invisible to hidden from  sensors,
false otherwise or on error"   
)

Definition at line 9519 of file lua.cpp.

ADE_VIRTVAR ( Gliding  ,
l_Ship  ,
"boolean"  ,
"Specifies whether this ship is currently gliding or not."  ,
"boolean"  ,
"true if  gliding,
false otherwise or in case of error"   
)

Definition at line 9550 of file lua.cpp.

ADE_VIRTVAR ( Orders  ,
l_Ship  ,
"shiporders"  ,
"Array of ship orders"  ,
"shiporders"  ,
"Ship  orders,
or invalid handle if ship handle is invalid"   
)

Definition at line 9628 of file lua.cpp.

ADE_VIRTVAR ( Class  ,
l_Weapon  ,
"weaponclass"  ,
"Weapon's class"  ,
"weaponclass"  ,
"Weapon  class,
or invalid weaponclass handle if weapon handle is invalid"   
)

Definition at line 10371 of file lua.cpp.

ADE_VIRTVAR ( DestroyedByWeapon  ,
l_Weapon  ,
"boolean"  ,
"Whether weapon was destroyed by another weapon ,
"boolean"  ,
"True if weapon was destroyed by another  weapon,
false if weapon was destroyed by another object or if weapon handle is invalid"   
)

Definition at line 10390 of file lua.cpp.

ADE_VIRTVAR ( LifeLeft  ,
l_Weapon  ,
"number"  ,
"Weapon life left (in seconds)"  ,
"number"  ,
"Life left (seconds) or 0 if weapon handle is invalid"   
)

Definition at line 10415 of file lua.cpp.

ADE_VIRTVAR ( FlakDetonationRange  ,
l_Weapon  ,
"number"  ,
"Range at which flak will detonate (meters)"  ,
"number"  ,
"Detonation range (meters) or 0 if weapon handle is invalid"   
)

Definition at line 10434 of file lua.cpp.

ADE_VIRTVAR ( Target  ,
l_Weapon  ,
"object"  ,
"Target of weapon. Value may also be a deriviative of the 'object class,
such as 'ship'."  ,
"object"  ,
"Weapon  target,
or invalid object handle if weapon handle is invalid"   
)

Definition at line 10453 of file lua.cpp.

ADE_VIRTVAR ( ParentTurret  ,
l_Weapon  ,
"subsystem"  ,
"Turret which fired this weapon."  ,
"subsystem"  ,
"Turret subsystem  handle,
or an invalid handle if the weapon not fired from a turret"   
)

Definition at line 10487 of file lua.cpp.

ADE_VIRTVAR ( HomingObject  ,
l_Weapon  ,
"object"  ,
"Object that weapon will home in on. Value may also be a deriviative of the 'object class,
such as 'ship'"  ,
"object"  ,
"Object that weapon is homing in  on,
or an invalid object handle if weapon is not homing or the weapon handle is invalid"   
)

Definition at line 10524 of file lua.cpp.

ADE_VIRTVAR ( HomingPosition  ,
l_Weapon  ,
"vector"  ,
"Position that weapon will home in on   World vector,
setting this without a homing object in place will not have any effect!"  ,
"vector"  ,
"Homing  point,
or null vector if weapon handle is invalid"   
)

Definition at line 10561 of file lua.cpp.

ADE_VIRTVAR ( HomingSubsystem  ,
l_Weapon  ,
"subsystem"  ,
"Subsystem that weapon will home in on."  ,
"subsystem"  ,
"Homing  subsystem,
or invalid subsystem handle if weapon is not homing or weapon handle is invalid"   
)

Definition at line 10593 of file lua.cpp.

ADE_VIRTVAR ( Team  ,
l_Weapon  ,
"team"  ,
"Weapon's team ,
"team"  ,
"Weapon  team,
or invalid team handle if weapon handle is invalid"   
)

Definition at line 10631 of file lua.cpp.

ADE_VIRTVAR ( Class  ,
l_Beam  ,
"weaponclass"  ,
"Weapon's class"  ,
"weaponclass"  ,
"Weapon  class,
or invalid weaponclass handle if beam handle is invalid"   
)

Definition at line 10689 of file lua.cpp.

ADE_VIRTVAR ( LastShot  ,
l_Beam  ,
"vector"  ,
"End point of the beam ,
"vector"  ,
"vector or null vector if beam handle is not valid"   
)

Definition at line 10708 of file lua.cpp.

ADE_VIRTVAR ( LastStart  ,
l_Beam  ,
"vector"  ,
"Start point of the beam ,
"vector"  ,
"vector or null vector if beam handle is not valid"   
)

Definition at line 10727 of file lua.cpp.

ADE_VIRTVAR ( Target  ,
l_Beam  ,
"object"  ,
"Target of beam. Value may also be a deriviative of the 'object class,
such as 'ship'."  ,
"object"  ,
"Beam  target,
or invalid object handle if beam handle is invalid"   
)

Definition at line 10746 of file lua.cpp.

ADE_VIRTVAR ( TargetSubsystem  ,
l_Beam  ,
"subsystem"  ,
"Subsystem that beam is targeting."  ,
"subsystem"  ,
"Target  subsystem,
or invalid subsystem handle if beam handle is invalid"   
)

Definition at line 10782 of file lua.cpp.

ADE_VIRTVAR ( ParentShip  ,
l_Beam  ,
"object"  ,
"Parent of the beam."  ,
"object"  ,
"Beam  parent,
or invalid object handle if beam handle is invalid"   
)

Definition at line 10819 of file lua.cpp.

ADE_VIRTVAR ( ParentSubsystem  ,
l_Beam  ,
"subsystem"  ,
"Subsystem that beam is fired from."  ,
"subsystem"  ,
"Parent  subsystem,
or invalid subsystem handle if beam handle is invalid"   
)

Definition at line 10855 of file lua.cpp.

ADE_VIRTVAR ( Name  ,
l_Camera  ,
"string"  ,
"New camera name ,
"string"  ,
"Camera name  
)

Definition at line 11170 of file lua.cpp.

ADE_VIRTVAR ( FOV  ,
l_Camera  ,
"number"  ,
"New camera FOV (in radians)"  ,
"number"  ,
"Camera FOV (in radians)"   
)

Definition at line 11187 of file lua.cpp.

ADE_VIRTVAR ( Orientation  ,
l_Camera  ,
"orientation"  ,
"New camera orientation"  ,
"orientation"  ,
"Camera orientation"   
)

Definition at line 11204 of file lua.cpp.

ADE_VIRTVAR ( Position  ,
l_Camera  ,
"vector"  ,
"New camera position"  ,
"vector"  ,
"Camera position"   
)

Definition at line 11223 of file lua.cpp.

ADE_VIRTVAR ( Self  ,
l_Camera  ,
"object"  ,
"New mount object ,
"object"  ,
"Camera object  
)

Definition at line 11242 of file lua.cpp.

ADE_VIRTVAR ( SelfSubsystem  ,
l_Camera  ,
"subsystem"  ,
"New mount object subsystem"  ,
"subsystem"  ,
"Subsystem that the camera is mounted on"   
)

Definition at line 11259 of file lua.cpp.

ADE_VIRTVAR ( Target  ,
l_Camera  ,
"object"  ,
"New target object ,
"object"  ,
"Camera target object  
)

Definition at line 11297 of file lua.cpp.

ADE_VIRTVAR ( TargetSubsystem  ,
l_Camera  ,
"subsystem"  ,
"New target subsystem"  ,
"subsystem"  ,
"Subsystem that the camera is pointed at"   
)

Definition at line 11314 of file lua.cpp.

ADE_VIRTVAR ( Pitch  ,
l_Control_Info  ,
"number"  ,
"Pitch of the player ship ,
"number"  ,
"Pitch"   
)

Definition at line 11436 of file lua.cpp.

ADE_VIRTVAR ( Heading  ,
l_Control_Info  ,
"number"  ,
"Heading of the player ship ,
"number"  ,
"Heading"   
)

Definition at line 11451 of file lua.cpp.

ADE_VIRTVAR ( Bank  ,
l_Control_Info  ,
"number"  ,
"Bank of the player ship ,
"number"  ,
"Bank"   
)

Definition at line 11466 of file lua.cpp.

ADE_VIRTVAR ( Vertical  ,
l_Control_Info  ,
"number"  ,
"Vertical control of the player ship ,
"number"  ,
"Vertical control"   
)

Definition at line 11481 of file lua.cpp.

ADE_VIRTVAR ( Sideways  ,
l_Control_Info  ,
"number"  ,
"Sideways control of the player ship ,
"number"  ,
"Sideways control"   
)

Definition at line 11496 of file lua.cpp.

ADE_VIRTVAR ( Forward  ,
l_Control_Info  ,
"number"  ,
"Forward control of the player ship ,
"number"  ,
"Forward"   
)

Definition at line 11511 of file lua.cpp.

ADE_VIRTVAR ( ForwardCruise  ,
l_Control_Info  ,
"number"  ,
"Forward control of the player ship ,
"number"  ,
"Forward"   
)

Definition at line 11526 of file lua.cpp.

ADE_VIRTVAR ( PrimaryCount  ,
l_Control_Info  ,
"number"  ,
"Number of primary weapons that will fire"  ,
"number"  ,
"Number of weapons to  fire,
or 0 if handle is invalid"   
)

Definition at line 11541 of file lua.cpp.

ADE_VIRTVAR ( SecondaryCount  ,
l_Control_Info  ,
"number"  ,
"Number of secondary weapons that will fire"  ,
"number"  ,
"Number of weapons to  fire,
or 0 if handle is invalid"   
)

Definition at line 11556 of file lua.cpp.

ADE_VIRTVAR ( CountermeasureCount  ,
l_Control_Info  ,
"number"  ,
"Number of countermeasures that will launch"  ,
"number"  ,
"Number of countermeasures to  launch,
or 0 if handle is invalid"   
)

Definition at line 11571 of file lua.cpp.

ADE_VIRTVAR ( AllButtonPolling  ,
l_Control_Info  ,
"boolean"  ,
"Toggles the all button polling for lua"  ,
"boolean"  ,
"If the all button polling is enabled or not"   
)

Definition at line 11690 of file lua.cpp.

ADE_VIRTVAR ( Age  ,
l_Particle  ,
"number"  ,
"The time this particle already lives"  ,
"number"  ,
"The current age or -1 on error"   
)

Definition at line 11806 of file lua.cpp.

ADE_VIRTVAR ( MaximumLife  ,
l_Particle  ,
"number"  ,
"The time this particle can live"  ,
"number"  ,
"The maximal life or -1 on error"   
)

Definition at line 11828 of file lua.cpp.

ADE_VIRTVAR ( Radius  ,
l_Particle  ,
"number"  ,
"The radius of the particle ,
"number"  ,
"The radius or -1 on error"   
)

Definition at line 11850 of file lua.cpp.

ADE_VIRTVAR ( TracerLength  ,
l_Particle  ,
"number"  ,
"The tracer legth of the particle ,
"number"  ,
"The radius or -1 on error"   
)

Definition at line 11872 of file lua.cpp.

ADE_VIRTVAR ( AttachedObject  ,
l_Particle  ,
"object"  ,
"The object this particle is attached to. If valid the position will be relativ to this object and the velocity will be ignored."  ,
"object"  ,
"Attached object or invalid object handle on error"   
)

Definition at line 11894 of file lua.cpp.

ADE_VIRTVAR ( MouseControlStatus  ,
l_Mouse  ,
"boolean"  ,
"Gets and sets the retail mouse control status"  ,
"boolean"  ,
"if the retail mouse is on or off"   
)

Definition at line 12706 of file lua.cpp.

ADE_VIRTVAR ( HUDDrawn  ,
l_HUD  ,
"boolean"  ,
"Current HUD draw status"  ,
"boolean"  ,
"If the HUD is drawn or not"   
)

Definition at line 12811 of file lua.cpp.

ADE_VIRTVAR ( HUDDisabledExceptMessages  ,
l_HUD  ,
"boolean"  ,
"Specifies if only the messages gauges of the hud are drawn"  ,
"boolean"  ,
"true if only the message gauges are  drawn,
false otherwise"   
)

Definition at line 12832 of file lua.cpp.

ADE_VIRTVAR ( CurrentFont  ,
l_Graphics  ,
"font"  ,
"Current font ,
"font"  ,
NULL   
)

Definition at line 12960 of file lua.cpp.

ADE_VIRTVAR ( CurrentOpacityType  ,
l_Graphics  ,
"enumeration"  ,
"Current alpha blending type; uses ALPHABLEND_* enumerations"  ,
"enumeration"  ,
NULL   
)

Definition at line 13035 of file lua.cpp.

ADE_VIRTVAR ( CurrentRenderTarget  ,
l_Graphics  ,
"texture"  ,
"Current rendering target ,
"texture"  ,
"Current rendering  target,
or invalid texture handle if screen is render target  
)

Definition at line 13063 of file lua.cpp.

Assert ( pm!  = NULL)
int cfread_lua_number ( double *  buf,
CFILE cfile 
)

Definition at line 234 of file cfilearchive.cpp.

for ( )

Definition at line 449 of file lua.cpp.

gr_set_cursor_bitmap ( bm_load(s ,
ul   
)
if ( !numargs||s!  [1] = '\0')
else if ( s  [0] = ='p') = -2
else if ( atoi(s )
if ( idx< -3||idx==0||idx 9)
if ( )

Definition at line 375 of file lua.cpp.

if ( ADE_SETTING_VAR &&*val!  = newval)

Definition at line 392 of file lua.cpp.

if ( ade_get_argsL,"oof", l_Matrix.GetPtr(&oriA), l_Matrix.GetPtr(&oriB),&factor)
if ( ade_get_argsL,"o", l_Matrix.GetPtr(&mh))
Initial value:
{
matrix_h *mh = NULL
matrix_h * mh
Definition: lua.cpp:4789
if ( ade_get_argsL,"o|i", l_Event.Get(&idx),&newinterval)
if ( idx< 0||idx = Num_mission_events)
if ( ADE_SETTING_VAR  )

Definition at line 1019 of file lua.cpp.

if ( ade_get_argsL,"o|s", l_Font.Get(&font_num),&newname)
if ( font_num< 0||font_num >  = Num_fonts)
if ( ade_get_argsL,"o|i", l_Font.Get(&font_num),&newheight)
if ( ADE_SETTING_VAR &&  newheight,
 
)

Definition at line 1400 of file lua.cpp.

if ( ade_get_argsL,"o|o", l_Eyepoint.GetPtr(&eh), l_Vector.GetPtr(&v))
if ( !eh->  IsValid())
if ( ADE_SETTING_VAR &&v!  = NULL)

Definition at line 1600 of file lua.cpp.

if ( ade_get_argsL,"o|f", l_Model.GetPtr(&mdl),&nr)
if ( pm  = = NULL)
if ( ade_get_argsL,"o|o", l_Glowpoint.GetPtr(&glh), l_Vector.Get(&newVec))
if ( !glh->  isValid())
if ( ade_get_argsL,"o|o", l_Physics.GetPtr(&pih), l_Vector.GetPtr(&v3))
if ( !pih->  IsValid())
if ( ADE_SETTING_VAR &&v3!  = NULL)

Definition at line 2508 of file lua.cpp.

if ( ade_get_argsL,"o|f", l_Physics.GetPtr(&pih),&f)
if ( lua_isstring(L, 2)  )

Definition at line 3108 of file lua.cpp.

if ( ade_get_argsL,"oo|f", l_Shields.GetPtr(&objh), l_Enum.GetPtr(&qd),&nval)
if ( !objh->  IsValid())
if ( qdx  = = -1)

Definition at line 3160 of file lua.cpp.

if ( ADE_SETTING_VAR &&nval >=0.  0f)

Definition at line 3188 of file lua.cpp.

if ( ade_get_argsL,"o|f", l_Shields.GetPtr(&objh),&nval)
if ( lua_isnumber(L, 1)||lua_isnumber(L, 2)  )
Initial value:
{
Definition: pstypes.h:88
vec3d vmd_zero_vector
Definition: vecmat.cpp:24
GLfloat GLfloat GLfloat GLfloat v3
Definition: Glext.h:5641

Definition at line 3616 of file lua.cpp.

if ( ade_get_argsL,"oo", l_Vector.GetPtr(&v1), l_Vector.GetPtr(&v2))
if ( ade_get_argsL,"o", l_Vector.GetPtr(&v3))
Initial value:
{
Definition: pstypes.h:88
GLfloat GLfloat GLfloat GLfloat v3
Definition: Glext.h:5641
if ( ade_get_argsL,"o|f", l_Weaponclass.Get(&idx),&f)
if ( ade_get_argsL,"o", l_Weaponclass.Get(&idx))
Initial value:
{
int idx
int idx
Definition: lua.cpp:360
if ( Weapon_info.  subtype[idx] = =WP_LASER)
if ( ade_get_argsL,"o|b", l_ColInfo.GetPtr(&info),&local)
if ( !info->  IsValid())
if ( collide->num_hits<=  0)

Definition at line 4534 of file lua.cpp.

if ( ade_get_argsL,"o", l_Object.GetPtr(&objh))
if ( ade_get_argsL,"o|o", l_Object.GetPtr(&objh), l_Vector.GetPtr(&v3))
if ( ade_get_argsL,"o|o", l_Object.GetPtr(&objh), l_Matrix.GetPtr(&mh))
if ( ADE_SETTING_VAR &&mh!  = NULL)

Definition at line 4796 of file lua.cpp.

if ( ade_get_argsL,"ooo|b", l_Object.GetPtr(&objh), l_Vector.GetPtr(&v3a), l_Vector.GetPtr(&v3b),&local)
else if ( obj->  type = OBJ_SHIP)

Definition at line 5035 of file lua.cpp.

if ( !model_collide hull_check)

Definition at line 5055 of file lua.cpp.

if ( local  )
if ( numargs)
if ( !bh->  IsValid())
if ( ade_get_argsL,"o|o", l_Subsystem.GetPtr(&sso), l_Vector.GetPtr(&v))
if ( !sso->  IsValid())
if ( ade_get_argsL,"o|i", l_Subsystem.GetPtr(&sso),&newVal)
if ( sso->ss->system_info->flags &MSS_FLAG_TURRET_RESET_IDLE)
if ( ade_get_argsL,"o|f", l_Subsystem.GetPtr(&sso),&newVal)
if ( ade_get_argsL,"o|f", l_Ship.GetPtr(&objh),&fov)
if ( ADE_SETTING_VAR &&fov >=0.  0f)

Definition at line 9164 of file lua.cpp.

if ( ade_get_argsL,"o|i", l_Ship.GetPtr(&objh),&ets_idx)
if ( ade_get_argsL,"o", l_Ship.GetPtr(&objh))
Initial value:
{
object_h *objh
if ( ade_get_argsL,"o|si", l_Ship.GetPtr(&objh),&s,&subtype)
if ( ade_get_argsL,"o|o", l_Particle.GetPtr(&ph), l_Vector.Get(&newVec))
if ( ph  = = NULL)
if ( !ph->  isValid())
if ( depth  ,
gameseq_get_depth()   
)
if ( ade_get_argsL,"s|o",&s, l_Enum.GetPtr(&u))
if ( u!  = NULL)

Definition at line 12654 of file lua.cpp.

if ( ade_get_args(L,"ii",&x,&y))
if ( (x >=0)&&(x<=gr_screen.max_w))
if ( (y >=0)&&(y<=gr_screen.max_h))
if ( ade_get_argsL,"i|iiii",&idx,&r,&g,&b,&a)
if ( (idx< 0)||(idx >=NUM_HUD_GAUGES )
if ( ade_get_argsL,"i",&idx)
if ( Game_mode GM_CAMPAIGN_MODE)

Definition at line 15460 of file lua.cpp.

if ( ade_get_argsL,"ii",&a,&b)
Initial value:
{
int a, b
int a
Definition: lua.cpp:12856
GLboolean GLboolean GLboolean b
Definition: Glext.h:5781
if ( (b >=0)&&(b< 32))
if ( a 1<< b)
if ( ade_get_argsL,"s",&filename)
int l_cf_get_path_id ( char *  n_path)

Definition at line 12452 of file lua.cpp.

void model_calc_bound_box ( vec3d box,
vec3d big_mn,
vec3d big_mx 
)

Definition at line 1009 of file modelread.cpp.

mouse_set_pos ( x  ,
y   
)
movie_play ( filename  )
l_Matrix Set ( matrix_h()  )
l_Matrix Set ( matrix_h vmd_identity_matrix)
l_Vector Set ( hull_check.  hit_point)
l_GameState Set ( gamestate_h()  )
void ship_reset_disabled_physics ( object objp,
int  ship_class 
)

Reset some physics info when ship's engines goes from disabled->enabled

Definition at line 8974 of file ship.cpp.

sprintf ( buf  ,
"(%f,%f,%f)"  ,
v3->xyz.  x,
v3->xyz.  y,
v3->xyz.  z 
)
switch ( qd->  index)

Definition at line 3137 of file lua.cpp.

switch ( objh->objp->  type)

Definition at line 4701 of file lua.cpp.

switch ( obj->  type)

Definition at line 5009 of file lua.cpp.

switch ( bh->  type)

Definition at line 6794 of file lua.cpp.

bool turret_fire_weapon ( int  weapon_num,
ship_subsys turret,
int  parent_objnum,
vec3d turret_pos,
vec3d turret_fvec,
vec3d predicted_pos = NULL,
float  flak_range_override = 100.0f 
)

Fire a weapon from a turret

Definition at line 1832 of file aiturret.cpp.

Variable Documentation

matrix* A = oriA->GetMatrix()

Definition at line 444 of file lua.cpp.

int a = 0

Definition at line 12856 of file lua.cpp.

lua_Debug Ade_debug_info

Definition at line 15807 of file lua.cpp.

bool Ade_get_args_lfunction = false

Definition at line 16098 of file lua.cpp.

int Ade_get_args_skip = 0

Definition at line 16097 of file lua.cpp.

int ade_Num_operators = sizeof(ade_Operators)/sizeof(string_conv)

Definition at line 202 of file lua.cpp.

string_conv ade_Operators[]
Initial value:
= {
{"__add", "+"},
{"__sub", "-"},
{"__mul", "*"},
{"__div", "/"},
{"__mod", "%"},
{"__pow", "^"},
{"__unm", "~"},
{"__concat", ".."},
{"__len", "#"},
{"__eq", "=="},
{"__lt", "<"},
{"__le", "<="},
{"__newindex", "="},
{"__call", ""},
{"__gc", "__gc"},
{"__tostring", "(string)"},
{"__indexer", "[]"},
}

Definition at line 180 of file lua.cpp.

else return ADE_RETURN_FALSE

Definition at line 4364 of file lua.cpp.

return ADE_RETURN_NIL
Initial value:
{
Warning(LOCATION, "%s", lua_tostring(L, -1))
void _cdecl void void _cdecl void _cdecl Warning(char *filename, int line, SCP_FORMAT_STRING const char *format,...) SCP_FORMAT_STRING_ARGS(3
#define LOCATION
Definition: pstypes.h:245

Definition at line 12181 of file lua.cpp.

return ADE_RETURN_TRUE

Definition at line 12703 of file lua.cpp.

SCP_vector<ade_table_entry> Ade_table_entries

Definition at line 61 of file lua.cpp.

matrix* B = oriB->GetMatrix()

Definition at line 445 of file lua.cpp.

int b = 0

Definition at line 6789 of file lua.cpp.

char buf[512]

Definition at line 3672 of file lua.cpp.

else c = HUD_config.clr[idx]

Definition at line 12879 of file lua.cpp.

mc_info * collide = info->Get()

Definition at line 4532 of file lua.cpp.

char debug_stack[4][32]

Definition at line 15808 of file lua.cpp.

else
Initial value:
{
idx--
int idx
Definition: lua.cpp:360

Definition at line 387 of file lua.cpp.

int ets_idx = 0

Definition at line 9580 of file lua.cpp.

f = 0.0f

Definition at line 358 of file lua.cpp.

float factor = 0.0f

Definition at line 440 of file lua.cpp.

false

Definition at line 6789 of file lua.cpp.

Attempted to set incomplete feature

Definition at line 9589 of file lua.cpp.

Definition at line 446 of file lua.cpp.

Definition at line 5006 of file lua.cpp.

float fov = -1

Definition at line 9155 of file lua.cpp.

int g = 0

Definition at line 12854 of file lua.cpp.

gr_init_alphacolor&[idx] HUD_config

Definition at line 12864 of file lua.cpp.

mc_info_init & hull_check

Definition at line 5043 of file lua.cpp.

i = 0

Definition at line 1012 of file lua.cpp.

int idx =0

Definition at line 360 of file lua.cpp.

const size_t INVALID_ID = (size_t) -1

Definition at line 215 of file lua.cpp.

ade_obj<object_h> l_Asteroid("asteroid","Asteroid handle",&l_Object)
ade_lib l_Audio("Audio", NULL,"ad","Sound/Music Library")
ade_lib l_Base("Base", NULL,"ba","Base FreeSpace 2 functions")
ade_lib l_Base_Events("GameEvents",&l_Base, NULL,"Freespace 2 game events")
ade_lib l_Base_States("GameStates",&l_Base, NULL,"Freespace 2 states")
ade_obj<object_h> l_Beam("beam","Beam handle",&l_Object)
ade_lib l_BitOps("BitOps", NULL,"bit","Bitwise Operations library")
ade_obj<camid> l_Camera("camera","Camera handle")
ade_lib l_Campaign("Campaign", NULL,"ca","Campaign Library")
ade_lib l_CFile("CFile", NULL,"cf","CFile FS2 filesystem access")
ade_obj<cockpit_display_h> l_CockpitDisplay("display","Cockpit display handle")
ade_obj<cockpit_displays_info_h> l_CockpitDisplayInfos("cockpitdisplays","Array of cockpit display information")
ade_obj<cockpit_displays_h> l_CockpitDisplays("displays","Player cockpit displays array handle")
ade_obj<mc_info_h> l_ColInfo("collision info","Information about a collision")
ade_obj<int> l_Control_Info("control info","control info handle")
ade_obj<object_h> l_Debris("debris","Debris handle",&l_Object)
ade_obj<cockpit_disp_info_h> l_DisplayInfo("display info","Ship cockpit display information handle")
ade_obj<dockingbay_h> l_Dockingbay("dockingbay","Handle to a model docking bay")
ade_obj<dockingbays_h> l_Dockingbays("dockingbays","The docking bays of a model")
ade_obj<enum_h> l_Enum("enumeration","Enumeration object")
ade_obj<int> l_Event("event","Mission event handle")
ade_obj<eye_h> l_Eyepoint("eyepoint","Eyepoint handle")
ade_obj<eyepoints_h> l_Eyepoints("eyepoints","Array of model eye points")
ade_obj<CFILE*> l_File("file","File handle")
ade_obj<int> l_Font("font","font handle")
ade_obj<gameevent_h> l_GameEvent("gameevent","Game event")
ade_obj<gamestate_h> l_GameState("gamestate","Game state")
ade_obj<glowpoint_h> l_Glowpoint("glowpoint","A model glowpoint")
ade_lib l_Graphics("Graphics", NULL,"gr","Graphics Library")
ade_lib l_Graphics_Cameras("Cameras",&l_Graphics, NULL,"Cameras")
ade_lib l_Graphics_Fonts("Fonts",&l_Graphics, NULL,"Font library")
ade_lib l_Graphics_Posteffects("PostEffects",&l_Graphics, NULL,"Post processing effects")
ade_lib l_HookVar("HookVariables", NULL,"hv","Hook variables repository")
ade_lib l_HookVar_Globals("Globals",&l_HookVar)
ade_lib l_HUD("HUD", NULL,"hu","HUD library")
ade_obj<HudGauge> l_HudGauge("HudGauge","HUD Gauge handle")
ade_obj<matrix_h> l_Matrix("orientation","Orientation matrix object")
ade_obj<int> l_Message("message","Handle to a mission message")
ade_lib l_Mission("Mission", NULL,"mn","Mission library")
ade_lib l_Mission_Asteroids("Asteroids",&l_Mission, NULL,"Asteroids in the mission")
ade_lib l_Mission_Beams("Beams",&l_Mission, NULL, NULL)
ade_lib l_Mission_BuiltinMessages("BuiltinMessages",&l_Mission, NULL, NULL)
ade_lib l_Mission_Debris("Debris",&l_Mission, NULL,"debris in the mission")
ade_lib l_Mission_EscortShips("EscortShips",&l_Mission, NULL, NULL)
ade_lib l_Mission_Events("Events",&l_Mission, NULL,"Events")
ade_lib l_Mission_Messages("Messages",&l_Mission, NULL, NULL)
ade_lib l_Mission_Personas("Personas",&l_Mission, NULL, NULL)
ade_lib l_Mission_SEXPVariables("SEXPVariables",&l_Mission, NULL,"SEXP Variables")
ade_lib l_Mission_Ships("Ships",&l_Mission, NULL,"Ships in the mission")
ade_lib l_Mission_Teams("Teams",&l_Mission, NULL, NULL)
ade_lib l_Mission_WaypointLists("WaypointLists",&l_Mission, NULL, NULL)
ade_lib l_Mission_Waypoints("Waypoints",&l_Mission, NULL, NULL)
ade_lib l_Mission_Weapons("Weapons",&l_Mission, NULL, NULL)
ade_lib l_Mission_Wings("Wings",&l_Mission, NULL, NULL)
ade_obj<model_h> l_Model("model","3D Model (POF) handle")
ade_obj<modeltextures_h> l_ModelTextures("modeltextures_h","Array of materials")
ade_lib l_Mouse("Controls", NULL,"io","Controls library")
ade_obj<order_h> l_Order("order","order handle")
ade_obj<particle_h> l_Particle("particle","Handle to a particle")
ade_obj<int> l_Persona("persona","Persona handle")
ade_obj<physics_info_h> l_Physics("physics","Physics handle")
ade_obj<int> l_Player("player","Player handle")
ade_obj<sexpvar_h> l_SEXPVariable("sexpvariable","SEXP Variable handle")
ade_obj<object_h> l_Shields("shields","Shields handle")
ade_obj<object_h> l_Ship("ship","Ship handle",&l_Object)
ade_obj<int> l_Shipclass("shipclass","Ship class handle")
ade_obj<object_h> l_ShipOrders("shiporders","Ship orders")
ade_obj<object_h> l_ShipTextures("shiptextures","Ship textures handle")
ade_obj<int> l_Shiptype("shiptype","Ship type handle")
ade_obj<sound_h> l_Sound("sound","sound instance handle")
ade_obj<sound_h> l_Sound3D("3Dsound","3D sound instance handle",&l_Sound)
ade_obj<sound_entry_h> l_SoundEntry("soundentry","sounds.tbl table entry handle")
ade_obj<int> l_Soundfile("soundfile","Handle to a sound file")
ade_obj<int> l_Species("species","Species handle")
ade_obj<ship_subsys_h> l_Subsystem("subsystem","Ship subsystem handle")
ade_lib l_Tables("Tables", NULL,"tb","Tables library")
ade_lib l_Tables_ShipClasses("ShipClasses",&l_Tables, NULL, NULL)
ade_lib l_Tables_WeaponClasses("WeaponClasses",&l_Tables, NULL, NULL)
ade_obj<int> l_Team("team","Team handle")
ade_lib l_Testing("Testing", NULL,"ts","Experimental or testing stuff")
ade_obj<int> l_Texture("texture","Texture handle")
ade_obj<texture_map_h> l_TextureMap("material","Texture map, including diffuse, glow, and specular textures")
ade_obj<thrusterbank_h> l_Thrusterbank("thrusterbank","A model thrusterbank")
ade_obj<thrusters_h> l_Thrusters("thrusters","The thrusters of a model")
ade_obj<vec3d> l_Vector("vector","Vector object")
ade_obj<object_h> l_Waypoint("waypoint","waypoint handle",&l_Object)
ade_obj<waypointlist_h> l_WaypointList("waypointlist","waypointlist handle")
ade_obj<object_h> l_Weapon("weapon","Weapon handle",&l_Object)
ade_obj<ship_bank_h> l_WeaponBank("weaponbank","Ship/subystem weapons bank handle")
ade_obj<ship_banktype_h> l_WeaponBankType("weaponbanktype","Ship/subsystem weapons bank type handle")
ade_obj<int> l_Weaponclass("weaponclass","Weapon class handle")
ade_obj<int> l_Wing("wing","Wing handle")
bool local = false

Definition at line 4524 of file lua.cpp.

float Master_event_music_volume

Definition at line 40 of file eventmusic.cpp.

Definition at line 1017 of file lua.cpp.

matrix_h * mh =NULL

Definition at line 4789 of file lua.cpp.

hull_check model_instance_num = -1

Definition at line 4996 of file lua.cpp.

hull_check model_num = -1

Definition at line 4996 of file lua.cpp.

int mouse_inited

Definition at line 30 of file mouse.cpp.

bool newfire = false

Definition at line 6817 of file lua.cpp.

int newheight = -1

Definition at line 1393 of file lua.cpp.

int newinterval = 0

Definition at line 1010 of file lua.cpp.

bool newlink = false

Definition at line 6785 of file lua.cpp.

char* newname = NULL

Definition at line 1376 of file lua.cpp.

float newval = 0.0f

Definition at line 354 of file lua.cpp.

float newVal = -1

Definition at line 7233 of file lua.cpp.

vec3d newVec
Initial value:
{
glowpoint_h *glh = NULL

Definition at line 2163 of file lua.cpp.

float nr = 0.0f

Definition at line 1945 of file lua.cpp.

int num_plr_commands = sizeof(plr_commands)/sizeof(flag_def_list)

Definition at line 877 of file lua.cpp.

int numargs = ade_get_args(L, "os|f", l_Matrix.GetPtr(&mh), &s, &newval)

Definition at line 355 of file lua.cpp.

float nval = -1.0f

Definition at line 3103 of file lua.cpp.

o

Definition at line 442 of file lua.cpp.

obj = NULL

Definition at line 4995 of file lua.cpp.

objp = NULL

Definition at line 3105 of file lua.cpp.

int Om_tracker_flag

Definition at line 247 of file optionsmenumulti.cpp.

oo

Definition at line 5060 of file lua.cpp.

matrix_h* oriB = NULL

Definition at line 439 of file lua.cpp.

hull_check orient = &obj->orient

Definition at line 5049 of file lua.cpp.

Definition at line 5051 of file lua.cpp.

Definition at line 5052 of file lua.cpp.

flag_def_list plr_commands[]

Definition at line 756 of file lua.cpp.

polymodel * pm = model_get(eh->model)

Definition at line 1598 of file lua.cpp.

hull_check pos = &obj->pos

Definition at line 5050 of file lua.cpp.

qdx = -1

Definition at line 3106 of file lua.cpp.

int r = 0

Definition at line 12853 of file lua.cpp.

char* s = NULL

Definition at line 353 of file lua.cpp.

ship* shipp = &Ships[objh->objp->instance]

Definition at line 9162 of file lua.cpp.

int ships_inited

Definition at line 129 of file ship.cpp.

bsp_info* sm = &pm->submodel[sso->ss->system_info->turret_gun_sobj]

Definition at line 7079 of file lua.cpp.

int Species_initted

Definition at line 3259 of file lua.cpp.

int submodel = -1

Definition at line 5007 of file lua.cpp.

hull_check submodel_num = submodel

Definition at line 5048 of file lua.cpp.

int subtype =-1

Definition at line 9763 of file lua.cpp.

int temp = 0

Definition at line 4996 of file lua.cpp.

int time_ms = model_anim_get_time_type(&Ships[objh->objp->instance], type, subtype)

Definition at line 9774 of file lua.cpp.

float time_s = (float)time_ms / 1000.0f

Definition at line 9775 of file lua.cpp.

Definition at line 9770 of file lua.cpp.

enum_h* u = NULL

Definition at line 12649 of file lua.cpp.

int ul = 0

Definition at line 12653 of file lua.cpp.

vec3d* v
Initial value:
{
eye_h *eh
Definition: lua.cpp:1551

Definition at line 1589 of file lua.cpp.

vec3d* v2 = NULL

Definition at line 3628 of file lua.cpp.

vec3d* v3 =NULL

Definition at line 2501 of file lua.cpp.

vec3d* v3a

Definition at line 4997 of file lua.cpp.

vec3d * v3b

Definition at line 4997 of file lua.cpp.

val = NULL

Definition at line 374 of file lua.cpp.

vec3d vec = glh->point->pnt

Definition at line 2173 of file lua.cpp.

int Weapons_inited

Definition at line 108 of file weapons.cpp.

int x = v1->xyz.x * v2->xyz.x

Definition at line 3632 of file lua.cpp.

int y = v1->xyz.y * v2->xyz.y

Definition at line 3633 of file lua.cpp.

v3 xyz z = v1->xyz.z * v2->xyz.z

Definition at line 3634 of file lua.cpp.