public abstract class CommandBlockExecutor extends Object implements CommandOutput
Modifier and Type | Field and Description |
---|---|
private String |
command |
private Text |
customName |
private static SimpleDateFormat |
DATE_FORMAT |
private static Text |
DEFAULT_NAME |
private long |
lastExecution |
private Text |
lastOutput |
private int |
successCount |
private boolean |
trackOutput |
private boolean |
updateLastExecution |
DUMMY
Constructor and Description |
---|
CommandBlockExecutor() |
Modifier and Type | Method and Description |
---|---|
void |
deserialize(CompoundTag tag) |
boolean |
execute(World world) |
String |
getCommand() |
Text |
getCustomName() |
Text |
getLastOutput() |
abstract Vec3d |
getPos() |
abstract ServerCommandSource |
getSource() |
int |
getSuccessCount() |
abstract ServerWorld |
getWorld() |
ActionResult |
interact(PlayerEntity player) |
boolean |
isTrackingOutput() |
abstract void |
markDirty() |
void |
sendSystemMessage(Text message,
UUID senderUuid) |
CompoundTag |
serialize(CompoundTag tag) |
void |
setCommand(String command) |
void |
setCustomName(Text name) |
void |
setLastOutput(Text lastOutput) |
void |
setSuccessCount(int successCount) |
boolean |
shouldBroadcastConsoleToOps() |
boolean |
shouldReceiveFeedback() |
boolean |
shouldTrackOutput() |
void |
shouldTrackOutput(boolean trackOutput) |
private static final SimpleDateFormat DATE_FORMAT
private static final Text DEFAULT_NAME
private long lastExecution
private boolean updateLastExecution
private int successCount
private boolean trackOutput
private String command
private Text customName
public int getSuccessCount()
public void setSuccessCount(int successCount)
public Text getLastOutput()
public CompoundTag serialize(CompoundTag tag)
public void deserialize(CompoundTag tag)
public void setCommand(String command)
public String getCommand()
public boolean execute(World world)
public Text getCustomName()
public void sendSystemMessage(Text message, UUID senderUuid)
sendSystemMessage
in interface CommandOutput
public abstract ServerWorld getWorld()
public abstract void markDirty()
public void shouldTrackOutput(boolean trackOutput)
@Environment(value=CLIENT) public boolean isTrackingOutput()
public ActionResult interact(PlayerEntity player)
@Environment(value=CLIENT) public abstract Vec3d getPos()
public abstract ServerCommandSource getSource()
public boolean shouldReceiveFeedback()
shouldReceiveFeedback
in interface CommandOutput
public boolean shouldTrackOutput()
shouldTrackOutput
in interface CommandOutput
public boolean shouldBroadcastConsoleToOps()
shouldBroadcastConsoleToOps
in interface CommandOutput