diff --git a/Assets/Scripts/Players/LocalPlayer.cs b/Assets/Scripts/Players/LocalPlayer.cs index d6cf360..2404bde 100644 --- a/Assets/Scripts/Players/LocalPlayer.cs +++ b/Assets/Scripts/Players/LocalPlayer.cs @@ -1,5 +1,6 @@ using UnityEngine; using UnityEngine.InputSystem; +using NeonTea.Quakeball.Interface; using NeonTea.Quakeball.Networking; using NeonTea.Quakeball.Networking.Packets; @@ -44,6 +45,14 @@ namespace NeonTea.Quakeball.Players { .With("Down", "/s") .With("Left", "/a") .With("Right", "/d"); + + Terminal.Singleton.RegisterCommand("tp", args => { + if (args.Length != 3) { + return false; + } + transform.position = new Vector3(float.Parse(args[0]), float.Parse(args[1]), float.Parse(args[2])); + return true; + }, "tp x y z - Teleports the local player to the specified coordinates."); } private void Update() {