[Commands] Fix Flymode Command Help Prompt (#2669)

This commit is contained in:
Aeadoin
2022-12-22 19:37:54 -05:00
committed by GitHub
parent 2f9a6daab5
commit 5bb27dd4c0
+2 -4
View File
@@ -1,4 +1,5 @@
#include "../client.h"
#include "../../common/data_verification.h"
void command_flymode(Client *c, const Seperator *sep)
{
@@ -13,10 +14,7 @@ void command_flymode(Client *c, const Seperator *sep)
}
auto flymode_id = std::stoul(sep->arg[1]);
if (
flymode_id < EQ::constants::GravityBehavior::Ground &&
flymode_id > EQ::constants::GravityBehavior::LevitateWhileRunning
) {
if (!EQ::ValueWithin(flymode_id, EQ::constants::GravityBehavior::Ground, EQ::constants::GravityBehavior::LevitateWhileRunning)) {
c->Message(Chat::White, "Usage:: #flymode [Flymode ID]");
c->Message(Chat::White, "0 = Ground, 1 = Flying, 2 = Levitating, 3 = Water, 4 = Floating, 5 = Levitating While Running");
return;