requires

fun requires(predicate: (CommandSourceStack) -> Boolean)

Sets a requirement predicate that must be satisfied for the command to be executable.

Parameters

predicate

A function that takes a CommandSourceStack and returns true if the command should be available to that source