﻿{
	"counters":
	[
		{
			"sid": "Tutorial_C3_Win_Counter",
			"comment": "win_condition_counter"
		},

		{
			"sid": "Tutorial_C3_Counter",
			"comment": "Tutorial_C3_Counter"
		},

		{
			"sid": "Tutorial_C3_Counter_1",
			"comment": "Tutorial_C3_Counter"
		},

		{
			"sid": "Tutorial_C3_Rep",
			"comment": "Tutorial_C3_Rep"
		}
	],

	"quests":
	[
		{
			"sid": "intro",

			"hidden": true,

			"comment": "intro",

			"activeOnStart": true,
			"sharing": "Clone",

			"name": "1",

			"subQuests":
			[	
				{
					"sid": "1",
					"activeOnStart": true,

					"triggers":
					[
						{
							"conditions":
							[
								{ "c": "StartTurn", "p": [ "1", "1" ] }
							],

							"actions":
							[					
								{ "a": "RevealFogOfWar", "p": [ "136", "10" ] },		
								{ "a": "Guide", "p": [ "tutorial_C3_start" ] },
								{ "a": "GiveRes", "p": [ "gold", "100000" ] },
								{ "a": "GiveRes", "p": [ "gemstones", "11" ] },
								{ "a": "CounterPlus", "p": [ "Tutorial_C3_Rep", "10" ] },
								{ "a": "AddGlobalBuff", "p": [ "tutorial_one_day_week_buff", "UntilNextWeek" ] }
							]
						}
					]
				}
			]
		},

		{
			"sid": "win_lose_conditions",
			"hidden": true,

			"comment": "conditions for losing, sometimes winning",

			"activeOnStart": true,
			"name": "1",
			"sharing": "Clone",

			"subQuests":
			[	
				{
					"sid": "lose_condition",
					"activeOnStart": true,

					"triggers":
					[
						{
							"conditionsLogic": "Or",

							"conditions":
							[
								{ "c": "StartTurn", "p": [ "2", "2" ] },
								{ "c": "HeroKill", "p": [ "tutorial_hero_c1_4" ] }
							],

							"actions":
							[
								{ "a": "GameLose" }
							]
						}
					]
				},
				{
					"sid": "win_condition_kill_checker",
					"activeOnStart": true,

					"triggers":
					[
						{
							"conditionsLogic": "And",

							"conditions":
							[
								{ "c": "SquadKill", "p": [ "SquadKill" ] }
							],

							"actions":
							[
								{ "a": "CounterPlus", "p": [ "Tutorial_C3_Counter_1", "1" ] },
								{ "a": "SetActiveVFX", "p": [ "vfx_1", "false" ] }
							]
						}
					]
				},
				{
					"sid": "win_condition_dialog",
					"activeOnStart": true,

					"triggers":
					[
						{
							"conditionsLogic": "And",

							"conditions":
							[
								{ "c": "Counter", "p": [ "Tutorial_C3_Counter_1", "=", "1" ] }
							],

							"actions":
							[
								{ "a": "Dialog", "p": [ "t_C3_dial_end" ] }
							]
						}
					]
				},
				{
					"sid": "win_condition",
					"activeOnStart": true,

					"triggers":
					[
						{
							"conditions":
							[
								{ "c": "Counter", "p": [ "Tutorial_C3_Win_Counter", "=", "1" ] }
							],

							"actions":
							[
								{ "a": "GameVictory" }
							]
						}
					]
				}
			]
		},

		{
			"sid": "Questlog_Main",
			"main": true,

			"comment": "Main Goal",

			"activeOnStart": true,
			"sharing": "Clone",

			"name": "Tutorial_Challenge_Mission_3_title",

			"subQuests":
			[	
				{
					"sid": "win_condition_m_0",
					"activeOnStart": true,
					
					"name": "t_M_Questlog_C3_description_day",

					"triggers":
					[
						{
							"conditions":
							[
								{ "c": "StartTurn", "p": [ "2", "1" ] }
							],

							"actions":
							[
								{ "a": "CurrentSubQuestDone" }
							]
						}
					]
				},
				{
					"sid": "win_condition_m_1",
					"activeOnStart": true,
					
					"name": "t_M_Questlog_C3_description",

					"triggers":
					[
						{
							"conditions":
							[
								{ "c": "Counter", "p": [ "Tutorial_C3_Counter_1", "=", "1" ] }
							],

							"actions":
							[
								{ "a": "CurrentSubQuestDone" }
							]
						}
					]
				}
			]
		}
	]
}