TheEnlightenedFlorist:
There is a much better way of making campaigns. This method is far more powerful and flexible (and it won't get overwritten with every update). Here's a quick overview.
I. Be sure to have Visual Studio installed.
II. Download this example campaign that naryv* posted. As far as I know, this is exactly the code that is used for the stock campaigns.
III. In the example campaign, open the Visual Studio solution at parts/tst/src/Campaign/TstCapaign.sln.
Under "Solution Explorer" on the right, expand both "References" folders.
Some of these will probably have errors. Right click on the "References" folder.
Navigate to Steam/steamapps/common/il-2 sturmovik cliffs of dover/parts/core and add the references that are showing errors.
IV. Now, we will modify the code to work with our campaign.
First, change the namespace at the top of both TstCampaign.cs and TstMission.cs to something like yourname.campaign.
Next, go to lines 178 and 179 in TstCampaign.cs.
Change USER_PATH and PATH to more appropriate values. USER_PATH is where the campaigns state files will be saved.
Make this something like "$user/mission/yourname/campaign/".
PATH is where your campaigns.ini file will be placed.
Make it something like "$home/parts/yourname/campaign/".
V. Save all of the files you've modified and press F6. This will compile the code. Hopefully, you don't get errors.
The compiled .dlls can be found in TstCampaign/parts/tst/src/Campaign/TstCampaign/bin/debug and TstCampaign/parts/tst/src/Campaign/TstCampaign/bin/debug.
You will need to modify the script files for your missions to user your new .dlls. This is very simple. There is an example of this in naryv's campaign.
VI. Open the xml file in TstCampaign/AddIns using Visual Studio.
Change name="TstCampaign" to the name of your campaign.
Change type="tst.campaign.Campaigns" to match your campaign.
Using our previous example, we would make it type="yourname.campaign.Campaigns".
Change path="$home/parts/tst/TstCampaign.dll" to the location where your newly compiled .dlls will be stored.
Something like path="$home/parts/yourname/yourCampaign.dll".
Be sure that the name of your .dll matches the name in your xml file.
Change text="Tst Campaign" to the name you want your campaign to appear under in the main menu.
VII. After saving the xml file, we now have everything we need.
To install your campaign, all you have to do is copy your xml file into Steam/steamapps/common/il-2 sturmovik cliffs of dover/AddIns.
Then, put the two .dll files you compiled into the appropriate directory in "parts".
In our example, we would put them into parts/yourname.
Now, take the campaigns.ini file and folder containing the missions and put them into the folder you specified in the TstCampaign code.
In our example, this was parts/yourname/campaign/.
After putting everything together, you should be able to start Cliffs of Dover and see your campaigns in the menu.
Bookmarks