Advanced Strategic Command
Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
MapNetwork Class Referenceabstract

Base class for the management of resource networks and globally stored resources. More...

#include <resourcenet.h>

Inheritance diagram for MapNetwork:
Inheritance graph
[legend]

Public Types

enum  Scope { singleField, net, wholeMap, globalPool }
 

Public Member Functions

virtual void start (int x, int y)
 
 MapNetwork (GameMap *gamemap, int checkInstances=1)
 
virtual ~MapNetwork ()
 

Protected Member Functions

virtual int fieldavail (int x, int y)=0
 
virtual int searchfinished (void)=0
 
virtual void checkvehicle (Vehicle *v)=0
 
virtual void checkbuilding (Building *b)=0
 
virtual int globalsearch (void)=0
 
virtual void searchbuilding (int x, int y)
 
virtual void searchvehicle (int x, int y)
 
virtual void searchfield (int x, int y, int dir)
 
void searchAllVehiclesNextToBuildings (int player)
 

Protected Attributes

GameMapactmap
 
int pass
 
MapCoordinate startposition
 

Detailed Description

Base class for the management of resource networks and globally stored resources.

Definition at line 29 of file resourcenet.h.

Member Enumeration Documentation

Enumerator
singleField 
net 
wholeMap 
globalPool 

Definition at line 48 of file resourcenet.h.

Constructor & Destructor Documentation

MapNetwork::MapNetwork ( GameMap gamemap,
int  checkInstances = 1 
)

Definition at line 159 of file resourcenet.cpp.

References displaymessage(), and pass.

MapNetwork::~MapNetwork ( )
virtual

Definition at line 173 of file resourcenet.cpp.

Member Function Documentation

virtual void MapNetwork::checkbuilding ( Building b)
protectedpure virtual
virtual void MapNetwork::checkvehicle ( Vehicle v)
protectedpure virtual
virtual int MapNetwork::fieldavail ( int  x,
int  y 
)
protectedpure virtual

Implemented in ResourceNet.

Referenced by searchfield().

virtual int MapNetwork::globalsearch ( void  )
protectedpure virtual

Implemented in ResourceNet.

Referenced by start().

void MapNetwork::searchAllVehiclesNextToBuildings ( int  player)
protected
void MapNetwork::searchbuilding ( int  x,
int  y 
)
protectedvirtual
void MapNetwork::searchfield ( int  x,
int  y,
int  dir 
)
protectedvirtual
virtual int MapNetwork::searchfinished ( void  )
protectedpure virtual
void MapNetwork::searchvehicle ( int  x,
int  y 
)
protectedvirtual
void MapNetwork::start ( int  x,
int  y 
)
virtual

Member Data Documentation

GameMap* MapNetwork::actmap
protected
int MapNetwork::pass
protected
MapCoordinate MapNetwork::startposition
protected

Definition at line 35 of file resourcenet.h.

Referenced by start().


The documentation for this class was generated from the following files: