Ult3D
Implementation of "Ultimate 3D Game Engine Design & Architecture" by Allan Sherrod
Loading...
Searching...
No Matches
Ult::GameMonkeyFunction Class Reference

#include <GameMonkey.h>

Public Member Functions

 GameMonkeyFunction ()
 
virtual ~GameMonkeyFunction ()
 
void AddIntParam (int param)
 
void AddFloatParam (float param)
 
void AddStringParam (const std::string &param)
 
void ExecuteCall ()
 
bool GetReturnValueAsInt (int &retVal)
 
bool GetReturnValueAsFloat (float &retVal)
 
bool GetReturnValueAsString (const char *retVal)
 
gmCall * GetCallPtr ()
 

Detailed Description

Wraps a callable function from a GameMonkey script.

Constructor & Destructor Documentation

◆ GameMonkeyFunction()

Ult::GameMonkeyFunction::GameMonkeyFunction ( )
inline

GameMonkeyFunction constructor.

◆ ~GameMonkeyFunction()

virtual Ult::GameMonkeyFunction::~GameMonkeyFunction ( )
inlinevirtual

GameMonkeyFunction destructor.

Member Function Documentation

◆ AddFloatParam()

void Ult::GameMonkeyFunction::AddFloatParam ( float param)
inline

Set the float value of the next parameter used in the next call of this function.

◆ AddIntParam()

void Ult::GameMonkeyFunction::AddIntParam ( int param)
inline

Set the int value of the next parameter used in the next call of this function.

◆ AddStringParam()

void Ult::GameMonkeyFunction::AddStringParam ( const std::string & param)
inline

Set the string value of the next parameter used in the next call of this function.

◆ ExecuteCall()

void Ult::GameMonkeyFunction::ExecuteCall ( )
inline

Call this function with the (if any) previously added parameters.

◆ GetCallPtr()

gmCall * Ult::GameMonkeyFunction::GetCallPtr ( )
inline

Returns a pointer to the GameMonkey library call.

◆ GetReturnValueAsFloat()

bool Ult::GameMonkeyFunction::GetReturnValueAsFloat ( float & retVal)
inline

Attempt to store the return value of this call into retVal.

Returns
True on success, otherwise false.

◆ GetReturnValueAsInt()

bool Ult::GameMonkeyFunction::GetReturnValueAsInt ( int & retVal)
inline

Attempt to store the return value of this call into retVal.

Returns
True on success, otherwise false.

◆ GetReturnValueAsString()

bool Ult::GameMonkeyFunction::GetReturnValueAsString ( const char * retVal)
inline

Attempt to store the return value of this call into retVal.

Returns
True on success, otherwise false.

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