mauporte
Chieftain
I am trying to create a mod with espionage type mechanics and whilst browsing through the databases and the code I stumbled upon the following in EspionageChooser.lua under Assets/UI/Choosers/
-- ===========================================================================
-- MEMBERS
-- ===========================================================================
-- Currently selected spy
local m_spy :table = nil;
-- Currently selected city
local m_city :table = nil;
the code then proceeds to do a series of checks to which information and options to display in the espionage chooser, but what I cannot find anywhere else in the data files is where and how is it defined that the currently selected city is m_city and that the currently selected spy is m_spy. So this brings me to the question: How does the game know what is currently selected? And where are these definitions stored?
-- ===========================================================================
-- MEMBERS
-- ===========================================================================
-- Currently selected spy
local m_spy :table = nil;
-- Currently selected city
local m_city :table = nil;
the code then proceeds to do a series of checks to which information and options to display in the espionage chooser, but what I cannot find anywhere else in the data files is where and how is it defined that the currently selected city is m_city and that the currently selected spy is m_spy. So this brings me to the question: How does the game know what is currently selected? And where are these definitions stored?