MFMv2.0.10
Movable Feast Machine Simulator 2.0.10
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Static Public Attributes
MFM::Element_Boids1< CC > Class Template Reference
Inheritance diagram for MFM::Element_Boids1< CC >:
MFM::Element_Boids< CC > MFM::Element< CC >

Public Member Functions

const char * GetName () const
 
virtual const T & GetDefaultAtom () const
 
virtual u32 DefaultPhysicsColor () const
 
- Public Member Functions inherited from MFM::Element_Boids< CC >
Vector GetHeading (const T &atom) const
 
void SetHeading (const T &atom, const Vector v) const
 
SPoint PickPossibleDestination (EventWindow< CC > &window, const Vector &target, Random &random) const
 
virtual void Behavior (EventWindow< CC > &window) const
 
- Public Member Functions inherited from MFM::Element< CC >
 Element (const UUID &uuid)
 
void AllocateType ()
 
u32 GetType () const
 
const char * GetAtomicSymbol () const
 
const char * GetName () const
 
virtual void AppendDescription (const T *atom, OString64 &desc) const
 
bool IsType (u32 type) const
 
const UUIDGetUUID () const
 
virtual u32 PhysicsColor () const
 
virtual const char * GetDescription () const
 
virtual u32 DefaultLowlightColor () const
 
void ToggleLowlightPhysicsColor ()
 
virtual u32 LocalPhysicsColor (const T &atom, u32 selector) const
 
virtual u32 Diffusability (EventWindow< CC > &ew, SPoint nowAt, SPoint maybeAt) const
 
u32 NoDiffusability (EventWindow< CC > &ew, SPoint nowAt, SPoint maybeAt) const
 
const ElementParameters< CC > & GetElementParameters () const
 
ElementParameters< CC > & GetElementParameters ()
 
const AtomicParameters< CC > & GetAtomicParameters () const
 
AtomicParameters< CC > & GetAtomicParameters ()
 

Static Public Attributes

static Element_Boids1 THE_INSTANCE
 
static const u32 SUB_TYPE = 1
 
static const u32 TYPE = Element_Boids<CC>::TYPE|(SUB_TYPE<<Element_Boids<CC>::TYPE_BITS)
 
- Static Public Attributes inherited from MFM::Element_Boids< CC >
static const u32 TYPE = 0xbd
 
static const u32 TYPE_BITS = 8
 
static const u32 TYPE_MASK = (1<<TYPE_BITS)-1
 
static const u32 BITS_PER_DIM = 4
 
static const u32 STATE_HEADING_IDX = 0
 
static const u32 STATE_HEADING_LEN = 2 * BITS_PER_DIM
 
static const u32 STATE_BITS = STATE_HEADING_IDX + STATE_HEADING_LEN
 
- Static Public Attributes inherited from MFM::Element< CC >
static const u32 COMPLETE_DIFFUSABILITY = 1000
 

Additional Inherited Members

- Static Public Member Functions inherited from MFM::Element_Boids< CC >
static bool IsBoidType (u32 type)
 
- Protected Member Functions inherited from MFM::Element< CC >
virtual T BuildDefaultAtom () const
 
const BitVector
< P::BITS_PER_ATOM > & 
GetBits (const T &atom) const
 
BitVector< P::BITS_PER_ATOM > & GetBits (T &atom) const
 
bool IsValidAtomicSymbol (const char *symbol)
 
void SetAtomicSymbol (const char *symbol)
 
void SetName (const char *name)
 
void Diffuse (EventWindow< CC > &window) const
 
virtual u32 PercentMovable (const T &you, const T &me, const SPoint &offset) const =0
 

Member Function Documentation

template<class CC >
virtual u32 MFM::Element_Boids1< CC >::DefaultPhysicsColor ( ) const
inlinevirtual

Gets the 32-bit ARGB formatted color that all Atoms of this Element will be drawn with.

Returns
The 32-bit ARGB formatted color that all Atoms of this Element will be drawn with.

Implements MFM::Element< CC >.

template<class CC >
virtual const T& MFM::Element_Boids1< CC >::GetDefaultAtom ( ) const
inlinevirtual

Gets the default Atom of this Element . If this Element has not been assigned a type through AllocateType() , this will FAIL with ILLEGAL_STATE. NOTE: The defaultAtom returned here will have been constructed by Element::BuildDefaultAtom, which leaves all state bits zero. If this is not desirable, element subclasses should override this to provide their own default atom initialization.

Returns
The default Atom of this Element.
See Also
BuildDefaultAtom

Reimplemented from MFM::Element< CC >.


The documentation for this class was generated from the following file: