##########################################
##########################################
###############地图GUI部分 ################
##########################################
##########################################
defined_text = {
	name = getCYSY_map_selected_building_name
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 1} }
		localization_key = CYSY_map_building_1_name
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 2} }
		localization_key = CYSY_map_building_2_name
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 3} }
		localization_key = CYSY_map_building_3_name
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 4} }
		localization_key = CYSY_map_building_4_name
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 5} }
		localization_key = CYSY_map_building_5_name
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 6} }
		localization_key = CYSY_map_building_6_name
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 7} }
		localization_key = CYSY_map_building_7_name
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 8} }
		localization_key = CYSY_map_building_8_name
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 9} }
		localization_key = CYSY_map_building_9_name
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 10} }
		localization_key = CYSY_map_building_10_name
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 11} }
		localization_key = CYSY_map_building_11_name
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 12} }
		localization_key = CYSY_map_building_12_name
	}

}
defined_text = {
	name = getCYSY_map_selected_building_name_white
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 1} }
		localization_key = CYSY_map_building_1_name_white
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 2} }
		localization_key = CYSY_map_building_2_name_white
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 3} }
		localization_key = CYSY_map_building_3_name_white
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 4} }
		localization_key = CYSY_map_building_4_name_white
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 5} }
		localization_key = CYSY_map_building_5_name_white
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 6} }
		localization_key = CYSY_map_building_6_name_white
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 7} }
		localization_key = CYSY_map_building_7_name_white
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 8} }
		localization_key = CYSY_map_building_8_name_white
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 9} }
		localization_key = CYSY_map_building_9_name_white
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 10} }
		localization_key = CYSY_map_building_10_name_white
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 11} }
		localization_key = CYSY_map_building_11_name_white
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 12} }
		localization_key = CYSY_map_building_12_name_white
	}

}

###这是绰号
defined_text = {
	name = getCYSY_map_selected_building_nickname 
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 1} }
		localization_key = CYSY_map_building_1_nickname
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 2} }
		localization_key = CYSY_map_building_2_nickname
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 3} }
		localization_key = CYSY_map_building_3_nickname
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 4} }
		localization_key = CYSY_map_building_4_nickname
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 5} }
		localization_key = CYSY_map_building_5_nickname
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 6} }
		localization_key = CYSY_map_building_6_nickname
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 7} }
		localization_key = CYSY_map_building_7_nickname
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 8} }
		localization_key = CYSY_map_building_8_nickname
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 9} }
		localization_key = CYSY_map_building_9_nickname
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 10} }
		localization_key = CYSY_map_building_10_nickname
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 11} }
		localization_key = CYSY_map_building_11_nickname
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 12} }
		localization_key = CYSY_map_building_12_nickname
	}

}

