Don't use names for item suggestions
This commit is contained in:
@@ -28,7 +28,7 @@ import type { WorldgenSetup } from "$/common/generation.ts";
|
||||
import { CYCLE_TICKS, format_clock, time_of_day, TIMES_OF_DAY } from "$/common/time.ts";
|
||||
import { can_place, can_stand_on, display_name, placement_target } from "$/common/utils.ts";
|
||||
import { EXHAUSTION, MAX_HEALTH } from "./vitals.ts";
|
||||
import { item_argument, ModRuntime, run_guarded, type ServerCommandSource } from "./mod_runtime.ts";
|
||||
import { ModRuntime, run_guarded, type ServerCommandSource } from "./mod_runtime.ts";
|
||||
import {
|
||||
argument,
|
||||
choice,
|
||||
@@ -36,6 +36,7 @@ import {
|
||||
CommandError,
|
||||
type CommandNode,
|
||||
integer,
|
||||
item,
|
||||
literal,
|
||||
word,
|
||||
} from "$/common/commands.ts";
|
||||
@@ -953,7 +954,7 @@ export class GameServer {
|
||||
};
|
||||
register(
|
||||
literal<ServerCommandSource>("give").describe("Gives you an item").then(
|
||||
argument<string, ServerCommandSource>("item", item_argument())
|
||||
argument<string, ServerCommandSource>("item", item())
|
||||
.executes((context) => give(context, 1))
|
||||
.then(
|
||||
argument<number, ServerCommandSource>("count", integer(1, MAX_GIVE))
|
||||
|
||||
Reference in New Issue
Block a user