Drag[en]gine Script Module DragonScript Script API  1.0
SpawnPoint Class Reference
Inheritance diagram for SpawnPoint:
Element

Public Member Functions

int getReferenceNumber ()
 
void init (StubElement stub)
 Initialize element from stub. More...
 
SpawnPoint new (SpawnPointClass eclass)
 
void visit (ElementVisitor visitor)
 
- Public Member Functions inherited from Element
void addToGameWorld ()
 
void dispose ()
 
void enterFrame ()
 Frame update started. More...
 
ElementClass getClass ()
 
DMatrix getElementMatrix ()
 Matrix to transform from element space into world space. More...
 
GameWorld getGameWorld ()
 
UniqueID getID ()
 
DMatrix getInverseElementMatrix ()
 Matrix to transform from world space into element space. More...
 
Quaternion getOrientation ()
 
Element getParent ()
 
DVector getPosition ()
 
StubElement getStub ()
 Element stub used to create the element. More...
 
bool getTouchable ()
 
bool getVisible ()
 
void init (StubElement stub)
 Initialize element from stub. More...
 
bool isChildOf (Element parent)
 
bool isMyselfOrChildOf (Element parent)
 
Element new (ElementClass elementClass)
 
void onSetGameWorld ()
 
void onSetGeometry ()
 
void onSetOrientation ()
 
void onSetParent ()
 
void onSetPosition ()
 
void onSetTouchable ()
 
void onSetVisible ()
 
void postThink (float elapsed)
 
void readFromFile (PersistencyEnvironment env, FileReader reader)
 Read element from file reader. More...
 
void removeFromGameWorld ()
 
void removeFromGameWorldIfPresent ()
 Remove element from game world if present. More...
 
void setGameWorld (GameWorld gameWorld)
 
void setGeometry (DVector position, Quaternion orientation)
 
void setID (UniqueID id)
 
void setOrientation (Quaternion orientation)
 
void setParent (Element parent)
 
void setPosition (DVector position)
 
void setStub (StubElement stub)
 Set element stub used to create the element. More...
 
void setTouchable (bool touchable)
 
void setVisible (bool visible)
 
void think (float elapsed)
 
String toString ()
 
void visit (ElementVisitor visitor)
 
void writeToFile (PersistencyEnvironment env, FileWriter writer)
 Write element to file writer. More...
 
void writeToFileWithStub (PersistencyEnvironment env, FileWriter writer)
 Write element to file writer with stub. More...
 

Protected Member Functions

void setReferenceNumber (int refNum)
 

Additional Inherited Members

- Static Public Member Functions inherited from Element
static Element readElementFromFileWithStub (PersistencyEnvironment env, FileReader reader, ElementClassList ElementClassList)
 Load element from file reader with stub supporting null element. More...
 
static void writeElementToFileWithStub (PersistencyEnvironment env, FileWriter writer, Element element)
 Write element to file writer with stub supporting null element. More...
 

Detailed Description

Spawn point for some character or object. Has support for variable class names as often a spawn point has no other options than a reference number to identify it among multiple spawn points of the same type. This way you can create the class with the class name as parameter saving you from creating an empty subclass for each spawn point type you have got in your game.

Author
Roland Pl├╝ss
Version
1.0

Member Function Documentation

◆ getReferenceNumber()

int getReferenceNumber ( )

Retrieves the reference number of this spawn point.

◆ init()

void init ( StubElement  stub)

Initialize element from stub.

The stub is stored in the element for saving. Do not change the stub after using it for the init() call.

◆ new()

SpawnPoint new ( SpawnPointClass  eclass)

Creates a new SpawnPoint object.

◆ setReferenceNumber()

void setReferenceNumber ( int  refNum)
protected

Sets the reference number of this spawn point.

◆ visit()

void visit ( ElementVisitor  visitor)

Visit this element.


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