Xonotic QuakeC
The free, fast arena FPS with crisp movement and a wide array of weapons
all.qh File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define _CHIMPULSE(id, n)
#define _REGISTER_IMPULSE(id, alias, n)
#define CHIMPULSE(id, n)
#define IMPULSE_ALIAS(alias, id)
#define LEGACY_IMPULSE(alias, id, new)
#define LEGACY_IMPULSE_ID(alias, id)
#define REGISTER_IMPULSE(id, n)
#define X(i, imp)
#define X(slot, dir, imp)
#define X(slot, imp)

Functions

void _impCheck (string s, string alias)
void Impulse_Send (entity imp)
 STATIC_INIT (IMPULSES_renumber)
 void (entity this) impulse_handle
 X (0, 230) X(1
 X (0, best, 210) X(1
 X (0, next, 220) X(1
 X (0, prev, 200) X(1
 X (1, 1) X(2
 X (10, 240) X(11
 X (12, 242) X(13
 X (14, 244) X(15
 X (16, 246) X(17
 X (18, 248) X(19
 X (2, 232) X(3
 X (2, best, 212) X(3
 X (2, next, 222) X(3
 X (2, prev, 202) X(3
 X (20, 250) X(21
 X (22, 252) X(23
 X (3, 3) X(4
 X (4, 234) X(5
 X (4, best, 214) X(5
 X (4, next, 224) X(5
 X (4, prev, 204) X(5
 X (5, 5) X(6
 X (6, 236) X(7
 X (6, best, 216) X(7
 X (6, next, 226) X(7
 X (6, prev, 206) X(7
 X (7, 7) X(8
 X (8, 238) X(9
 X (8, best, 218) X(9
 X (8, next, 228) X(9
 X (8, prev, 208) X(9
 X (9, 9) X(0

Variables

 best
 next
 prev

Macro Definition Documentation

◆ _CHIMPULSE

#define _CHIMPULSE ( id,
n )
Value:
REGISTER(IMPULSES, id, m_id, new_pure(Impulse)) \
{ \
this.impulse = n; \
}
int m_id
Definition effect.qh:19
#define new_pure(class)
purely logical entities (not linked to the area grid)
Definition oo.qh:67
float impulse
Definition progsdefs.qc:158
#define REGISTER(...)
Register a new entity with a registry.
Definition registry.qh:87

Definition at line 205 of file all.qh.

205#define _CHIMPULSE(id, n) \
206 REGISTER(IMPULSES, id, m_id, new_pure(Impulse)) \
207 { \
208 this.impulse = n; \
209 }

◆ _REGISTER_IMPULSE

#define _REGISTER_IMPULSE ( id,
alias,
n )
Value:
REGISTER(IMPULSES, id, m_id, new_pure(Impulse)) \
{ \
this.impulse = n; \
IMPULSE_ALIAS(alias, "impulse " #n); \
}

Definition at line 28 of file all.qh.

28#define _REGISTER_IMPULSE(id, alias, n) \
29 REGISTER(IMPULSES, id, m_id, new_pure(Impulse)) \
30 { \
31 this.impulse = n; \
32 IMPULSE_ALIAS(alias, "impulse " #n); \
33 }

◆ CHIMPULSE

#define CHIMPULSE ( id,
n )
Value:
_CHIMPULSE(CHIMPULSE_##id, n)
#define _CHIMPULSE(id, n)
Definition all.qh:205

Definition at line 204 of file all.qh.

◆ IMPULSE_ALIAS

#define IMPULSE_ALIAS ( alias,
id )
Value:
localcmd("\nalias " #alias " \"", id ,"\"\n")
void localcmd(string command,...)

Definition at line 22 of file all.qh.

◆ LEGACY_IMPULSE

#define LEGACY_IMPULSE ( alias,
id,
new )
Value:
STATIC_INIT(legacy_##alias) { \
string s = new; \
_impCheck(s, #alias); \
IMPULSE_ALIAS(alias, s); \
} \
SHUTDOWN(legacy_##alias) { IMPULSE_ALIAS(alias, "impulse " #id); }
#define IMPULSE_ALIAS(alias, id)
Definition all.qh:22
#define STATIC_INIT(func)
during worldspawn
Definition static.qh:32

Definition at line 44 of file all.qh.

44#define LEGACY_IMPULSE(alias, id, new) \
45 STATIC_INIT(legacy_##alias) { \
46 string s = new; \
47 _impCheck(s, #alias); \
48 IMPULSE_ALIAS(alias, s); \
49 } \
50 SHUTDOWN(legacy_##alias) { IMPULSE_ALIAS(alias, "impulse " #id); }

Referenced by X().

◆ LEGACY_IMPULSE_ID

#define LEGACY_IMPULSE_ID ( alias,
id )
Value:
LEGACY_IMPULSE(alias, id, sprintf("impulse %d", IMP_##alias.impulse))
#define LEGACY_IMPULSE(alias, id, new)
Definition all.qh:44

Definition at line 35 of file all.qh.

Referenced by X().

◆ REGISTER_IMPULSE

#define REGISTER_IMPULSE ( id,
n )
Value:
_REGISTER_IMPULSE(IMP_##id, id, n)
#define _REGISTER_IMPULSE(id, alias, n)
Definition all.qh:28

Definition at line 27 of file all.qh.

Referenced by X().

◆ X [1/3]

#define X ( i,
imp )
Value:
REGISTER_IMPULSE(weapon_byid_##i, imp)
#define REGISTER_IMPULSE(id, n)
Definition all.qh:27
int int int imp
Definition impulse.qc:90

Definition at line 52 of file all.qh.

52#define X(slot, imp) \
53 REGISTER_IMPULSE(weapon_group_##slot, imp) \
54 LEGACY_IMPULSE(weapon_group_##slot, imp, "impulse " #imp)

◆ X [2/3]

#define X ( slot,
dir,
imp )
Value:
REGISTER_IMPULSE(weapon_priority_##slot##_##dir, imp) \
LEGACY_IMPULSE(weapon_priority_##slot##_##dir, imp, "impulse " #imp)
int dir
Definition impulse.qc:89

Definition at line 52 of file all.qh.

52#define X(slot, imp) \
53 REGISTER_IMPULSE(weapon_group_##slot, imp) \
54 LEGACY_IMPULSE(weapon_group_##slot, imp, "impulse " #imp)

◆ X [3/3]

#define X ( slot,
imp )
Value:
REGISTER_IMPULSE(weapon_group_##slot, imp) \
LEGACY_IMPULSE(weapon_group_##slot, imp, "impulse " #imp)

Definition at line 52 of file all.qh.

52#define X(slot, imp) \
53 REGISTER_IMPULSE(weapon_group_##slot, imp) \
54 LEGACY_IMPULSE(weapon_group_##slot, imp, "impulse " #imp)

Function Documentation

◆ _impCheck()

void _impCheck ( string s,
string alias )

Definition at line 37 of file all.qh.

38{
39 // this is inside a function to avoid expanding it on compilation everytime
40 if (s == alias)
41 LOG_FATALF("LEGACY_IMPULSE: would define a recursive alias for '%s', use LEGACY_IMPULSE_ID instead", s);
42}
#define LOG_FATALF(...)
Definition log.qh:54

References LOG_FATALF.

◆ Impulse_Send()

void Impulse_Send ( entity imp)

Definition at line 17 of file all.qh.

18{
19 localcmd(sprintf("\nimpulse %d\n", imp.impulse));
20}

References entity(), imp, and localcmd().

Referenced by View_SpectatorCamera().

◆ STATIC_INIT()

STATIC_INIT ( IMPULSES_renumber )

Definition at line 8 of file all.qh.

9{
10 FOREACH(IMPULSES, true, it.m_id = i);
11}
#define FOREACH(list, cond, body)
Definition iter.qh:19

References FOREACH, and STATIC_INIT.

◆ void()

void ( entity this)

References entity().

◆ X() [1/32]

X ( 0 ,
230  )

References X.

◆ X() [2/32]

X ( 0 ,
best ,
210  )

References best, and X.

◆ X() [3/32]

X ( 0 ,
next ,
220  )

References next, and X.

◆ X() [4/32]

X ( 0 ,
prev ,
200  )

References prev.

◆ X() [5/32]

X ( 1 ,
1  )

References X.

◆ X() [6/32]

X ( 10 ,
240  )

References X.

◆ X() [7/32]

X ( 12 ,
242  )

References X.

◆ X() [8/32]

X ( 14 ,
244  )

References X.

◆ X() [9/32]

X ( 16 ,
246  )

References X.

◆ X() [10/32]

X ( 18 ,
248  )

References X.

◆ X() [11/32]

X ( 2 ,
232  )

References X.

◆ X() [12/32]

X ( 2 ,
best ,
212  )

References best, and X.

◆ X() [13/32]

X ( 2 ,
next ,
222  )

References next, and X.

◆ X() [14/32]

X ( 2 ,
prev ,
202  )

References prev, and X.

◆ X() [15/32]

X ( 20 ,
250  )

References X.

◆ X() [16/32]

X ( 22 ,
252  )

◆ X() [17/32]

X ( 3 ,
3  )

References X.

◆ X() [18/32]

X ( 4 ,
234  )

References X.

◆ X() [19/32]

X ( 4 ,
best ,
214  )

References best, and X.

◆ X() [20/32]

X ( 4 ,
next ,
224  )

References next, and X.

◆ X() [21/32]

X ( 4 ,
prev ,
204  )

References prev, and X.

◆ X() [22/32]

X ( 5 ,
5  )

References X.

◆ X() [23/32]

X ( 6 ,
236  )

References X.

◆ X() [24/32]

X ( 6 ,
best ,
216  )

References best, and X.

◆ X() [25/32]

X ( 6 ,
next ,
226  )

References next, and X.

◆ X() [26/32]

X ( 6 ,
prev ,
206  )

References prev, and X.

◆ X() [27/32]

X ( 7 ,
7  )

References X.

◆ X() [28/32]

X ( 8 ,
238  )

References X.

◆ X() [29/32]

X ( 8 ,
best ,
218  )

References best, and X.

◆ X() [30/32]

X ( 8 ,
next ,
228  )

References next, and X.

◆ X() [31/32]

X ( 8 ,
prev ,
208  )

References prev, and X.

◆ X() [32/32]

X ( 9 ,
9  )

References X.

Variable Documentation

◆ best

◆ next

◆ prev