示例#1
0
文件: Warp.cs 项目: rdebath/MCGalaxy
        public void Goto(Warp warp, Player p)
        {
            if (!p.level.name.CaselessEq(warp.Level))
            {
                PlayerActions.ChangeMap(p, warp.Level);
            }

            if (p.level.name.CaselessEq(warp.Level))
            {
                p.SendPosition(warp.Pos, new Orientation(warp.Yaw, warp.Pitch));
                p.Message("Sent you to waypoint/warp");
            }
            else
            {
                p.Message("Unable to send you to the warp as the map it is on is not loaded.");
            }
        }