namespace = planeteditor

planet_event = {
   id = planeteditor.target
   hide_window = yes
   is_triggered_only = yes
	

	immediate = { set_planet_flag = planeteditor_target }
          }
 



# hauptmen
country_event = {
	id = planeteditor.1
	title = planeteditor.1.name
	desc = planeteditor.1.desc
	picture = GFX_evt_alien_city   
	is_triggered_only = yes	



	option = {
      name = planeteditor.2.a
      hidden_effect = {
         country_event = { id = planeteditor.3 }
		}
	}
	
	option = {
      name = planeteditor.2.b
      hidden_effect = {
         country_event = { id = planeteditor.4 }
		}
	}
	
	option = {
      name = planeteditor.2.g
      hidden_effect = {
		country_event = { id = planeteditor.9 }
		}
	}


	option = {
      name = planeteditor.2.c
      hidden_effect = {
		country_event = { id = planeteditor.5 }
		}
	}
	
	option = {
      name = planeteditor.2.d
      hidden_effect = {
		country_event = { id = planeteditor.6 }
		}
	}
	
	option = {
      name = planeteditor.2.e
      hidden_effect = {
		country_event = { id = planeteditor.7 }
		}
	}
	
	option = {
      name = planeteditor.2.f
      hidden_effect = {
		country_event = { id = planeteditor.8 }
		}
	}
	


	option = {
		name = planeteditor.exit
		hidden_effect = {
			random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				remove_planet_flag = planeteditor_target 

			}
		}
	}
}

# Planeten Klasse
country_event = {
	id = planeteditor.3
	title = planeteditor.1.name
	desc = planeteditor.3.desc
	picture = GFX_evt_alien_city
        
        is_triggered_only = yes	
          
 

        
	option = {
		name = planeteditor.3.a
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_desert 
			}
			country_event = { id = planeteditor.1 }
		}
	}



	option = {
		name = planeteditor.3.b
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_arid
			}
			country_event = { id = planeteditor.1 }
		}
	}



	option = {
		name = planeteditor.3.c
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_savannah
			}
			country_event = { id = planeteditor.1 }
		}
	}


	option = {
		name = planeteditor.3.d
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_ocean
			}
			country_event = { id = planeteditor.1 }
		}
	}


	option = {
		name = planeteditor.3.e
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_continental
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.3.f
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_tropical
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.3.g
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_arctic
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.3.h
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_alpine
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.3.i
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_tundra
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.3.j
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_toxic
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.3.k
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_molten
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.3.l
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_gas_giant
			}
			country_event = { id = planeteditor.1 }
		}
	}		


	option = {
		name = planeteditor.3.m
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_frozen
			}
			country_event = { id = planeteditor.1 }
		}
	}		


	option = {
		name = planeteditor.3.n
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_barren
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.3.o
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_barren_cold
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.3.p
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_nuked
			}
			country_event = { id = planeteditor.1 }
		}
	}		

	option = {
		name = planeteditor.3.q
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_machine
			}
			country_event = { id = planeteditor.1 }
		}
	}		


	option = {
		name = planeteditor.3.r
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_gaia 
			}
			country_event = { id = planeteditor.1 }
		}
	}		


	option = {
		name = planeteditor.3.s
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_pc = pc_asteroid 
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.return
      hidden_effect = {
		country_event = { id = planeteditor.1 }
		}
	}
}


# Planeten Gre
country_event = {
	id = planeteditor.4
	title = planeteditor.1.name
	desc = planeteditor.4.desc
	picture = GFX_evt_alien_city
	is_triggered_only = yes	


	option = {
		name = planeteditor.4.a
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
                                change_planet_size = 1
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.4.b
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_planet_size = 2
			}
			country_event = { id = planeteditor.1 }
		}
	}


	option = {
		name = planeteditor.4.c
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_planet_size = 5
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.4.d
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_planet_size = -1
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.4.e
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_planet_size = -2
			}
			country_event = { id = planeteditor.1 }
		}
	}

	option = {
		name = planeteditor.4.f
		hidden_effect = {
			   random_planet = {
				limit = { has_planet_flag = planeteditor_target }
				change_planet_size = -5
			}
			country_event = { id = planeteditor.1 }
		}
	}


	option = {
      name = planeteditor.return
      hidden_effect = {
		country_event = { id = planeteditor.1 }
		}
	}
}

