e_time.c File Reference

Battlescape event timing code. More...

#include "../../client.h"
#include "../cl_localentity.h"
#include "e_time.h"
#include "e_main.h"
Include dependency graph for e_time.c:

Go to the source code of this file.

Defines

#define OLDEVENTTIME

Functions

int CL_GetEventTime (const event_t eType, struct dbuffer *msg, const int dt)
 Calculates the time the event should get executed. If two events return the same time, they are going to be executed in the order the were parsed.

Variables

static int nextTime
 CL_ParseEvent timers and vars.
static int shootTime
static int impactTime
static qboolean parsedDeath

Detailed Description

Battlescape event timing code.

Definition in file e_time.c.


Define Documentation

#define OLDEVENTTIME
Todo:
remove the old event timing

Definition at line 32 of file e_time.c.


Function Documentation

int CL_GetEventTime ( const event_t  eType,
struct dbuffer msg,
const int  dt 
)

Calculates the time the event should get executed. If two events return the same time, they are going to be executed in the order the were parsed.

Parameters:
[in] eType The event type
[in,out] msg The message buffer that can be modified to get the event time
[in] dt Delta time in msec since the last event was parsed

Definition at line 49 of file e_time.c.

References byte, cl, CL_GetEvent(), CL_OutsideMap(), cls, Com_DPrintf(), DEBUG_EVENTSYS, fireDef_s::delayBetweenShots, EV_ACTOR_APPEAR, EV_ACTOR_DIE, EV_ACTOR_MOVE, EV_ACTOR_SHOOT, EV_ACTOR_SHOOT_HIDDEN, EV_ACTOR_START_SHOOT, EV_ACTOR_THROW, EV_ENT_APPEAR, EV_INV_ADD, EV_INV_RELOAD, EV_MODEL_EXPLODE, EV_PARTICLE_APPEAR, EV_PARTICLE_SPAWN, EV_RESET, EV_RESULTS, FIRESH_GetFiredef(), eventRegister_s::formatString, getDVdir, i, impactTime, INVSH_GetItemByIDX(), LE_ActorGetStepTime(), LE_Get(), LE_IsCrouched, LE_NotFoundError, eventRegister_s::name, NET_ReadByte(), NET_ReadFormat(), NET_ReadShort(), nextTime, oldPos, parsedDeath, le_s::pos, pos, PosAddDV, qfalse, qtrue, SF_BOUNCED, shootTime, fireDef_s::speed, client_static_s::team, eventRegister_s::timeCallback, UNIT_SIZE, VectorCopy, and VectorDist.

Referenced by CL_ParseEvent().


Variable Documentation

int impactTime [static]

time when the shoot hits the target

Definition at line 38 of file e_time.c.

Referenced by CL_ActorDoShootTime(), CL_ActorShootHiddenTime(), and CL_GetEventTime().

int nextTime [static]

CL_ParseEvent timers and vars.

time when the next event should be executed

Definition at line 36 of file e_time.c.

Referenced by CL_ActorAppearTime(), CL_ActorDoShootTime(), CL_ActorShootHiddenTime(), CL_ActorStartShootTime(), CL_GetEventTime(), and CL_InvReloadTime().

extra delay caused by death -

See also:
impactTime

Definition at line 39 of file e_time.c.

Referenced by CL_GetEventTime().

int shootTime [static]

time when the shoot was fired

Definition at line 37 of file e_time.c.

Referenced by CL_ActorDoShootTime(), CL_ActorShootHiddenTime(), CL_ActorStartShootTime(), and CL_GetEventTime().


Generated by  doxygen 1.6.2