Page 1 of 1

Modding Sandbox Campaign

Posted: Sun Jun 02, 2019 9:06 pm
by Gnaeus
Is there any easy way to mod the sandbox campaign to limit the number of enemies that will appear, e.g., to have a Roman campaign in Gaul or Belisarius vs. the Ostrogoths, without being moved randomly to other parts of the world to fight other enemies?

Re: Modding Sandbox Campaign

Posted: Mon Jun 03, 2019 7:09 am
by rbodleyscott
No easy way, no.

Re: Modding Sandbox Campaign

Posted: Mon Jun 03, 2019 4:03 pm
by Gnaeus
Thanks for the quick response.

Take this as a humble request from a devoted supplicant.

Re: Modding Sandbox Campaign

Posted: Wed Jun 05, 2019 4:15 pm
by Gnaeus
If it doesn't rank high on your todo list, I'm not completely computer illiterate and might give it a try if I knew where to look.

I suppose I could do a save just before winning a battle, so I can reload the campaign and roll the dice again on the continuation to get an opponent I want, but that's a bit of a hassle.

Maybe it's just me, but aside from specific historical situations like the 3rd Century crisis or Belisarius, I'd rather focus on a particular campaign instead of bouncing around the empire from battle to battle. Even with Belisarius, I'd like to be able to focus on Italy or Persia.

Re: Modding Sandbox Campaign

Posted: Wed Jun 05, 2019 5:01 pm
by Paul59
Gnaeus wrote: Wed Jun 05, 2019 4:15 pm If it doesn't rank high on your todo list, I'm not completely computer illiterate and might give it a try if I knew where to look.

I suppose I could do a save just before winning a battle, so I can reload the campaign and roll the dice again on the continuation to get an opponent I want, but that's a bit of a hassle.

Maybe it's just me, but aside from specific historical situations like the 3rd Century crisis or Belisarius, I'd rather focus on a particular campaign instead of bouncing around the empire from battle to battle. Even with Belisarius, I'd like to be able to focus on Italy or Persia.
This would be a good place to start learning how to understand and modify the scripts:

http://www.slitherine.com/forum/viewtop ... 92&t=80109

Re: Modding Sandbox Campaign

Posted: Wed Jun 05, 2019 5:27 pm
by Paul59
On second thoughts, it might be easier to create a mod folder with a modded ArmyList.txt.

The ArmyList.txt contains information on the unit availability for every army list in the game. It also contains other information on when and where that army can operate. The geographical limits are imposed by army's latitude and longitude values. This determines what potential allies it may face, or might give help in a random campaign. These values are easily altered in a text editor.

Currently these values are set to encompass the historical range of a factions operations. For small nations this is usually not much bigger than it's historical home territory. Your problem is caused by large empires such as the Roman and Byzantine, whose historical range of operations is vast. What you would need to do is delete the current army lists for these large empires, and replace with new regional Imperial armies, with much more restricted latitude and longitude values.

This could turn out to be a very long winded job, with a lot of trial and error, but probably easier than trying to rewrite the campaign scripts. You could just treat it as a work in progress though, and only modify the armies that you need to, to fight one particular campaign at a time.

Whatever you do DON"T modify the main game installation folder! Create a mod folder and put all the modded files in there.

My Campaign and Scenario creation guides in the Scenario Design forum maybe of assistance:

http://www.slitherine.com/forum/viewforum.php?f=491

Re: Modding Sandbox Campaign

Posted: Wed Jun 05, 2019 9:19 pm
by Gnaeus
Thanks very much. I'll give it a try.

And thanks for all the work that you and RBS have put into this. As a once budding classicist with an interest in military history who had to give it up for something more practical, this game is a dream come true.

Re: Modding Sandbox Campaign

Posted: Wed Jun 05, 2019 9:24 pm
by rbodleyscott
Gnaeus wrote: Wed Jun 05, 2019 4:15 pm If it doesn't rank high on your todo list, I'm not completely computer illiterate and might give it a try if I knew where to look.

