K-Mod: Far Beyond the Sword

It's been a while since I edited a game font file, but I recall that it was a pain. I doubt that it's a problem with K-Mod. You've probably just got some pixel wrong somewhere.
 
Congratulations on an amazing project, Karadoc!! I've been playing the K-Mod for years - your dedication (along with so many others) keeps me coming back to the Civ 4 Community :thumbsup:

I hope I've done a thorough check in the discussion thread, but I'd like to ask if anyone could please help me bring my woes to an end: Is it possible to add religions to the K-Mod?

I believe I've correctly managed the XML and the GameFont.tga files, so that I get several added religions, properly represented by their GameFont.tga icons, along with their correct buildings, missionaries, etc. But as soon as I start adding icons in the GameFont_75.tga file, the game gets wonky :crazyeye: I'm using Asaf's Game Font Editor. Once I fire up the game, depending how I've modified, green smiley faces appear before any and all text, icons are mismatched (e.g. yellow smiley instead of the flexing bicep icon for unit strength), and/or icons don't appear, causing text overlay. It also tends to default to white oversized font for announcing in-game events. I actually do get the religion icons correctly matched, but it's not that much fun with all the interface eyesores :cringe:

If I don't modify the GameFont_75.tga file, the corporation icons replace the religion icons. For example, when I attempt to merge K-Mod with JARM (leaving K-Mod's GameFont_75.tga file unaltered), the religion Pesedjet is given the Aluminum Co. icon, Aesir Myth is represented by Sid's Sushi, and so on. While not ideal, the rest of the mod looks good and is functionally smooth.

From what I've read and understand, the game is just going down the list (script?) and matching Religion #1 with the first two religion icons (i.e. Judaism unstarred and starred) in the respective gamefont tga's. Likewise for corporations. What I'm fuzzy about is where/how exactly the icons I add in GameFont_75.tga become disruptive to K-Mod.

I’m upgraded to the latest K-Mod release (v1.45 5/Oct/2016) and I’m also running it with a merged Varietas Delectat. I've seen in other threads that I may need to alter CvGameCoreDLL.dll (and/or python files?), but if that kinda stuff isn't arcane black magic, I'm pretty sure it's beyond my capabilities for the foreseeable future... :borg:

Thank you very much in advance to any intrepid soul/ modding demigod who hears my :religion: and can reassure me that a religion merge for K-Mod isn't just a pipe dream :love:

Some symbols in the gamefont files are read sequentially (offset from start of line), while others are referenced by fixed indexes. This means that adding new symbols (and especially new rows) can cause later symbols to get offset. Another annoyance is that the same symbol can be correct in one place (e.g the pedia), but incorrect in another (e.g. above the city nameplate) - because they're referenced differently in each case. This is not a problem unique to K-Mod, though its inclusion of BUG complicates things further, as BUG adds its own symbols and way of referencing them.

The only advice I can give is to experiment with adding extra unused symbols (with corresponding xml) in order to correct these offsets. For example, my mod has 18 religions and 16 corporations, but I found I had to add symbols for a 17th corporation (and some dummy xml) or the symbols above the city nameplate would get offset. And the last time I added some new resources I found I had to add exactly 4 or everything would break. It gets rather bewildering at times.

In summary, JARM + K-Mod is absolutely possible, but you'll have to experiment a lot to get everything lined up.
 
Thanks for your advice and encouragement, Xyth!! Btw your :bowdown: HR Mod is awesome!! I'll take a look at what you did in your XML and keep trying :D Thanks again!!
 
... aaaand my Persian civ just got wiped out. I ragequitted :cry:

Let's start another civilization :scan:
 
Karadoc, I just wanted to thank you for all the effort you have put into this mod. I've been playing with K-Mod exclusively for many years now and I will never go back to "vanilla" :D I was a solid immortal player in BTS, but K-Mod bumped me down to emperor (which still feels somewhat harder than BTS immortal)
 
Probaly will give this a shot soon again as I was reminsed rexently.

I also found the earlier complaints about missing the red fist icons and begging for treaties hillarious Because I just realized how much of a crutch wheoohrn is. Yes, even for myself.

