natiny_script_release
void natiny_script_release(NatinyScript script, NatinyScriptValue value);
Gives back a value kept with natiny_script_hold.
Parameters
| Name | Type | Description |
|---|---|---|
script |
NatinyScript |
The state the value belongs to |
value |
NatinyScriptValue |
The kept value |
Example
NatinyScriptValue on_frame =
natiny_script_hold(script, natiny_script_get(script, "game.on_frame"));
/* ... every frame ... */
natiny_script_call_value(script, on_frame, NULL, 0, NULL, NULL);
/* at shutdown */
natiny_script_release(script, on_frame);