Xonotic
cl_cts.qc File Reference
#include "cl_cts.qh"
#include <common/mutators/base.qh>
+ Include dependency graph for cl_cts.qc:

Go to the source code of this file.

Functions

 MUTATOR_HOOKFUNCTION (cl_cts, HUD_Physics_showoptional)
 
 MUTATOR_HOOKFUNCTION (cl_cts, HUD_StrafeHUD_showoptional)
 
 MUTATOR_HOOKFUNCTION (cl_cts, HUD_Score_show)
 
 MUTATOR_HOOKFUNCTION (cl_cts, DrawScoreboardItemStats)
 
 MUTATOR_HOOKFUNCTION (cl_cts, DrawDeathScoreboard)
 
 MUTATOR_HOOKFUNCTION (cl_cts, DrawScoreboardAccuracy)
 
 MUTATOR_HOOKFUNCTION (cl_cts, ShowRankings)
 
 MUTATOR_HOOKFUNCTION (cl_cts, ShowNames_Draw)
 
 MUTATOR_HOOKFUNCTION (cl_cts, ShowRaceTimer)
 
 REGISTER_MUTATOR (cl_cts, true)
 

Function Documentation

◆ MUTATOR_HOOKFUNCTION() [1/9]

MUTATOR_HOOKFUNCTION ( cl_cts  ,
HUD_Physics_showoptional   
)

Definition at line 7 of file cl_cts.qc.

References ISGAMETYPE.

8 {
9  return ISGAMETYPE(CTS); // show the optional physics panel
10 }
#define ISGAMETYPE(NAME)
Definition: main.qh:32

◆ MUTATOR_HOOKFUNCTION() [2/9]

MUTATOR_HOOKFUNCTION ( cl_cts  ,
HUD_StrafeHUD_showoptional   
)

Definition at line 12 of file cl_cts.qc.

References ISGAMETYPE.

13 {
14  return ISGAMETYPE(CTS); // show the optional strafehud
15 }
#define ISGAMETYPE(NAME)
Definition: main.qh:32

◆ MUTATOR_HOOKFUNCTION() [3/9]

MUTATOR_HOOKFUNCTION ( cl_cts  ,
HUD_Score_show   
)

Definition at line 17 of file cl_cts.qc.

References ISGAMETYPE, and spectatee_status.

18 {
19  return spectatee_status == -1 && ISGAMETYPE(CTS); // hide the score panel while observing
20 }
float spectatee_status
Definition: main.qh:166
#define ISGAMETYPE(NAME)
Definition: main.qh:32

◆ MUTATOR_HOOKFUNCTION() [4/9]

MUTATOR_HOOKFUNCTION ( cl_cts  ,
DrawScoreboardItemStats   
)

Definition at line 22 of file cl_cts.qc.

References ISGAMETYPE.

23 {
24  return ISGAMETYPE(CTS); // hide the item stats panel
25 }
#define ISGAMETYPE(NAME)
Definition: main.qh:32

◆ MUTATOR_HOOKFUNCTION() [5/9]

MUTATOR_HOOKFUNCTION ( cl_cts  ,
DrawDeathScoreboard   
)

Definition at line 27 of file cl_cts.qc.

References ISGAMETYPE.

28 {
29  return ISGAMETYPE(CTS); // no scoreboard shown while dead
30 }
#define ISGAMETYPE(NAME)
Definition: main.qh:32

◆ MUTATOR_HOOKFUNCTION() [6/9]

MUTATOR_HOOKFUNCTION ( cl_cts  ,
DrawScoreboardAccuracy   
)

Definition at line 32 of file cl_cts.qc.

References ISGAMETYPE.

33 {
34  return ISGAMETYPE(CTS); // accuracy is not a factor in this gamemode
35 }
#define ISGAMETYPE(NAME)
Definition: main.qh:32

◆ MUTATOR_HOOKFUNCTION() [7/9]

MUTATOR_HOOKFUNCTION ( cl_cts  ,
ShowRankings   
)

Definition at line 37 of file cl_cts.qc.

References ISGAMETYPE, and M_ARGV.

38 {
39  if(ISGAMETYPE(CTS))
40  {
41  M_ARGV(0, string) = _("Rankings");
42  return true;
43  }
44 }
#define M_ARGV(x, type)
Definition: events.qh:17
#define ISGAMETYPE(NAME)
Definition: main.qh:32

◆ MUTATOR_HOOKFUNCTION() [8/9]

MUTATOR_HOOKFUNCTION ( cl_cts  ,
ShowNames_Draw   
)

Definition at line 46 of file cl_cts.qc.

References ALPHA_MIN_VISIBLE, ISGAMETYPE, and M_ARGV.

47 {
48  return (ISGAMETYPE(CTS) && M_ARGV(1, float) < ALPHA_MIN_VISIBLE);
49 }
const float ALPHA_MIN_VISIBLE
Definition: main.qh:128
#define M_ARGV(x, type)
Definition: events.qh:17
#define ISGAMETYPE(NAME)
Definition: main.qh:32

◆ MUTATOR_HOOKFUNCTION() [9/9]

MUTATOR_HOOKFUNCTION ( cl_cts  ,
ShowRaceTimer   
)

Definition at line 51 of file cl_cts.qc.

References ISGAMETYPE.

52 {
53  return ISGAMETYPE(CTS); // show the race timer panel
54 }
#define ISGAMETYPE(NAME)
Definition: main.qh:32

◆ REGISTER_MUTATOR()

REGISTER_MUTATOR ( cl_cts  ,
true   
)