I suppose I could do a save just before winning a battle, so I can reload the campaign and roll the dice again on the continuation to get an opponent I want, but that's a bit of a hassle.
It wouldn't work anyway, as the identity of other opponents is decided at the start of the campaign, not randomly decided after each battle.

Re: Modding Sandbox Campaign

Posted: Wed Jun 05, 2019 11:43 pm
by Gnaeus
Thanks. I'm working on changing the lat long of the army list in a copy of the Belisarius Campaign to see what happens.

Re: Modding Sandbox Campaign

Posted: Thu Jun 06, 2019 7:23 am
by rbodleyscott
Gnaeus wrote: Wed Jun 05, 2019 11:43 pm Thanks. I'm working on changing the lat long of the army list in a copy of the Belisarius Campaign to see what happens.
It won't have any effect because the opponents in the Belisarius Campaign are scripted.

It would only have an effect on the sandbox campaign, where the extra opponents are chosen randomly from those nations in close proximity to the lat/long limits of your army list.

Fortunately, you can turn your clone of the Belisarius Campaign into a sandbox campaign simply by deleting the CustomCampaign.txt file from it. (So that it becomes unscripted).

You should also edit Text1.txt (or the equivalent for whichever language you are using) so that the only lines in it are:

IDS_CAMPAIGN_NAME, "My Modded Sandbox Campaigns",
IDS_CAMPAIGN_TEXT,"Whatever",

otherwise some of the campaign choices, which had modded versions tailored to the Belisarius campaign, may read a bit oddly.

Re: Modding Sandbox Campaign

Posted: Thu Jun 06, 2019 10:30 am
by Paul59
Gnaeus wrote: Wed Jun 05, 2019 11:43 pm Thanks. I'm working on changing the lat long of the army list in a copy of the Belisarius Campaign to see what happens.
I'm getting rather confused about what you are trying to do.

The title of this thread suggested that you wanted to modify how the Sandbox campaigns work. But now it seems like you want to modify an historical campaign?

If it is the historical campaigns that you want to change, then the best way is just to create your own new ones to have exactly the opponents, number and type of battles that you want.

The Campaign Creation Guide part 1 tells you how to do that:

http://www.slitherine.com/forum/viewtop ... 91&t=80666



cheers

Re: Modding Sandbox Campaign

Posted: Thu Jun 06, 2019 4:04 pm
by Gnaeus
My fault. I am trying to mod the sandbox campaign but discovered starting with a DLC just got me a copy of a historical campaign. I'll try again today or tomorrow. I appreciate all your help. If nothing else, I'm developing even more respect for the modders.

Re: Modding Sandbox Campaign

Posted: Thu Jun 06, 2019 5:04 pm
by Paul59
Gnaeus wrote: Thu Jun 06, 2019 4:04 pm My fault. I am trying to mod the sandbox campaign but discovered starting with a DLC just got me a copy of a historical campaign. I'll try again today or tomorrow. I appreciate all your help. If nothing else, I'm developing even more respect for the modders.
No problem Gnaeus.

Re: Modding Sandbox Campaign

Posted: Tue Jun 11, 2019 3:43 am
by Gnaeus
I haven't tested this extensively, but I've done a couple of short, modded Byzantine-Ostrogoth sandbox campaigns in Italy and all I've seen so far are Ostrogoths and Visigoths. Thanks for your help.

Re: Modding Sandbox Campaign

Posted: Tue Jun 11, 2019 7:16 am
by rbodleyscott
Gnaeus wrote: Tue Jun 11, 2019 3:43 am I haven't tested this extensively, but I've done a couple of short, modded Byzantine-Ostrogoth sandbox campaigns in Italy and all I've seen so far are Ostrogoths and Visigoths. Thanks for your help.
Glad to hear it.