# orbitale resource
country_event = {
	id = planeteditor.5
	title = planeteditor.1.name
	desc = planeteditor.5.desc
	picture = GFX_evt_alien_city
	is_triggered_only = yes	



	option = {
      name = planeteditor.5.a
      custom_tooltip = planeteditor.5.a.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_immense_energy_deposit }
			}
		country_event = { id = planeteditor.1 }
		}
	}		


	
	option = {
      name = planeteditor.5.b
      custom_tooltip = planeteditor.5.b.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_immense_mineral_deposit }
			}
		country_event = { id = planeteditor.1 }
		}
	}		


	option = {
      name = planeteditor.5.c
      custom_tooltip = planeteditor.5.c.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_immense_physics_deposit }
			}
		country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.5.d
      custom_tooltip = planeteditor.5.d.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_immense_society_deposit }
			}
		country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.5.e
      custom_tooltip = planeteditor.5.e.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_immense_engineering_deposit }
			}
		country_event = { id = planeteditor.1 }
		}
	}


	option = {
      name = planeteditor.5.f
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { clear_deposits = yes }
			}
		country_event = { id = planeteditor.1 }
		}
	}



	option = {
      name = planeteditor.return
      hidden_effect = {
		country_event = { id = planeteditor.1 }
		}
	}
}


# strategische resource
country_event = {
	id = planeteditor.6
	title = planeteditor.1.name
	desc = planeteditor.6.desc
	picture = GFX_evt_alien_city
	is_triggered_only = yes	


	option = {
      name = planeteditor.6.a
custom_tooltip = planeteditor.6.a.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_terraforming_gas_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}		

	option = {
      name = planeteditor.6.b
custom_tooltip = planeteditor.6.b.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_terraforming_fluid_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.6.c
custom_tooltip = planeteditor.6.c.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_garanthium_deposit }
			}
         country_event = { id = planeteditor.1 }
         
		}
	}

	option = {
      name = planeteditor.6.d
custom_tooltip = planeteditor.6.d.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_lythuric_gas_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.6.e
custom_tooltip = planeteditor.6.e.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_engos_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}		


	option = {
      name = planeteditor.6.f
custom_tooltip = planeteditor.6.f.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_teldar_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.6.g
custom_tooltip = planeteditor.6.g.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_pitharan_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.6.h
custom_tooltip = planeteditor.6.h.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_orillium_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.6.i
custom_tooltip = planeteditor.6.i.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_satramene_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}		

	option = {
      name = planeteditor.6.j
custom_tooltip = planeteditor.6.j.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_neutronium_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}		


	option = {
      name = planeteditor.6.k
custom_tooltip = planeteditor.6.k.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_living_metal_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.6.l
custom_tooltip = planeteditor.6.l.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_zro_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.6.m
custom_tooltip = planeteditor.6.m.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_dark_matter_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.6.n
custom_tooltip = planeteditor.6.n.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { add_deposit = d_yuranic_deposit }
			}
         country_event = { id = planeteditor.1 }
		}
	}		

	option = {
      name = planeteditor.6.o
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            orbital_deposit_tile = { clear_deposits = yes }
			}
		country_event = { id = planeteditor.1 }
		}
	}




	option = {
      name = planeteditor.return
      hidden_effect = {
		country_event = { id = planeteditor.1 }
		}
	}
}



# planet modifikator
country_event = {
	id = planeteditor.7
	title = planeteditor.1.name
	desc = planeteditor.7.desc
	picture = GFX_evt_alien_city
	is_triggered_only = yes	

	option = {
      name = planeteditor.7.a
custom_tooltip = planeteditor.7.a.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "asteroid_belt"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.7.b
custom_tooltip = planeteditor.7.b.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "asteroid_impacts"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }
		}
	}		


	option = {
      name = planeteditor.7.c
custom_tooltip = planeteditor.7.c.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "atmospheric_aphrodisiac"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.7.d
custom_tooltip = planeteditor.7.d.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "atmospheric_hallucinogen"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.7.e
custom_tooltip = planeteditor.7.e.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "ultra_rich"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.7.f
custom_tooltip = planeteditor.7.f.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "carbon_world"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }
		}
	}		

	option = {
      name = planeteditor.7.g
custom_tooltip = planeteditor.7.g.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "extensive_moon_system"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.7.h
custom_tooltip = planeteditor.7.h.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "hazardous_weather"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }      
		}
	}


	option = {
      name = planeteditor.7.i
custom_tooltip = planeteditor.7.i.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "mineral_rich"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.7.j
custom_tooltip = planeteditor.7.j.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "dangerous_wildlife"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}		


	option = {
      name = planeteditor.7.k
custom_tooltip = planeteditor.7.k.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "low_gravity"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}

	option = {
      name = planeteditor.7.l
custom_tooltip = planeteditor.7.l.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "natural_beauty"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}

	option = {
      name = planeteditor.7.m
custom_tooltip = planeteditor.7.m.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "strong_magnetic_field"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}

	option = {
      name = planeteditor.7.n
custom_tooltip = planeteditor.7.n.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "titanic_life"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}		

	option = {
      name = planeteditor.7.o
custom_tooltip = planeteditor.7.o.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "unstable_tectonics"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}		


	option = {
      name = planeteditor.7.p
custom_tooltip = planeteditor.7.p.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "wild_storms"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}

	option = {
      name = planeteditor.7.q
custom_tooltip = planeteditor.7.q.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "lush_planet"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}

	option = {
      name = planeteditor.7.t
custom_tooltip = planeteditor.7.t.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "weak_magnetic_field"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}

	option = {
      name = planeteditor.7.u
custom_tooltip = planeteditor.7.u.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "tidal_locked"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}

	option = {
      name = planeteditor.7.v
custom_tooltip = planeteditor.7.v.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "mineral_poor"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}

	option = {
      name = planeteditor.7.w
custom_tooltip = planeteditor.7.w.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "irradiated_planet"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}

	option = {
      name = planeteditor.7.x
custom_tooltip = planeteditor.7.x.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "high_gravity"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}

	option = {
      name = planeteditor.7.y
custom_tooltip = planeteditor.7.y.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			add_modifier = {
				modifier = "bleak_planet"
				days = -1
				}
			}
         country_event = { id = planeteditor.1 }

		}
	}

	option = {
      name = planeteditor.7.r
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
			remove_modifier = "asteroid_belt"
			remove_modifier = "asteroid_impacts"
			remove_modifier = "atmospheric_aphrodisiac"
			remove_modifier = "atmospheric_hallucinogen"
			remove_modifier = "bleak_planet"
			remove_modifier = "carbon_world"
			remove_modifier = "chthonian_planet"
			remove_modifier = "extensive_moon_system"
			remove_modifier = "hazardous_weather"
			remove_modifier = "high_gravity"
			remove_modifier = "dangerous_wildlife"
			remove_modifier = "irradiated_planet"
			remove_modifier = "low_gravity"
			remove_modifier = "lush_planet"
			remove_modifier = "mineral_poor"
			remove_modifier = "mineral_rich"
			remove_modifier = "natural_beauty"
			remove_modifier = "strong_magnetic_field"
			remove_modifier = "tidal_locked"
			remove_modifier = "titanic_life"
			remove_modifier = "ultra_rich"
			remove_modifier = "unstable_tectonics"
			remove_modifier = "weak_magnetic_field"
			remove_modifier = "wild_storms"
			remove_modifier = "terraforming_candidate"
			}
         country_event = { id = planeteditor.1 }

		}
	}

	option = {
      name = planeteditor.return
      hidden_effect = {
		country_event = { id = planeteditor.1 }
		}
	}
}

#pre-sapient
country_event = {
	id = planeteditor.8
	title = planeteditor.1.name
	desc = planeteditor.8.desc
	picture = GFX_evt_alien_city
	is_triggered_only = yes	


	option = {
      name = planeteditor.8.a
custom_tooltip = planeteditor.8.a.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
                     			create_species = {
				name = random
				class = random
				portrait = random
				traits = {
					trait = random_presapient_trait
				}
				homeworld = this
				sapient = no
			}
			while = {
				limit = {
					count_pops = {
						limit = { is_sapient = no }
						count < 3
					}
					free_pop_tiles > 0
				}
				best_tile_for_pop = {
					create_pop = { species = last_created }
				}
			}
		}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.return
      hidden_effect = {
		country_event = { id = planeteditor.1 }
		}
	}
}

#ground resources
country_event = {
	id = planeteditor.9
	title = planeteditor.1.name
	desc = planeteditor.9.desc
	picture = GFX_evt_alien_city

        is_triggered_only = yes	


	option = {
      name = planeteditor.9.a
custom_tooltip = planeteditor.9.a.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }

          			random_tile = { add_deposit = d_rich_energy_deposit 
                                       limit = { has_resource = {type = society_research amount < 1} has_resource = {type = physics_research amount < 1} has_resource = {type = engineering_research amount < 1}  }  }
      
                                random_tile = { add_deposit = d_energy_deposit 
                                       limit = { has_resource = {type = society_research amount < 1} has_resource = {type = physics_research amount < 1} has_resource = {type = engineering_research amount < 1}  }  }
                                  
                                random_tile = { add_deposit = d_energy_deposit 
                                       limit = { has_resource = {type = society_research amount < 1} has_resource = {type = physics_research amount < 1} has_resource = {type = engineering_research amount < 1}  }  }
                                    
 
				}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.9.b
