ddnet/src/engine/shared/config.h

40 lines
1 KiB
C
Raw Normal View History

2010-11-20 10:37:14 +00:00
/* (c) Magnus Auvinen. See licence.txt in the root of the distribution for more information. */
/* If you are missing that file, acquire a complete release at teeworlds.com. */
#ifndef ENGINE_SHARED_CONFIG_H
#define ENGINE_SHARED_CONFIG_H
2010-05-29 07:25:38 +00:00
2015-07-22 16:23:40 +00:00
#define CONFIG_FILE "settings_ddnet.cfg"
2018-04-05 15:24:49 +00:00
#define CONFIG_FILE_TMP CONFIG_FILE ".tmp"
#define AUTOEXEC_FILE "autoexec.cfg"
#define AUTOEXEC_CLIENT_FILE "autoexec_client.cfg"
#define AUTOEXEC_SERVER_FILE "autoexec_server.cfg"
2015-07-22 16:23:40 +00:00
2010-05-29 07:25:38 +00:00
struct CConfiguration
{
#define MACRO_CONFIG_INT(Name,ScriptName,Def,Min,Max,Save,Desc) int m_##Name;
#define MACRO_CONFIG_STR(Name,ScriptName,Len,Def,Save,Desc) char m_##Name[Len]; // Flawfinder: ignore
#include "config_variables.h"
#undef MACRO_CONFIG_INT
#undef MACRO_CONFIG_STR
2010-05-29 07:25:38 +00:00
};
extern CConfiguration g_Config;
enum
{
CFGFLAG_SAVE=1,
CFGFLAG_CLIENT=2,
CFGFLAG_SERVER=4,
CFGFLAG_STORE=8,
CFGFLAG_MASTER=16,
2011-12-30 18:12:31 +00:00
CFGFLAG_ECON=32,
// DDRace
2011-08-31 10:10:15 +00:00
CMDFLAG_TEST=64,
CFGFLAG_CHAT=128,
CFGFLAG_GAME=256,
CFGFLAG_NONTEEHISTORIC=512,
2010-05-29 07:25:38 +00:00
};
#endif