My Project
Public Member Functions | Public Attributes | List of all members
ParaEngine::IObjectScriptingInterface::ScriptCallback Struct Reference

the game object will keep a list of script call backs. More...

#include <IObjectScriptingInterface.h>

Public Member Functions

 ScriptCallback (int type, const std::string &script)
 
void SetScriptFunc (const std::string &script)
 set the script function
 
const std::string & GetCode ()
 
const std::string & GetFileName ()
 
const std::string & GetScriptFunc ()
 
unsigned int GetLastTick () const
 
void SetLastTick (unsigned int nTick)
 
int ActivateAsync (const std::string &code)
 activate the script callback with the given code. More...
 
int ActivateLocalNow (const std::string &script)
 activate the script callback locally now. More...
 

Public Attributes

int func_type
 function type
 
std::string script_func
 the NPL file and function to be activated. More...
 
std::string m_sFilename
 
std::string m_sCode
 
unsigned int m_nLastTick
 last time this function is called.
 

Detailed Description

the game object will keep a list of script call backs.

Member Function Documentation

§ ActivateAsync()

int ParaEngine::IObjectScriptingInterface::ScriptCallback::ActivateAsync ( const std::string &  code)

activate the script callback with the given code.

§ ActivateLocalNow()

int ParaEngine::IObjectScriptingInterface::ScriptCallback::ActivateLocalNow ( const std::string &  script)

activate the script callback locally now.

when function returns, the script has returned.

Member Data Documentation

§ script_func

std::string ParaEngine::IObjectScriptingInterface::ScriptCallback::script_func

the NPL file and function to be activated.

Its format is similar to GUI events. e.g. "(gl)script/NPC1.lua;NPC1.On_Click();"


The documentation for this struct was generated from the following files: