deScriptingSystem Class Reference

Scripting System. More...

#include <deScriptingSystem.h>

Inheritance diagram for deScriptingSystem:
deBaseSystem

List of all members.

Public Member Functions

Constructors and Destructors
 deScriptingSystem (deEngine *engine)
 Creates a new scripting system linked to the given engine.
 ~deScriptingSystem ()
 Cleans up the scripting system.
Management
deBaseScriptingModuleGetActiveModule () const
const char * GetScriptDir () const
 Retrieves the directory relative to the game directory where the scripts are located.
void SetScriptDir (const char *scriptDir)
 Sets the directory relative to the game directory where the scripts are located.
bool GetEditMode () const
 Determines if the scripts are executed in edit mode.
void SetEditMode (bool editMode)
 Sets if the scripts are executed in edit mode.
void InitGame ()
 Inits the game if not running.
void ExitGame ()
 Exits the game it running.
void OnFrameUpdate ()
 A new fram update cycle started.
void OnResizeRenderWindow ()
 Render window has changed size.
void PaintScreen ()
 Primary render target has to be painted.
void SendEvent (deInputEvent *event)
 Event has to be processed.
void LoadComponent (deComponent *component)
 Creates the peer object for the given component using the active module and assigns it.
void LoadCollider (deCollider *collider)
 Creates the peer object for the given collider using the active module and assigns it.
void LoadServer (deServer *server)
 Creates the peer object for the given server using the active module and assigns it.
void LoadConnection (deConnection *connection)
 Creates the peer object for the given connection using the active module and assigns it.
void LoadNetworkState (deNetworkState *state)
 Creates the peer object for the given network state using the active module and assigns it.
void LoadAI (deAI *ai)
 Creates the peer object for the given ai using the active module and assigns it.
void LoadTouchSensor (deTouchSensor *touchSensor)
 Creates the peer object for the given touch sensor using the active module and assigns it.
void LoadPropField (dePropField *propField)
 Creates the peer object for the given prop field using the active module and assigns it.
void LoadParticleEmitter (deParticleEmitter *emitter)
 Creates the peer object for the given particle emitter using the active module and assigns it.
Overloadables
virtual void SetActiveModule (deLoadableModule *module)
 Sets the active loadable module.
virtual void ClearPermanents ()
 Clears cross references and links that could lead to memory leaks.
virtual void PostStart ()
 Carry out here actions right after the system started up.
virtual void PreStop ()
 Carry out here actions right before the system shuts down.

Detailed Description

Scripting System.

Provides support for an external scripting or programming language. This is the only system that can not change during the run of a game not even during engine-break time. The scripts drive the entire engine and should provide an interface ( abstraction layer ) between the engine and engine systems towards the game developer. The amount of access to the engine functionality is depending on the scripting module used.

Note:
Currently the system sends events directly to the scripting system. It would be better to avoid this by giving the scripting system the chance to retrieve the events itself from a queue. The best idea would be to create an event queue in the engine object that the input system writes to and that the scripting system retrieves from. Conversion of events has to be done anyways.
Author:
Plüss Roland
Version:
1.0
Date:
2008

Constructor & Destructor Documentation

deScriptingSystem::deScriptingSystem ( deEngine engine )

Creates a new scripting system linked to the given engine.

deScriptingSystem::~deScriptingSystem (  )

Cleans up the scripting system.


Member Function Documentation

virtual void deScriptingSystem::ClearPermanents (  ) [virtual]

Clears cross references and links that could lead to memory leaks.

Do not forget to call the super function.

Reimplemented from deBaseSystem.

void deScriptingSystem::ExitGame (  )

Exits the game it running.

deBaseScriptingModule* deScriptingSystem::GetActiveModule (  ) const [inline]
bool deScriptingSystem::GetEditMode (  ) const [inline]

Determines if the scripts are executed in edit mode.

In this mode the scripts are reduced to what is required by an editing application. The edit mode can only be changed while the system is not running.

const char* deScriptingSystem::GetScriptDir (  ) const [inline]

Retrieves the directory relative to the game directory where the scripts are located.

void deScriptingSystem::InitGame (  )

Inits the game if not running.

void deScriptingSystem::LoadAI ( deAI ai )

Creates the peer object for the given ai using the active module and assigns it.

void deScriptingSystem::LoadCollider ( deCollider collider )

Creates the peer object for the given collider using the active module and assigns it.

void deScriptingSystem::LoadComponent ( deComponent component )

Creates the peer object for the given component using the active module and assigns it.

void deScriptingSystem::LoadConnection ( deConnection connection )

Creates the peer object for the given connection using the active module and assigns it.

void deScriptingSystem::LoadNetworkState ( deNetworkState state )

Creates the peer object for the given network state using the active module and assigns it.

void deScriptingSystem::LoadParticleEmitter ( deParticleEmitter emitter )

Creates the peer object for the given particle emitter using the active module and assigns it.

void deScriptingSystem::LoadPropField ( dePropField propField )

Creates the peer object for the given prop field using the active module and assigns it.

void deScriptingSystem::LoadServer ( deServer server )

Creates the peer object for the given server using the active module and assigns it.

void deScriptingSystem::LoadTouchSensor ( deTouchSensor touchSensor )

Creates the peer object for the given touch sensor using the active module and assigns it.

void deScriptingSystem::OnFrameUpdate (  )

A new fram update cycle started.

void deScriptingSystem::OnResizeRenderWindow (  )

Render window has changed size.

void deScriptingSystem::PaintScreen (  )

Primary render target has to be painted.

virtual void deScriptingSystem::PostStart (  ) [virtual]

Carry out here actions right after the system started up.

Reimplemented from deBaseSystem.

virtual void deScriptingSystem::PreStop (  ) [virtual]

Carry out here actions right before the system shuts down.

Reimplemented from deBaseSystem.

void deScriptingSystem::SendEvent ( deInputEvent event )

Event has to be processed.

virtual void deScriptingSystem::SetActiveModule ( deLoadableModule module ) [virtual]

Sets the active loadable module.

Do not forget to call the super function.

Reimplemented from deBaseSystem.

void deScriptingSystem::SetEditMode ( bool  editMode )

Sets if the scripts are executed in edit mode.

In this mode the scripts are reduced to what is required by an editing application. The edit mode can only be changed while the system is not running.

void deScriptingSystem::SetScriptDir ( const char *  scriptDir )

Sets the directory relative to the game directory where the scripts are located.


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