custom_tooltip = planeteditor.9.b.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
                                      
          			random_tile = { add_deposit = d_rich_mineral_deposit 
                                       limit = { has_resource = {type = society_research amount < 1} has_resource = {type = physics_research amount < 1} has_resource = {type = engineering_research amount < 1}  }  }
                                    
                                random_tile = { add_deposit = d_mineral_deposit 
                                       limit = { has_resource = {type = society_research amount < 1} has_resource = {type = physics_research amount < 1} has_resource = {type = engineering_research amount < 1}  }  }
                                      
                                random_tile = { add_deposit = d_mineral_deposit   
                                       limit = { has_resource = {type = society_research amount < 1} has_resource = {type = physics_research amount < 1} has_resource = {type = engineering_research amount < 1}  }  }
                                      

				}
         country_event = { id = planeteditor.1 }
		}
	}


	option = {
      name = planeteditor.9.c
custom_tooltip = planeteditor.9.c.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }

          			random_tile = { add_deposit = d_rich_farmland_deposit 
                                       limit = { has_resource = {type = society_research amount < 1} has_resource = {type = physics_research amount < 1} has_resource = {type = engineering_research amount < 1}  }  }
                                    
                                random_tile = { add_deposit = d_farmland_deposit 
                                       limit = { has_resource = {type = society_research amount < 1} has_resource = {type = physics_research amount < 1} has_resource = {type = engineering_research amount < 1}  }  }
                                     
                                random_tile = { add_deposit = d_farmland_deposit 
                                       limit = { has_resource = {type = society_research amount < 1} has_resource = {type = physics_research amount < 1} has_resource = {type = engineering_research amount < 1}  }  }
                                      

				}
        country_event = { id = planeteditor.1 }
		}
	}


	option = {
      name = planeteditor.9.d
custom_tooltip = planeteditor.9.d.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
          			random_tile = { add_deposit = d_rich_physics_deposit 
                                       limit = { has_resource = {type = energy amount < 1} has_resource = {type = food amount < 1} has_resource = {type = minerals amount < 1}  }  }
                                      
                                random_tile = { add_deposit = d_physics_deposit 
                                       limit = { has_resource = {type = energy amount < 1} has_resource = {type = food amount < 1} has_resource = {type = minerals amount < 1}  }  }
                                       
				}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.9.e
custom_tooltip = planeteditor.9.e.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
          			random_tile = { add_deposit = d_rich_society_deposit 
                                       limit = { has_resource = {type = energy amount < 1} has_resource = {type = food amount < 1} has_resource = {type = minerals amount < 1}  }  }
                                       
                                random_tile = { add_deposit = d_society_deposit 
                                       limit = { has_resource = {type = energy amount < 1} has_resource = {type = food amount < 1} has_resource = {type = minerals amount < 1}  }  }
                                         
				}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.9.f
custom_tooltip = planeteditor.9.f.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
          			random_tile = { add_deposit = d_rich_engineering_deposit 
                                       limit = { has_resource = {type = energy amount < 1} has_resource = {type = food amount < 1} has_resource = {type = minerals amount < 1}  }  }
                                      
                                random_tile = { add_deposit = d_engineering_deposit 
                                       limit = { has_resource = {type = energy amount < 1} has_resource = {type = food amount < 1} has_resource = {type = minerals amount < 1}  }  }
                                         
				}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.9.j
custom_tooltip = planeteditor.9.j.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
          			random_tile = { add_deposit = d_society_deposit 
                                       limit = { has_resource = {type = energy amount < 1} has_resource = {type = food amount < 1} has_resource = {type = minerals amount < 1}  }  }
                                        
                                random_tile = { add_deposit = d_engineering_deposit 
                                       limit = { has_resource = {type = energy amount < 1} has_resource = {type = food amount < 1} has_resource = {type = minerals amount < 1}  }  }
                                         
                                random_tile = { add_deposit = d_physics_deposit 
                                       limit = { has_resource = {type = energy amount < 1} has_resource = {type = food amount < 1} has_resource = {type = minerals amount < 1}  }  }
                                         
				}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.9.g
custom_tooltip = planeteditor.9.g.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
          			random_tile = { add_deposit = d_betharian_deposit 
                                       limit = { has_resource = {type = society_research amount < 1} has_resource = {type = physics_research amount < 1} has_resource = {type = engineering_research amount < 1}  }  }
                                      
				}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.9.h
custom_tooltip = planeteditor.9.h.tooltip
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
          			random_tile = { add_deposit = d_alien_pets_deposit 
                                       limit = { has_resource = {type = food amount < 2} has_resource = {type = minerals amount < 2} has_resource = {type = energy amount < 2}  }  }
                                       
				}
         country_event = { id = planeteditor.1 }
		}
	}

	option = {
      name = planeteditor.9.i
      hidden_effect = {
         random_planet = {
            limit = { has_planet_flag = planeteditor_target }
            every_tile = { clear_deposits = yes }
			}
		country_event = { id = planeteditor.1 }
		}
	}


	option = {
      name = planeteditor.return
      hidden_effect = {
		country_event = { id = planeteditor.1 }
		}
	}
}
