Info Addict

robk

Warlord
Joined
Sep 8, 2006
Messages
210
Location
Santa Monica, CA
Info Addict

Current Version: v22 (2013-09-10)
Compatible with Game Version: 1.0.3.80
Steam Workshop Page
Direct download from civfanatics


Info Addict GNK

For use with the Gods and Kings version of civ V
Current Version: v19 (2013-09-09)
Compatible with Game Version: 1.0.1.705
Steam Workshop Page


Info Addict Vanilla

For use with non-expansion version of civ V
Current Version: v17 (2012-07-01)
Compatible with Game Version: 1.0.1.674
Steam Workshop Page



Adds time based graphs showing civilizations' score, gold, military power, etc., visual representation of global relationships and tons of extra info on each civ. To access the Info Addict screen, hit the scroll button underneath the turn indicator and select "Info Addict". The main screen will pop up and you will be able to choose from three different panels where you can view historical data for each empire in several different categories, a world factbook that ranks each civilization by several demographics and a global relationship screen that illustrates the political and economic links between each empire.

Info Addict also adds a button to the trade and discussion screens so you can check Info Addict when a leader proposes a trade, pact or declaration of war.

Please note: this mod collects and saves the data it displays, so it will only work with games that have been started after Info Addict is enabled. It is also necessary to keep Info Addict enabled throughout the lifetime of the game to make sure there are no breaks in the data.

Features

Historical Graphs
  • Tracks civ statistics over time.
  • Clicking on a civ in the key to the left will highlight that civ in the current graph.
  • To remove a civ highlight, click on that civ again or hit the "Reset Selection" button that appears at the bottom left.
  • A zoom button appears in the bottom right corner as time progresses so you can zoom in on the last several turns to see immediate effects of your actions.
  • Each drawn line is offset by one pixel so that they don't overwrite each other. This is now optional.
  • Hovering over the graphing field will highlight that turn and display a tooltip with all the civs' values at that time (must be turned on from the options screen). Thanks to kris159 for this idea.

World Factbook
  • Demographics on steroids.
  • You can view world wide rankings for each data category.
  • You can also view demograhic data for each civ with ranking information included.
  • Unlike the vanilla civ demographics, ranks are only based on the civs that you have met so far. Rankings expand as you meet more civs.
  • Clicking on a row title in the empire view will take you to the view for that category. Also, clicking on a empire in the category view will take you to the empire view for that civ.

Global Relations
  • Visual representation of global empire relationships.
  • Lines are drawn between civ icons to indicate an active relationship based on the current view. The color of the line defines the type of relationship and those colors are indicated in a key at the bottom right corner of the window.
  • You can select different views via the menu on the bottom left.
  • Each icon has a mouseover tooltip with detailed information for each relationship.
  • You can select empire icons to show only the relationships associated with those empires. Tooltips on other empires change to show only relationship details with your selection or selections.
  • You can also select the different relationship types from the key on the bottom right to view only those types.
  • Dead civs show up as dimmed icons and tooltips for that empire are no longer shown.

Misc. Features
  • All panels only display civilizations that you've met so far.
  • Leader trade and discussion screens include a button to check Info Addict.
  • A selection reset button appears in the historical and global relations panels whenever a civ or relationship type is selected. This clears all current selections and redraws the current graph.
  • Various options are available in the Options panel.
  • All text is localized. If you would like to have your translations included with the mod, use XML/InfoAddictText.xml as a template and send me your additions via PM.

Installation

Download via the mod browser. Alternatively, you can download the zip file and unzip it into your Civ 5 MODS directory.

Spoiler Change Log :


v22 (2013-09-10)
  • Fixed bug that showed trade routes for civs that have not been met yet.

v21 (2013-09-08)
  • Fix crash to desktop issue when advanced start options are used
  • Fixed French and Spanish translation files

v20 (2013-09-02)
  • Updated for Brave New World
  • Added influence, great works, trade routes and tourism as new metrics to track.
  • Current international trade routes are shown in Global Relations.
  • Added some more info messages to log at startup to record the leader names of each civ.
  • Historical graphs will now display data correctly when all values are 0.
  • Up to 5 connectors possible in the civ relations screen now, instead of 3.
  • Italian translation added. Thanks Simone1974.
  • Imports and exports fix in civ relations graph. Thanks Aristos for pointing out the extra args to m_Deal:GetNextItem().
  • Compatible with patch 1.0.3.80.

