UNPKG

yoni-mcscripts-lib

Version:

为 Minecraft Script API 中的部分接口创建了 wrapper,并提供简单的事件管理器和任务管理器,另附有一些便于代码编写的一些小工具。

29 lines (28 loc) 1.8 kB
import { YoniWorld } from "./remix/world.js"; import { YoniEntityValue, YoniEntity, YoniPlayer, YoniSimulatedPlayer } from "./types"; import { YoniDimension } from "./remix/dimension.js"; import { Minecraft, Gametest } from "./basis.js"; import { ScoreboardEntry, Objective, Scoreboard } from "./scoreboard.js"; /** * 这个类上的方法用于将各种对象在原始对象与映射对象之间转换。 */ export declare class Yoni { static getVanilla(object: YoniEntityValue): Minecraft.Entity; static getVanilla(object: YoniEntity): Minecraft.Entity; static getVanilla(object: YoniPlayer): Minecraft.Player; static getVanilla(object: YoniSimulatedPlayer): Gametest.SimulatedPlayer; static getVanilla(object: YoniDimension): Minecraft.Dimension; static getVanilla(object: YoniWorld): Minecraft.World; static getVanilla(object: ScoreboardEntry): Minecraft.ScoreboardIdentity; static getVanilla(object: Objective): Minecraft.ScoreboardObjective; static getVanilla(object: typeof Scoreboard): Minecraft.Scoreboard; static getVanilla(object: YoniEntityValue | YoniWorld | ScoreboardEntry | Objective | typeof Scoreboard): Minecraft.Entity | Minecraft.Dimension | Minecraft.World | Minecraft.ScoreboardIdentity | Minecraft.ScoreboardObjective | Minecraft.Scoreboard; static get(object: Minecraft.Entity): YoniEntity; static get(object: Minecraft.Player): YoniPlayer; static get(object: Gametest.SimulatedPlayer): YoniSimulatedPlayer; static get(object: Minecraft.Dimension): YoniDimension; static get(object: Minecraft.World): YoniWorld; static get(object: Minecraft.ScoreboardIdentity): ScoreboardEntry; static get(object: Minecraft.ScoreboardObjective): Objective; static get(object: Minecraft.Scoreboard): typeof Scoreboard; }