scripted_gui = {
	coring_button_powers3 = {
	
		context_type = selected_state_context
		
		window_name = "coring_button_powers3_container"
		
		visible = {
			AND = {
				is_fully_controlled_by = ROOT
				NOT = { is_core_of = FROM }
				state_population > 100000
				NOT = { state_population > 250000 }
			}
		}
		
		effects = {
			create_core3_click = {
				ROOT = { 
					add_political_power = -25 
				}
				
				add_core_of = FROM
				}
		}
		triggers = {
			create_core3_click_enabled = {
				check_variable = { ROOT.political_power > 24.99 }
			}
		}
		        
		ai_check = {
			check_variable = { ROOT.political_power > 24.99 }
			check_variable = { ai_random > 0.65 }
		}
		
		ai_weights = {
			create_core3_click = {
				ai_will_do = {
					factor = 40
				}
			}
		}
	}
}

