Skip to content

Commit

Permalink
Fix incorrect radius check in /me command (EssentialsX#3848)
Browse files Browse the repository at this point in the history
  • Loading branch information
triagonal authored and DarkEyeDragon committed Dec 24, 2020
1 parent ae1cbed commit b6a3cb1
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,13 @@ public void run(final Server server, final User user, final String commandLabel,
message = FormatUtil.formatMessage(user, "essentials.chat", message);

user.setDisplayNick();
final int radius = ess.getSettings().getChatRadius();
long radius = ess.getSettings().getChatRadius();
final String toSend = tl("action", user.getDisplayName(), message);
if (radius < 1) {
ess.broadcastMessage(user, toSend);
return;
}
radius *= radius;

final World world = user.getWorld();
final Location loc = user.getLocation();
Expand Down

0 comments on commit b6a3cb1

Please # to comment.