# Comprehensive Sandbox Control - show/hide cheat decision controls
#
# Show sets the csc_cheats_shown country flag; Hide clears it. All one-shot
# cheat categories/decisions gate on this flag (via csc_cheats_visible). Flag
# toggles are instant, but HOI4 does not refresh decision visibility while the
# game is paused: a short passage of game time is needed for the revealed/hidden
# decisions to refresh. This is documented in the decision descriptions.

csc_cheats_category = {

	csc_show_cheat_decisions = {
		cost = 0
		fire_only_once = no

		allowed = { csc_is_human_controlled = yes }

		visible = {
			NOT = { has_country_flag = csc_cheats_shown }
		}

		available = { csc_is_human_controlled = yes }

		complete_effect = {
			set_country_flag = csc_cheats_shown
		}

		ai_will_do = { factor = 0 }
	}

	csc_hide_cheat_decisions = {
		cost = 0
		fire_only_once = no

		allowed = { csc_is_human_controlled = yes }

		visible = {
			has_country_flag = csc_cheats_shown
		}

		available = { csc_is_human_controlled = yes }

		complete_effect = {
			clr_country_flag = csc_cheats_shown
		}

		ai_will_do = { factor = 0 }
	}
}
