Skip to content

Library to expose access for getting and setting the current script instance

License

Notifications You must be signed in to change notification settings

DanEngelbrecht/LuaScriptInstance

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LuaScriptInstance

Library to expose access for getting and setting the current script instance.

Installation

You can use LuaScriptInstance in your own project by adding this project as a Defold library dependency. Open your game.project file and in the dependencies field under project add:

https://github.com/DanEngelbrecht/LuaScriptInstance/archive/master.zip

Or point to the ZIP file of a specific release.

Usage

Once the dependecy is added two Lua functions are available: lua_script_instance.Get() and lua_script_instance.Set(instance)

LuaScriptInstance API

lua_script_instance.Get()

Gets the current script instance. The returned value is an opaque type and you should only use it to set the current instance.

RETURN

  • instance (opaque) - the current script instance

lua_script_instance.Set(instance)

Sets the current script instance. The instance parameters must be a value returned by lua_script_instance.Get().

PARAMETERS

  • instance (opaque) - the script instance to set

About

Library to expose access for getting and setting the current script instance

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages