BGForums

BattleGoat Studios | Supreme Wiki | Facebook | Twitter @SRColdWar | Twitter @SR1936 | YouTube
It is currently Oct 30 2014

All times are UTC - 5 hours




Post new topic Reply to topic  [ 11 posts ] 
Author Message
 Post subject: Modding saved games
PostPosted: Jul 08 2009 
Offline
General

Joined: Jun 03 2009
Posts: 1113
OK, I've read all of the Wiki and forum info on modding. I think that I have an understanding of the process.

My understanding is that the goal of modding is to produce a customized .SAV file (a cache file) that you can start in the Lobby. If this is true then it is not possible to mod an existing cache file - that is to mod a game in progress. The only "modding" that can be done to a game in progress is to edit the .INI files that are re-read when the saved game is restarted.

Is this correct? I'm amazed that the question "Can you mod a .SAV game?" has not been asked or answered plainly anywhere that I have read. I would think that it would be a FAQ.

Or maybe it is too dumb a question to ask...

_________________
"War is merely the continuation of politics [diplomacy] by other means"
General Carl von Clausewitz - 1832

"Defense: De ting dat keeps de cows off de road."
Catatonic - 2012


Top
 Profile  
 
 Post subject: Re: Modding saved games
PostPosted: Jul 08 2009 
Offline
Supreme Ruler

Joined: Jun 04 2002
Posts: 18945
Location: BattleGoat Studios
I think this has previously been asked as "can a savegame be used as a cache for modding?"

and the answer is yes, absolutely.

_________________
Chris Latour
BattleGoat Studios
chris@battlegoat.com


Top
 Profile  
 
 Post subject: Re: Modding saved games
PostPosted: Jul 08 2009 
Offline
General

Joined: Jun 03 2009
Posts: 1113
Quote:
I think this has previously been asked as "can a savegame be used as a cache for modding?"


First of all, I am ecstatic that this can be done. I have wanted to do it about two times per day for the last month, but I never believed that it was possible.

I searched the forum for "+savegame +cache +modding" and did not come up with the "how to" answer that you mentioned. If you or someone could please point me to this I would appreciate it.

But again, this goes counter to my understanding of how modding works. Everything that I have read is couched in terms of creating a new cache file, not about how to modify an existing one. And it always involves deleting the existing "cache" file. My saved game (a cache as you call it) contains many years of my game play information. But it is already "compiled" with the original DEFAULT.UNITS file, etc.

For instance, if I want to mod my .SAV file so that the next time that I restart the game a certain unit's display name is changed. Suppose that I want the "Airborne ECB Engineer" unit to display in the units list as "nnn INF ECB Engineer" instead of "nnn INF Engineer". I would need to edit the existing DEFAULT.UNITS file or supply a new customized MY.UNITS file to the .SCENERIO file.

So how would this work? Would the game program load my current .SAV game file but somehow detect that its scenerio's .UNITS file has changed and then parse and merge in my new customized units text info before starting the game? Would it take a long time re-compiling and produce a new "CACHED - new.sav" file in the /Savegame folder, or would it just grab my new customized UNITS info and immediately restart the game?

_________________
"War is merely the continuation of politics [diplomacy] by other means"
General Carl von Clausewitz - 1832

"Defense: De ting dat keeps de cows off de road."
Catatonic - 2012


Top
 Profile  
 
 Post subject: Re: Modding saved games
PostPosted: Jul 08 2009 
Offline
Supreme Ruler

Joined: Jun 04 2002
Posts: 18945
Location: BattleGoat Studios
You're misunderstanding what I said...

I did not say you could modify a savegame to use it as a cache file. I said you could use the savegame as the cache file.

Now, if you read through the details of the .scenario file, it does talk about what data files are applied pre-creation (such as equipment) and what files are applied post creation (such as the relations overrides). Anything post, you can use a .scenario that specifies your savegame filename as the cache and just dump your save into the cache folder. That won't however get you things like equipment file changes.

There is rumor that some "pre" files can be re-specified in the "post" section to make alterations, but much of this is untested (read unsupported).

look at the files for Saudi Invasion or African Dragon to get some clues on how this is done. Start in the .scenario.

_________________
Chris Latour
BattleGoat Studios
chris@battlegoat.com


Top
 Profile  
 
 Post subject: Re: Modding saved games
PostPosted: Jul 08 2009 
Offline
General
User avatar

Joined: Aug 22 2008
Posts: 3401
Location: Nearby, really I'll see you tonight when your sleeping
I am not sure if this would work or not, and if it does work it would mean a long load time. But here is how I think it could be done. I am going to use the Global Crisis Scenario as an example.

Open up the Global Crisis.scenario in the CampainGC folder. In there you will see:

...........
Code:
#ifset 0x01
#include "GlobalCrisis.CVP", "MAPS\"
#include "GlobalCrisis.REGIONINCL", "MAPS\"
#endifset

#ifset 0x02
#include "DEFAULT.UNIT", "MAPS\DATA\"
#include "DEFAULT.PPLX", "MAPS\DATA\"
#include "DEFAULT.TTRX", "MAPS\DATA\"
#include "DEFAULT.TERX", "MAPS\DATA\"
#include "DEFAULT.WMDATA", "MAPS\DATA\"
#include "DEFAULT.NEWSITEMS", "MAPS\DATA\"
#include "AllSourceLoad.INI", "INI\"
#endifset

#ifset 0x02
&&MAP
mapfile "GlobalCrisis"
&&END

#include "GlobalCrisis.OOF", "MAPS\"
#include "GlobalCrisis.OOB", "MAPS\ORBATS\"
#include "AllLoad.INI", "INI\"
#include "Global Crisis.csv"
#endifset

#ifset 0x04
&&SAV
savfile "Global Crisis"
&&END

#endifset

#include "LocalText-RegionsGC.csv", "SCENARIO\", Y
#include "Global Crisis-Text.csv", "SCENARIO\", Y

...........

Change it to:
........
Code:
#ifset 0x01
#include "GlobalCrisis.CVP", "MAPS\"
#include "GlobalCrisis.REGIONINCL", "MAPS\"
#endifset

#ifset 0x02
#include "DEFAULT.PPLX", "MAPS\DATA\"
#include "DEFAULT.TTRX", "MAPS\DATA\"
#include "DEFAULT.TERX", "MAPS\DATA\"
#include "DEFAULT.WMDATA", "MAPS\DATA\"
#include "DEFAULT.NEWSITEMS", "MAPS\DATA\"
#include "AllSourceLoad.INI", "INI\"
#endifset

#ifset 0x02
&&MAP
mapfile "GlobalCrisis"
&&END

#include "GlobalCrisis.OOF", "MAPS\"
#include "GlobalCrisis.OOB", "MAPS\ORBATS\"
#include "AllLoad.INI", "INI\"
#include "Global Crisis.csv"
#endifset

#ifset 0x04
&&SAV
savfile "Global Crisis"
&&END

#endifset

#include "DEFAULT.UNIT", "MAPS\DATA\"
#include "LocalText-RegionsGC.csv", "SCENARIO\", Y
#include "Global Crisis-Text.csv", "SCENARIO\", Y

...........

This should cause the game to load the .units file everytime the game starts. It might need to go under the global crisis.CVS instead of above the localtext.

_________________
Brutal Beating
Image


Top
 Profile  
 
 Post subject: Re: Modding saved games
PostPosted: Jul 08 2009 
Offline
Supreme Ruler

Joined: Jun 04 2002
Posts: 18945
Location: BattleGoat Studios
if it worked, first time it loads, you could save that as the .sav you turn into a cache and remove the post cache overrides (to avoid applying them twice).

_________________
Chris Latour
BattleGoat Studios
chris@battlegoat.com


Top
 Profile  
 
 Post subject: Re: Modding saved games
PostPosted: Jul 09 2009 
Offline
General

Joined: Jun 03 2009
Posts: 1113
Hey - it works!

And it didn't take long to load at all.

Thanks guys.

LLAP

_________________
"War is merely the continuation of politics [diplomacy] by other means"
General Carl von Clausewitz - 1832

"Defense: De ting dat keeps de cows off de road."
Catatonic - 2012


Top
 Profile  
 
 Post subject: Re: Modding saved games
PostPosted: Jul 09 2009 
Offline
Supreme Ruler

Joined: Jun 04 2002
Posts: 18945
Location: BattleGoat Studios
feel free to update the wiki and share the mod!

hint, hint...

_________________
Chris Latour
BattleGoat Studios
chris@battlegoat.com


Top
 Profile  
 
 Post subject: Re: Modding saved games
PostPosted: Jul 12 2009 
Offline
General

Joined: Jun 03 2009
Posts: 1113
So, when you modify a unit and then over-ride it's original specs with a customized .UNIT file, then the game forces you to re-research the unit.

You sly Goats you...

P.S.

I know about the "No Research" setting in the .UNIT file.
Looks like if I publish a mod, it may have to be in "new game" and "saved game" versions.

_________________
"War is merely the continuation of politics [diplomacy] by other means"
General Carl von Clausewitz - 1832

"Defense: De ting dat keeps de cows off de road."
Catatonic - 2012


Top
 Profile  
 
 Post subject: Re: Modding saved games
PostPosted: Aug 06 2009 
Offline
Captain

Joined: Sep 22 2007
Posts: 101
Hi Guys

Can the moding of saved games be used to mod relations between countries? I am at a state of war with virtually every nation and would like to change it so that I am at peace with them?

If so please can someone provide me with a step by step process of how to do it? Sorry but I am a complete newbie when it comes to things like this!


Top
 Profile  
 
 Post subject: Re: Modding saved games
PostPosted: Aug 06 2009 
Offline
General

Joined: Jun 03 2009
Posts: 1113
Red Dawn wrote:
Hi Guys

Can the moding of saved games be used to mod relations between countries? I am at a state of war with virtually every nation and would like to change it so that I am at peace with them?

If so please can someone provide me with a step by step process of how to do it? Sorry but I am a complete newbie when it comes to things like this!


This thread will tell you how to worsen or improve relations:

viewtopic.php?f=47&t=15322&p=92504#p92504

_________________
"War is merely the continuation of politics [diplomacy] by other means"
General Carl von Clausewitz - 1832

"Defense: De ting dat keeps de cows off de road."
Catatonic - 2012


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 11 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: Bing [Bot] and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group