~ubuntu-branches/ubuntu/karmic/starvoyager/karmic

« back to all changes in this revision

Viewing changes to mission.h

  • Committer: Bazaar Package Importer
  • Author(s): Idan Sofer
  • Date: 2003-08-01 16:55:13 UTC
  • Revision ID: james.westby@ubuntu.com-20030801165513-0ueb129iym99k7tg
Tags: upstream-0.4.4
ImportĀ upstreamĀ versionĀ 0.4.4

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
        mission.h
 
3
        
 
4
        (c) Richard Thrippleton
 
5
        Licensing terms are in the 'LICENSE' file
 
6
        If that file is not included with this source then permission is not given to use this source in any way whatsoever.
 
7
*/
 
8
 
 
9
class player;
 
10
class ship;
 
11
class planet;
 
12
 
 
13
class mission //Handles in progress missions
 
14
{
 
15
        public:
 
16
        static const ISIZE=64; //Size of mission index  
 
17
        enum {CARGO=0,ESCORT=1,DESTROY=2,DEFEND=3,RECON=4,CAPTURE=5}; //Mission types
 
18
 
 
19
        mission(alliance* all,int typ); //Constructor generates a mission of given type for given alliance
 
20
 
 
21
        static void init(); //Initialise the missions subsystem
 
22
        static void poll(); //Poll current missions, see how they're progressing
 
23
                
 
24
        private:
 
25
        static mission* missions[ISIZE]; //Index of current missions
 
26
        static int lev; //Mission difficulty level in current environment
 
27
 
 
28
        int typ; //Mission type
 
29
        long pay; //Mission pay
 
30
        player* cmdr; //Mission commander
 
31
        ship* help; //Ship assisting
 
32
        alliance* all; //Alliance controlling the mission
 
33
        planet* home; //Home planet of mission, place to return for payment
 
34
        ship* sinv; //Involved ship (if any)
 
35
        planet* pinv; //Involved planet (if any)
 
36
        equip* crf; //Cargo if appropriate
 
37
}