Skip to content

Commit

Permalink
chore: update messages
Browse files Browse the repository at this point in the history
  • Loading branch information
0utplay committed Sep 9, 2024
1 parent afebc9a commit 9c7acf9
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -584,7 +584,7 @@ public boolean onCommand(CommandSender sender, Command command, String label, St

case "r", "rot", "rotate" -> {
if (args.length < 4) {
sender.sendMessage("§cInvalid usage! Use §6/cn edit rotate <yaw/pitch> <value>§c!");
sender.sendMessage("§cInvalid usage! Use §6/cn edit rotate [~]<yaw/pitch> <value>§c!");
return true;
}

Expand All @@ -598,7 +598,7 @@ public boolean onCommand(CommandSender sender, Command command, String label, St
var position = npc.location();
var value = Doubles.tryParse(input);
if (value == null) {
sender.sendMessage(String.format("§cUnable to parse value from string §6%s§c.", args[3]));
sender.sendMessage(String.format("§cUnable to parse yaw or pitch from input §6%s§c.", args[3]));
return true;
}

Expand All @@ -607,7 +607,7 @@ public boolean onCommand(CommandSender sender, Command command, String label, St
case "yaw" -> {
var yaw = relative ? position.yaw() + value : value;
if (yaw < 0 || yaw > 360) {
sender.sendMessage("§cInvalid argument! Use a value between 0 and 360");
sender.sendMessage("§cInvalid argument! Yaw must be between 0 and 360, got " + yaw);
return true;
}

Expand All @@ -623,7 +623,7 @@ public boolean onCommand(CommandSender sender, Command command, String label, St
case "pitch" -> {
var pitch = relative ? position.pitch() + value : value;
if (pitch < -90 || pitch > 90) {
sender.sendMessage("§cInvalid argument! Use a value between -90 and 90");
sender.sendMessage("§cInvalid argument! Pitch must be between -90 and 90, got " + pitch);
return true;
}

Expand All @@ -637,7 +637,7 @@ public boolean onCommand(CommandSender sender, Command command, String label, St
position.group());
}
default -> {
sender.sendMessage("§cInvalid usage! Use §6/cn edit rotate <yaw/pitch> <value>§c!");
sender.sendMessage("§cInvalid usage! Use §6/cn edit rotate [~]<yaw/pitch> <value>§c!");
return true;
}
}
Expand Down

0 comments on commit 9c7acf9

Please sign in to comment.