Interface PortalScript


public interface PortalScript
傳送門腳本的 Java 接口,由 GraalJS 引擎從 scripts/portal/<名稱>.js 解析並實作。

PortalScriptManager 透過 Invocable.getInterface(Class) 取得本接口的實作, 再以 enter(PortalPlayerInteraction)PortalPlayerInteraction 傳入腳本環境(腳本中即為 ppi 全域物件), 使腳本能呼叫傳送、地圖切換等操作。

  • Method Summary

    Modifier and Type
    Method
    Description
    void