Planeshift
|
00001 /* 00002 * psglyph.h 00003 * 00004 * Copyright (C) 2001-2003 Atomic Blue ([email protected], http://www.atomicblue.org) 00005 * 00006 * 00007 * This program is free software; you can redistribute it and/or 00008 * modify it under the terms of the GNU General Public License 00009 * as published by the Free Software Foundation (version 2 of the License) 00010 * This program is distributed in the hope that it will be useful, 00011 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00013 * GNU General Public License for more details. 00014 * You should have received a copy of the GNU General Public License 00015 * along with this program; if not, write to the Free Software 00016 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 00017 * 00018 */ 00019 00020 #ifndef __PSGLYPH_H__ 00021 #define __psglyph_h__ 00022 //============================================================================= 00023 // Crystal Space Includes 00024 //============================================================================= 00025 #include <csutil/csstring.h> 00026 #include <csutil/refcount.h> 00027 #include <csutil/refarr.h> 00028 #include <csutil/array.h> 00029 00030 //============================================================================= 00031 // Project Includes 00032 //============================================================================= 00033 #include "util/psconst.h" 00034 00035 #include <idal.h> 00036 00037 //============================================================================= 00038 // Local Includes 00039 //============================================================================= 00040 #include "psitem.h" 00041 #include "psstdint.h" 00042 00043 class psCharacter; 00044 00045 00048 class psGlyph : public psItem 00049 { 00050 public: 00051 psGlyph(); 00052 virtual ~psGlyph() { }; 00053 00056 virtual const char* GetItemType() 00057 { 00058 return "Glyph"; 00059 } 00060 00061 virtual bool Load(iResultRow &row); 00062 00063 virtual psItem* CreateNew(); 00064 virtual void Copy(psGlyph* target); 00065 00066 virtual void SetOwningCharacter(psCharacter* owner); 00067 00068 csString GlyphToXML(); 00069 virtual int GetPurifyStatus() const; 00070 void PurifyingStarted(); 00071 void PurifyingFinished(); 00072 void UnPurify(); 00073 bool Purified(); 00074 00075 virtual psItem* Clone(); 00076 00078 void* operator new(size_t); 00079 00081 void operator delete(void*); 00082 00083 private: 00085 static PoolAllocator<psGlyph> glyphpool; 00086 00087 }; 00088 00089 #endif