Xonotic
assault.qh
Go to the documentation of this file.
1 #pragma once
2 
3 #include <common/mapinfo.qh>
4 
7  {
8  this.gametype_init(this, _("Assault"),"as","g_assault",GAMETYPE_FLAG_TEAMPLAY,"","timelimit=20",_("Destroy obstacles to find and destroy the enemy power core before time runs out"));
9  }
10  METHOD(Assault, m_generate_mapinfo, void(Gametype this, string v))
11  {
12  if(v == "target_assault_roundend")
14  }
15  METHOD(Assault, m_isTwoBaseMode, bool())
16  {
17  return true;
18  }
19  METHOD(Assault, m_configuremenu, void(Gametype this, entity menu, void(entity me, string pLabel, float pMin, float pMax, float pStep, string pCvar, string tCvar, string pTooltip) returns))
20  {
21  TC(Gametype, this);
22  returns(menu, _("Point limit:"), 50, 500, 10, string_null, string_null, string_null);
23  }
24  ATTRIB(Assault, m_legacydefaults, string, "20 0");
26 REGISTER_GAMETYPE(ASSAULT, NEW(Assault));
27 #define g_assault IS_GAMETYPE(ASSAULT)
string string_null
Definition: nil.qh:9
#define NEW(cname,...)
Definition: oo.qh:105
CLASS(Object) Object
Definition: oo.qh:318
entity() spawn
#define METHOD(cname, name, prototype)
Definition: oo.qh:257
int m_flags
Definition: mapinfo.qh:27
const int GAMETYPE_FLAG_TEAMPLAY
Definition: mapinfo.qh:19
#define ATTRIB(...)
Definition: oo.qh:136
#define INIT(cname)
Definition: oo.qh:198
int MapInfo_Map_supportedGametypes
Definition: mapinfo.qh:13
#define TC(T, sym)
Definition: _all.inc:82
vector v
Definition: ent_cs.qc:116
#define ENDCLASS(cname)
Definition: oo.qh:269
REGISTER_GAMETYPE(ASSAULT, NEW(Assault))