###这是名称
defined_text = {
	name = getCYSY_map_data_power_selected_name
	text = {
		trigger = {
			check_variable = { CYSY_map_data_power_selected = 1 }
		}
		localization_key = CYSY_map_data_ZJC_name
	}

	text = {
		trigger = {
			check_variable = { CYSY_map_data_power_selected = 2 }
		}
		localization_key = CYSY_map_data_JWC_name
	}

	text = {
		trigger = {
			check_variable = { CYSY_map_data_power_selected = 3 }
		}
		localization_key = CYSY_map_data_XSH_name
	}

	text = {
		trigger = {
			check_variable = { CYSY_map_data_power_selected = 4 }
		}
		localization_key = CYSY_map_data_FJW_name
	}

	text = {
		trigger = {
			check_variable = { CYSY_map_data_power_selected = 5 }
		}
		localization_key = CYSY_map_data_JBZX_name
	}

}
###建筑物介绍
defined_text = {
	name = getCYSY_map_selected_building_desc 
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 1} }
		localization_key = CYSY_map_building_1_desc 
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 2} }
		localization_key = CYSY_map_building_2_desc 
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 3} }
		localization_key = CYSY_map_building_3_desc 
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 4} }
		localization_key = CYSY_map_building_4_desc 
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 5} }
		localization_key = CYSY_map_building_5_desc 
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 6} }
		localization_key = CYSY_map_building_6_desc 
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 7} }
		localization_key = CYSY_map_building_7_desc 
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 8} }
		localization_key = CYSY_map_building_8_desc 
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 9} }
		localization_key = CYSY_map_building_9_desc 
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 10} }
		localization_key = CYSY_map_building_10_desc 
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 11} } 
		localization_key = CYSY_map_building_11_desc 
	}
	text = {
		trigger = { check_variable = { CYSY_map_selected_building = 12} }
		localization_key = CYSY_map_building_12_desc 
	}

}
####给按钮白色
defined_text = {
	name = getGFX_CYSY_map_data_display_button_ZJC
	text = {
		trigger = {
			check_variable = { CYSY_map_data_power_selected = 1 }
		}
		localization_key = "GFX_CYSY_map_data_display_button_chosen"
	}
	text = {
		trigger = {NOT = {check_variable = { CYSY_map_data_power_selected = 1 }}}
		localization_key = "GFX_CYSY_map_data_display_button"
	}
}
defined_text = {
	name = getGFX_CYSY_map_data_display_button_JWC
	text = {
		trigger = {
			check_variable = { CYSY_map_data_power_selected = 2 }
		}
		localization_key = "GFX_CYSY_map_data_display_button_chosen"
	}
	text = {
		trigger = {NOT = {check_variable = { CYSY_map_data_power_selected = 2 }}}
		localization_key = "GFX_CYSY_map_data_display_button"
	}
}
defined_text = {
	name = getGFX_CYSY_map_data_display_button_XSH
	text = {
		trigger = {
			check_variable = { CYSY_map_data_power_selected = 3 }
		}
		localization_key = "GFX_CYSY_map_data_display_button_chosen"
	}
	text = {
		trigger = {NOT = {check_variable = { CYSY_map_data_power_selected = 3 }}}
		localization_key = "GFX_CYSY_map_data_display_button"
	}
}
defined_text = {
	name = getGFX_CYSY_map_data_display_button_FJW
	text = {
		trigger = {
			check_variable = { CYSY_map_data_power_selected = 4 }
		}
		localization_key = "GFX_CYSY_map_data_display_button_chosen"
	}
	text = {
		trigger = {NOT = {check_variable = { CYSY_map_data_power_selected = 4 }}}
		localization_key = "GFX_CYSY_map_data_display_button"
	}
}
defined_text = {
	name = getGFX_CYSY_map_data_display_button_JBZX
	text = {
		trigger = {
			check_variable = { CYSY_map_data_power_selected = 5 }
		}
		localization_key = "GFX_CYSY_map_data_display_button_chosen"
	}
	text = {
		trigger = {NOT = {check_variable = { CYSY_map_data_power_selected = 5 }}}
		localization_key = "GFX_CYSY_map_data_display_button"
	}
}

##########################################
###############收支数据上色################
##########################################
defined_text = {
	name = getCYSY_finance_profit_title 
	text = {
		trigger = {
			OR = {
				check_variable = { CYSY_finance_current_profit > 0 }
				check_variable = { CYSY_finance_current_profit = 0 }
			}
		}
		localization_key = CYSY_finance_profit_green_number
	}
	text = {
		trigger = {
			check_variable = { CYSY_finance_current_profit < 0 }
		}
		localization_key = CYSY_finance_profit_red_number
	}
}
defined_text = {
	name = getCYSY_cash_reserve_title
	text = {
		trigger = {
			OR = {
				check_variable = { CYSY_finance_current_cash_reserve > 0 }
				check_variable = { CYSY_finance_current_cash_reserve = 0 }
			}
		}
		localization_key = CYSY_cash_reserve_available
	}
	text = {
		trigger = {
			check_variable = {CYSY_finance_current_cash_reserve < 0 }
		}
		localization_key = CYSY_cash_reserve_in_debt
	}
}

