Here's a question for the coders responsible for Campaign Persistent Variables.
I have three ships: Enterprise, Falcon, and Tardis. I want to track how many of them are destroyed over the span of two missions. At the end of these two missions, I want to have a number, 0-3 inclusive, that tells me how many of them are dead.
I decide I'm going to use a CPV to achieve this. I'll call it @destroyedCount.
I add the following events to Mission 1:
If the Enterprise explodes, add 1 to @destroyedCount
If the Falcon explodes, add 1 to @destroyedCount
If the Tardis explodes, add 1 to @destroyedCount
Then I add the same events to Mission 2. If a ship blew up in Mission 1 it doesn't appear in Mission 2, so we don't need to worry about its destruction being counted twice.
In mission 3, I check the value of @destroyedCount to branch the mission into one of four states. I don't bother to handle values below 0 and above 3.
Have I implemented this correctly?