Tutorial: How to create a campaign

A forum to discuss custom scenarios, campaigns and modding in general.

Moderators: Slitherine Core, Panzer Corps Moderators, Panzer Corps Design

Post Reply
nikivdd
Panzer Corps Map Designer
Panzer Corps Map Designer
Posts: 4525
Joined: Fri Jun 24, 2011 1:21 pm
Location: Belgium
Contact:

Tutorial: How to create a campaign

Post by nikivdd »

How to make a campaign very basically.

1) Prepare your mod with the necessary folders
- Make a folder with the name of your project. For ex. Myproject
- Your mod folder must contain the subfolder Data -> Myproject\Data
- Your data folder should contain the subfolder Briefings -> Myproject\Data\Briefings

2) Create\Inject the necessary files into the folders
- Create a GUID (http://www.guidgenerator.com/), then create a GUID.txt file in Myproject folder. The GUID.txt contains one line, for ex. {b534186f-3d16-4da7-a6fd-52dcead2e842}
- Create or Copy an existing campaign.pzdat file into Myproject\Data folder. Here you can also add other files if you would deem it necessary to tweak as for ex. equipment.pzdat, gamerules.pzdat, diff.pzdat, nations.pzdat... I do advise not to temper with any of those additional files before you have familiarised yourself with the game mechanics (= alot of playing), before changing parameters in additional files. The equipment.pzdat is very important to add new entries for units - but for that there is another manual available -.

A campaign.pzdat file can look (there are different kinds) like this...this one is based on the DLC campaign.pzdat structure. As an example i have taken a part of the MPC '37-'39 campaign structure

# This file contains Panzer Corps campaign structure

FormatVersion 1

# Entry points
# Name Label in campaign path Description Side Nation Starting prestige Display name
Rhineland 1 "MPC: From the Rhineland to Valhalla" 0 0 1000 More Panzer Corps content '37-'39 Grand Campaign


Name: name of the label that adresses the first scenario of your campaign. In this example Rhineland.
Label in campaign path: on which place is the Name? In this case on place 1.
Description: description of your scenario
Side: axis or allies? (0 or 1)
Nation: 0 (=Germany) . You can add multiple nations separated by a comma. For example 0,5 would be Germany and Italy...last info i have is that up to 5 nations can be added
Starting prestige: amount of prestige the player starts with at the beginning of the campaign
Display name: think that explains itself


# Campaign path
# Decisive Victory Marginal Victory Loss
# Label Briefing Scenario Next label Prestige Briefing Next label Prestige Briefing Next label Prestige Briefing
Rhineland RhinelandA.pzbrf Rhineland.pzscn Zaolzie 10 RhinelandB_decisive.pzbrf END 0 EmptyC_marginal.pzbrf END 0 RhinelandD_loss.pzbrf

Label: label of this scenario
Briefing: opening briefing of the scenario ... all kinds of briefings always end on .pzbrf
Scenario: name of the scenario (see further)...always ends on .pzscn
Next label: label of the next scenario (for a Decisive Victory)
Prestige: prestige reward (for a Decisive Victory)
Briefing: briefing once you finished the scenario (for a Decisive Victory)
Next label: label of the next scenario (for a Marginal Victory)
Prestige: prestige reward (for a Marginal Victory)
Briefing: briefing once you finished the scenario (for a Marginal Victory)
The last three are those for a Loss


There are several kinds of next label... just the label (as in my example Zaolzie) , END (this outcome ends the campaign) or left blank. Blank means that you present the player with a choice in the briefing after the scenario is finished.
Example:
<p>Where would you like to proceed with your army?</p>
<p>
<button type="radio" name="NextScn" id="Mokra">Mokra</button><br/>
</p>
<p>
<button type="radio" name="NextScn" id="BorowaGora">Borowa Gora</button>
</p>

id= the label in your campaign. pzdat tree
When you check the line Czajanek, the player is given a choice at the end of the scenario with a DV and a MV.

The last type of next label is END_SAVE_CORE, as in the label Mannerheim of my example. This is used to save the player's core. The GUID of this MPC is linked to the saved core. This is extremely handy if you with to create a dynamic linked campaign.

Zaolzie ZaolzieA.pzbrf Zaolzie.pzscn Sudetenland 10 ZaolzieB_decisive.pzbrf Sudetenland 7 EmptyC_marginal.pzbrf Sudetenland 5 ZaolzieD_loss.pzbrf
Sudetenland SudetenlandA.pzbrf Sudetenland.pzscn Czajanek 200 SudetenlandB_decisive.pzbrf END 0 EmptyC_marginal.pzbrf END 0 SudetenlandD_loss.pzbrf
Czajanek CzajanekA.pzbrf Czajanek.pzscn 200 CzajanekB_decisive.pzbrf 100 CzajanekC_marginal.pzbrf END 0 CzajanekD_loss.pzbrf
Mokra MokraA.pzbrf Mokra.pzscn BorowaGora 200 MokraB_decisive.pzbrf BorowaGora 100 MokraC_marginal.pzbrf END 0 MokraD_loss.pzbrf
Borowa Gora BorowaGoraA.pzbrf BorowaGora.pzscn PiotrTrybu 200 BorowaGoraB_decisive.pzbrf PiotrTrybu 100 BorowaGoraC_marginal.pzbrf END 0 BorowaGoraD_loss.pzbrf
PiotrTrybu PiotrTrybuA.pzbrf PiotrTrybu.pzscn WolaCyrusowa 200 PiotrTrybuB_decisive.pzbrf WolaCyrusowa 100 PiotrTrybuC_marginal.pzbrf WolaCyrusowa 50 PiotrTrybuD_loss.pzbrf
WolaCyrusowa WolaCyrusowaA.pzbrf WolaCyrusowa.pzscn Warsaw2 200 WolaCyrusowaB_decisive.pzbrf Warsaw2 100 WolaCyrusowaC_marginal.pzbrf Warsaw2 50 WolaCyrusowaD_loss.pzbrf
Warsaw2 Warsaw2A.pzbrf Warsaw2.pzscn Modlin2 200 Warsaw2B_decisive.pzbrf Saar 400 Warsaw2C_marginal.pzbrf END 0 Warsaw2D_loss.pzbrf
Modlin2 Modlin2A.pzbrf Modlin2.pzscn Saar 400 Modlin2B_decisive.pzbrf Saar 200 Modlin2C_marginal.pzbrf END 0 Modlin2D_loss.pzbrf
Saar SaarA.pzbrf Saar.pzscn Mannerheim 500 SaarB_decisive.pzbrf END 0 EmptyC_marginal.pzbrf END 0 SaarD_loss.pzbrf
Mannerheim MannerheimA.pzbrf Mannerheim.pzscn END_SAVE_CORE 600 MannerheimB_decisive.pzbrf END_SAVE_CORE 550 MannerheimC_marginal.pzbrf END_SAVE_CORE 500 MannerheimD_loss.pzbrf

To demonstrate the dynamic linked campaign. The next example is the continuation of the MPC series.
You notice that {f534186e-3d16-4da7-a6fd-52dcead2e642} END_SAVE_CORE has been added. The main reason is for this MPC '40 to know that a player's core from MPC '37-'39 can be imported. The GUID you see, is the GUID from the first installment. If i wish to create a MPC '41, the Guid in the MPC '41 campaign.pzdat structure will be the GUID from MPC '40, so that it will know that a core from MPC '40 can be imported. This is how it works with the official DLC's 39-45


# This file contains Panzer Corps campaign structure

FormatVersion 1

# Entry points
# Name Label in campaign path Description Side Nation Starting prestige Display name
Weser 24 "MPC: From the northern abyss to Damocles" 0 0 1000 More Panzer Corps content '40 Grand Campaign {f534186e-3d16-4da7-a6fd-52dcead2e642} END_SAVE_CORE

Bergen BergenA.pzbrf Bergen.pzscn Voss 220 BergenB_decisive.pzbrf Voss 100 BergenC_marginal.pzbrf END 0 BergenD_loss.pzbrf
Voss VossA.pzbrf Voss.pzscn Hegra 220 VossB_decisive.pzbrf Hegra 100 VossC_marginal.pzbrf END 0 VossD_loss.pzbrf
Hegra HegraA.pzbrf Hegra.pzscn Maastricht 220 HegraB_decisive.pzbrf Maastricht 100 HegraC_marginal.pzbrf END 0 HegraD_loss.pzbrf
Maastricht MaastrichtA.pzbrf Maastricht.pzscn Hannut 250 MaastrichtB_decisive.pzbrf Hannut 100 MaastrichtC_marginal.pzbrf END 0 MaastrichtD_loss.pzbrf
Hannut HannutA.pzbrf Hannut.pzscn Gembloux 250 HannutB_decisive.pzbrf Gembloux 100 HannutC_marginal.pzbrf END 0 HannutD_loss.pzbrf
Gembloux GemblouxA.pzbrf Gembloux.pzscn Abbeville 250 GemblouxB_decisive.pzbrf Abbeville 100 GemblouxC_marginal.pzbrf END 0 GemblouxD_loss.pzbrf
Abbeville AbbevilleA.pzbrf Abbeville.pzscn Dunkerque 1800 AbbevilleB_decisive.pzbrf Dunkerque 1200 AbbevilleC_marginal.pzbrf END 0 AbbevilleD_loss.pzbrf
Dunkerque DunkerqueA.pzbrf Dunkerque.pzscn END 220 DunkerqueB_decisive.pzbrf END 100 DunkerqueC_marginal.pzbrf END 0 DunkerqueD_loss.pzbrf

If i want to finish the campaign after Dunkerque, this is how this line in the campaign.pzdat would look like.
Dunkerque DunkerqueA.pzbrf Dunkerque.pzscn END_SAVE_CORE 220 DunkerqueB_decisive.pzbrf END_SAVE_CORE 100 DunkerqueC_marginal.pzbrf END_SAVE_CORE 0 DunkerqueD_loss.pzbrf

Single campaign structures do not require END_SAVE_CORE after the final scenario, just END will do.

3) The scenarios you create and save must be located in MyProject\Data folder. All briefings you create for every scenario must be saved in MyProject\Data\Briefings. The names you give to your scenarios and briefings must match the names you enter in the campaign.pzdat file (logical). Typos will lead to either returning to the startscreen or showing a black screen when you start the next scenario. Each label, scenario name, briefing names should be unique. For example, when you give labels in different lines the same name, it might mess things up. If you create two different Moscow scenarios, label it Moscow1 and Moscow2, Moscow_easy and Moscow_hard...