############母公司态度###################


defined_text = {
	name = getCYSY_parent_company_relationship
	text = {
		trigger = {
			check_variable = { CYSY_parent_company_relationship_value < 2}
		}
		localization_key = CYSY_parent_company_relationship_level_1
	}
	text = {
		trigger = {
			check_variable = { CYSY_parent_company_relationship_value = 2}		
		}
		localization_key = CYSY_parent_company_relationship_level_2
	}
	text = {
		trigger = {
			check_variable = { CYSY_parent_company_relationship_value = 3}		
		}
		localization_key = CYSY_parent_company_relationship_level_3
	}
	text = {
		trigger = {
			check_variable = { CYSY_parent_company_relationship_value = 4}		
		}
		localization_key = CYSY_parent_company_relationship_level_4
	}
	text = {
		trigger = {
			check_variable = { CYSY_parent_company_relationship_value = 5}		
		}
		localization_key = CYSY_parent_company_relationship_level_5
	}
	text = {
		trigger = {
			check_variable = { CYSY_parent_company_relationship_value = 6}		
		}
		localization_key = CYSY_parent_company_relationship_level_6
	}
	text = {
		trigger = {
			check_variable = { CYSY_parent_company_relationship_value > 6 }		
		}
		localization_key = CYSY_parent_company_relationship_level_7
	}


}


################################################
################################################
###############非常可爱折线图部分################
################################################
################################################

##日期label处理
defined_text = {
	name = getCYSY_graph_label_month
	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			add_to_temp_variable = { i = 1}
			set_temp_variable = { months = CYSY_graph_months^i }
			
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 0 }
		}
		localization_key = CYSY_graph_label_month_12
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			add_to_temp_variable = { i = 1}
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 1 }
			
			
		}
		localization_key = CYSY_graph_label_month_1
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			add_to_temp_variable = { i = 1}
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 2 }
			
			
		}
		localization_key = CYSY_graph_label_month_2
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			add_to_temp_variable = { i = 1}
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 3 }
			
			
		}
		localization_key = CYSY_graph_label_month_3
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			add_to_temp_variable = { i = 1}
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
				modulo_temp_variable = { months = 12 }
				check_variable = { months = 4 }
			
			
		}
		localization_key = CYSY_graph_label_month_4
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			add_to_temp_variable = { i = 1}
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 5 }
		}
		localization_key = CYSY_graph_label_month_5
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			add_to_temp_variable = { i = 1}
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 6 }
		}
		localization_key = CYSY_graph_label_month_6
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			add_to_temp_variable = { i = 1}
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 7 }
			
			
		}
		localization_key = CYSY_graph_label_month_7
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			add_to_temp_variable = { i = 1}
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 8 }
			
		}
		localization_key = CYSY_graph_label_month_8
	}
	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			add_to_temp_variable = { i = 1}
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 9 }
			
		}
		localization_key = CYSY_graph_label_month_9
	}        
	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }  
			add_to_temp_variable = { i = 1}   
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 10 }
			
		}
		localization_key = CYSY_graph_label_month_10
	}
	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			add_to_temp_variable = { i = 1}
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 11 }
			
		}
		localization_key = CYSY_graph_label_month_11
	}
}

