Post by JRavens on Jan 10, 2016 16:23:50 GMT
This was a post I made on the Steam forums for the game Lords of Xulima (a modern RPG that is a throwback to classic games like Baldur's Gate, Ultima and so forth). It's a fun, but challenging RPG and I recommend it it you get an itch for dungeon crawling and classic turn based style combat. Any way the modder in me took over and I explored what could be changed about the game and found that quite a lot actually could be modified if someone wanted to. So just sharing this for that one random person out there who has an itch to do this (nothing more frustrating than wanting to do something, but not knowing HOW to do it)
Hi guys. I'm a modder and have made mods for a variety of games (from tiny little joke mods all the way to sweeping whole game conversions). I'm probably best know for my Far Cry 4 mods though I've created stuff for several other AAA games as well. If you are interested in checking out my mods or just want a cool place to discuss games check out my forums here: farcrymods.freeforums.net/
OK on with the show -
I was going to mod Lords of Xulima after I picked it up during the Steam Winter sale, but the truth is I really don't have the time. My free time is extremely restricted now and my choice of upcoming mods that I can work on will be limited. However rather than let my (limited) knowledge go to waste I decided to share it here in case someone wants to pick up the torch.
NOTE: this is a VERY LONG article so grab a nice cup of coffee/tea/soda and sit back. Maybe print it off or take it in small chunks. Sorry for the WALL OF TEXT, but it's a lot of info to convey and I want to do it in one fell swoop.
This is all info I gleaned from examining the files and VERY BASIC experimentation over my holiday vacation. If you apply any of these techniques you WILL need to test, test, test and like any game some things will either (A) NOT WORK as intended or (B) flat out crash the game. This is true of modding ANY game. Essentially you are forcing the game to do things it wasn't designed to do (even if it seems simple or innocent like replacing an image, changing a text label or swapping around sound files)
Having said that also be aware the Devs may NOT want us mucking around in their files and at the very least may turn a blind eye to it. They certainly cannot support any modding outside of the official editor so DON'T ask them about bugs related to modifying anything found here.
They might however alter the files in a future patch to prevent modifying them in the way I describe here. I honestly have no idea how they will feel about it. Hopefully they understand that modding is something we do out of love for a game and it helps a game's longevity and popularity as mods are often featured in YouTube videos and gaming site articles.
Before we start you should grab three important tools useful to any modder (these are not the ONLY tools, but I do highly recommend them. You can use whatever programs you feel comfortable with):
1) 7zip (http://www.7-zip.org/) - this is an archive program that works with .zip files as well as MANY other types of archiving and compression. It's most useful feature is you can attempt to open ANY file even if it has a weird file extension. Many game designers (like this one) use .zip or other compression and simply rename the extension. Having this will let you open Xulima's unusual archives.
2) Notepad++ (https://notepad-plus-plus.org/) is a powerful text editor. One thing I really like about it (besides being easy to use) is that it doesn't make changes "on it's own" like some other editors do. So it won't add arbitrary line spaces, carriage returns, etc. Nor will it change the text encoding when you save files that you were working on. So essentially 99.9% of the time anything you change will be exactly the same KIND of file that it originally was and so any errors the game throws are going to be some mistake you made when typing or something the game doesn't support like a line that is too long, a number that is too large or small, etc. and NOT something Windows Notepad or Wordpad has done when it saved the file. It also has a lot of cool features like multiple tabs, plugins, etc. that you can learn about in the future. For now though it's a fantastic and useful alternative to anything that came with your operating system.
and
3) Bulk Rename Utility (http://www.bulkrenameutility.co.uk/) - this program is a power tool which will let you rename hundreds (or even thousands) of files at once. It's useful here because the graphics files in LOX are png files, but they have no file extension. So using this will let you temporarily examine all of them at once.
Once you have those tools we can discuss what files are in the Lords of Xulima folder and how you might edit them.
Go to where the game is installed (the easiest way is in Steam to right click on a game and choose "Properties", switch to the "Local Files" tab and click the "Browse Local Files" button.
You WILL want to make backup copies of any file you intend to change "just in case" you need to revert back to it (or sometimes it just helpful to be able to go back and reference what the original value of something was before you changed it)
Here are the files you can edit and what (presumably) they do:
SOL.jxdat - this is an XML file. You can open it with Notepad ++.
This file seems to work in conjunction with SOL.jxdatgal which contains the art assets for maps (?). The file contains a variety of interesting entries that appear to adjust how the graphics are displayed. A LOT of experimentation would be needed here, but some of the possible changes include Random color percentage, Hue variation, Random Size percentage, Random rotation, Random flipping and so on.
SOL.jxdatgal - this is an archive. You can open it with 7zip.
This archive contains all of the graphics used on the maps. This include not only rocks, trees, plants and the like, but also creatures, furniture and even the terrains themselves (grass, rocks, bricks, snow, water, etc) that form the background of the maps.
These files are all .PNG files without the .png extension and they do not have typical file names. Instead they are named numbers like -1158406, 4481943, 27061541, etc.
If you extract these files to a folder (create one on yoru desktop or elsewhere) and then rename them to add .png to the ends of each file you can double click them to look at them (or in Windows just set the folder view to large or extra large icons)
In limited testing I found you can take a png file and rename it to one of these numbers and then remove the .png from the file name. Use 7zip to add the file to the SOL.jxdatgal file (back it up first!) overwriting the existing file. Fire up the game and observe your change Testing must be done to see if there is a min or max size on these and if you can chnage several without causing the game to crash or act in some odd or expected manner though I would suspect that graphics swapping is mostly straight forward in this game as long as you keep the actual .png files more or less the same height and width as what you are replacing. Note = Messing with these may require you to have Photoshop, Gimp or some other graphics program suitable for working with .png files.
SOL.jxrul - this is an encoded file and cannot be edited by the tools I suggested.
This file is the same file created when you use the official LOX editor program and contains the "rules" for the game. I would encourage everyone to just leave this file alone and use the official editor to make changes (note there have been posts on these forums about bugs and crashes when changing some things with the official editor so be aware that you may not be able to always do exactly what you had hoped for). Additional "rules" and game functions are most likely handled by the .exe file and any .dlls (i.e. SOL.dll) Sorry I can't offer any advice here.
SOL.jxworldmap - this is an archive (7zip) which contains a large .xml file (Notepad++)
This file contains all of the maps used in the game (Nabros, Velegarn, etc) however it looks like they are embedded into the .xml file in some manner and I'm unsure how (if at all) you could edit them. Best to leave this file as it is.
SOL.dxgal - this is an archive. You can open it with 7zip.
Much like SOL.jxdatgal this is an archive containing graphics used in the game. These graphics however are the ones used in all the menus, splash/loading screens, character screens, inventory items, weapons, portraits, battle monsters, and so on.
Just like SOL.jxdatgal you can extract all of these files to a seperate folder and rename them all adding .png to them to see them. In limited testing I replaced the character portraits and it seemed to work fine. Again much more extensive testing would need to be done and I would encourage replacing files only with files which are sized to the same height and width to avoid potential problems although it looks to me that the game automatically scales some of these down in different places (for example inventory items appear much smaller in the game)
SOL_SOUNDS.dxpackage - this is an archive (7zip) containing sound files.
Basically when you open this archive it includes a master folder called SOL_Sounds with subfolders like Music, Voice, Ambient, Monsters etc. each containing various .OGG and .MP3 files I didn't test replacing these files, but it looks fairly straightforward - simply use the same format (OGG or MP3) and same file name to replace a sound file. I'm not really a "sound guy", but in the past I have found many games sound systems are tempermental when a file SIZE (in KB/MB) is too large or too small and also in file length (how long the song / sound plays) if it's too short or too long. That may or may not be an issue, but be aware just like changing images to be the right size you may need to tweak sounds to also be the around the same size and/ or length. Like everything else you just have to test it and see what happens (isn't modding "fun" )
SOLCredits.jxcredits - this is an archive (7zip) containing an XML file (Notepad++) which holds all of the names displayed in the credits. I would not modify this file as there is no need and it would be disrespectful. I only included it here for the sake of completeness.
I'm going to quickly go over the English versions of the files here - designated by _EN in the file names, but be aware that there are also German (DE), French (FR), Spanish? (ES) and others should you want to modify files in another language.
PS - my appologies, but not sure if CN is Chinese, Cantonese or something else and also if PL is Polish. I didn't see Russian which is surprising, but maybe I'm wrong about one of the above extensions.
SOL_EN.jxdlg - this is an archive file (7zip) which contains an XML file named (shockingly) SOL_EN.jxdlg which can be opened with Notepad++
This file contains all of the dialog in the game, but what I found most fascinating about it is a series of "COMMANDS" that the game can issue during dialog including things like:
Simple name="Command" value="EXP [400]" (looks like it gives 400 XP)
Simple name="Command" value="ADD_HP" (refills party HP)
Simple name="Command" value="ADD_PP" (refills party PP)
Simple name="Command" value="GIVE_FOOD [ 3 ]"
and so on
Remember the guy you can harvest 20 crops for 50 gold in the first town? His dialog includes these:
Simple name="Command" value="GIVE_GOLD[ 50 ]"
Simple name="Command" value="REMOVE[Cereal,20]"
There's some fairly complex campaign stuff too like:
Simple name="Command" value="MISSION_ACTIVATED [ KillSpiders ]"
Simple name="Command" value="ACTIVATE_ENTRY[Princes, RoadToNabrosCastle]"
Simple name="Command" value="ACTIVATE_CHAPTER [ Chapter_Titan ]"
etc.
Possibly some interesting modifications to existing missions and dialog could be made in this file...
SOL_EN.jxint - this is an archive file (7zip) which contains an XML file named (you guessed it) SOL_EN.jxint which can be opened with Notepad++
This XML file contains various strings used in game menus. Things such as:
"Heavy armors or shields may penalize the character's speed and initiative in combat. A character's maximum weight capacity can be increased by Strength and the Armor skill."
"To open the character sheet, double click on his portrait or press the round button below the portrait or use the key 'C'."
"Required XP to level up"
and so on.
If you wanted to change the name of Power Points, Skill Points or some in game message about leveling up or combat then this is probably the file you want to try and edit.
SOL_EN.jxjou - just like the other two files this is an archive (7zip) containing an XML file (Notepad++) of the same name.
This XML file contains all of the Journal entries, but it also includes any pop up text you would find on the map while playing - for example when you click on a sign at a crossroads and it pops up what the sign says.
Additionally various rumors like those you can get from the Tavern are contained here.
I hope you found this post interesting and/or helpful. My best wishes to you if you decide to try modding the game. If you found anything useful here and use it to create a mod please consider giving me a small credit as JRavens (yeah I know my Steam name is jvarnes - they won't let me change it sigh) with a link to my forums (http://farcrymods.freeforums.net/)
Thanks very much guys, best of luck and I'm out! <mic drop>
INTRODUCTION
Hi guys. I'm a modder and have made mods for a variety of games (from tiny little joke mods all the way to sweeping whole game conversions). I'm probably best know for my Far Cry 4 mods though I've created stuff for several other AAA games as well. If you are interested in checking out my mods or just want a cool place to discuss games check out my forums here: farcrymods.freeforums.net/
OK on with the show -
I was going to mod Lords of Xulima after I picked it up during the Steam Winter sale, but the truth is I really don't have the time. My free time is extremely restricted now and my choice of upcoming mods that I can work on will be limited. However rather than let my (limited) knowledge go to waste I decided to share it here in case someone wants to pick up the torch.
NOTE: this is a VERY LONG article so grab a nice cup of coffee/tea/soda and sit back. Maybe print it off or take it in small chunks. Sorry for the WALL OF TEXT, but it's a lot of info to convey and I want to do it in one fell swoop.
DISCLAIMER
This is all info I gleaned from examining the files and VERY BASIC experimentation over my holiday vacation. If you apply any of these techniques you WILL need to test, test, test and like any game some things will either (A) NOT WORK as intended or (B) flat out crash the game. This is true of modding ANY game. Essentially you are forcing the game to do things it wasn't designed to do (even if it seems simple or innocent like replacing an image, changing a text label or swapping around sound files)
Having said that also be aware the Devs may NOT want us mucking around in their files and at the very least may turn a blind eye to it. They certainly cannot support any modding outside of the official editor so DON'T ask them about bugs related to modifying anything found here.
They might however alter the files in a future patch to prevent modifying them in the way I describe here. I honestly have no idea how they will feel about it. Hopefully they understand that modding is something we do out of love for a game and it helps a game's longevity and popularity as mods are often featured in YouTube videos and gaming site articles.
TOOLS
Before we start you should grab three important tools useful to any modder (these are not the ONLY tools, but I do highly recommend them. You can use whatever programs you feel comfortable with):
1) 7zip (http://www.7-zip.org/) - this is an archive program that works with .zip files as well as MANY other types of archiving and compression. It's most useful feature is you can attempt to open ANY file even if it has a weird file extension. Many game designers (like this one) use .zip or other compression and simply rename the extension. Having this will let you open Xulima's unusual archives.
2) Notepad++ (https://notepad-plus-plus.org/) is a powerful text editor. One thing I really like about it (besides being easy to use) is that it doesn't make changes "on it's own" like some other editors do. So it won't add arbitrary line spaces, carriage returns, etc. Nor will it change the text encoding when you save files that you were working on. So essentially 99.9% of the time anything you change will be exactly the same KIND of file that it originally was and so any errors the game throws are going to be some mistake you made when typing or something the game doesn't support like a line that is too long, a number that is too large or small, etc. and NOT something Windows Notepad or Wordpad has done when it saved the file. It also has a lot of cool features like multiple tabs, plugins, etc. that you can learn about in the future. For now though it's a fantastic and useful alternative to anything that came with your operating system.
and
3) Bulk Rename Utility (http://www.bulkrenameutility.co.uk/) - this program is a power tool which will let you rename hundreds (or even thousands) of files at once. It's useful here because the graphics files in LOX are png files, but they have no file extension. So using this will let you temporarily examine all of them at once.
FILES
Once you have those tools we can discuss what files are in the Lords of Xulima folder and how you might edit them.
Go to where the game is installed (the easiest way is in Steam to right click on a game and choose "Properties", switch to the "Local Files" tab and click the "Browse Local Files" button.
You WILL want to make backup copies of any file you intend to change "just in case" you need to revert back to it (or sometimes it just helpful to be able to go back and reference what the original value of something was before you changed it)
Here are the files you can edit and what (presumably) they do:
SOL.jxdat - this is an XML file. You can open it with Notepad ++.
This file seems to work in conjunction with SOL.jxdatgal which contains the art assets for maps (?). The file contains a variety of interesting entries that appear to adjust how the graphics are displayed. A LOT of experimentation would be needed here, but some of the possible changes include Random color percentage, Hue variation, Random Size percentage, Random rotation, Random flipping and so on.
SOL.jxdatgal - this is an archive. You can open it with 7zip.
This archive contains all of the graphics used on the maps. This include not only rocks, trees, plants and the like, but also creatures, furniture and even the terrains themselves (grass, rocks, bricks, snow, water, etc) that form the background of the maps.
These files are all .PNG files without the .png extension and they do not have typical file names. Instead they are named numbers like -1158406, 4481943, 27061541, etc.
If you extract these files to a folder (create one on yoru desktop or elsewhere) and then rename them to add .png to the ends of each file you can double click them to look at them (or in Windows just set the folder view to large or extra large icons)
In limited testing I found you can take a png file and rename it to one of these numbers and then remove the .png from the file name. Use 7zip to add the file to the SOL.jxdatgal file (back it up first!) overwriting the existing file. Fire up the game and observe your change Testing must be done to see if there is a min or max size on these and if you can chnage several without causing the game to crash or act in some odd or expected manner though I would suspect that graphics swapping is mostly straight forward in this game as long as you keep the actual .png files more or less the same height and width as what you are replacing. Note = Messing with these may require you to have Photoshop, Gimp or some other graphics program suitable for working with .png files.
SOL.jxrul - this is an encoded file and cannot be edited by the tools I suggested.
This file is the same file created when you use the official LOX editor program and contains the "rules" for the game. I would encourage everyone to just leave this file alone and use the official editor to make changes (note there have been posts on these forums about bugs and crashes when changing some things with the official editor so be aware that you may not be able to always do exactly what you had hoped for). Additional "rules" and game functions are most likely handled by the .exe file and any .dlls (i.e. SOL.dll) Sorry I can't offer any advice here.
SOL.jxworldmap - this is an archive (7zip) which contains a large .xml file (Notepad++)
This file contains all of the maps used in the game (Nabros, Velegarn, etc) however it looks like they are embedded into the .xml file in some manner and I'm unsure how (if at all) you could edit them. Best to leave this file as it is.
SOL.dxgal - this is an archive. You can open it with 7zip.
Much like SOL.jxdatgal this is an archive containing graphics used in the game. These graphics however are the ones used in all the menus, splash/loading screens, character screens, inventory items, weapons, portraits, battle monsters, and so on.
Just like SOL.jxdatgal you can extract all of these files to a seperate folder and rename them all adding .png to them to see them. In limited testing I replaced the character portraits and it seemed to work fine. Again much more extensive testing would need to be done and I would encourage replacing files only with files which are sized to the same height and width to avoid potential problems although it looks to me that the game automatically scales some of these down in different places (for example inventory items appear much smaller in the game)
SOL_SOUNDS.dxpackage - this is an archive (7zip) containing sound files.
Basically when you open this archive it includes a master folder called SOL_Sounds with subfolders like Music, Voice, Ambient, Monsters etc. each containing various .OGG and .MP3 files I didn't test replacing these files, but it looks fairly straightforward - simply use the same format (OGG or MP3) and same file name to replace a sound file. I'm not really a "sound guy", but in the past I have found many games sound systems are tempermental when a file SIZE (in KB/MB) is too large or too small and also in file length (how long the song / sound plays) if it's too short or too long. That may or may not be an issue, but be aware just like changing images to be the right size you may need to tweak sounds to also be the around the same size and/ or length. Like everything else you just have to test it and see what happens (isn't modding "fun" )
SOLCredits.jxcredits - this is an archive (7zip) containing an XML file (Notepad++) which holds all of the names displayed in the credits. I would not modify this file as there is no need and it would be disrespectful. I only included it here for the sake of completeness.
LOCALIZED FILES
I'm going to quickly go over the English versions of the files here - designated by _EN in the file names, but be aware that there are also German (DE), French (FR), Spanish? (ES) and others should you want to modify files in another language.
PS - my appologies, but not sure if CN is Chinese, Cantonese or something else and also if PL is Polish. I didn't see Russian which is surprising, but maybe I'm wrong about one of the above extensions.
SOL_EN.jxdlg - this is an archive file (7zip) which contains an XML file named (shockingly) SOL_EN.jxdlg which can be opened with Notepad++
This file contains all of the dialog in the game, but what I found most fascinating about it is a series of "COMMANDS" that the game can issue during dialog including things like:
Simple name="Command" value="EXP [400]" (looks like it gives 400 XP)
Simple name="Command" value="ADD_HP" (refills party HP)
Simple name="Command" value="ADD_PP" (refills party PP)
Simple name="Command" value="GIVE_FOOD [ 3 ]"
and so on
Remember the guy you can harvest 20 crops for 50 gold in the first town? His dialog includes these:
Simple name="Command" value="GIVE_GOLD[ 50 ]"
Simple name="Command" value="REMOVE[Cereal,20]"
There's some fairly complex campaign stuff too like:
Simple name="Command" value="MISSION_ACTIVATED [ KillSpiders ]"
Simple name="Command" value="ACTIVATE_ENTRY[Princes, RoadToNabrosCastle]"
Simple name="Command" value="ACTIVATE_CHAPTER [ Chapter_Titan ]"
etc.
Possibly some interesting modifications to existing missions and dialog could be made in this file...
SOL_EN.jxint - this is an archive file (7zip) which contains an XML file named (you guessed it) SOL_EN.jxint which can be opened with Notepad++
This XML file contains various strings used in game menus. Things such as:
"Heavy armors or shields may penalize the character's speed and initiative in combat. A character's maximum weight capacity can be increased by Strength and the Armor skill."
"To open the character sheet, double click on his portrait or press the round button below the portrait or use the key 'C'."
"Required XP to level up"
and so on.
If you wanted to change the name of Power Points, Skill Points or some in game message about leveling up or combat then this is probably the file you want to try and edit.
SOL_EN.jxjou - just like the other two files this is an archive (7zip) containing an XML file (Notepad++) of the same name.
This XML file contains all of the Journal entries, but it also includes any pop up text you would find on the map while playing - for example when you click on a sign at a crossroads and it pops up what the sign says.
Additionally various rumors like those you can get from the Tavern are contained here.
CLOSING
I hope you found this post interesting and/or helpful. My best wishes to you if you decide to try modding the game. If you found anything useful here and use it to create a mod please consider giving me a small credit as JRavens (yeah I know my Steam name is jvarnes - they won't let me change it sigh) with a link to my forums (http://farcrymods.freeforums.net/)
Thanks very much guys, best of luck and I'm out! <mic drop>