mojira.dev
MC-248198

Error for using a /spreadplayers "under" value lower than the world's minimum height is misleading

The bug

The error for specifying an "under" value in the /spreadplayers command that is less than the minimum world height (-64) is misleading. The error, "Invalid maxHeight -65; expected higher than world minimum -64" uses "higher than", which implies that this value is exclusive. However, the command does allow for inputs equal to the minimum world height.

How to reproduce

  1. Run the command /spreadplayers ~ ~ 2 2 under -64 false @s
    ✔ Command runs successfully

  2. Run the command /spreadplayers ~ ~ 2 2 under -65 false @s
    ❌ Error implies that -64 is excluded from the range of acceptable inputs

Expected behavior

The error message for using an invalid "under" value would imply that "under" values equal to the minimum world height would be valid (for example, by using "at least").

Comments 1

Can confirm in 1.18.2.

markderickson

(Unassigned)

Confirmed

Platform

Low

Commands, Text

22w03a, 1.18.2, 22w17a, 23w06a, 1.19.4, 1.20 Release Candidate 1, 1.20, 23w51b, 1.21.11 Pre-Release 3

Retrieved