Question about InGame UI Override

Tokata_RuNeLess

Chieftain
Joined
Sep 17, 2015
Messages
39
Location
USTC in Hefei, China
What should I do to override a file such as PlotHelpManager.lua ?

Besides, I wonder if these columns of Table 'Improvements' below are working properly.
Code:
<Column name="RiverSideUpgradeMod" type="integer" default="0"/>
<Column name="CoastalLandUpgradeMod" type="integer" default="0"/>
<Column name="HillsUpgradeMod" type="integer" default="0"/>
<Column name="FreshWaterUpgradeMod" type="integer" default="0"/>
Actually they do not have any effect on an upgradeable improvement, with 'ImprovementUpgrade' and 'UpgradeTime' defined. If these columns work, how?:confused:
 
Here is my new problem.
I managed to get one improvement's ID from another, through column "ImprovementUpdate". I have tried the following codes, but none of them seemed to work.

Code:
GameInfo.Improvements[prereqImprovement].ImprovementUpdate
prereqImprovement.ImprovementUpdate
GameInfo.Improvements{Type=prereqImprovement}().ImprovementUpdate

and also

Code:
for row in DB.Query("SELECT new.ID FROM Improvements new, Improvements pre WHERE new.Type = pre.ImprovementUpgrade AND pre.Type = (a certain improvement type)") do
	newImprovement = row.ID
end

It is so sad that without this I have to use a looooooooong and miscellaneous lua file for my mod.
I wonder in which way could this work?:confused:
 
Most of those should work, so are you 100% positive (ie have you used something like SQLiteSpy to look) that your modded Improvements table actually contains what you think it should?
 
The table is a standard one, the question is "what's in the table"

The result of SQLiteSpy suggests that the table does contains the data I added. And I am pretty sure that it is just the code which try to get another improvement's ID that made the lua unable to work. :(

Anyway, I would continue trying to fix it.
 
Back
Top Bottom