v19 (2012-07-29)
  • German translation update (thanks Delta187).
  • No longer replaces the diplomacy screen files to add the "Check InfoAddict" button. The button is added exclusively through mod files. Hopefully, this will help with an intermittent problem with leader screens (not entirely sure this is a problem with InfoAddict since I cannot recreate the problem consistently but this change might help with it).

v18 (2012-07-03)
  • Fix for "The Netherlands" bleeding into the graphing area.
  • Dimmer colors are brightened somewhat now in the historical graphs. Civs like Ethiopia should be easier to see now.
  • Categories in historical graph screen moved around to make better use of available space.
  • Compatible with patch 1.0.1.705
  • Russian translation now included (thanks Kindofbear!)

v17 (2012-06-27)
  • Now compatible with Gods and Kings expansion.
  • Faith and Faith per Turn are now being tracked and displayed for each civ.

v16 (2011-07-11)
  • Bug Fix: y-axis labels on graphs with negative values now show correct values.
  • Changes from patch 1.0.1.332 merged in.
  • The last empire to be viewed in the factbook is now remembered and refreshes when civs are met or a new turn is encountered uses that info.
  • End of turn time sped up by removing unecessary garbage collection calls.
  • Total gold in each civ's treasury is now displayed in the historical graphs and factbook.
  • Added an option to smooth the lines in the historical graphs.
  • Added an option to enable line offsets in the historical graphs. This makes lines more easily visible between civs with equal values but sacrifices a little accuracy in the graphs to do so. Previous to v16, this was the default mode of display.
  • Subtle change in the way data is presented in the historical graphs: before this version, the value reported for each turn was the value of that type at the end of that turn. Now, however, the value being reported is where things stood at the beginning of that turn. I made this change to match the new replay data available from the latest game patch. As a consequence, turn 0 (or the first turn in an advanced age game) will always report 0 for every category.

v15 (2011-06-16)
  • Bug fix: Civ historical data will now be collected when player slots are changed in certain ways from the advanced set up screen.
  • Better end of turn detection. AI player data will no longer appear to be one turn behind the active player in the historical graphs.

v14 (2011-06-08)
  • Performance improvements when saving data.
  • German translation added (thanks Delta187!)
  • Spanish translation added (thanks Rual!)

v13 (2011-05-31)
  • Attitude graph available in Global Relations now.
  • Data saved in game file instead of ModUser Database.

v12 (2011-05-27)
  • Number of wonders an Empire controls is now tracked and displayed in the historical charts and world factbook.
  • "Culture" now means culture per turn. "Science" now means science per turn (beakers). Accumulated technologies is now called "Techs" and accumulated policies is now called "Policies". These changes affect both the historical graphs and the world factbook.
  • Both current graphs and the factbook will refresh when a new leader is encountered.
  • Resource icons have been added to the tooltips in the economic relations graph.
  • In the political relationship chart, "denouncement" is now "denouncing" to make it more clear what the direction of the denouncement is. Hovering over a civ icon will show you which empires that civ is currently denouncing.
  • Lines in the global relations graph are now generated through the ciV engine instead of pre-generated images. Consequently, 123 image files have been removed from the mod's Art directory. The only visible effect in the game is the lines sometimes look a little thicker in those graphs.

v11 (2011-05-14)
  • Merged in 1.0.1.275 changes to modified files.
  • Added French translation (thanks Smash15195!).

v10 (2010-12-22)
  • Minor update: ScriptData function are available again in hotfix 1.0.1.141 so the code that uses those functions is now back in (see last change in v7 for more info).

v9 (2010-12-18)
  • Merged in 1.0.1.135 changes to modified files.
  • Removed InfoAddict.xml from UpdateDatabase since it was not needed.
  • Updated InGameUIAddin path to jive with 1.0.1.135 changes.
  • Removed Pact of Cooperation and Pact of Secrecy logic in global relations, replaced with Declaration of Friendship and Denouncements.
  • Selection bubbles in the empire key of the historical graphs are moved up a little to make room for longer civ descriptions.
  • Temporary fix for identifying a game since ScriptData functions are missing.
  • Added alpaca's diplocorner menu library (http://forums.civfanatics.com/showthread.php?t=403481)
  • Incompatible with previous versions of Info Addict.