defined_text = { ##今夕是何年？？
	name = getCYSY_graph_label_year 
	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }add_to_temp_variable = { i = 1}   
			set_temp_variable = { yearmonths = CYSY_graph_months^i }
			check_variable = { yearmonths < month_standred_1 } #就是前年
		}
		localization_key = CYSY_graph_label_year_TYBLY #The year before last year
	}

	text = {
			trigger = {
				set_temp_variable = { i = segment_idx }add_to_temp_variable = { i = 1}   
				set_temp_variable = { yearmonths = CYSY_graph_months^i } 
				check_variable = { yearmonths > month_standred_12 } #就是今年
			}
		localization_key = CYSY_graph_label_year_NOW
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }add_to_temp_variable = { i = 1}   
			set_temp_variable = { yearmonths = CYSY_graph_months^i }
				NOT = {
					AND = {
						check_variable = { yearmonths < month_standred_1 }
						check_variable = { yearmonths > month_standred_12 } #就是去年
					}
				}
			}
		localization_key = CYSY_graph_label_year_LAST    
	}
}
#########################FIRST LABEL#####################
defined_text = { 
	name = getCYSY_graph_first_label_year 
	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }add_to_temp_variable = { i = 1}   
			set_temp_variable = { yearmonths = CYSY_graph_months^i }
			check_variable = { yearmonths < month_standred_1 } #就是前年
		}
		localization_key = CYSY_graph_label_year_TYBLY #The year before last year
	}

	text = {
			trigger = {
				set_temp_variable = { i = segment_idx }add_to_temp_variable = { i = 1}   
				set_temp_variable = { yearmonths = CYSY_graph_months^i } 
				check_variable = { yearmonths > month_standred_12 } #就是今年
			}
		localization_key = CYSY_graph_label_year_NOW
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }add_to_temp_variable = { i = 1}   
			set_temp_variable = { yearmonths = CYSY_graph_months^i }
				NOT = {
					AND = {
						check_variable = { yearmonths < month_standred_1 }
						check_variable = { yearmonths > month_standred_12 } #就是去年
					}
				}
			}
		localization_key = CYSY_graph_label_year_LAST    
	}
}

defined_text = {
	name = getCYSY_graph_first_label_month
	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			set_temp_variable = { months = CYSY_graph_months^i }
			
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 0 }
		}
		localization_key = CYSY_graph_label_month_12
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 1 }
			
			
		}
		localization_key = CYSY_graph_label_month_1
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 2 }
			
			
		}
		localization_key = CYSY_graph_label_month_2
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 3 }
			
			
		}
		localization_key = CYSY_graph_label_month_3
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
				modulo_temp_variable = { months = 12 }
				check_variable = { months = 4 }
			
			
		}
		localization_key = CYSY_graph_label_month_4
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 5 }
		}
		localization_key = CYSY_graph_label_month_5
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 6 }
		}
		localization_key = CYSY_graph_label_month_6
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 7 }
			
			
		}
		localization_key = CYSY_graph_label_month_7
	}

	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 8 }
			
		}
		localization_key = CYSY_graph_label_month_8
	}
	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 9 }
			
		}
		localization_key = CYSY_graph_label_month_9
	}        
	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }    
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 10 }
			
		}
		localization_key = CYSY_graph_label_month_10
	}
	text = {
		trigger = {
			set_temp_variable = { i = segment_idx }
			set_temp_variable = { months = CYSY_graph_months^i }
			add_to_temp_variable = { months = 12 }
			modulo_temp_variable = { months = 12 }
			check_variable = { months = 11 }
			
		}
		localization_key = CYSY_graph_label_month_11
	}
}
###################################################################
defined_text = {
	name = CYSY_Line_graph_display_unit_name 
	text = {
		trigger = { check_variable = { CYSY_Line_graph_display_unit = 0 } }
		localization_key = CYSY_graph_label_unit_none
	}
	text = {
		trigger = { check_variable = { CYSY_Line_graph_display_unit = 2 } }
		localization_key = CYSY_graph_label_unit_w
	}
	text = {
		trigger = { check_variable = { CYSY_Line_graph_display_unit = 3 } }
		localization_key = CYSY_graph_label_unit_m
	}
	text = {
		trigger = { check_variable = { CYSY_Line_graph_display_unit = 4 } }
		localization_key = CYSY_graph_label_unit_y
	}
	text = {
		trigger = { check_variable = { CYSY_Line_graph_display_unit = -1 } }
		localization_key = CYSY_graph_label_unit_pct
	}
}


