src/WorshiperInfo.cpp

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 #include "WorshiperInfo.h"
00026 
00027 #include "Worshiper.h"
00028 
00029 WorshiperInfo::WorshiperInfo() : _w_info(NULL), _w_request(NULL) {
00030 
00031 }
00032 
00033 WorshiperInfo::~WorshiperInfo() {
00034 
00035 }
00036 
00037 void WorshiperInfo::setWorshiperInfo(const Worshiper * w_info) {
00038   _w_info = w_info;
00039 }
00040 
00041 void WorshiperInfo::setWorshiperRequest(const Worshiper * w_request) {
00042   _w_request = w_request;
00043 }
00044 
00045 unsigned int WorshiperInfo::getSize() const {
00046   return (_w_info != NULL ? _w_info->getSize() : 0);
00047 }
00048 
00049 bool WorshiperInfo::isEnnemy() const {
00050   return (_w_info != NULL && _w_info->getColony() != _w_request->getColony());
00051 }

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