Difference between revisions of "NDGIS"

From Legends of Aria Admin and Modding Wiki
Jump to: navigation, search
 
Line 68: Line 68:
 
{| class="wikitable" | style="width: 60%"
 
{| class="wikitable" | style="width: 60%"
 
|-
 
|-
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">ServerTimeMs()</p> || .
+
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">ServerTimeMs()</p>Returns<br>number - server time in milliseconds || Return the current server time in milliseconds.
 
|}
 
|}
 
</center>
 
</center>
Line 79: Line 79:
 
{| class="wikitable" | style="width: 60%"
 
{| class="wikitable" | style="width: 60%"
 
|-
 
|-
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">SetEvent()</p> || .
+
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">SetEvent()</p>Params<br>key - key unique key identifier<br>value - value string value (ex JSON string) || Redis set command, will create if doesn't exist and overwrite what does exist at given key.
 
|}
 
|}
 
</center>
 
</center>
Line 90: Line 90:
 
{| class="wikitable" | style="width: 60%"
 
{| class="wikitable" | style="width: 60%"
 
|-
 
|-
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">SetLuaDebugLevel()</p> || .
+
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">SetLuaDebugLevel()</p>Params<br>debuglevel - debug level (All,Off,Error,Warning,Information,Verbose) || Set the debug log output level for the lua environment.
 
|}
 
|}
 
</center>
 
</center>
Line 101: Line 101:
 
{| class="wikitable" | style="width: 60%"
 
{| class="wikitable" | style="width: 60%"
 
|-
 
|-
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">SetLuaProfilingEnabled()</p> || .
+
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">SetLuaProfilingEnabled()</p>Params<br>bool - isenabled || Enabled/disable lua profiling.
 
|}
 
|}
 
</center>
 
</center>
Line 112: Line 112:
 
{| class="wikitable" | style="width: 60%"
 
{| class="wikitable" | style="width: 60%"
 
|-
 
|-
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">SortedSetEvent()</p> || .
+
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">SortedSetEvent()</p>Params<br>key - key unique key identifier<br>value - value string value (generally JSON string) || Redis database Sorted Set with automatic timestamp score.
 
|}
 
|}
 
</center>
 
</center>
Line 123: Line 123:
 
{| class="wikitable" | style="width: 60%"
 
{| class="wikitable" | style="width: 60%"
 
|-
 
|-
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">SortedSetScoreEvent()</p> || .
+
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">SortedSetScoreEvent()</p>Params<br>key - key unique key identifier<br>value - value string value(generally JSON string)<br>number - value score value || Redis database Sorted Set with an explicit score value.
 
|}
 
|}
 
</center>
 
</center>
Line 134: Line 134:
 
{| class="wikitable" | style="width: 60%"
 
{| class="wikitable" | style="width: 60%"
 
|-
 
|-
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">ShutdownServer()</p> || .
+
|style="width: 40%"| <p style="color: #DDDD88;font-size: 18px">ShutdownServer()</p> || Shuts the server down.
 
|}
 
|}
 
</center>
 
</center>

Latest revision as of 06:39, 24 November 2019

[Main] [Lua Examples]

A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Global Functions & Examples

SaveSeedGroup()

Params
seedgroup - seed group to save
bool - Should this group be excluded from the list of seed groups that are initially loaded
seedobjectsarray - Array of seed object data in the side table format to the right.
Save seed objects for a specific seed group
table_template = {

Template = templateId,
Position = pos,
Rotation = rot,
Scale = scale,
ObjVarOverrides = { Name = Value, Name = Value ... },
SharedStateOverrides = { Name = Value, Name = Value ... },
}.

Example

 CODE EXAMPLE BLOCK

SaveTemplateData()

Params
templatedata - template table data
categoryname - category name
templatename - template name
Returns
bool - true if save was successful, false if not
Save template data to a template.

Example

 CODE EXAMPLE BLOCK

SendMessageToPlugin()

Params
pluginname - plug-in name to send to
eventid - event identifier name
(...) One or more object arguments to be passed to the plug-in
Sends a message to a C# gameplay plugin.

Example

 CODE EXAMPLE BLOCK

SendRemoteMessage()

Params
regionaddress - target region address
location - target location
range - range around target location
eventid - message to event handler
object - serializable event parameters
Sends a message to all objects at a location on another region server.

Example

 CODE EXAMPLE BLOCK

SendRequestToPlugin()

Params
pluginname - plug-in name to send to
(...) One or more object arguments to be passed to the plug-in
Returns
a single value, or an array of values
Sends a direct request to a C# gameplay plugin.

Example

 CODE EXAMPLE BLOCK

ServerTimeMs()

Returns
number - server time in milliseconds
Return the current server time in milliseconds.

Example

 CODE EXAMPLE BLOCK

SetEvent()

Params
key - key unique key identifier
value - value string value (ex JSON string)
Redis set command, will create if doesn't exist and overwrite what does exist at given key.

Example

 CODE EXAMPLE BLOCK

SetLuaDebugLevel()

Params
debuglevel - debug level (All,Off,Error,Warning,Information,Verbose)
Set the debug log output level for the lua environment.

Example

 CODE EXAMPLE BLOCK

SetLuaProfilingEnabled()

Params
bool - isenabled
Enabled/disable lua profiling.

Example

 CODE EXAMPLE BLOCK

SortedSetEvent()

Params
key - key unique key identifier
value - value string value (generally JSON string)
Redis database Sorted Set with automatic timestamp score.

Example

 CODE EXAMPLE BLOCK

SortedSetScoreEvent()

Params
key - key unique key identifier
value - value string value(generally JSON string)
number - value score value
Redis database Sorted Set with an explicit score value.

Example

 CODE EXAMPLE BLOCK

ShutdownServer()

Shuts the server down.

Example

 CODE EXAMPLE BLOCK