propclass/chars.h
00001 /* 00002 Crystal Space Entity Layer 00003 Copyright (C) 2001 by Jorrit Tyberghein 00004 00005 This library is free software; you can redistribute it and/or 00006 modify it under the terms of the GNU Library General Public 00007 License as published by the Free Software Foundation; either 00008 version 2 of the License, or (at your option) any later version. 00009 00010 This library 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 GNU 00013 Library General Public License for more details. 00014 00015 You should have received a copy of the GNU Library General Public 00016 License along with this library; if not, write to the Free 00017 Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 00018 */ 00019 00020 #ifndef __CEL_PF_CHARS__ 00021 #define __CEL_PF_CHARS__ 00022 00023 #include "cstypes.h" 00024 #include "csutil/scf.h" 00025 00026 struct iCelEntity; 00027 struct iPcInventory; 00028 00032 struct iCharacteristicsIterator : public virtual iBase 00033 { 00034 SCF_INTERFACE (iCharacteristicsIterator, 0, 0, 1); 00035 00036 virtual bool HasNext () const = 0; 00038 virtual const char* Next (float& value) = 0; 00039 }; 00040 00051 struct iPcCharacteristics : public virtual iBase 00052 { 00053 SCF_INTERFACE (iPcCharacteristics, 0, 0, 1); 00054 00060 virtual bool SetCharacteristic (const char* name, float value) = 0; 00061 00072 virtual bool SetInheritedCharacteristic (const char* name, 00073 float factor, float add) = 0; 00074 00079 virtual float GetCharacteristic (const char* name) const = 0; 00080 00085 virtual float GetLocalCharacteristic (const char* name) const = 0; 00086 00091 virtual float GetInheritedCharacteristic (const char* name) const = 0; 00092 00098 virtual bool ClearCharacteristic (const char* name) = 0; 00099 00103 virtual bool HasCharacteristic (const char* name) const = 0; 00104 00111 virtual bool ClearAll () = 0; 00112 00118 virtual void AddToInventory (iPcInventory* inv) = 0; 00119 00125 virtual void RemoveFromInventory (iPcInventory* inv) = 0; 00126 00132 virtual void MarkDirty (const char* charName) = 0; 00133 00139 virtual bool TestConstraints (const char* charName) = 0; 00140 00144 virtual void Dump () = 0; 00145 }; 00146 00154 struct iTemplateCharacteristics : public virtual iBase 00155 { 00156 SCF_INTERFACE (iTemplateCharacteristics, 0, 0, 1); 00157 00161 virtual void SetCharacteristic (const char* name, float value) = 0; 00162 00166 virtual float GetCharacteristic (const char* name) const = 0; 00167 00171 virtual void ClearCharacteristic (const char* name) = 0; 00172 00176 virtual bool HasCharacteristic (const char* name) const = 0; 00177 00181 virtual csPtr<iCharacteristicsIterator> GetAllCharacteristics () const = 0; 00182 00186 virtual void ClearAll () = 0; 00187 }; 00188 00189 #endif // __CEL_PF_CHARS__ 00190
Generated for CEL: Crystal Entity Layer 2.1 by doxygen 1.6.1
