Give feedback when stepping ticks (#1234)
This commit is contained in:
1 parent
f2989d51fd
commit
212eb07131
1 file changed
+4
-3
@@ -51,10 +51,10 @@ public class TickCommand
|
||||
then(literal("deep").executes( (c)-> setFreeze(c.getSource(), true, true)))).
|
||||
then(literal("off").executes( (c) -> setFreeze(c.getSource(), false, false)))).
|
||||
then(literal("step").
|
||||
executes((c) -> step(1)).
|
||||
executes((c) -> step(c.getSource(), 1)).
|
||||
then(argument("ticks", integer(1,72000)).
|
||||
suggests( (c, b) -> suggestMatching(new String[]{"20"},b)).
|
||||
executes((c) -> step(getInteger(c,"ticks"))))).
|
||||
executes((c) -> step(c.getSource(), getInteger(c,"ticks"))))).
|
||||
then(literal("superHot").executes( (c)-> toggleSuperHot(c.getSource()))).
|
||||
then(literal("health").
|
||||
executes( (c) -> healthReport(c.getSource(), 100)).
|
||||
@@ -130,9 +130,10 @@ public class TickCommand
|
||||
return setFreeze(source, isDeep, !TickSpeed.isPaused());
|
||||
}
|
||||
|
||||
private static int step(int advance)
|
||||
private static int step(ServerCommandSource source, int advance)
|
||||
{
|
||||
TickSpeed.add_ticks_to_run_in_pause(advance);
|
||||
Messenger.m(source, "gi Stepping " + advance + " tick" + (advance != 1 ? "s" : ""));
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user