diff --git a/scripts/wayzer/cmds/gatherTp.kts b/scripts/wayzer/cmds/gatherTp.kts index 9a1b7e74..813c48b9 100644 --- a/scripts/wayzer/cmds/gatherTp.kts +++ b/scripts/wayzer/cmds/gatherTp.kts @@ -61,9 +61,9 @@ fun check(unit: Unit, tile: Tile): Boolean { listen { val tile = lastPos ?: return@listen if (it.message.equals("go", true)) { - it.caster.unit()?.apply { + it.player.unit()?.apply { if (!check(this, tile)) { - it.caster.sendMessage("[yellow]目标位置无法安全传送") + it.player.sendMessage("[yellow]目标位置无法安全传送") return@listen } set(tile) diff --git a/scripts/wayzer/user/ext/whiteList.kts b/scripts/wayzer/user/ext/whiteList.kts index 2135588c..69414325 100644 --- a/scripts/wayzer/user/ext/whiteList.kts +++ b/scripts/wayzer/user/ext/whiteList.kts @@ -122,7 +122,8 @@ listenTo { command("login", "统一登录") { attr(ClientOnly) body { - val player = context.caster ?: return@body + val player = player + ?: return@body openMenu(player) } } \ No newline at end of file