Index
| Interface | Endpoint | Description |
|---|---|---|
| OpenTips | Client | Open a tip popup |
| CloseTips | Client | Close the tip window |
| RegisterDebugTool | Client | Register a custom debugging tool |
| RegisterPackButton | Client | Register a button for the PC inventory proxy interface |
| CreateFormByJsonId | Client | Create a custom form based on the configuration file |
| CreateTipsTitle | Client | Create and display a tip title |
| CreateEntityChatUI | Client | Create an entity self-talk UI |
| OpenDebugToolMenu | Client | Open the menu for the specified debugging tool |
| CloseDebugToolMenu | Client | Close the menu of an open debugging tool |
| SetNewbieTipsWindow | Client | Set interface description tips |
| OpenMissionPanel | Client | Open the mission interface |
| GetMissionDictListByParentName | Client | Get the mission data list by the parent mission name |
| GetMissionIsAutoRewardByMissionId | Client | Get whether the mission automatically rewards based on the mission ID |
| GetMissionDictById | Client | Get mission data by mission ID |
| RegisterMission | Client | Dynamically register missions |
| UnlockMission | Server | Force unlock a mission |
| CompleteMission | Server | Complete a mission |
| PlayCGToScreen | Client | Play CG in full screen |
| PlayCGToUIControl | Client | Play CG to a UI control |
| OreUIForm | Client | Open the new multi-functional form |
| ItemSelector | Client | Item selector |
OpenTips
Client
-
Description:
Open a tip popup -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| Object | object | The instance returned by the event trigger function, example: clientApi.GetSystem(config.ModName, config.ClientSystemName) |
| Title | str | Title |
| Content | str | Content |
| LeftButtonText | str | Text for the left button |
| LeftButton | str | Name of the function triggered by the left button, default is None (no button displayed) |
| RightButtonText | str | Text for the right button |
| RightButton | str | Name of the function triggered by the right button, default is None (no button displayed) |
| CloseButton | str | Default close button, default is Left; options: Right, None (indicating the left button is close) |
| UIData | dict | Data for this UI, used to control button style, default is {} |
| IsOriginal | str | Whether to open the UI in its native way, default is False (automatically determines the scene) |
-
Return Value:
None -
Example:
self.LA = self.GetLASys('key')
self.LA.OpenTips(self, 'Unable to Set', 'This mod has no content set', LeftButtonText='Got it', LeftButton='CloseTips')
CloseTips
Client
-
Description:
Close the tip window -
Parameters:
None -
Return Value:
None -
Example:
None
RegisterDebugTool
Client
-
Description:
Register a custom debugging tool -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| Name | str | Tool name |
| IconPath | str | Tool icon path |
| Info | str | Tool introduction information, supports rich text |
| Plat | str | Applicable platform |
| Version | str | Version number |
| ToolMenu | dictlist | Tool menu list |
-
Return Value:
None -
Example:
def ClientInit(self):
self.LA.RegisterDebugTool('New Tool', 'textures/ui/research_2', 'Simple Introduction', 'Not supported on IOS', '1.0.0', [
{
'ModName': 'Demo',
'ClientSystemName': 'DemoClientSystem',
'ButtonName': 'Send Message Button',
'FunctionName': 'Msg'
},
{
'ModName': 'Demo',
'ClientSystemName': 'DemoClientSystem',
'ButtonName': 'Pop Up Tip Button',
'FunctionName': 'OpenTips'
}
])
RegisterPackButton
Client
-
Description:
Register a button for the PC inventory proxy interface -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| ButtonName | object | Button name |
| IconPath | str | Icon path, e.g., textures/ui/aaa |
| FunctionInstance | function | Function instance (no parameter input), corresponding to the function shown when the button is triggered |
-
Return Value:
None -
Example:
None
CreateFormByJsonId
Client
-
Description:
Create a custom form based on the configuration file -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| JsonId | str | Configuration component JsonId |
| ExtraData | dict | Additional parameters used to inherit and modify the configuration form, default is None |
-
Return Value:
None -
Example:
self.CreateFormByJsonId('form/output_building_form', {
'Title': 'New Form',
'Content': [
{
'key': 'name',
'type': 'input_text',
'infomation': 'Entity Name'
}
]
})
CreateTipsTitle
Client
-
Description:
Create and display a tip title -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| Content | str | Tip title content |
| SoundName | str | Sound played when the tip title is displayed, default is random.levelup |
-
Return Value:
None -
Example:
None
CreateEntityChatUI
Client
-
Description:
Create entity self-talk UI -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| EntityId | str | Entity ID |
| Content | str | Text content to be spoken |
| StopTimer | float | Close delay, default is 3 |
| SoundName | str | Sound name, default is None |
| Scale | int | Size type, options: 0, 1, default is 1 |
| Offset | tuple | Offset coordinates, default is (0, 1, 0) |
-
Return Value:
Entity UI Object (object) -
Example:
None
OpenDebugToolMenu
Client
-
Description:
Open the specified debugging tool menu -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| DebugDict | dict | Data for the debugging tool |
-
Return Value:
None -
Example:
None
CloseDebugToolMenu
Client
-
Description:
Close the open debugging tool menu -
Parameters:
None -
Return Value:
None -
Example:
None
SetNewbieTipsWindow
Client
-
Description:
Set interface description tips -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| UIObject | object | Interface Object |
| PanelPath | str | Interface path |
| TipsContent | str | Tip content |
| TipsOffsetType | int | Tip position type, options: 0: Center, 1: Top, 2: Bottom, 3: Left, 4: Right |
| CloseFunctionInstance | function | Function instance called after closing the tip |
| ExtraData | dict | Additional data passed to the close function |
-
Return Value:
None -
Example:
None
OpenMissionPanel
Client
-
Description:
Open the mission interface -
Parameters:
None -
Return Value:
None -
Example:
None
GetMissionDictListByParentName
Client
-
Description:
Get the mission data list by the parent mission name -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| ParentName | str | Parent mission name |
-
Return Value:
Mission data list (list) -
Example:
None
GetMissionIsAutoRewardByMissionId
Client
-
Description:
Get whether the mission automatically rewards based on the mission ID -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| MissionId | str | Mission ID |
-
Return Value:
Whether the reward is automatic (bool) -
Example:
None
GetMissionDictById
Client
-
Description:
Get mission data by mission ID -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| MissionId | str | Mission ID |
-
Return Value:
Mission data (dict) -
Example:
None
RegisterMission
Client
-
Description:
Dynamically register missions -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| MissionData | dict, list[dict] | Mission data, if dict, add one, if list, add multiple |
-
Return Value:
None -
Example:
LASystem.RegisterMission({
'Id': 'DoomsZ2-1',
'Parent': 'Chapter 2: The Disaster Stricken',
'LevelType': 0,
'Name': 'Entering the Camp: "Warmth" Bait',
'SubName': 'Sarlika Outskirts · Swallow Camp',
'Position': [23, 65, 16],
'Dimension': 0,
'Information': 'You’re not alive by miracle, but by the next exiled one.
A pile of burning bonfires in the center of the camp, surrounded by a dozen people sitting around it, some roasting wet shoes, others staring at the pot of rice porridge. The air is filled with the smell of cooked food mixed with oil.',
'UnLockCondition': [
{
'ConditionType': 'ALL',
'ConditionList': ['DoomsZ1-2']
}
],
'CompleteFunctionInstance': '',
'IsAutoReward': False,
'RewardList': [
{
'Type': 'MinecraftItem',
'Id': 'minecraft:diamond',
'AuxValue': 0,
'Num': 1,
'Level': 5,
}
]
})
UnlockMission
Server
-
Description:
Force unlock a mission -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| PlayerId | str | Player ID |
| MissionId | str | Mission ID |
-
Return Value:
None -
Example:
None
CompleteMission
Server
-
Description:
Complete a mission -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| PlayerId | str | Player ID |
| MissionId | str | Mission ID |
-
Return Value:
None -
Example:
None
RegisterModSettingConfig
Client
-
Description:
Register mod setting configuration -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| LingmienAetherModName | str | Mod name in InitLingmienAetherMod interface |
| SettingConfigDict | dict | Setting configuration data |
-
Return Value:
None -
Example:
def ClientInit(self):
LASystem.RegisterModSettingConfig('Test', {
'Title': 'Mod Settings',
'ModName': config.ModName,
'ClientSystemName': config.ClientSystemName,
'CloseFunctionName': 'SetModSettingConfig',
'SettingList': [
{
'Name': 'Sub Settings...',
'Key': 'MouseSetting',
'ControlType': 'menu',
'SettingConfigList': {
'Title': 'This is a sub setting',
'ModName': config.ModName,
'ClientSystemName': config.ClientSystemName,
'CloseFunctionName': 'SetModSettingConfig',
'SettingList': [
{
'Name': 'Float Slider',
'Key': 'DemoFloatSlider',
'ControlType': 'slider',
'ValueType': float,
'ValueLimit': [0, 5],
'DefaultValue': 0.35
},
]
}
},
{
'Name': 'Graphics Level',
'Key': 'Qul',
'ControlType': 'button',
'ValueType': list,
'DefaultValue': ['Medium', 'High', 'Low']
},
{
'Name': 'Enable Shadows',
'Key': 'IsShader',
'ControlType': 'button',
'ValueType': bool,
'DefaultValue': True
},
{
'Name': 'Brightness Level',
'Key': 'Light',
'ControlType': 'slider',
'ValueType': int,
'ValueLimit': [0, 100],
'DefaultValue': 0.45
},
]
})
def SetModSettingConfig(self, Data):
print(Data)
PlayCGToScreen
Client
-
Description:
Play CG in full screen -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| TexturePath | str | Folder path of CG images |
| StartPngName | str | Name of the starting image (no number), e.g., firstcg, so the sequence will start with firstcg1 |
| AllNum | int | Total number of sequence images |
| LastPngNum | int | Number of frames for the last sequence image |
| SoundName | str | The sound to be played with the CG |
-
Return Value:
None -
Example:
None
PlayCGToUIControl
Client
-
Description:
Play CG to a UI control -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| UIObject | object | UI object |
| UIPath | str | UI control path |
| TexturePath | str | Folder path of CG images |
| StartPngName | str | Name of the starting image (no number), e.g., firstcg, so the sequence will start with firstcg1 |
| AllNum | int | Total number of sequence images |
| LastPngNum | int | Number of frames for the last sequence image |
| SoundName | str | The sound to be played with the CG |
| CallBackFunctionInstance | function | Callback function instance after the CG finishes (no parameters), default is None |
-
Return Value:
None -
Example:
None
OreUIForm
Client
-
Description:
Open the new multi-functional form -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| FormConfig | list | Form configuration |
| FormData | dict | Pre-set data for the form, default is an empty dictionary |
| Title | str | Title of the form, default is None |
| IsESC | bool | Whether to close the form when the ESC key is pressed, default is True |
| IsIcon | bool | Whether to display item icons, default is False |
| IsChild | bool | Whether it’s a child form, default is False |
| CloseCallBackFunction | function | Function called when the form is closed, default is None |
-
Return Value:
None -
Example:
None
ItemSelector
Client
-
Description:
Item selector -
Parameters:
| Parameter Name | Data Type | Description |
|---|---|---|
| CallBackFunctionIstance | function | Callback function instance (needs to receive item data), default is None |
| ItemNameList | list | Form configuration |
| IsESC | bool | Whether to close the item selector when the ESC key is pressed, default is False |
-
Return Value:
None -
Example:
None