新增sendInventorySlotPacket接口
This commit is contained in:
+15
-2
@@ -331,7 +331,9 @@ const GMLIB_API = {
|
||||
/** 设置玩家UI栏物品 @type {function(Player,number,Item):void} */
|
||||
setPlayerUIItem: ll.import("GMLIB_API", "setPlayerUIItem"),
|
||||
/** 获取玩家UI栏物品 @type {function(Player,number):Item} */
|
||||
getPlayerUIItem: ll.import("GMLIB_API", "getPlayerUIItem")
|
||||
getPlayerUIItem: ll.import("GMLIB_API", "getPlayerUIItem"),
|
||||
/** 更新玩家容器物品 @type {function(Player,number,number,Item):void} */
|
||||
sendInventorySlotPacket: ll.import("GMLIB_API","sendInventorySlotPacket")
|
||||
}
|
||||
|
||||
/** 静态悬浮字类列表 @type {Map<number,StaticFloatingText>} */
|
||||
@@ -2445,7 +2447,7 @@ LLSE_Player.prototype.setPlayerUIItem =
|
||||
* @param {Item} item 要设置的物品
|
||||
*/
|
||||
function (slot, item) {
|
||||
return GMLIB_API.setPlayerUIItem(this, slot, item);
|
||||
GMLIB_API.setPlayerUIItem(this, slot, item);
|
||||
}
|
||||
|
||||
LLSE_Player.prototype.getPlayerUIItem =
|
||||
@@ -2458,6 +2460,17 @@ LLSE_Player.prototype.getPlayerUIItem =
|
||||
return GMLIB_API.getPlayerUIItem(this, slot);
|
||||
}
|
||||
|
||||
LLSE_Player.prototype.sendInventorySlotPacket =
|
||||
/**
|
||||
* 发送更新更新物品数据包
|
||||
* @param {number} containerId 容器ID
|
||||
* @param {number} slot 格子槽位
|
||||
* @param {Item} item 物品对象
|
||||
*/
|
||||
function (containerId, slot, item) {
|
||||
GMLIB_API.sendInventorySlotPacket(this, containerId, slot, item);
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
StaticFloatingText,
|
||||
DynamicFloatingText,
|
||||
|
||||
Reference in New Issue
Block a user