CEL

Public API Reference

physicallayer/entitytpl.h

00001 /*
00002     Crystal Space Entity Layer
00003     Copyright (C) 2005 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_PL_ENTITYTEMP__
00021 #define __CEL_PL_ENTITYTEMP__
00022 
00023 #include "cstypes.h"
00024 #include "csutil/scf.h"
00025 #include "csutil/strset.h"
00026 #include "csutil/set.h"
00027 #include "csgeom/vector2.h"
00028 #include "csgeom/vector3.h"
00029 #include "csutil/cscolor.h"
00030 
00031 #include "physicallayer/datatype.h"
00032 
00033 struct iCelEntity;
00034 struct iCelPropertyClassTemplate;
00035 struct iCelPropertyClass;
00036 struct iCelParameterBlock;
00037 
00038 SCF_VERSION (iCelEntityTemplate, 0, 0, 1);
00039 
00043 struct iCelEntityTemplate : public iBase
00044 {
00049   virtual iObject* QueryObject () = 0;
00050 
00055   virtual const char* GetName () const = 0;
00056 
00061   virtual void SetName (const char* n) = 0;
00062 
00066   virtual iCelPropertyClassTemplate* CreatePropertyClassTemplate () = 0;
00067 
00074   virtual void SetBehaviour (const char* layer, const char* behaviour) = 0;
00075 
00079   virtual const char* GetBehaviourLayer () const = 0;
00080 
00084   virtual const char* GetBehaviour () const = 0;
00085 
00091   virtual void AddMessage (const char* msgid, iCelParameterBlock* params) = 0;
00092 
00098   virtual void AddClass (csStringID cls) = 0;
00099 
00103   virtual void RemoveClass (csStringID cls) = 0;
00104 
00108   virtual bool HasClass (csStringID cls) = 0;
00109 
00113   virtual const csSet<csStringID>& GetClasses () const = 0;
00114 };
00115 
00116 SCF_VERSION (iCelPropertyClassTemplate, 0, 0, 1);
00117 
00122 struct iCelPropertyClassTemplate : public iBase
00123 {
00127   virtual void SetName (const char* name) = 0;
00128 
00132   virtual const char* GetName () const = 0;
00133 
00140   virtual void SetTag (const char* tagname) = 0;
00141 
00146   virtual const char* GetTag () const = 0;
00147 
00152   virtual void SetPropertyVariable (csStringID propertyID, celDataType type,
00153         const char* varname) = 0;
00154 
00168   virtual void SetProperty (csStringID propertyID, long value) = 0;
00169 
00173   virtual void SetProperty (csStringID propertyID, float value) = 0;
00174 
00178   virtual void SetProperty (csStringID propertyID, bool value) = 0;
00179 
00183   virtual void SetProperty (csStringID propertyID, const char* value) = 0;
00184 
00188   virtual void SetProperty (csStringID propertyID, const csVector2& value) = 0;
00189 
00193   virtual void SetProperty (csStringID propertyID, const csVector3& value) = 0;
00194 
00198   virtual void SetProperty (csStringID propertyID, const csColor& value) = 0;
00199 
00203   virtual void SetProperty (csStringID propertyID,
00204         iCelPropertyClass* value) = 0;
00205 
00209   virtual void SetProperty (csStringID propertyID, iCelEntity* entity) = 0;
00210 
00215   virtual void PerformAction (csStringID actionID,
00216         iCelParameterBlock* params) = 0;
00217 };
00218 
00219 #endif // __CEL_PL_ENTITYTEMP__
00220 

Generated for CEL: Crystal Entity Layer by doxygen 1.4.7