v8 (2010-12-06)
New Features:
  • Added empire's number of cities to historical graphs and the world factbook.
  • In the empire view of the factbook, each row title is now a link to the ranking view for the category. Also, each empire name in the ranking view is now a link to the empire view for that civ.
  • New options panel available from the main Info Addict screen.
  • Historical graph hover boxes highlight the turn and displays a tooltip with that turn's values when the mouse is hovering over the graphing field. [optional, default is off]
  • Added a y-axis for the historical graphs. [optional, default is off]
  • Number of labels on the x-axis and y-axis of the historical graphs can be set from slider in the option screen. [optional, default is 4 labels per axis]

Behavior Changes:
  • Dead civs now record nil values instead of 0. Historical graphs will not graph nil values so it should appear that the lines representing dead civs stop when they died. If a civ is liberated, it should reappear in the historical graphs from the time it is brought back to life.
  • Dead civs show a "-" instead of a "0" for each category in the world factbook. Also, their rank is always the lowest possible, even if live civs have negative values.
  • Factbook initializes to active player at the start of the game.
  • X-axis labels and averaged data are more accurate in the historical graphs.
  • X-axis labels no longer move with the x-axis when negative values are being graphed. They always stay at the bottom now.
  • The values in the Military and Land Area historical graphs now exactly match the values in the factbook and demographics instead of just being proportional.

Bug Fixes and Coding Changes:
  • Liberated civs no longer have dimmed icons in the Global Relations screen.
  • Bumped up the vertical size of the header row in the empire factbook view so that long names don't get their tops shaved off.
  • Reliance on InGame.xml to load Info Addict lua contexts has been removed.
  • Changes to NotificationLogPopup.lua are no longer needed. Instead of using the notification log event from the diplocorner menu, PushModal() is called directly to open up the main Info Addict panel.
  • SaveUtils upgraded to 07.2010.11.30.0000. Also, renamed to "SaveUtils" so it can be used in conjunction with other mods using the same library.
  • Performance enhanced by opening one, persistent connection to the mod user database per lua context.

v7 (2010-11-18)
  • Fixed bug in global relations that caused tooltips and highlights to break when a defensive pact is present.
  • Added Thal's logger utility (http://forums.civfanatics.com/showthread.php?t=398227)
  • Added Whys's SaveUtils library (http://forums.civfanatics.com/showthread.php?t=392958)
  • All text is now localized. If you would like to add translations, use XML/InfoAddictText.xml as a template and send me your additions via PM on the civfanatics message board.
  • Technologies and net happiness have their own rankings in the world factbook empire views.
  • Games are identified by a time string kept in the save file instead of counting up resources. This makes saved data somewhat more efficent and, more importantly, makes Info Addict fully compatible with resource modification mods and static maps. If Info Addict is upgraded and an old saved game started, the data will be converted to the new format, ensuring backward compatibility. For games that are well on their way (500+ turns), this conversion process, while only happening the first time the saved game is started, may take anywhere from 20 seconds to a minute to complete.

v6 (2010-11-07)
  • Removed the black flecks that occasionally showed up in the historical graph lines. Joints between horizontal and vertical lines are not perfect yet but it's much better now.
  • Fixed bugs related to the economic view in the global relations graph.
  • Patch 1.0.0.621 changes merged.

v5 (2010-11-05)
  • Added global relationship charts.
  • The list of civs in the historical graphs panel is now refreshed at the beginning of each turn.
  • Both the historical and relationship graphs have reset buttons now that appear when a selection is made. This button clears all selections and redraws the current graph.
  • Added a button to the trade and discussion screens so you can check Info Addict when a leader proposes a trade, pact or declaration of war.

v4 (2010-10-27)
  • Added a zoom button to view the last several turns without the graph resolution being lowered. Useful for seeing immediate effects of recent actions.
  • Removed the initial vertical bar that always sat on the left. It indicated an initial value of zero for every line, even when the first value wasn't zero.
  • Highlights are persistent through graph changes now.
  • Multiple civs can be highlighted at once.
  • Added light buttons (pips) next to each civ to indicate which one's are selected.
  • Fix for advanced starting era games.
  • Cheat mode is indicated in the main Info Addict title bar now.
  • The last graph drawn, current highlights and zoom state persist through turns now.
  • General code improvements.

