UI - Trade Opportunities

whoward69

DLL Minion
Joined
May 30, 2011
Messages
8,699
Location
Near Portsmouth, UK
Visualise trading opportunites from one screen

Adds a new Trade Opportunities tab to the Diplomatic screens



So your Silk for Wine trade with Rome has finished (and your happiness has just dropped by 4) but should you just immediately renew it, or is there a better option?

You want Silver, but only Liz has it and she wants your only Whales. Can you trade your spare Spices with someone else to get Whales, so you can trade yours to Liz for her Silver?

Six city states have Gold, but which one should you "buy" - preferably a Cultural one not already allied (as you don't want to get into a bidding war) and it would be good if they also had Coal - but which one has all those?

You have spare cash - who can you make a Research Agreement with?

You need cash - who's left to sell Open Borders and/or spare luxuries to?

What luxury will send the most cities into a "We Love The King Day"? And which Civ has that luxury?

This mod will help answer all those (and more) questions on one screen, thereby avoiding the need to click into evey civ and note what they are willing to trade (and what they want in return). And once you know which Civ to trade with or City State to "buy" you can go to their diplomacy screen with a single click.

Basic usage
* Find a resource on the top row (your resoures) with a green number - in this picture Wine.
* Scan down the column looking for red zeros
* Scan along that row looking for green numbers that have a corresponding red/yellow zero in the top row
* The combination of green resources gives you a trade opportunity

So in this picture I can trade Wine to
* Songhai for Cotton
* Rome for Dyes
* Korea for Sugar

Of those three, I already have a Research Agreement with Korea, Rome doesn't have enough cash for an RA, but Songhai does. So I'd probably do a combined deal of Wine + RA = Sugar + RA with Songhai

Which CS to "buy"
Well I could go for any of them, but I need Silver, Ivory or Incense to start a "We Love The King Day" in one or more cities (indicated by the yellow zeros in the top row), so it would make sense to "buy" a CS that has one of those luxuries. If I hover over the yellow zeros it will show me which cities want that resource, and as it happens, my capital and another city want Silver, so my choice is now down to three City States. I'm going for a cultural win, so one of the cultured two would be best, and if I hover over their icons I see that one is allied to Songhai (who can certainly out-bid me next turn) and the other is allied to Persia (who is locked in wars and about to exit the game anyway) so I'll go for that one. I click on the icon and go into the CS's diplomacy screen, give them a cash "donation", pick up the luxury and watch my citizens love me :)

The AI civilization list is ordered according to current score (so you should favour trading with the civs at the bottom of the screen!)

(Follow the link to Flickr, there are more notes on the image)

Modifies the core game files DiploOverview.lua and DiploOverview.xml, so will be incompatible with any other mod that changes these

You can find this mod on the Mod Hub under UI -> Widgets
 
This would be great if it were to replace or be added to the Trade button on Civ Williard. Maybe That will add this and put it on there. Civ Willard sometimes gets funky when there are lots of resources available, and you can't get to a very specific trade if you have extra copies of resources.
 
This is an incredibly important and well-done mod that should be part of the core game! It baffles me that vanilla has such a cumbersome trade interface.
 
Please put in the changes made by CivUp. This is the only mod I absolutely HAVE to play with - must don't really fundementally change the game. This one does. It takes an previously nearly unplayable area and makes it easy and fun. Thank you so much.

PS> CivUp never works for me, it eventually causes a game crash always has every version they put out. But if they could get that fixed it's a great mod. I can't use it past ~200 turns, but I love the trade opportunities feature they clearly got from this mod (maybe with permission?).

PPS> In case you are not aware of the specific changes I liked - they added clickable + signs to auto bring up the trade screen (trade all setup for you and ready to go) for basically everything (resources, open boarders, research agreements, defensive packs, etc...)
 
they added clickable + signs to auto bring up the trade screen (trade all setup for you and ready to go) for basically everything (resources, open boarders, research agreements, defensive packs, etc...)

Opening dialogs from dialogs (as that would do), in my experince, eventually causes memory leaks and hence crashes, so no, I won't be adding that type of feature.
 
Thank you for the prompt reply. Unfortunate that the feature can't be added safely, but I definitely don't want memory leaks, the game crashes or at best gets super slow. I run with this, and your clock mod, and a few other minor tweak mods (mostly UI and often yours) and don't get crashes anymore. So I appreciate you taking care with these things :)
 
Hey whoward, your mods are very great! Especially its presentation.

So I saw that TradeOpportunities is not yet compatible with GaK, what a pity! Looking forward for this. And by the way, if you need translations in German, do not hesitate to PM me ;-)
 
I'm working my way up to this one - the hardest part (probably) will be squeezing 7 more luxuries into the table!
 
Good to know. Easily my favourite mod this one. Trading is well tedious without it.
 
I've just (re-)surfaced from "UI layout hell"! Version 10 just uploaded to the Workshop (no G&K flash on the mod image yet, but this should work with G&K)

As the icons have been removed from in front of the numbers, if you hover over an AI player's number it will display the resource icon and name, similiarly the City State name is prefixed by the resource icon, and finally, hovering over a resource icon at the top of the screen will display the resource name.



If you have any mods installed that create new luxury resources (like SamBC's record label mod) this mod (should) just ignore them (a solution is planned)

Also, I haven't added the "Embassy" status yet (going in the obvious gap to the right of the luxury list)

Let me know about any issues

W
 
Version 11 uploaded.

Includes the 7 new luxuries, plus a column for luxuries added by any mods, plus a column for Embassy agreements.

Most of the code is unchanged, but please report any issues here, especially with the Embassy column as that was copied (rather hastily) from the core game files so it wouldn't surprise me if I've got the "us" and "them" logic the wrong way round!
 
My English ist not so good, do you speak German?

I used your Mod in Hotseat Mode (overwrite Original Files), and it worked
perfectly (except to one thing).

The Overviews "Trade Opportunities" and "City States" always refer Player 1.

Maybe you can install a player change?:)

Edit:

I've got the "us" and "them" logic the wrong way round!
Yes it´s wrong

It´s a addional Error in "DiploTradesStatus.xml"

"ToolTip"
TXT_KEY_RESOURCE_WHALE, TXT_KEY_RESOURCE_FUR, TXT_KEY_RESOURCE_DYE
must change to
TXT_KEY_RESOURCE_WHALES, TXT_KEY_RESOURCE_FURS, TXT_KEY_RESOURCE_DYES
 
Top Bottom