#pragma once

#include <common/mapinfo.qh>
#ifdef CSQC
	#include "cl_keepaway.qh"
#endif

CLASS(Keepaway, Gametype)
	INIT(Keepaway)
	{
		this.gametype_init(this, _("Keepaway"),"ka","g_keepaway",GAMETYPE_FLAG_USEPOINTS,"","timelimit=20 pointlimit=30",_("Hold the ball to get points for kills"));
	}
	METHOD(Keepaway, m_isAlwaysSupported, bool(Gametype this, int spawnpoints, float diameter))
	{
		return true;
	}
	METHOD(Keepaway, 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))
	{
		TC(Gametype, this);
		returns(menu, _("Point limit:"),     5,  100,  5, "g_keepaway_point_limit",         string_null,         _("The amount of points needed before the match will end"));
	}
#ifdef CSQC
	ATTRIB(Keepaway, m_modicons, void(vector myPos, vector mySize, bool should_draw), HUD_Mod_Keepaway);
#endif
ENDCLASS(Keepaway)
REGISTER_GAMETYPE(KEEPAWAY, NEW(Keepaway));

#ifdef GAMEQC
const int KA_CARRYING = BIT(0);
#endif
