torque Torque Game Engine Documentation
TGE Version 1.5.2

Scripting Engine Callbacks


Detailed Description

The scripting engine makes heavy use of callbacks to represent function exposed to the scripting language.

StringCallback, IntCallback, FloatCallback, VoidCallback, and BoolCallback all represent exposed script functions returning different types.

ConsumerCallback is used with the function Con::addConsumer; functions registered with Con::addConsumer are called whenever something is outputted to the console. For instance, the TelnetConsole registers itself with the console so it can echo the console over the network.

Note:
Callbacks to the scripting language - for instance, onExit(), which is a script function called when the engine is shutting down - are handled using Con::executef() and kin.


Typedefs

typedef const char *(*) StringCallback (SimObject *obj, S32 argc, const char *argv[])
typedef S32(*) IntCallback (SimObject *obj, S32 argc, const char *argv[])
typedef F32(*) FloatCallback (SimObject *obj, S32 argc, const char *argv[])
typedef void(*) VoidCallback (SimObject *obj, S32 argc, const char *argv[])
typedef bool(*) BoolCallback (SimObject *obj, S32 argc, const char *argv[])
typedef void(*) ConsumerCallback (ConsoleLogEntry::Level level, const char *consoleLine)


Typedef Documentation

typedef const char*(*) StringCallback(SimObject *obj, S32 argc, const char *argv[])

typedef S32(*) IntCallback(SimObject *obj, S32 argc, const char *argv[])

typedef F32(*) FloatCallback(SimObject *obj, S32 argc, const char *argv[])

typedef void(*) VoidCallback(SimObject *obj, S32 argc, const char *argv[])

typedef bool(*) BoolCallback(SimObject *obj, S32 argc, const char *argv[])

typedef void(*) ConsumerCallback(ConsoleLogEntry::Level level, const char *consoleLine)




All Rights Reserved GarageGames.com, Inc. 1999-2005
Auto-magically Generated with Doxygen