4) It is advised to test your campaign after you have created your first scenario and filled in the campaign.pzdat; at least then you know that the basics are filled in properly. A beginner's mistake was that i always forgot to match the name in the #entry points as the first label in the #campaign path. Your MyProject folder should be copied (keep backups of your project at all times!) to \documents\mygames\panzer corps\mods. If the mod folder is not present you have to create it. When you start the game, chose more campaigns and you should find your campaign in the list.

If anything should be added to this tutorial, let me know.
https://www.facebook.com/NikivddPanzerCorps
https://www.youtube.com/channel/UCk2lyeEuH_hoA1s7tnTAEJQ
cedonxp
Sergeant - Panzer IIC
Sergeant - Panzer IIC
Posts: 179
Joined: Thu Nov 02, 2006 12:47 am
Location: Tampa Florida

Re: Tutorial: How to create a campaign

Post by cedonxp »

Thank you as always. Hope you are well.
Japoivvb
Senior Corporal - Ju 87G
Senior Corporal - Ju 87G
Posts: 95
Joined: Sun Jan 16, 2011 6:15 pm

Re: Tutorial: How to create a campaign

Post by Japoivvb »

I miss in this tutorial how to implement "spend prestige in briefing" e.g. from PGF after DV in France
<p>Do you want to spend 1000 prestige to secure Gibralter and the help of the Italian Navy?</p>
<a -prestige="1000" href="Sealion_Plus">Yes</a><br/>
I could not find any PC campaign with this implementation, even those PG/AG ssi remakes... does it work in PC?
Post Reply

Return to “Panzer Corps : Scenario Design”