diff --git a/bun.lockb b/bun.lockb index 7a2b872..a2b3ffd 100755 Binary files a/bun.lockb and b/bun.lockb differ diff --git a/package.json b/package.json index a35770e..2d8511a 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,7 @@ "build-talko": "bunx tsc --build tsconfig.talko.json" }, "devDependencies": { - "@types/bun": "^1.1.9", + "@types/bun": "^1.1.11", "@types/dotenv": "^8.2.0", "esbuild": "^0.24.0" }, @@ -16,19 +16,19 @@ "typescript": "^5.6.3" }, "dependencies": { - "@prisma/client": "^5.19.1", + "@prisma/client": "^5.21.0", "@trpc/client": "next", "@trpc/server": "next", - "@types/node": "^20.16.5", + "@types/node": "^20.16.11", "cli-markdown": "^3.4.0", - "discord.js": "^14.16.2", + "discord.js": "^14.16.3", "dotenv": "^16.4.5", "markdown-to-unicode": "^1.0.2", "mpp-client-net": "^1.2.3", - "prisma": "^5.19.1", + "prisma": "^5.21.0", "socket.io-client": "^4.8.0", - "trpc-bun-adapter": "^1.1.2", - "yaml": "^2.5.1", + "trpc-bun-adapter": "^1.2.0", + "yaml": "^2.6.0", "zod": "^3.23.8" } } diff --git a/src/api/behavior/register.ts b/src/api/behavior/register.ts index 68dcdc2..87ff0c6 100644 --- a/src/api/behavior/register.ts +++ b/src/api/behavior/register.ts @@ -2,4 +2,5 @@ export function registerBehaviors() { require("./objects/fish"); require("./objects/kekklefruit"); require("./objects/burger"); + require("./objects/sand"); } diff --git a/src/api/commands/groups/inventory/yeet.ts b/src/api/commands/groups/inventory/yeet.ts index 953bb31..970da99 100644 --- a/src/api/commands/groups/inventory/yeet.ts +++ b/src/api/commands/groups/inventory/yeet.ts @@ -39,11 +39,13 @@ export const yeet = new BehaviorCommand( tryKekGen = true; } + logger.debug("namespace:", bhvNamespace); + const res = await self.behave<"yeet">( { part }, - foundObject.id, + bhvNamespace, async ctx => { logger.debug("stuff"); if (tryKekGen) { diff --git a/src/discord/bot/Bot.ts b/src/discord/bot/Bot.ts index 661978a..b2c6390 100644 --- a/src/discord/bot/Bot.ts +++ b/src/discord/bot/Bot.ts @@ -59,11 +59,16 @@ export class DiscordBot extends EventEmitter { if (!groups) throw "Unable to get command list."; const builders = []; + const seen: string[] = []; for (const group of groups) { for (const command of group.commands) { + const discordCommand = command.aliases[0]; + if (seen.indexOf(discordCommand) !== -1) continue; + const builder = new SlashCommandBuilder(); - builder.setName(command.aliases[0]); + + builder.setName(discordCommand); builder.setDescription(command.description); builder.addStringOption(option => option @@ -71,6 +76,8 @@ export class DiscordBot extends EventEmitter { .setDescription("Command arguments") ); + seen.push(discordCommand); + builders.push(builder); } } diff --git a/src/util/types.d.ts b/src/util/types.d.ts index 49acb7b..dba2782 100644 --- a/src/util/types.d.ts +++ b/src/util/types.d.ts @@ -126,7 +126,7 @@ interface IShopLocation extends ILocation { type TAnyLocation = | ILocation | IFishingLocation - | ISandyFishingLocation + | ISandyLocation | IShopLocation; interface TFisher {