Package net.citizensnpcs.trait
Class CommandTrait
java.lang.Object
net.citizensnpcs.api.trait.Trait
net.citizensnpcs.trait.CommandTrait
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic enumstatic enumstatic classstatic class -
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintaddCommand(CommandTrait.NPCCommandBuilder builder) voiddescribe(CommandSender sender) Send a brief description of the current state of the trait to the suppliedCommandSender.voiddispatch(Player player, CommandTrait.Hand hand) doublegetCost()floatbooleanhasCommandId(int id) booleanvoidremoveCommandById(int id) voidsetCost(double cost) voidvoidsetExperienceCost(float experienceCost) voidsetHideErrorMessages(boolean hide) voidsetTemporaryPermissions(List<String> permissions)
-
Constructor Details
-
CommandTrait
public CommandTrait()
-
-
Method Details
-
addCommand
-
describe
Send a brief description of the current state of the trait to the suppliedCommandSender. -
dispatch
-
getCost
public double getCost() -
getExecutionMode
-
getExperienceCost
public float getExperienceCost() -
hasCommandId
public boolean hasCommandId(int id) -
isHideErrorMessages
public boolean isHideErrorMessages() -
removeCommandById
public void removeCommandById(int id) -
setCost
public void setCost(double cost) -
setExecutionMode
-
setExperienceCost
public void setExperienceCost(float experienceCost) -
setHideErrorMessages
public void setHideErrorMessages(boolean hide) -
setTemporaryPermissions
-