Make a megastructor etc only build-able in unclaimed space?

  • We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.

StarDruid

Recruit
43 Badges
May 23, 2019
7
0
  • Cities: Skylines - Campus
  • Cities: Skylines - Parklife
  • Stellaris: Distant Stars
  • Shadowrun Returns
  • Shadowrun: Dragonfall
  • Surviving Mars: First Colony Edition
  • Cities: Skylines Industries
  • BATTLETECH: Flashpoint
  • Stellaris: Megacorp
  • Prison Architect
  • Surviving Mars: First Colony Edition
  • Surviving Mars: Digital Deluxe Edition
  • Stellaris: Ancient Relics
  • Age of Wonders: Planetfall
  • Age of Wonders: Planetfall Deluxe edition
  • Age of Wonders: Planetfall Premium edition
  • Age of Wonders: Planetfall Season pass
  • Stellaris: Lithoids
  • Age of Wonders: Planetfall - Revelations
  • Stellaris: Federations
  • Stellaris: Necroids
  • Stellaris: Nemesis
  • Stellaris: Apocalypse
  • Cities: Skylines
  • Cities: Skylines Deluxe Edition
  • Pillars of Eternity
  • Cities: Skylines - After Dark
  • Cities: Skylines - Snowfall
  • Stellaris
  • Hearts of Iron IV: Cadet
  • Stellaris: Digital Anniversary Edition
  • Stellaris: Leviathans Story Pack
  • Cities: Skylines - Natural Disasters
  • Cities: Skylines - Mass Transit
  • BATTLETECH
  • Surviving Mars
  • Age of Wonders III
  • Cities: Skylines - Green Cities
  • Stellaris: Humanoids Species Pack
  • Stellaris - Path to Destruction bundle
  • Stellaris: Synthetic Dawn
  • Cities in Motion 2
  • Magicka
Is it possible to make a megastructor etc only build-able in unclaimed space? Trying to make a modded gateway that can only be built in deep space that been surveyed, and can't be built in anyone borders, not even yours. It's going to cost more and be for a Gate builders style game play, send out construction ships deep space to build gateways then use them to setup new colonies etc.

I'm sadly not very inventive person, if I can find code that's similar I can see how it's done and go from there. Sadly I've not found any code similar to this that makes it unbuildable in claimed space. All I've seen is the foreign gateway mod that let you build it in external friendly borders then transferred owner ship to the space's owner.
 
take a look at common/megastructures/05_gateways.txt.

I haven't tested at all but this sure looks suspicious

possible = {
exists = starbase # <-------
custom_tooltip = {
fail_text = "requires_inside_border_or_subject" # <------- this whole block
OR = {
is_inside_border = from
AND = {
exists = owner
owner = {
is_subject = yes
overlord = { is_same_value = from }
}
}
}
}
 
take a look at common/megastructures/05_gateways.txt.

I haven't tested at all but this sure looks suspicious
Hmm was looking but didn't see how I could reverse it. Have to look at how their OR, AND, NOT statments are used but might be able to have it simple check if there there is a starbase then if so it can't be placed.
Edit:spelling/grammer
 
Last edited: