diff --git a/ReallifeGamemode.Server/Commands/UserCommands.cs b/ReallifeGamemode.Server/Commands/UserCommands.cs index 18ce329f..09c8dd44 100644 --- a/ReallifeGamemode.Server/Commands/UserCommands.cs +++ b/ReallifeGamemode.Server/Commands/UserCommands.cs @@ -41,13 +41,13 @@ namespace ReallifeGamemode.Server.Commands return; } PositionManager.eventportActive = false; - player.SendChatMessage("Du hast den Eventport deaktiviert."); + player.SendChatMessage("~y~Du hast den Eventport deaktiviert."); return; } if (!PositionManager.eventportActive || PositionManager.eventportPosition == null) { - player.SendChatMessage("Im Moment ist kein Eventport aktiv."); + player.SendChatMessage("~y~Im Moment ist kein Eventport aktiv."); return; } @@ -61,7 +61,14 @@ namespace ReallifeGamemode.Server.Commands } } - player.SafeTeleport(PositionManager.eventportPosition); + Random rnd = new Random(); + int randomX = rnd.Next(-5, 5); + int randomY = rnd.Next(-5, 5); + + Vector3 teleportPosition = new Vector3(PositionManager.eventportPosition.X + randomX, PositionManager.eventportPosition.Y + randomY, PositionManager.eventportPosition.Z); + + player.SafeTeleport(teleportPosition); + player.SendNotification("Du hast dich zum Event teleportiert"); } [Command("look", "~m~look")]