Index
| Interface | Side | Description |
|---|---|---|
| InitLingmienAetherMod | Server | [Required] Register Lingmien Aether module information |
| BindNextTickFunction | Both Ends | Bind a function to execute on the next tick, can carry parameters required by the function, and resubmitting within the same tick won鈥檛 take effect |
| BindNextTickFunctionAboutUUID | Both Ends | Bind a function to execute on the next tick, can carry parameters required by the function |
| SetIsDisable | Server | Server setting, need to be called directly after server initialization |
| GetServerIsDisable | Client | Get server configuration information |
| AddObjectFunction | Client | Add a function library to the instance |
| GetLingmienAetherManifest | Client | Get the Lingmien Aether function library manifest |
| Notify | Both Ends | Communication between both ends |
| UseServerApi | Client | Use server interfaces |
| UseClientApi | Server | Use client interfaces, but cannot obtain return values |
| GetIsStart | Client | Get whether the player is in the game entry state (i.e., whether they clicked "Single Player" after entering the Lingmien Aether main interface) |
| BindGameHighTickFunction | Client | Bind a high tick function for the game |
| BindMouseWheelFunction | Client | Bind mouse wheel event |
| Lerp | Client | General nonlinear calculation |
| SLerp | Client | Angular nonlinear calculation |
| GetLingmienAetherMod | Server | Get registered Lingmien Aether module data |
| GetTwoPosLength | Both Ends | Get the distance between the target coordinates and the first coordinates |
| DeltaDateTime | Both Ends | Calculate the date difference, FirstDate - SecondDate |
| SplitListByQuantity | Both Ends | Split a list by quantity |
| SortListByNumberMagnitude | Both Ends | Sort a list of Dict elements by numbers -- [{}, {}, ...] |
| SortDictByNumberMagnitude | Both Ends | Sort a dict that consists of Dict elements by numbers -- {'x':{}, 'y':{}, ...} |
| GetDictExtremeValueKey | Both Ends | Get the extreme value corresponding key of a specified key in a Dict -- {'x':float, 'y':float, ...} |
| GetPlatForm | Server | Get the server's runtime environment |
| ConvertUnicodeDictToUtf8 | Both Ends | Convert Unicode encoding in a dictionary to UTF-8 encoding |
| EncryptDict | Server | Encrypt data into a string |
| DecryptDict | Server | Decrypt data |
InitLingmienAetherMod
Server
-
Description
[Required] Register Lingmien Aether module information -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| ModData | dict | Module information |
-
Return Value
None -
Remarks
ModData(dict) Description
| Parameter Name | Data Type | Description |
|---|---|---|
| ModName | str | Module name |
| Version | str | Module version number |
| LogoPath | str | Logo path, starting from textures (optional) |
| Content | str | Module introduction |
Effect Image:

