OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Blacknite on 04 Jul 2006, 21:48:46

Title: Help on Campaign!
Post by: Blacknite on 04 Jul 2006, 21:48:46
I have the following:
Quote
class Campaign
{
   name = "Balkan Crisis";
   firstBattle = Part1;
      
   class Part1
   {
      class Intro: MissionDefault
      {
         end1 = BalkanCrisis;
         end2 = BalkanCrisis;
         end3 = BalkanCrisis;
         end4 = BalkanCrisis;
         end5 = BalkanCrisis;
         end6 = BalkanCrisis;
         lost = Intro;
         template = Intro.kegnoecain_snow;
      };
      class BalkanCrisis: MissionDefault
      {
         end1 = OnTheRun;
         end2 = OnTheRun;
         end3 = OnTheRun;
         end4 = OnTheRun;
         end5 = OnTheRun;
         end6 = OnTheRun;
         lost = BalkanCrisis;
         template = BalkanCrisis.kegnoecain_snow;
      };
      class OnTheRun: MissionDefault
      {
         end1 = GreatEscape;
         end2 = GreatEscape;
         end3 = GreatEscape;
         end4 = GreatEscape;
         end5 = GreatEscape;
         end6 = GreatEscape;
         lost = OnTheRun;
         template = OnTheRun.kegnoecain_snow;
      };
      class GreatEscape: MissionDefault
      {
         end1 = LZ;
         end2 = LZ;
         end3 = LZ;
         end4 = LZ;
         end5 = LZ;
         end6 = LZ;
         lost = GreatEscape;
         template = GreatEscape.kegnoecain_snow;
      };
      class LZ: MissionDefault
      {
         end1 = ;
         end2 = ;
         end3 = ;
         end4 = ;
         end5 = ;
         end6 = ;
         lost = LZ;
         template = LZ.kegnoecain_snow;
      };
   };   
};

But I get an error message when trying to load it up... :(
Title: Re: Help on Campaign!
Post by: bedges on 04 Jul 2006, 22:02:56
and what, pray tell, is the error message telling you?

because any advice offered will sort of depend on it...
Title: Re: Help on Campaign!
Post by: Blacknite on 04 Jul 2006, 22:13:34
campaigns\balkancrisis.eden\description.ext/Campaign/Part1.Intro:  Undefined base class 'Mission Default'
Title: Re: Help on Campaign!
Post by: bedges on 04 Jul 2006, 22:50:56
just looking through mikero's campaign class fundamentals (http://andrew.nf/OFP/BedtimeReading/Campaign/CampaignClases.htm), are you not missing a

Code: [Select]
class NoEndings
{
lost = ;
end1 = ;
end2 = ;
end3 = ;
end4 = ;
end5 = ;
end6 = ;
};


and

Code: [Select]
class MissionDefault : NoEndings
{
lives = -1;
};

in there? not pretending i understand campaigns as yet, but according to mikero (and the principles of inheritance) those are required...