v3 (2010-10-18)
  • Tracking 5 more types of historical data: Gross income (GNP), land area, production, crop yield & population.
  • Added page selectors at the bottom of the historical data panel to handle the extra data categories.
  • Dead civs now report 0 in every category. It doesn't make much sense for a dead civ to have +5 gold per turn.
  • "No Data Yet" and "Not Implemeted Yet" messages are centered properly now.
  • Fixed Y-Axis scaling when historical graph resolution is being lowered.
  • Clicking on "Historical Data" or "World Factbook" in the top menu bar forces a refresh of the left bar menus.
  • Added the world fact book panel.
  • Added the InfoAddictReadMe.txt file in the main mod directory.
  • Updated description for cleaner look (I hope).

v2 (2010-10-12)
  • Updated description
 

Attachments

  • economic relations.jpg
    economic relations.jpg
    173.4 KB · Views: 20,179
  • factbook.jpg
    factbook.jpg
    168.2 KB · Views: 16,186
  • global attitude.jpg
    global attitude.jpg
    193.6 KB · Views: 14,538
  • historical.jpg
    historical.jpg
    188.6 KB · Views: 10,961
  • historical_highlight.jpg
    historical_highlight.jpg
    171.8 KB · Views: 9,037
  • historical_zoomed_tooltip.jpg
    historical_zoomed_tooltip.jpg
    197.9 KB · Views: 9,256
  • political relations.jpg
    political relations.jpg
    166.2 KB · Views: 8,841
Compatibility with other mods

I used Kael's awesome mod guide to get started with everything and pretty much went step-by-step on the section about adding UI elements.

As of v19, InfoAddict no longer modifies any of the stock civ V xml or lua files.

Performance

I did a few tests with a game that ran for 900 turns with 8 players and, on my system, graphs were being created in a tenth of a second. Hopefully, the graphing part of the mod will not be significantly slower on other machines. Also, the civ engine would crash if I tried to create too many image instances while drawing the lines so I have a performance variable that will lower the graph resolution at a certain threshold to prevent that from happening. The lines will not be as smooth as they could be but, at least, the game won't crash.

(more info from InfoAddictHistoricalData.lua)
Spoiler :
-- maxDataPoints is exactly what it sounds like: the maximum number of data points allowed
-- in an InfoAddict historical graph. Because each data point is an image, the civ V engine
-- tends to have trouble rendering too many data points at once. The number of data points
-- per graph, if unbounded, is turns * visible players and this global sets an upper bound
-- on that number. If maxDataPoints is reached, the resolution of the graph is lowered and
-- values averaged over multiple turns to keep the number of images being used in the graph
-- from getting too large (actually, there are potentially two images per data point, the
-- horizontal image and the vertical image, which is why this is called maxDataPoints and
-- not maxImages).

-- If you ever click on the InfoAddict menu selection and the game freezes, lower this value
-- by 5-10% and keep doing so until it works. The default value is something that I worked out
-- by trial and error on my particular machine so it may not hold true for everyone. However,
-- it is a fairly conservative value so I hope it works for most.

local maxDataPoints = 1000;

If you're curious about performance info, you can fire up the SDK Tuner and you should see output like this:

Spoiler :

InfoAddictCivRelations: INFO: Total time to build political view: 0.012999999999977s
InfoAddictCivRelations: INFO: Total time to build economic view: 0.063999999999993s
InfoAddictCivRelations: INFO: Total time to build political view: 0.013000000000005s
InfoAddictCollector: INFO: GameIdent = 1290132241
InfoAddictCivRelations: INFO: Total time to build economic view: 0.076999999999998s
InfoAddictCivRelations: INFO: Total time to build political view: 0.01400000000001s
InfoAddictHistoricalData: INFO: loadPlayerDataTable() from 288 to 289 took 0.0060000000000002s to complete.
InfoAddictHistoricalData: INFO: Total time for DrawGraph(score): 0.043000000000006s
InfoAddictCivRelations: INFO: Total time to build political view: 0.0049999999999955s
 
yea, hard to believe they didn't keep these, one of my favorite things to look at in awe as my GNP graph goes exponential. Great job :)
 
Thank you! I didn't realize how much I'd miss these until they were gone.

