UFO: Alien Invasion
game_import_t Struct Reference

functions provided by the main engine More...

#include <game.h>

Collaboration diagram for game_import_t:
Collaboration graph

Public Member Functions

 void (IMPORT *BroadcastPrintf)(int printlevel
 
const char __attribute__ ((format(__printf__, 2, 3)))
 
 void (IMPORT *DPrintf)(const char *fmt
 
 __attribute__ ((format(__printf__, 1, 2)))
 
 void (IMPORT *PlayerPrintf)(const player_t *player
 
 void (IMPORT *ConfigString)(int num
 
const char __attribute__ ((format(__printf__, 2, 3)))
 
 void (IMPORT *Error)(const char *fmt
 
 __attribute__ ((noreturn, format(__printf__, 1, 2)))
 
unsigned int (IMPORT *ModelIndex)(const char *name)
 
 void (IMPORT *SetInlineModelOrientation)(const char *name
 
 void (IMPORT *GetInlineModelAABB)(const char *name
 
 void (IMPORT *SetModel)(edict_t *ent
 
 trace_t (IMPORT *Trace)(const Line &traceLine
 collision detection More...
 
 int (IMPORT *PointContents)(const vec3_t point)
 
const char *IMPORTGetFootstepSound (const char *texture)
 
 float (IMPORT *GetBounceFraction)(const char *texture)
 
 bool (IMPORT *LoadModelAABB)(const char *model
 
 void (IMPORT *LinkEdict)(edict_t *ent)
 
 void (IMPORT *UnlinkEdict)(edict_t *ent)
 
 bool (IMPORT *TestLine)(const vec3_t start
 fast version of a line trace but without including entities More...
 
 bool (IMPORT *TestLineWithEnt)(const vec3_t start
 fast version of a line trace that also includes entities More...
 
 float (IMPORT *GrenadeTarget)(const vec3_t from
 
 void (IMPORT *GridCalcPathing)(actorSizeEnum_t actorSize
 
 bool (IMPORT *GridFindPath)(const actorSizeEnum_t actorSize
 
 void (IMPORT *MoveStore)(pathing_t *path)
 
 pos_t (IMPORT *MoveLength)(const pathing_t *path
 
 int (IMPORT *MoveNext)(const pathing_t *path
 
 int (IMPORT *GetTUsForDirection)(int dir
 
 pos_t (IMPORT *GridFall)(actorSizeEnum_t actorSize
 
 void (IMPORT *GridPosToVec)(actorSizeEnum_t actorSize
 
 bool (IMPORT *isOnMap)(const vec3_t vec)
 
 void (IMPORT *GridRecalcRouting)(const char *name
 
 bool (IMPORT *CanActorStandHere)(actorSizeEnum_t actorSize
 
 bool (IMPORT *GridShouldUseAutostand)(const pathing_t *path
 
 float (IMPORT *GetVisibility)(const pos3_t position)
 
const char *IMPORTFS_Gamedir (void)
 
 int (IMPORT *FS_LoadFile)(const char *path
 
 void (IMPORT *FS_FreeFile)(void *buffer)
 
FILE *IMPORTSys_Fopen (const char *filename, const char *mode)
 
 void (IMPORT *WriteChar)(char c)
 
 void (IMPORT *WriteByte)(byte c)
 
 void (IMPORT *WriteShort)(int c)
 
 void (IMPORT *WriteLong)(int c)
 
 void (IMPORT *WriteString)(const char *s)
 
 void (IMPORT *WritePos)(const vec3_t pos)
 
 void (IMPORT *WriteGPos)(const pos3_t pos)
 
 void (IMPORT *WriteDir)(const vec3_t pos)
 
 void (IMPORT *WriteAngle)(float f)
 
 void (IMPORT *WriteFormat)(const char *format
 
 void (IMPORT *AbortEvents)(void)
 
 void (IMPORT *EndEvents)(void)
 
 void (IMPORT *AddEvent)(unsigned int mask
 
 int (IMPORT *GetEvent)(void)
 
edict_t *IMPORTGetEventEdict (void)
 
 void (IMPORT *QueueEvent)(unsigned int mask
 
 void (IMPORT *QueueWriteByte)(byte c)
 
 void (IMPORT *QueueWritePos)(const vec3_t pos)
 
 void (IMPORT *QueueWriteString)(const char *s)
 
 void (IMPORT *QueueWriteShort)(int c)
 
 int (IMPORT *ReadChar)(void)
 
 int (IMPORT *ReadByte)(void)
 
 int (IMPORT *ReadShort)(void)
 
 int (IMPORT *ReadLong)(void)
 
 int (IMPORT *ReadString)(char *str
 
 void (IMPORT *ReadPos)(vec3_t pos)
 
 void (IMPORT *ReadGPos)(pos3_t pos)
 
 void (IMPORT *ReadDir)(vec3_t vector)
 
 float (IMPORT *ReadAngle)(void)
 
 void (IMPORT *ReadData)(void *buffer
 
 void (IMPORT *ReadFormat)(const char *format
 
 bool (IMPORT *GetConstInt)(const char *name
 
 bool (IMPORT *GetConstIntFromNamespace)(const char *space
 
const char *IMPORTGetConstVariable (const char *space, int value)
 
 void (IMPORT *RegisterConstInt)(const char *name
 
 bool (IMPORT *UnregisterConstVariable)(const char *name)
 
 void (IMPORT *GetCharacterValues)(const char *teamDefinition
 
void *IMPORTTagMalloc (int size, int tag, const char *file, int line)
 
 void (IMPORT *TagFree)(void *block
 
 void (IMPORT *FreeTags)(int tag
 
cvar_t *IMPORTCvar_Get (const char *varName, const char *value, int flags, const char *desc)
 
cvar_t *IMPORTCvar_Set (const char *varName, const char *value,...) __attribute__((format(__printf__
 
cvar_t *IMPORT const char *IMPORTCvar_String (const char *varName)
 
 int (IMPORT *Cmd_Argc)(void)
 
const char *IMPORTCmd_Argv (int n)
 
const char *IMPORTCmd_Args (void)
 
 void (IMPORT *AddCommandString)(const char *text
 
 __attribute__ ((format(__printf__, 1, 2)))
 

Data Fields

int seed
 
const csi_tcsi
 
const char * fmt
 
int printlevel
 
int const char * fmt
 
int const char va_list ap
 
const vec3_t origin
 
const vec3_t const vec3_t angles
 
AABBaabb
 
const char * name
 
const AABBbox
 
const AABB const edict_tpassent
 
const AABB const edict_t int contentmask
 
int frame
 
int AABBaabb
 
const vec3_t stop
 
const vec3_t const int levelmask
 
const vec3_t const int const char ** entlist
 
const vec3_t at
 
const vec3_t float speed
 
const vec3_t float bool launched
 
const vec3_t float bool bool rolled
 
const vec3_t float bool bool vec3_t v0
 
pathing_tpath
 
pathing_t const pos3_t from
 
pathing_t const pos3_t int distance
 
pathing_t const pos3_t int forbiddenList_tfb_list
 
pathing_t const pos3_t const pos3_t targetPos
 
pathing_t const pos3_t const pos3_t byte crouchingState
 
pathing_t const pos3_t const pos3_t byte int maxTUs
 
pathing_t const pos3_t const pos3_t byte int forbiddenList_tfb_list
 
const pos3_t to
 
const pos3_t byte crouchingState
 
const pos3_t byte bool stored
 
const pos3_t from
 
bool crouched
 
const pos3_t pos
 
const pos3_t vec3_t vec
 
const GridBoxbox
 
const GridBox const char ** list
 
byte ** buffer
 
int eType
 
int int entnum
 
size_t length
 
int size
 
intvalue
 
const char intvalue
 
int value
 
character_tchr
 
const char * file
 
const char int line
 

Detailed Description

functions provided by the main engine

Definition at line 173 of file game.h.

Member Function Documentation

◆ __attribute__() [1/5]

game_import_t::__attribute__ ( (format(__printf__, 1, 2))  )

◆ __attribute__() [2/5]

game_import_t::__attribute__ ( (format(__printf__, 1, 2))  )

◆ __attribute__() [3/5]

const char game_import_t::__attribute__ ( (format(__printf__, 2, 3))  )

◆ __attribute__() [4/5]

const char game_import_t::__attribute__ ( (format(__printf__, 2, 3))  )

◆ __attribute__() [5/5]

game_import_t::__attribute__ ( (noreturn, format(__printf__, 1, 2))  )

◆ bool() [1/10]

game_import_t::bool ( IMPORT CanActorStandHere)

◆ bool() [2/10]

game_import_t::bool ( IMPORT GetConstInt) const

◆ bool() [3/10]

game_import_t::bool ( IMPORT GetConstIntFromNamespace) const

◆ bool() [4/10]

game_import_t::bool ( IMPORT GridFindPath) const

◆ bool() [5/10]

game_import_t::bool ( IMPORT GridShouldUseAutostand) const

◆ bool() [6/10]

game_import_t::bool ( IMPORT isOnMap) const

◆ bool() [7/10]

game_import_t::bool ( IMPORT LoadModelAABB) const

◆ bool() [8/10]

game_import_t::bool ( IMPORT TestLine) const

fast version of a line trace but without including entities

◆ bool() [9/10]

game_import_t::bool ( IMPORT TestLineWithEnt) const

fast version of a line trace that also includes entities

◆ bool() [10/10]

game_import_t::bool ( IMPORT UnregisterConstVariable) const

◆ Cmd_Args()

const char *IMPORT * game_import_t::Cmd_Args ( void  )

concatenation of all argv >= 1

Referenced by G_Say_f().

◆ Cmd_Argv()

const char *IMPORT * game_import_t::Cmd_Argv ( int  n)

◆ Cvar_Get()

cvar_t *IMPORT * game_import_t::Cvar_Get ( const char *  varName,
const char *  value,
int  flags,
const char *  desc 
)

Referenced by G_Init().

◆ Cvar_Set()

cvar_t *IMPORT * game_import_t::Cvar_Set ( const char *  varName,
const char *  value,
  ... 
)

Referenced by CheckNeedPass(), and G_RunFrame().

◆ Cvar_String()

cvar_t *IMPORT const char *IMPORT * game_import_t::Cvar_String ( const char *  varName)

◆ float() [1/4]

game_import_t::float ( IMPORT GetBounceFraction) const

◆ float() [2/4]

game_import_t::float ( IMPORT GetVisibility) const

◆ float() [3/4]

game_import_t::float ( IMPORT GrenadeTarget) const

◆ float() [4/4]

game_import_t::float ( IMPORT ReadAngle)

◆ FS_Gamedir()

const char *IMPORT * game_import_t::FS_Gamedir ( void  )

Referenced by G_Init(), and SVCmd_WriteIP_f().

◆ GetConstVariable()

const char *IMPORT * game_import_t::GetConstVariable ( const char *  space,
int  value 
)

Referenced by AIL_toTeamString().

◆ GetEventEdict()

edict_t *IMPORT * game_import_t::GetEventEdict ( void  )

Referenced by G_EventEnd().

◆ GetFootstepSound()

const char *IMPORT * game_import_t::GetFootstepSound ( const char *  texture)

Referenced by G_SendFootstepSound().

◆ int() [1/12]

game_import_t::int ( IMPORT Cmd_Argc)

◆ int() [2/12]

game_import_t::int ( IMPORT FS_LoadFile) const

◆ int() [3/12]

game_import_t::int ( IMPORT GetEvent)

◆ int() [4/12]

game_import_t::int ( IMPORT GetTUsForDirection)

◆ int() [5/12]

unsigned game_import_t::int ( IMPORT ModelIndex) const

the *index functions create configstrings and some internal server state

◆ int() [6/12]

game_import_t::int ( IMPORT MoveNext) const

◆ int() [7/12]

game_import_t::int ( IMPORT PointContents) const

◆ int() [8/12]

game_import_t::int ( IMPORT ReadByte)

◆ int() [9/12]

game_import_t::int ( IMPORT ReadChar)

◆ int() [10/12]

game_import_t::int ( IMPORT ReadLong)

◆ int() [11/12]

game_import_t::int ( IMPORT ReadShort)

◆ int() [12/12]

game_import_t::int ( IMPORT ReadString)

◆ pos_t() [1/2]

game_import_t::pos_t ( IMPORT GridFall)

◆ pos_t() [2/2]

game_import_t::pos_t ( IMPORT MoveLength) const

◆ Sys_Fopen()

FILE *IMPORT * game_import_t::Sys_Fopen ( const char *  filename,
const char *  mode 
)

Referenced by G_Init(), and SVCmd_WriteIP_f().

◆ TagMalloc()

void *IMPORT * game_import_t::TagMalloc ( int  size,
int  tag,
const char *  file,
int  line 
)

◆ trace_t()

game_import_t::trace_t ( IMPORT Trace) const &

collision detection

Note
traces a box from start to end, ignoring entities passent, stopping if it hits an object of type specified via contentmask (MASK_*). Mins and maxs set the box which will do the tracing - if nullptr then a line is used instead
Returns
the trace data

◆ void() [1/43]

game_import_t::void ( IMPORT AbortEvents)

◆ void() [2/43]

game_import_t::void ( IMPORT AddCommandString) const

add commands to the server console as if they were typed in for map changing, etc

◆ void() [3/43]

game_import_t::void ( IMPORT AddEvent)

◆ void() [4/43]

game_import_t::void ( IMPORT BroadcastPrintf)

sends message to all players

◆ void() [5/43]

game_import_t::void ( IMPORT ConfigString)

configstrings hold all the index strings. All of the current configstrings are sent to clients when they connect, and changes are sent to all connected clients.

◆ void() [6/43]

game_import_t::void ( IMPORT DPrintf) const

print output to server console

◆ void() [7/43]

game_import_t::void ( IMPORT EndEvents)

◆ void() [8/43]

game_import_t::void ( IMPORT Error) const
Note
The error message should not have a newline - it's added inside of this function

◆ void() [9/43]

game_import_t::void ( IMPORT FreeTags)

◆ void() [10/43]

game_import_t::void ( IMPORT FS_FreeFile)

◆ void() [11/43]

game_import_t::void ( IMPORT GetCharacterValues) const

◆ void() [12/43]

game_import_t::void ( IMPORT GetInlineModelAABB) const

◆ void() [13/43]

game_import_t::void ( IMPORT GridCalcPathing)

◆ void() [14/43]

game_import_t::void ( IMPORT GridPosToVec)

◆ void() [15/43]

game_import_t::void ( IMPORT GridRecalcRouting) const

◆ void() [16/43]

game_import_t::void ( IMPORT LinkEdict)

links entity into the world - so that it is sent to the client and used for collision detection, etc. Must be relinked if its size, position or solidarity changes

◆ void() [17/43]

game_import_t::void ( IMPORT MoveStore)

◆ void() [18/43]

game_import_t::void ( IMPORT PlayerPrintf) const

sends message to only one player (don't use this to send messages to an AI player struct)

◆ void() [19/43]

game_import_t::void ( IMPORT QueueEvent)

◆ void() [20/43]

game_import_t::void ( IMPORT QueueWriteByte)

◆ void() [21/43]

game_import_t::void ( IMPORT QueueWritePos) const

◆ void() [22/43]

game_import_t::void ( IMPORT QueueWriteShort)

◆ void() [23/43]

game_import_t::void ( IMPORT QueueWriteString) const

◆ void() [24/43]

game_import_t::void ( IMPORT ReadData)

◆ void() [25/43]

game_import_t::void ( IMPORT ReadDir)

◆ void() [26/43]

game_import_t::void ( IMPORT ReadFormat) const

◆ void() [27/43]

game_import_t::void ( IMPORT ReadGPos)

◆ void() [28/43]

game_import_t::void ( IMPORT ReadPos)

◆ void() [29/43]

game_import_t::void ( IMPORT RegisterConstInt) const

◆ void() [30/43]

game_import_t::void ( IMPORT SetInlineModelOrientation) const

This updates the inline model's orientation

◆ void() [31/43]

game_import_t::void ( IMPORT SetModel)

◆ void() [32/43]

game_import_t::void ( IMPORT TagFree)

◆ void() [33/43]

game_import_t::void ( IMPORT UnlinkEdict)

call before removing an interactive edict

◆ void() [34/43]

game_import_t::void ( IMPORT WriteAngle)

◆ void() [35/43]

game_import_t::void ( IMPORT WriteByte)

◆ void() [36/43]

game_import_t::void ( IMPORT WriteChar)

◆ void() [37/43]

game_import_t::void ( IMPORT WriteDir) const

single byte encoded, very coarse

◆ void() [38/43]

game_import_t::void ( IMPORT WriteFormat) const

◆ void() [39/43]

game_import_t::void ( IMPORT WriteGPos) const

◆ void() [40/43]

game_import_t::void ( IMPORT WriteLong)

◆ void() [41/43]

game_import_t::void ( IMPORT WritePos) const

some fractional bits

◆ void() [42/43]

game_import_t::void ( IMPORT WriteShort)

◆ void() [43/43]

game_import_t::void ( IMPORT WriteString) const

Field Documentation

◆ aabb [1/2]

AABB& game_import_t::aabb

Definition at line 200 of file game.h.

◆ aabb [2/2]

int AABB& game_import_t::aabb

Definition at line 214 of file game.h.

◆ angles

const vec3_t const vec3_t game_import_t::angles

Definition at line 199 of file game.h.

◆ ap

int const char va_list game_import_t::ap

Definition at line 185 of file game.h.

◆ at

const vec3_t game_import_t::at

Definition at line 226 of file game.h.

◆ box [1/2]

const AABB& game_import_t::box

Definition at line 209 of file game.h.

◆ box [2/2]

const GridBox& game_import_t::box

Definition at line 237 of file game.h.

◆ buffer

byte** game_import_t::buffer

Definition at line 244 of file game.h.

◆ chr

character_t* game_import_t::chr

Definition at line 294 of file game.h.

◆ contentmask

const AABB const edict_t int game_import_t::contentmask

Definition at line 209 of file game.h.

◆ crouched

bool game_import_t::crouched

Definition at line 233 of file game.h.

◆ crouchingState [1/2]

const pos3_t byte game_import_t::crouchingState

Definition at line 229 of file game.h.

◆ crouchingState [2/2]

const pos3_t byte game_import_t::crouchingState

Definition at line 231 of file game.h.

◆ csi

◆ distance

pathing_t const pos3_t int game_import_t::distance

Definition at line 228 of file game.h.

◆ entlist

const vec3_t const int const char** game_import_t::entlist

Definition at line 225 of file game.h.

◆ entnum

int int game_import_t::entnum

Definition at line 264 of file game.h.

◆ eType

int game_import_t::eType

Definition at line 264 of file game.h.

◆ fb_list [1/2]

pathing_t const pos3_t int forbiddenList_t* game_import_t::fb_list

Definition at line 228 of file game.h.

◆ fb_list [2/2]

pathing_t const pos3_t const pos3_t byte int forbiddenList_t* game_import_t::fb_list

Definition at line 229 of file game.h.

◆ file

const char * game_import_t::file

Definition at line 298 of file game.h.

◆ fmt [1/2]

const char * game_import_t::fmt

Definition at line 181 of file game.h.

◆ fmt [2/2]

int const char* game_import_t::fmt

Definition at line 185 of file game.h.

◆ frame

int game_import_t::frame

Definition at line 214 of file game.h.

◆ from [1/2]

pathing_t const pos3_t game_import_t::from

Definition at line 228 of file game.h.

◆ from [2/2]

const pos3_t game_import_t::from

Definition at line 232 of file game.h.

◆ launched

const vec3_t float bool game_import_t::launched

Definition at line 226 of file game.h.

◆ length

size_t game_import_t::length

Definition at line 279 of file game.h.

◆ levelmask

const vec3_t const int game_import_t::levelmask

Definition at line 223 of file game.h.

◆ line

const char int game_import_t::line

Definition at line 298 of file game.h.

◆ list

const GridBox const char** game_import_t::list

Definition at line 237 of file game.h.

◆ maxTUs

pathing_t const pos3_t const pos3_t byte int game_import_t::maxTUs

Definition at line 229 of file game.h.

◆ name

const char * game_import_t::name

Definition at line 202 of file game.h.

◆ origin

const vec3_t game_import_t::origin

Definition at line 199 of file game.h.

◆ passent

const AABB const edict_t* game_import_t::passent

Definition at line 209 of file game.h.

◆ path

pathing_t * game_import_t::path

Definition at line 228 of file game.h.

◆ pos

const pos3_t game_import_t::pos

Definition at line 234 of file game.h.

◆ printlevel

int game_import_t::printlevel

Definition at line 185 of file game.h.

◆ rolled

const vec3_t float bool bool game_import_t::rolled

Definition at line 226 of file game.h.

◆ seed

int game_import_t::seed

random seed

Definition at line 175 of file game.h.

Referenced by GetGameAPI().

◆ size

int game_import_t::size

Definition at line 284 of file game.h.

◆ speed

const vec3_t float game_import_t::speed

Definition at line 226 of file game.h.

◆ stop

const vec3_t game_import_t::stop

Definition at line 223 of file game.h.

◆ stored

const pos3_t byte bool game_import_t::stored

Definition at line 231 of file game.h.

◆ targetPos

pathing_t const pos3_t const pos3_t game_import_t::targetPos

Definition at line 229 of file game.h.

◆ to

const pos3_t game_import_t::to

Definition at line 231 of file game.h.

◆ v0

const vec3_t float bool bool vec3_t game_import_t::v0

Definition at line 226 of file game.h.

◆ value [1/3]

int* game_import_t::value

Definition at line 287 of file game.h.

◆ value [2/3]

const char int* game_import_t::value

Definition at line 288 of file game.h.

◆ value [3/3]

int game_import_t::value

Definition at line 290 of file game.h.

◆ vec

const pos3_t vec3_t game_import_t::vec

Definition at line 235 of file game.h.


The documentation for this struct was generated from the following file: