parser=GooeyParser(description=f'AzurLaneAutoScript, An Azur Lane automation tool. Config: {config_file}\nDo not forget to Press start button to save your settings in each function that modifies')
stage=setting_parser.add_argument_group('Level settings','Need to Press start to save your settings.',gooey_options={'label_color':'#931D03'})
stage.add_argument('--enable_stop_condition',default=default('--enable_stop_condition'),choices=['yes','no'],help='If enabled will start reward loop when triggered any filter below',gooey_options={'label_color':'#4B5F83'})
stage.add_argument('--enable_exception',default=default('--enable_exception'),choices=['yes','no'],help='Enable or disable some exceptions, ALAS will withdraw from the map when it occurs instead of stopping',gooey_options={'label_color':'#4B5F83'})
stage.add_argument('--enable_fast_forward',default=default('--enable_fast_forward'),choices=['yes','no'],help='Enable or disable clearing mode',gooey_options={'label_color':'#4B5F83'})
stop=stage.add_argument_group('Stop condition','After triggering, it will not stop immediately. It will complete the current attack first, Set 0 to disable',gooey_options={'label_color':'#4B5F83'})
stop.add_argument('--if_count_greater_than',default=default('--if_count_greater_than'),help='How many map completions\n until ALAS enter in Reward loop.',gooey_options={'label_color':'#4B5F83'})
stop.add_argument('--if_time_reach',default=default('--if_time_reach'),help='How many time in minutes run ALAS until stop\n. It is recommended about\n 10 minutes to complete the current attack. Format 14:59',gooey_options={'label_color':'#4B5F83'})
stop.add_argument('--if_oil_lower_than',default=default('--if_oil_lower_than'),help='Will enter in reward loop when\ntriggered Oil limit',gooey_options={'label_color':'#4B5F83'})
stop.add_argument('--if_trigger_emotion_control',default=default('--if_trigger_emotion_control'),choices=['yes','no'],help='Will enter in reward loop when\ntriggered Mood limit',gooey_options={'label_color':'#4B5F83'})
stop.add_argument('--if_reach_lv120',default=default('--if_reach_lv120'),choices=['yes','no'],help='Will enter in reward loop when\na ship of lv119 reached lv120 in combat',gooey_options={'label_color':'#4B5F83'})
fleet=setting_parser.add_argument_group('Attack fleet','No support for alternate lane squadrons, inactive map or weekly mode will ignore the step setting',gooey_options={'label_color':'#931D03'})
f1=fleet.add_argument_group('Mob Fleet','Players can choose a formation before battle. Though it has no effect appearance-wise, the formations applies buffs to certain stats.\nLine Ahead: Increases Firepower and Torpedo by 15%, but reduces Evasion by 10% (Applies only to Vanguard fleet)\nDouble Line: Increases Evasion by 30%, but decreases Firepower and Torpedo by 5% (Applies only to Vanguard fleet)\nDiamond: Increases Anti-Air by 20% (no penalties, applies to entire fleet)',gooey_options={'label_color':'#4B5F83'})
f1.add_argument('--fleet_step_1',default=default('--fleet_step_1'),choices=['1','2','3','4','5','6'],help='In event map, fleet has limit on moving, so fleet_step is how far can a fleet goes in one operation, if map cleared, it will be ignored',gooey_options={'label_color':'#4B5F83'})
f2.add_argument('--fleet_step_2',default=default('--fleet_step_2'),choices=['1','2','3','4','5','6'],help='In event map, fleet has limit on moving, so fleet_step is how far can a fleet goes in one operation, if map cleared, it will be ignored',gooey_options={'label_color':'#4B5F83'})
f3=fleet.add_argument_group('Alternate Mob Fleet','It hasnt been implemented yet',gooey_options={'label_color':'#4B5F83'})
f3.add_argument('--fleet_step_3',default=default('--fleet_step_3'),choices=['1','2','3','4','5','6'],help='In event map, fleet has limit on moving, so fleet_step is how far can a fleet goes in one operation, if map cleared, it will be ignored',gooey_options={'label_color':'#4B5F83'})
emotion.add_argument('--enable_emotion_reduce',default=default('--enable_emotion_reduce'),help='Set No to disable MOOD control by ALAS',choices=['yes','no'],gooey_options={'label_color':'#4B5F83'})
hp_balance.add_argument('--scout_hp_difference_threshold',default=default('--scout_hp_difference_threshold'),help='When the difference in HP volume is greater than the threshold, transpose',gooey_options={'label_color':'#4B5F83'})
hp_balance.add_argument('--scout_hp_weights',default=default('--scout_hp_weights'),help='Should be repaired when there is a difference in Vanguard, format 1000,1000,1000',gooey_options={'label_color':'#4B5F83'})
hp_add.add_argument('--emergency_repair_single_threshold',default=default('--emergency_repair_single_threshold'),help='Used when single shipgirl is below the threshold',gooey_options={'label_color':'#4B5F83'})
hp_add.add_argument('--emergency_repair_hole_threshold',default=default('--emergency_repair_hole_threshold'),help='Used when all front rows or all back rows are below the threshold',gooey_options={'label_color':'#4B5F83'})
hp_withdraw=hp.add_argument_group('Low HP volume withdrawal','',gooey_options={'label_color':'#4B5F83'})
hp_withdraw.add_argument('--low_hp_withdraw_threshold',default=default('--low_hp_withdraw_threshold'),help='When HP is below the threshold, retreat',gooey_options={'label_color':'#4B5F83'})
retire.add_argument('--retire_method',default=default('--retire_method'),choices=['enhance','one_click_retire','old_retire'],help='If choosing enhance, when not having enough enhance material, will use one click retire',gooey_options={'label_color':'#4B5F83'})
help='Use example format "cv > bb > ..." may omit a ship type category altogether to skip otherwise leave blank to not apply any filter. Using \'?\' will have ALAS select a category at random, may use multiple in same string',
help='How many ships at maximum are viewed before moving onto the next category, ships that are \'in battle\' do not count towards this number and are skipped to the next available ship for enhancement',
rarity=retire.add_argument_group('Retirement rarity','The ship type selection is not supported yet. Ignore the following options when using one-key retirement',gooey_options={'label_color':'#4B5F83'})
drop=setting_parser.add_argument_group('Drop record','Save screenshots of dropped items, which will slow down the click speed when settlement is enabled',gooey_options={'label_color':'#931D03'})
# clear = setting_parser.add_argument_group('Wasteland mode', 'Unopened maps will stop after completion. Opened maps will ignore options, and its done if you do not open up')
# clear.add_argument('--map_star_clear_all', default=default('--map_star_clear_all'), choices=['index_1', 'index_2', 'index_3', 'do_not_use'], help='The first few stars are to destroy all enemy ships')
reward_condition=reward_parser.add_argument_group('Triggering conditions','Need to Press start to save your settings, after running it will enter the on-hook vegetable collection mode',gooey_options={'label_color':'#931D03'})
reward_general.add_argument('--enable_data_key_collect',default=default('--enable_data_key_collect'),help='Enable collection of data key in war archives.',choices=['yes','no'],gooey_options={'label_color':'#4B5F83'})
reward_dorm.add_argument('--enable_dorm_reward',default=default('--enable_dorm_reward'),choices=['yes','no'],help='Dorm collect coins and loves',gooey_options={'label_color':'#4B5F83'})
help='How many minutes to replace feed. Recommend to set a time range, such as "10, 40"\nIf 6 ships in dorm, to use 6 kind of food, interval needs to greater than (14, 28, 42, 70, 139, 278)',gooey_options={'label_color':'#4B5F83'})
reward_dorm.add_argument('--dorm_feed_filter',default=default('--dorm_feed_filter'),help='Like research filter string',gooey_options={'label_color':'#4B5F83'})
priority2.add_argument('--daily_comm',default=default('--daily_comm'),help='Daily resource development, high-level tactical research and development',gooey_options={'label_color':'#4B5F83'})
priority4.add_argument('--urgent_drill',default=default('--urgent_drill'),help='Defend the transport troops, annihilate the enemy elite troops',gooey_options={'label_color':'#4B5F83'})
priority4.add_argument('--urgent_part',default=default('--urgent_part'),help='Support Vila Vela Island, support terror Banner',gooey_options={'label_color':'#4B5F83'})
priority4.add_argument('--urgent_book',default=default('--urgent_book'),help='Support Tuhaoer Island, support Moe Island',gooey_options={'label_color':'#4B5F83'})
reward_tactical=reward_parser.add_argument_group('Classroom','Only support continuation of skill books, not new skills',gooey_options={'label_color':'#931D03'})
choices=['yes','no'],help='Choose Yes, give priority to the 150% bonus \nSelect No, give priority to the skills book with the same rarity',gooey_options={'label_color':'#4B5F83'})
choices=['3','2','1'],help='Wich skill book will use first\nT3 is a gold book, T2 is a purple book, T1 is a blue book\ntier_max should greater than or equal to tier_min',gooey_options={'label_color':'#4B5F83'})
reward_meowfficer.add_argument('--buy_meowfficer',default=default('--buy_meowfficer'),help='From 0 to 15. If no need, fill 0.',gooey_options={'label_color':'#4B5F83'})
reward_guild=reward_parser.add_argument_group('Guild','Check Guild Logistics and Operations. Running for every reward loop.',gooey_options={'label_color':'#931D03'})
reward_guild.add_argument('--enable_guild_logistics',default=default('--enable_guild_logistics'),help='Enable logistics actions if applicable.',choices=['yes','no'],gooey_options={'label_color':'#4B5F83'})
reward_guild.add_argument('--enable_guild_operations',default=default('--enable_guild_operations'),help='Enable operations actions if applicable.',choices=['yes','no'],gooey_options={'label_color':'#4B5F83'})
reward_guild_logistics_items=reward_guild.add_argument_group('Logistics item input','Available items: t1, t2, t3, oxycola, coolant, coins, oil, and merit. Omitting an item will skip it. Less error-prone with many specified',gooey_options={'label_color':'#4B5F83'})
reward_guild_logistics_plates=reward_guild.add_argument_group('Logistics plate input','Available plates: torpedo, antiair, plane, gun, and general. Omitting a plate will skip it. Less error-prone with many specified',gooey_options={'label_color':'#4B5F83'})
emulator=emulator_parser.add_argument_group('Emulator','Need to Press start to save your settings, it will check whether the game is started \nIf the game has not started, it will be started',gooey_options={'label_color':'#931D03'})
help='If use one fleet, fill in the index of the fleet, such as 5\nIf use different fleets in different daily, separate index with commas, order: Escort Mission, Advance Mission, Fierce Assault, Tactical Training, such as 5, 5, 5, 6',gooey_options={'label_color':'#4B5F83'})
help='Change equipment before playing, unload equipment after playing, do not need to fill in 0 \ncomma, such as 3, 1, 0, 1, 1, 0',gooey_options={'label_color':'#4B5F83'})
help='Change equipment before playing, unload equipment after playing, do not need to fill in 0 \ncomma, such as 3, 1, 0, 1, 1, 0',gooey_options={'label_color':'#4B5F83'})
exercise.add_argument('--exercise_try',default=default('--exercise_try'),help='The number of attempts by each opponent',gooey_options={'label_color':'#4B5F83'})
help='After HP is below the threshold, it will retreat after a certain period of time \nRecommended 1.0 ~ 3.0',gooey_options={'label_color':'#4B5F83'})
help='Change equipment before playing, unload equipment after playing, do not need to fill in 0 \ncomma, such as 3, 1, 0, 1, 1, 0',gooey_options={'label_color':'#4B5F83'})
# event_daily_ab
event_bonus=daily_parser.add_argument_group('Event Daily Bonus','bonus for first clear each day',gooey_options={'label_color':'#931D03'})
event.add_argument('--event_stage',default=default('--event_stage'),help='Type stage name, not case sensitive, E.g D3, SP3, HT6',gooey_options={'label_color':'#4B5F83'})
event.add_argument('--event_name',default=event_latest,choices=event_folder,help='There a dropdown menu with many options',gooey_options={'label_color':'#4B5F83'})
'sos settings','Set fleets for SOS maps, order: fleet_1, fleet_2, submarine_fleet\nsuch as "4, 6", "4, 0", "4, 6, 1"\nFill 0 to skip a map',gooey_options={'label_color':'#931D03'})
'war archives settings','Type a stage and select a corresponding event for that stage',gooey_options={'label_color':'#931D03'})
war_archives.add_argument('--war_archives_stage',default=default('--war_archives_stage'),help='Type stage name, not case sensitive, E.g D3, SP3, HT6',gooey_options={'label_color':'#4B5F83'})
war_archives.add_argument('--war_archives_name',default=default('--war_archives_name'),choices=archives_folder,help='There a dropdown menu with many options',gooey_options={'label_color':'#4B5F83'})
semi=semi_parser.add_argument_group('Semi-automatic mode','Manual selection of enemies, automatic settlement, used to attack unsuited pictures',gooey_options={'label_color':'#931D03'})
semi.add_argument('--enable_semi_story_skip',default=default('--enable_semi_story_skip'),help='Note that this will automatically confirm all the prompt boxes, including the red face attack',
c_1_1=c_1_1_parser.add_argument_group('c1-1_affinity_farming','Will auto turn off clearing mode\nWith MVP, 8 battle to 1 affnity. Without MVP, 16 battle to 1 affnity.',
c_12_4=c_12_4_parser.add_argument_group('12-4 Search enemy settings','Need to ensure that the team has a certain strength',gooey_options={'label_color':'#931D03'})
os_semi=os_semi_parser.add_argument_group('os_semi_auto','Start and finish combat automatically',gooey_options={'label_color':'#931D03'})
os_semi.add_argument('--enable_os_semi_story_skip',default=default('--enable_os_semi_story_skip'),choices=['yes','no'],help='Note that this will automatically choose the options in map events',gooey_options={'label_color':'#4B5F83'})