Xonotic
campaign_setup.qc
Go to the documentation of this file.
1
#include "
campaign_setup.qh
"
2
3
#if defined(CSQC)
4
#elif defined(MENUQC)
5
#elif defined(SVQC)
6
#include <
common/campaign_common.qh
>
7
#include <
common/mapinfo.qh
>
8
#endif
9
10
void
CampaignSetup
(
int
n)
11
{
12
localcmd
(
"set g_campaign 1\n"
);
13
localcmd
(
"set _campaign_name \""
);
14
localcmd
(
campaign_name
);
15
localcmd
(
"\"\n"
);
16
localcmd
(
"set _campaign_index "
);
17
localcmd
(
ftos
(
campaign_offset
+ n));
18
localcmd
(
"\n"
);
19
localcmd
(
"disconnect\nmaxplayers 16\n"
);
20
MapInfo_LoadMap
(
campaign_mapname
[n], 1);
21
}
campaign_name
string campaign_name
Definition:
campaign_common.qh:26
ftos
string ftos(float f)
campaign_common.qh
localcmd
#define localcmd
Definition:
menudefs.qh:21
campaign_setup.qh
CampaignSetup
void CampaignSetup(int n)
Definition:
campaign_setup.qc:10
mapinfo.qh
campaign_offset
int campaign_offset
Definition:
campaign_common.qh:9
campaign_mapname
string campaign_mapname[CAMPAIGN_MAX_ENTRIES]
Definition:
campaign_common.qh:11
MapInfo_LoadMap
void MapInfo_LoadMap(string s, float reinit)
Definition:
mapinfo.qc:1183
common
campaign_setup.qc
Generated on Thu Mar 17 2022 17:26:27 for Xonotic by
1.8.13