CEL

Public API Reference

iCelInventorySpaceSlot Struct Reference

A slot in the inventory system. More...

#include <propclass/inv.h>

List of all members.

Public Member Functions

virtual bool AddEntity (iCelEntity *entity, iCelParameterBlock *params)=0
 Add an entity in this slot.
virtual int GetCount ()=0
 Return number of entities inside this slot.
virtual iCelEntityGetEntity (iCelParameterBlock *params)=0
 Get an entity on this slot.
virtual bool IsEmpty ()=0
 Check if there are entities in this slot.
virtual void RemoveAll ()=0
 Remove all entities in this slot.
virtual bool RemoveEntity (iCelEntity *entity)=0
 Remove this entity from the slot.


Detailed Description

A slot in the inventory system.

Applications can implement this to make any kind of slot system (like a 2D based grid).

Definition at line 53 of file inv.h.


Member Function Documentation

virtual bool iCelInventorySpaceSlot::AddEntity ( iCelEntity entity,
iCelParameterBlock params 
) [pure virtual]

Add an entity in this slot.

If you support stacking then you can use 'params' to specify where to stack. /return false if the entity can't be added for some reason.

virtual int iCelInventorySpaceSlot::GetCount (  )  [pure virtual]

Return number of entities inside this slot.

virtual iCelEntity* iCelInventorySpaceSlot::GetEntity ( iCelParameterBlock params  )  [pure virtual]

Get an entity on this slot.

If there are more entities on this slot then you can use the abstract 'params' to specify the correct one. The exact parameter specification depends on the implementation of this slot. If you don't support stacking then you can ignore this parameter.

virtual bool iCelInventorySpaceSlot::IsEmpty (  )  [pure virtual]

Check if there are entities in this slot.

virtual void iCelInventorySpaceSlot::RemoveAll (  )  [pure virtual]

Remove all entities in this slot.

virtual bool iCelInventorySpaceSlot::RemoveEntity ( iCelEntity entity  )  [pure virtual]

Remove this entity from the slot.

/return false if the entity can't be removed for some reason.


The documentation for this struct was generated from the following file:
Generated for CEL: Crystal Entity Layer by doxygen 1.4.7