diff --git a/exp_scenario/module/commands/_types.lua b/exp_scenario/module/commands/_types.lua index d2ade8fa..94f3e950 100644 --- a/exp_scenario/module/commands/_types.lua +++ b/exp_scenario/module/commands/_types.lua @@ -1,6 +1,7 @@ --[[-- Command Types - Roles The data types that are used with exp_roles +A lower role index indicates it is more privileged Adds parsers for: role @@ -30,7 +31,7 @@ types.lower_role = --- @cast result any TODO role is not a defined type local player_highest = highest_role(player) - if player_highest.index < result.index then + if player_highest.index >= result.index then return invalid{ "exp-commands-parse_role.lower-role" } else return valid(result) @@ -46,7 +47,7 @@ types.lower_role_player = local other_highest = highest_role(result) local player_highest = highest_role(player) - if player_highest.index < other_highest.index then + if player_highest.index >= other_highest.index then return invalid{ "exp-commands-parse_role.lower-role-player" } else return valid(result) @@ -62,7 +63,7 @@ types.lower_role_player_online = local other_highest = highest_role(result) local player_highest = highest_role(player) - if player_highest.index < other_highest.index then + if player_highest.index >= other_highest.index then return invalid{ "exp-commands-parse_role.lower-role-player" } else return valid(result) @@ -78,7 +79,7 @@ types.lower_role_player_alive = local other_highest = highest_role(result) local player_highest = highest_role(player) - if player_highest.index < other_highest.index then + if player_highest.index >= other_highest.index then return invalid{ "exp-commands-parse_role.lower-role-player" } else return valid(result)