One comment on how you noted that you would change "net income" to GNP, (sorry, I'm an accountant and a bit of a nerd to boot) the "net" term is always used to show a difference between two figures, like sales minus expenses equals net income. So GDP or GNP would actually be more correct, assuming that your gold number isn't considering expenses (which probably wouldn't be useful, since drastically different nations could each have 10 gold after expenses)

GNP measures a nation's total economic activity, and GDP is essentially the same but only for activity within its own borders. So, if you really want to be technically correct, GDP would probably be the best, since it's not looking at trade deals.

So now that I've become the accounting equivalent of a grammar nazi, thank you again for these. :)
 
Thank you! I didn't realize how much I'd miss these until they were gone.

One comment on how you noted that you would change "net income" to GNP, (sorry, I'm an accountant and a bit of a nerd to boot) the "net" term is always used to show a difference between two figures, like sales minus expenses equals net income. So GDP or GNP would actually be more correct, assuming that your gold number isn't considering expenses (which probably wouldn't be useful, since drastically different nations could each have 10 gold after expenses)

GNP measures a nation's total economic activity, and GDP is essentially the same but only for activity within its own borders. So, if you really want to be technically correct, GDP would probably be the best, since it's not looking at trade deals.

So now that I've become the accounting equivalent of a grammar nazi, thank you again for these. :)

I'm glad you brought that up because it forced me to look at it again and I think I was wrong. The values I'm reporting as "net gold" are actually the income after all expenses are accounted for, including trade deals. Specifically, it's the number reported by the function Player:CalculateGoldRate(), which is the positive or negative number that shows up in parenthesis in the top panel next to your total gold. I think I was looking at the graphs vs. the amount of gold each civ had available to them in the trade deals, forgetting that my graphs are one turn behind and they have to average values over multiple turns when the game has been going on for a while. Doofy move on my part.

I did find, however, that the "GNP" reported in the demographics screen comes from a function called Player:CalculateGrossGold() which reports income before any expenses are accounted for. Would it make sense for me to track the gross gold, call it "GDP" and also track gold after expenses, calling it "GNP"? I guess I could call them "Net Gold" and "Gross Gold" but I'm looking to jam more options on the bottom bar and the shorter the descriptions, the more stuff I can put down there. :)
 
GNP would be the best term for gross gold, if it's including trade deals. I could clarify it a little better. I hesitate to write too much because this stuff puts most people to sleep :). GDP and GNP kind of mean the same thing, at least as far as the average guy is concerned. Gross Domestic Product and Gross National Product. GDP just doesn't include any activity that occurs outside of the country's borders, hence the domestic in the name. So if the gross amount is including everything, including trade deals, GNP would probably be the most accurate name for gross gold.

The gold after expenses is a lot more like budget surplus or deficit than anything. Net gold, net income, gain/loss, surplus/deficit - these would all be pretty standard accounting terms for this number, but I'd avoid using the GDP or GNP terms for anything after expenses since those figures are generally used to measure whole economies.

Maybe if it says GNP for one and then Net for the other, and you wrote in the mod description that GNP is for all gold before expenses and Net is for gold left over after expenses, I think it would be clear enough for people, and the descriptions would be kept to three letters. Some of the more condensed financial statements will just use the word "net" instead of "net x."
 
Well, I have to say this looks amazing. :goodjob:

Given that my mod modifies all of those files, would you object to me merging this?

Thanks!

And, sure, no problem -- I don't object to the mod being merged. I tried to make my changes obvious via comments so you should be able to search for "robk" to see where those are made.
 
Thanks!

And, sure, no problem -- I don't object to the mod being merged. I tried to make my changes obvious via comments so you should be able to search for "robk" to see where those are made.

Excellent. :goodjob:

I'll be bringing it in for v3, then. I've merged many UI mods, simply because they are almost never compatible; This looks to be one of the best I've seen, right up there with the resource panel. Filled a very large need. :goodjob:
 
Maybe if it says GNP for one and then Net for the other, and you wrote in the mod description that GNP is for all gold before expenses and Net is for gold left over after expenses, I think it would be clear enough for people, and the descriptions would be kept to three letters. Some of the more condensed financial statements will just use the word "net" instead of "net x."

Thanks for the advice, I really appreciate it. I might keep it "GNP" and "Net Gold", just to keep the ambiguity down, as long as that doesn't blow out the bar on the bottom. I may have to put in a slider or pager down there because I'm already adding things like production and land area. If I end up doing that, then saving on character space isn't quite as important as being clear on what the data represents. I do like calling gross gold GNP because it matches the GNP in the demographics screen.
 
Hooray! I really missed graphs and can't believe they left them out. Thank you!
 
Could you please add the scale for the y-axis of the plot so it's easier to read? Would really appreciate it. Thanks for making the game more like it should be :)
 
Can you add a downloadable link to this mod, as stated in another mod post I am playing Civ5 in Wine (linux) and cant use the ingame downloading machanics.
 
Top Bottom