Now granted ai manipulation is needed to win from a disadvantage but then I realize the meta changes depends on the ai.
 
Last edited:
Hi @karadoc, many thanks for Development at K-mod. I just test it some hours and it looks awesome for me. I plan to use K-mod as GameCore Basis for my XML mod and would like to ask you some questions.
Do you have plans to include DCM to K-mod in future?
Is a new release of K-mod in a nearly release phase?
I only ask if it will better to wait some time for a new version or start next week with mod merging
best regards xas
 
Last edited:
Hi all,
I just merge the K-Mod with my artstyle mod and the game is starting well.

But can someone point me out on which position at GameFont_75.tga i have to add icons and what is the corresponding FontButtonIndex in CIV4ArtDefines_Bonus.xml :confused::confused::confused:
I tested this around 100 times and crash my HUD Interface icons every shot.......:cry:

one more question, i using custom unitartstyle buttons also. But the map HUD shows me only the default unit button. In city build menu and civilopedia is the custom button visible....
it seams the in K-Mod included BUG mod use the default buttons for units at the HUD.
Is there a option to change this ?

BR Xas
 
Last edited:
(Unrelated to the questions above, which I can't answer.)

I've posted a short list of bugfixes and minor UI improvements that could be integrated into the K-Mod main branch or other K-Mod mods without much effort. And I'd like to take this occasion to make K-Mod players aware of my mod "Advanced Civ", which is based on K-Mod and largely in the spirit of K-Mod. I uploaded a first version in April, and, by now, it seems pretty stable, at least on standard settings in singleplayer. The biggest contribution is a rewritten AI for decisions about war and peace.
 
And I'd like to take this occasion to make K-Mod players aware of my mod "Advanced Civ", which is based on K-Mod and largely in the spirit of K-Mod. I uploaded a first version in April, and, by now, it seems pretty stable, at least on standard settings in singleplayer. The biggest contribution is a rewritten AI for decisions about war and peace.

Interesting, going to download and try Advanced Civ. The Kmod AI decisions about war/peace is obviously a bit flawed. Could you elaborate on the changes made to that part of the AI?

edit: apparently you have written a gigantic manual explaining changes. Wow.
 
Last edited:
Hi
@f1rpo , Thanks for the hint will checkout your mod as well!
Did you observe the same unit button issue by using custom unitartstyles buttons and shows you the default unit buttons only ?
I don't talk about the civ special units... this buttons will correctly visible in the HUD.

BR
 
That's a bit disappointing. Then it would be perfect!

I would be very happy if someone were to integrate the two. Improved balance and AI combined with improved flavor? That balance is what made most of us love this game in the first place!
 
From what I can tell, BAT only includes art changes, so it should be trivial to merge with K-Mod, since there is probably little overlap. Right now I guess only a couple of XML schema files should need to be merged.
 
BAT might not be as trivial as it seems. It has its own DLL that would have to be merged with KMod in order to work correctly.
 
Oh, I thought BAT came without DLL just like BUG, my mistake.
 
Just a quick message:
I haven't made any significant changes for a few months; but I have been sitting on some stuff which is not yet uploaded. One of the things I've done is to change the way the AI chooses tech...
In the previous system, the AI would usually consider techs up to 3 levels deep; and just pick whatever it thought was the best value per research cost. It did not take into account the research cost, or the benefits, of any prereqs. It just sometimes chose techs that had prereqs, and beelined towards it.

I thought this was a bit silly; and sometimes led to poor decisions such as obsoleting important wonders with scientific method... So I rewrote it to instead only choose techs that it can immediately research, but with added value based on what the tech leads to.

That all sounds pretty good, and I'm sure it's a 'smarter' system overall, but so far with my limited testing I've not been impressed with the outcomes. The other system might have been illogical, but I'm not certain that the new logic of the new system is actually helping. I believe the path forward is to refine the new system; but at the moment I'm not sure if it is actually better...


If you feel like it, you can try for yourself. It's attached.

Let me know what you think. A few other things have been tweaked too; but the tech AI has had the most work (and possibly the least benefit)!
 

Attachments

Back
Top Bottom