Open Borders mod

Is this possible?

The issue with open borders is so glaring that it destroys any sense of immersion for me. I do not expect this to be officially fixed anytime soon, as it should have been fixed during development (not a good sign). So I was wondering if it would be possible to mod the game's core rules to solve this issue?

Either adding a restriction to require a declaration of war before entering the borders of another civ, and/or allowing a ruling civ to attack ships within it's own borders without a declaration of war. The second option is one I've never seen in a 4X game and seems more accurate to real life diplomacy "You can't blame us for destroying your ship, it appeared suddenly out of warp right next to our planet, and we are at war with another race so our military is on high alert on that world."

Is a mod of this nature possible?

20,775 views 15 replies
Reply #1 Top

(possibly a double post i apologize if so, my browser crashed mid post) If you mean influence boundaries as civ borders then no this will not happen. Open Borders treaty replaces a negative for having property inside a foreign influence border to a positive for having the treaty. And what you desire is beyond the available modding capability of the community. These are not borders in the way you think and will never be. Feel free to correct me others if i got any of this wrong and more so that i left something out which i am sure i have.

Reply #2 Top

As I intimated in the other thread, you're looking at this all wrong.  Those aren't your political borders.  They simply show your (and others) influlence.  If you hover a mouse of a tile, it'll even show how much influence each civ has on a tile.  If one looks at it that way, immersion should be broken in the slightest. 

Now as for turning them into political borders at the start of the game via a mod?  Sure, that should be possible, since there is a UP vote that allows them to be made into political borders.  What one would have to do is figure out how to turn that on on Turn One.  Shouldn't be too difficult, even if I'm not the one to do it. ;)

Reply #3 Top

The only UP resolution that I am seeing close to this is the Galactic Domain which prevents colonizing in another player's zone of control. This is glancing through the xml, i haven't played a game in a bit. A trigger on turn 1 is easy to implement but getting that to work inside a trigger I am not sure which schema to reference and if it would work since it only seems to appear in UPresolutions as a <Behavior> tag which is always outside of a trigger and only defined as an element to an entire UPresolution block. The behavior tag in question is <Behavior>BlockColonizationInOtherPlayerZOC</Behavior> . This could possibly be used although I understand you are asking for more than that. Possibly I am missing the resolution intended and also, I do not know xml by any means. I just try things that appear to be logically available given the structure I am allowed to see.

Reply #4 Top


Either adding a restriction to require a declaration of war before entering the borders of another civ, and/or allowing a ruling civ to attack ships within it's own borders without a declaration of war. The second option is one I've never seen in a 4X game and seems more accurate to real life diplomacy "You can't blame us for destroying your ship, it appeared suddenly out of warp right next to our planet, and we are at war with another race so our military is on high alert on that world."

Sid Meier's Civilization has a mechanic that prevents troops from entering rival territory without an open borders treaty. Also, Endless Legend has a nice feature where you can attack a rival faction in your territory or in neutral territory without DoW. You do suffer a diplomatic penalty, but only with that faction.

Reply #5 Top

This topic has been brought up before. I am ok with mods that have similiar mechanic like Civ 5 or Endless worlds, but only if the implications of how those mechanics work modify the Ai actions. 

 

I would much prefer mods that give me diplomatic threats to the ai and have the ai make a choice. For example, GET OFF MY LAWN or I will cancel all trade with you or NOT IN MY BACK YARD or I will declare on you. 

 

Then the ai has a choice and this choice/action is enforced for 25 or so turns. If it says no we go to war, so be it, now we are at war for AT LEAST 25 turns and no asking for peace or if they agree to leave they must keep all (MILITARY) ships out of my 'borders. 

NOTE: These border mods you ask for must NOT include Survey or Trade or scouts, but does include transports and colonizers and any armed ships. 

 

There, that is what I want....

Reply #6 Top

To be honest, having thought about it a bit, I'd like to see the addition of closed borders as an extra diplomatic option - so you have 'normal', 'open borders' AND 'closed borders'.

 

Normal would be pretty much how it is presently; they can enter your space but there's a relations penalty. This should stack for every unauthorized intrusion. The AI should be coded to be aware of this, and so should auto-exploring ships. The stacking effect should make an AI grow hostile very rapidly if you move 60 transports in to hover over his planets, but should make it less angry if 1 or 2 scouts happen to blunder in (I'm kind of sick of seeing the AI getting pissed at me the moment we meet because my scout had to fly into his influence). This is the absence of either open or closed borders.

