mirror of
https://github.com/CitizensDev/Citizens2.git
synced 2024-11-29 22:23:59 +01:00
Fix say in /npc command
This commit is contained in:
parent
58da8489e4
commit
55f8a1f75c
@ -474,8 +474,8 @@ public class CommandTrait extends Trait {
|
|||||||
if (command.startsWith("say")) {
|
if (command.startsWith("say")) {
|
||||||
cmd = "npc speak " + command.replaceFirst("say", "").trim() + " --target <p>";
|
cmd = "npc speak " + command.replaceFirst("say", "").trim() + " --target <p>";
|
||||||
}
|
}
|
||||||
if ((command.startsWith("npc ") || command.startsWith("waypoints ") || command.startsWith("wp "))
|
if ((cmd.startsWith("npc ") || cmd.startsWith("waypoints ") || cmd.startsWith("wp "))
|
||||||
&& !command.contains("--id ")) {
|
&& !cmd.contains("--id ")) {
|
||||||
cmd += " --id <id>";
|
cmd += " --id <id>";
|
||||||
}
|
}
|
||||||
String interpolatedCommand = Placeholders.replace(cmd, clicker, npc);
|
String interpolatedCommand = Placeholders.replace(cmd, clicker, npc);
|
||||||
|
Loading…
Reference in New Issue
Block a user