Main Page | Class List | File List | Class Members | File Members

entity Class Reference

holds the data for an entity More...

#include <world.h>

List of all members.

Public Member Functions

 entity (uInt seed, const energy &e, const memory &m, const position &p, const direction &d)
 ~entity ()
energy getEnergy ()
virtual void draw ()

Protected Attributes

energy m_energy
 the entity's energy pool

direction m_direction
 the direction the entity is facing

position m_position
 the current position of the entity

processId m_pid


Detailed Description

holds the data for an entity

Definition at line 14 of file world.h.


Constructor & Destructor Documentation

entity::entity uInt  seed,
const energy e,
const memory m,
const position p,
const direction d
 

Definition at line 11 of file world.cpp.

References entity(), and memory.

Referenced by entity().

entity::~entity  )  [inline]
 

Definition at line 26 of file world.h.


Member Function Documentation

void entity::draw  )  [virtual]
 

Definition at line 26 of file world.cpp.

energy entity::getEnergy  )  [inline]
 

Definition at line 28 of file world.h.

References energy, and m_energy.


Member Data Documentation

direction entity::m_direction [protected]
 

the direction the entity is facing

Definition at line 36 of file world.h.

Referenced by world::getPosInfrontOfEntity(), world::giveMemory(), world::rotateEntityLeft(), and world::rotateEntityRight().

energy entity::m_energy [protected]
 

the entity's energy pool

Definition at line 34 of file world.h.

Referenced by world::canBeExecuted(), world::convertEnergyToMemory(), world::convertMemoryToEnergy(), getEnergy(), world::kill(), and world::transferEnergy().

processId entity::m_pid [protected]
 

the entity's process in the virtual machine

Definition at line 41 of file world.h.

Referenced by world::spawnEntity().

position entity::m_position [protected]
 

the current position of the entity

Definition at line 38 of file world.h.

Referenced by world::absorbEnergy(), world::getPosInfrontOfEntity(), world::kill(), world::moveEntity(), world::releaseEnergy(), and world::transferMemory().


The documentation for this class was generated from the following files:
Generated on Sun Mar 6 22:11:29 2005 for experiment03 by doxygen 1.3.7