Open borders would remove all penalties from moving in enemy space, though the AI should still remain aware of influence and avoid settling in someone else's simply because it's a very stupid thing to do most of the time. I have never once seen any AI planet that is settled within an area of reasonably established influence avoid being flipped to me eventually.

 

Closed borders would allow you to basically warn an enemy that any future entry into their space will be treated as an act of war. Any ships you have in their space should be forced to move directly out of their influence, like ships that are out of range do. Any attempt to move into their space is immediately greeted with an 'are you sure, this will declare war on this guy?' message. All trade routes are cancelled. If planets or SBs are on the wrong side of the border... tough luck, you shouldn't be dropping stuff on a potentially hostile power's turf.

+1 Loading…
Reply #7 Top

That sounds good Nasselus, now can you mod that? If not what api hooks do we need?

Reply #8 Top

Quoting Larsenex, reply 7

That sounds good Nasselus, now can you mod that? If not what api hooks do we need?

 

I suspect it's not moddable just yet, since there's no means to actually close the borders. We'd need an api to do that, just for starters. We'd also need the AI to understand it, which is part of it's C++ brain, rather than the xml script.

 

What we probably can do, however, is create a 'close borders' diplo move that prevents the receiving faction from placing Star Bases or colonizing in your influence. The code hooks are all there for that effect, and could be applied... but I'll need to check if we're actually allowed to define new diplo actions, or if they're hard-listed in the enums (like resources, or weapon types). 

Reply #9 Top

If it is a third option, than the border is the influence line, right? What will happen if ships, planets or starbases switch the site of borders because of spreading influence? Do you have to declare on your neighbour, because your influence spreads and engulfes a starbase?

Reply #10 Top

Anytime I have colonized inside another player's border I promptly lose the planet to cultural flip. Even if I prepare ahead of time and fill the skies around the planet with maxed-out culture starbases, it still quickly flips. The last time I tried it I blew it up when it was 90% in rebellion, then declared war and took 75% of the other fellow's planets. That'll teach 'em.

Reply #11 Top

Quoting Empress_Fujiko, reply 9

If it is a third option, than the border is the influence line, right? What will happen if ships, planets or starbases switch the site of borders because of spreading influence? Do you have to declare on your neighbour, because your influence spreads and engulfes a starbase?

 

No, whenever a ship starts a turn in 'closed' enemy influence, it just automatically retreats toward your influence. Likewise, if planets or SBs are on the wrong side for whatever reason, they cannot be reached by your ships, but the planet's surface itself actually does remain your influence until the enemy flips it. So any ships in orbit are ok, as long as they remain in orbit; anyone trying to reach orbit, on the other hand, has to declare a war.

 

Think of it as a Berlin Airlift sort of situation (since that's almost the exact real-life parallel, tbh) - the Soviets closed the borders, but didn't go so far as to actually attack West Berlin.

Reply #12 Top

Not poked around in the files since beta but is it not possible to just make the penalty much higher to relations across the board, so all races suffer high penalties with ships in each others territories, of course that'd mean more war but :)

Further for general use, a racial trait would be nice in that regard, so races that we wanted it on could have further customization from the norm.

Reply #13 Top

Quoting markmid, reply 12

Not poked around in the files since beta but is it not possible to just make the penalty much higher to relations across the board.

Further, a racial trait would be nice in that regard, so races that we wanted it on could have further customization from the norm.

 

Not until we can be sure that the AI notices (it won't) and so doesn't go off causing massive constant wars with each other, and also that the scouting command doesn't go off and begin stupid numbers of wars whenever you let it auto-scout.

Reply #14 Top

Quoting naselus, reply 13



Not until we can be sure that the AI notices (it won't) and so doesn't go off causing massive constant wars with each other, and also that the scouting command doesn't go off and begin stupid numbers of wars whenever you let it auto-scout.



Not for general play no I agree but for a xenophobic, invading or expansionist race who either don't want people entering their borders, or want an excuse to invade others, this makes sense that they would go to war a lot.

Reply #15 Top

Another gotcha with closed borders is that current and future "friendly AI" routines you activate on your fleets (such as Patrol, Scout, Explore, etc.) will need to take the enemy closed borders into account. This is part of the basic pathfinding algorithm and likely isn't modable.

Having experience with programming pathfinding, closed borders has the potential to totally cripple the CPU by trying to exhaustively pathfind for fleets in which no goal solution exists (you're totally boxed in) or for which the solution would take a fleet halfway around the galaxy and back. Pathfinding works fast and easy when you have a mostly clear space. When you have complicated maze-like spaces or when there is no way from A to B, then the algorithm blows up.