- Example
def __init__(self, namespace, systemName):
...
self.LA = self.GetLASys('Your key here')
@Event.ClientEvent('UiInitFinished')
def UiInitFinished(self, *args):
ModData = {
'ModName': 'Lingmien Aether',
'Version': '1.0.2',
'LogoPath': 'textures/ui/LA/logo_text',
'Content': 'Lingmien Aether'
'\nVersion: 1.0.2'
'\nDevelopers: Da Fei Mian Development Team\n'
'\nLAAPI Mod Manager',
}
self.LA.UseServerApi('InitLingmienAetherMod', [ModData])
BindNextTickFunction
Both Ends
-
Description
Bind a function to execute on the next tick, can carry parameters required by the function; resubmitting within the same tick won鈥檛 take effect. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| FunctionInstance | function | Function, e.g. self.CreateMsg, do not write it as self.CreateMsg() |
| *args | any | Parameters for the bound function |
-
Return Value
None -
Remarks
None -
Example None
BindNextTickFunctionAboutUUID
Both Ends
-
Description
Bind a function to execute on the next tick, can carry parameters required by the function. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| FunctionInstance | function | Function, e.g. self.CreateMsg, do not write it as self.CreateMsg() |
| *args | any | Parameters for the bound function |
-
Return Value
None -
Remarks
None -
Example None
SetIsDisable
Server
-
Description
Server setting, needs to be called directly after server initialization. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| Type | str | Setting type |
| Bool | bool | Whether to enable, default is None |
-
Return Value
The boolean value of the setting (bool) -
Remarks
-
Setting Types:
Parameter Name Data Type Default Value Description AntiCheatUseServerApi bool True Anti-cheat for the online lobby and network game using UseServerApi AntiCheatPing bool True Anti-cheat for weak networks in the online lobby and network game IsStartUI bool True Whether to enable the Lingmien Aether main interface; disabling this will invalidate related interfaces and functions IsLobby bool Auto Whether it is an online lobby or network game environment IsLobbyKick bool False Whether to restrict players from re-entering this room/record -
-
Example
def __init__(self, namespace, systemName):
...
self.LA = self.GetLASys('Your key here')
self.LA.SetIsDisable('IsStartUI', False)
GetServerIsDisable
Client
-
Description
Get server configuration information. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| Type | str | Setting type |
-
Return Value
The boolean value of the setting (bool) -
Remarks
List of Setting Types -
Example None
AddObjectFunction
Client
-
Description
Add a function library to the instance. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| Manifest | list | Function library manifest |
-
Return Value
None -
Remarks
def QuerySet(Value):
pass
Manifest = [
('QuerySet', QuerySet, False, None, None),
...
]
Explanation of tuple
| Parameter Position | Data Type | Description |
|---|---|---|
| 0 | str | Name of the function after addition |
| 1 | function | The function itself after addition |
| 2 | bool | Whether it has a decorator (deprecated, please write as False) |
| 3 | object | Listener decorator (deprecated, please write as None) |
| 4 | str | Event name (deprecated, please write as None) |
- Example None
GetLingmienAetherManifest
Client
-
Description
Get the Lingmien Aether function library manifest. -
Parameters
None -
Return Value
Lingmien Aether function library manifest (list) -
Remarks
Allows direct use of some interfaces in a non-Lingmien Aether client instance; types that require round-trip support between both ends usually are not supported. -
Example
self.LA = self.GetLASys('Your key here')
LingmienAetherManifest = self.LA.GetLingmienAetherManifest()
self.AddObjectFunction(LingmienAetherManifest)
Notify
Both Ends
-
Description
Server Usage: Communication from the server to client events using the Lingmien Aether engine.Client Usage: Communication from the client to server events using the Lingmien Aether engine.
-
Server Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| LAConfig | object | Lingmien Aether script configuration config, used to specify communication for the script system |
| ClientFunctionName | str | The function name of the client system in this Lingmien Aether script configuration |
| DataDict | dict | Communication data |
| PlayerIdList | str, list, None | List of clients for the communication; defaults to None for broadcasting to all players |
| DelayTime | float | How long to delay on failure in communication to the client (in seconds); defaults to None for retrying in the next frame |
- Client Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| LAConfig | object | Lingmien Aether script configuration config, used to specify communication for the script system |
| ServerFunctionName | str | The function name of the server system in this Lingmien Aether script configuration |
| DataDict | dict | Communication data |
-
Return Value
None -
Remarks
This interface automatically optimizes communication efficiency, saving bandwidth. -
Example Broadcasting from server to client
Server Sending
LASystem.Notify(config, 'CustomFunction', {'a': 1})
Client Receiving
def CustomFunction(self, args):
print(args)
# Result will be {'a': 1}
UseServerApi
Client
-
Description
Use server interfaces but cannot obtain return values. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| ApiName | str | Server interface name |
| ArgsList | list | List of server interface parameters |
| OnlyClient | bool | Whether to only call cached data on the client; defaults to False |
-
Return Value
ApiId, used to get return values from the interface (str) -
Remarks
- This interface is prohibited for execution in online lobbies and network games!
- It is recommended to enable
OnlyClientwhen handling large amounts of return data.
-
Example
self.LA = self.GetLASys('Your key here')
ApiId = self.LA.UseServerApi('PlaySound', [playerId, 'random.click'])
# Consider player latency, to avoid not being able to get return values
ApiId = self.LA.UseServerApi('GetItemDictByInv', [playerId, 0, 0])
Ping = self.LA.GetPlayerPing(playerId)
# Since the ping is in milliseconds, use a 0.02 multiplier timer to obtain it
compTimer.AddTimer(0.02 * Ping, self.CallBack, ApiId)
def CallBack(self, ApiId):
# Get the return value
self.LA.GetModRenderAttrByKey(playerId, ApiId)
UseClientApi
Server
-
Description
Use client interfaces but cannot obtain return values. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| ApiName | str | Client interface name |
| ArgsList | list | List of client interface parameters |
| PlayerId | str | Specify client player Id; defaults to None to broadcast to all clients using this interface |
-
Return Value
None -
Remarks
None -
Example None
GetIsStart
Client
-
Description
Get whether the player is in the game entry state (i.e., whether they clicked "Single Player" after entering the Lingmien Aether main interface). -
Parameters
None -
Return Value
Whether the player is in the game entry state (bool) -
Remarks
None -
Example None
BindGameHighTickFunction
Client
-
Description
Bind a high tick function for the game. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| FunctionInstance | function | Function (no parameters), e.g., self.CreateMsg, do not write it as self.CreateMsg() |
| IsAdd | bool | Whether it is adding binding; defaults to True, indicating an addition, otherwise a removal |
-
Return Value
None -
Remarks
The original MC is 20 ticks per second, while the NetEase MC script is 30 ticks per second; this tick is based on the player's current FPS. -
Example
def __init__(self, namespace, systemName):
...
self.LA = self.GetLASys('Your key here')
@Event.ClientEvent('UiInitFinished')
def UiInitFinished(self, *args):
self.LA.BindGameHighTickFunction(self.CreateMsg)
def CreateMsg(self):
self.LA.Msg('High refresh tick')
BindMouseWheelFunction
Client
-
Description
Bind mouse wheel event. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| FunctionInstance | function | Function (with a bool parameter indicating whether it is scrolling up); e.g., self.CreateMsg, do not write it as self.CreateMsg() |
| IsAdd | bool | Whether it is adding binding; defaults to True, indicating an addition, otherwise a removal |
-
Return Value
None -
Remarks
None -
Example None
Lerp
Client
-
Description
General nonlinear calculation. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| Start | float | Starting value |
| End | float | Ending value |
| Factor | float | Nonlinear coefficient |
-
Return Value
Result after linear interpolation (float) -
Remarks
None -
Example None
SLerp
Client
-
Description
Angular nonlinear calculation. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| Start | float | Starting angle |
| End | float | Ending angle |
| Factor | float | Nonlinear coefficient |
-
Return Value
Result after linear interpolation (float) -
Remarks
None -
Example None
GetLingmienAetherMod
Server
-
Description
Get registered Lingmien Aether module data. -
Parameters
None -
Return Value
Lingmien Aether module data (dict) -
Remarks
None -
Example None
GetTwoPosLength
Both Ends
-
Description
Get the distance between the target coordinates and the first coordinates. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| FirstPos | tuple | First 3D coordinates |
| TargetPos | tuple | Target 3D coordinates |
-
Return Value
Distance (float) -
Remarks
None -
Example None
DeltaDateTime
Both Ends
-
Description
Calculate the date difference, FirstDate - SecondDate. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| FirstDate | str | Format: %Y-%m-%d %H:%M:%S |
| SecondDate | str | Format: %Y-%m-%d %H:%M:%S |
-
Return Value
Difference (datetime), <type 'datetime.timedelta'> -
Remarks
None -
Example None
SplitListByQuantity
Both Ends
-
Description
Split a list by quantity. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| List | list | List to be split |
| Number | int | Number of elements per new variable |
-
Return Value
List after processing (list) -
Remarks
None -
Example None
SortListByNumberMagnitude
Both Ends
-
Description
Sort a list of Dict elements by numbers -- [{}, {}, ...]. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| List | list | List to be sorted |
| Key | str | Which key in the list to sort by; fill none if not applicable |
| IsPositiveSequence | bool | Whether it is in ascending order |
-
Return Value
List after processing (list) -
Remarks
None -
Example None
SortDictByNumberMagnitude
Both Ends
-
Description
Sort a dict consisting of Dict elements by numbers -- {'x':{}, 'y':{}, ...}. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| Dict | dict | Dict to be sorted |
| Key | str | Key in the Dict to sort by |
| IsPositiveSequence | bool | Whether it is in ascending order |
| Num | int | How many to sort out |
-
Return Value
List of dict after processing (list) -
Remarks
None -
Example None
GetDictExtremeValueKey
Both Ends
-
Description
Get the extreme value corresponding key of a specified key in a Dict -- {'x':float, 'y':float, ...}. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| Dict | dict | Dict to be accessed |
| Key | str | Target key for comparison; the value of this key in the dict will be compared |
| FindMax | bool | Whether to look for the maximum value; defaults to True |
-
Return Value
Corresponding key of extreme value (any) -
Remarks
None -
Example None
GetPlatForm
Server
-
Description
Get the server's runtime environment. -
Parameters
None -
Return Value
Runtime environment: 0 for Windows; 1 for iOS; 2 for Android; -1 for others, such as online lobbies, Apollo, and other Linux servers (int) -
Remarks
None -
Example None
ConvertUnicodeDictToUtf8
Both Ends
-
Description
Convert Unicode encoding in a dictionary to UTF-8 encoding. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| UnicodeDict | dict | Input dictionary |
-
Return Value
Converted dictionary (dict) -
Remarks
None -
Example None
EncryptDict
Server
-
Description
Encrypt data into a string. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| Data | any | Data |
-
Return Value
Encrypted string (str) -
Remarks
None -
Example
Data = {
'Name': 'Minecraft'
}
LASecret = LASystem.Secret()
SecretData = LASecret.EncryptDict(Data)
print(LASecret.DecryptDict(SecretData))
DecryptDict
Server
-
Description
Decrypt data. -
Parameters
| Parameter Name | Data Type | Description |
|---|---|---|
| Password | str | String of encrypted data |
-
Return Value
Decrypted content, first being the date at encryption, second being the encrypted data (tuple[datetime, any]) -
Remarks
None -
Example
Data = {
'Name': 'Minecraft'
}
LASecret = LASystem.Secret()
SecretData = LASecret.EncryptDict(Data)
print(LASecret.DecryptDict(SecretData))