#include "..\script_component.hpp"

//---------------------
// Respawn Settings
[
	QGVAR(setting_enabled), // variable
	"CHECKBOX", // type
	["Enabled", "Whether or not players can file for reinsert and pilots can check the reinsert queue"], // title
	[QUOTE(SETTINGS_GROUP_NAME), QUOTE(COMPONENT_BEAUTIFIED)], // category
	true, // default value
	true, // global setting
	{
		params ["_value"];
		[
			QGVAR(setting_enabled),
			_value
		] call EFUNC(common,logSettingChanged);
	}
] call CBA_fnc_addSetting;

[
	QGVAR(setting_maxRangeToReady), // variable
	"SLIDER", // type
	["Max Request Filing Range", "Maximum distance from a respawn point a player can be to ready up"], // title
	[QUOTE(SETTINGS_GROUP_NAME), QUOTE(COMPONENT_BEAUTIFIED)], // category
	[0, 1000, 400, 0, false], // [_min, _max, _default, _trailingDecimals, _isPercentage]
	true, // global setting
	{
		params ["_value"];
		[
			QGVAR(setting_maxRangeToReady),
			_value
		] call EFUNC(common,logSettingChanged);
	}
] call CBA_fnc_addSetting;

[
	QGVAR(setting_maxWait), // variable
	"TIME", // type
	["Max Wait Before Global Notify", "How long should at least one person be waiting before prompting a global notification."], // title
	[QUOTE(SETTINGS_GROUP_NAME), QUOTE(COMPONENT_BEAUTIFIED)], // category
	[60*5, 60*30, 60*20], // [_min, _max, _default]
	true,
	{
		params ["_value"];
		[
			QGVAR(setting_maxWait),
			_value
		] call EFUNC(common,logSettingChanged);
	}
] call CBA_fnc_addSetting;

[
	QGVAR(setting_pilotForcedCheckEnabled), // variable
	"CHECKBOX", // type
	["Force Queue Checks for Pilots", "Whether or not pilots are forced to view the contents of the reinsertion queue per interval"], // title
	[QUOTE(SETTINGS_GROUP_NAME), QUOTE(COMPONENT_BEAUTIFIED)], // category
	false, // default value
	true, // global setting
	{
		params ["_value"];
		[
			QGVAR(setting_pilotForcedCheckEnabled),
			_value
		] call EFUNC(common,logSettingChanged);
	}
] call CBA_fnc_addSetting;

[
	QGVAR(setting_pilotForcedCheckInterval), // variable
	"TIME", // type
	["Pilot Forced Check Interval", "Pilots will be force shown the queue if they haven't checked it in X seconds"], // title
	[QUOTE(SETTINGS_GROUP_NAME), QUOTE(COMPONENT_BEAUTIFIED)], // category
	[60*5, 60*30, 60*10], // [_min, _max, _default]
	true,
	{
		params ["_value"];
		[
			QGVAR(setting_pilotForcedCheckInterval),
			_value
		] call EFUNC(common,logSettingChanged);
	}
] call CBA_fnc_addSetting;
