src/ReachableCell.h

Go to the documentation of this file.
00001 
00008 /*
00009 This file is part of Teapot Colony Wars.
00010 
00011 Teapot Colony Wars is free software: you can redistribute it and/or modify
00012 it under the terms of the GNU General Public License as published by
00013 the Free Software Foundation, either version 2 of the License, or
00014 (at your option) any later version.
00015 
00016 Teapot Colony Wars is distributed in the hope that it will be useful,
00017 but WITHOUT ANY WARRANTY; without even the implied warranty of
00018 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00019 GNU General Public License for more details.
00020 
00021 You should have received a copy of the GNU General Public License
00022 along with Teapot Colony Wars.  If not, see <http://www.gnu.org/licenses/>.
00023 */
00024 
00025 #ifndef REACHABLECELL_H
00026 #define REACHABLECELL_H
00027 
00028 #include <list>
00029 #include <map>
00030 
00031 #include "Cell.h"
00032 
00033 class Pheromone;
00034 class Worshiper;
00035 
00039 class ReachableCell  : public Cell
00040 {
00041 protected:
00042 
00044   std::list<Worshiper *>* _people;
00045 
00047   std::map<Pheromone*, unsigned int>* _pheromones;
00048 
00050   ReachableCell *_next;
00051 
00055   ReachableCell();
00056 
00057 public:
00058 
00062   virtual ~ReachableCell();
00063 
00067   virtual void draw();
00068 
00075   virtual bool reachable(Worshiper *w);
00076 
00082   virtual std::list<Worshiper*>* getPeople();
00083 
00090   virtual std::map<Pheromone*, unsigned int>* getPheromones();
00091 
00098   virtual bool addWorshiper(Worshiper *w);
00099 
00106   virtual bool removeWorshiper(const Worshiper *w);
00107 
00114   virtual void addPheromone(Pheromone *p);
00115 
00121   virtual void push(ReachableCell *next);
00122 
00128   virtual ReachableCell* pop();
00129 
00135   virtual Cell* makeActions();
00136 };
00137 
00138 #endif // REACHABLECELL_H

Generated on Sat Feb 2 22:22:54 2008 for Teapot Colony Wars by  doxygen 1.5.4