feat: adapt gmlib 1.0.0

This commit is contained in:
zimuya4153
2025-04-16 17:47:08 +08:00
Unverified
parent 1693ac7290
commit ce7da22e96
10 changed files with 203 additions and 146 deletions
+2 -3
View File
@@ -256,7 +256,7 @@ const GMLIB_API = {
blockPlayerWillDestroy: ll.import("GMLIB_API", "blockPlayerWillDestroy"),
/** 使玩家攻击实体 @type {function(Entity,Player):boolean} */
playerAttack: ll.import("GMLIB_API", "playerAttack"),
/** @type {function(Player,Entity):boolean} */
/** @type {function(Player,Entity):void} */
playerPullInEntity: ll.import("GMLIB_API", "playerPullInEntity"),
/** 根据命令空间获取翻译键名 @type {function(string):string} */
getBlockTranslateKeyFromName: ll.import("GMLIB_API", "getBlockTranslateKeyFromName"),
@@ -2739,10 +2739,9 @@ LLSE_Player.prototype.pullInEntity =
/**
*
* @param {Entity} entity 实体对象
* @returns {boolean}
*/
function (entity) {
return GMLIB_API.playerPullInEntity(this, entity);
GMLIB_API.playerPullInEntity(this, entity);
};
LLSE_Item.prototype.applyEnchant =