mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-23 19:49:50 +02:00
feat: added command suffix to commands
This commit is contained in:
1 parent
d2d575bd72
commit
423a8b8088
17 files changed
+66
-67
No files matched your search
@@ -10,7 +10,7 @@ import { CommandRegistry } from '../events/interactionCreate/index.js';
|
||||
|
||||
const executionStart = new Date().getTime();
|
||||
|
||||
export default {
|
||||
export const debugCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -42,4 +42,4 @@ export default {
|
||||
]),
|
||||
);
|
||||
},
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -23,7 +23,7 @@ export const SKILLED_CLANS: Record<SkilledClan, string> = {
|
||||
SMRI: 'Samurai',
|
||||
};
|
||||
|
||||
export default {
|
||||
export const eligibleCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: false,
|
||||
@@ -169,4 +169,4 @@ export default {
|
||||
|
||||
return (isEligible ? embedPositive : embedNegative)(title, body);
|
||||
},
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -18,9 +18,9 @@ import evolution from '../renderers/evolution.js';
|
||||
import { StatType } from '../renderers/statsfull.js';
|
||||
import { AccountInfo } from '../types/accountInfo.js';
|
||||
|
||||
export default {
|
||||
export const evolutionCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
|
||||
command: addStatTypeSubCommandGroups(
|
||||
@@ -83,4 +83,4 @@ export default {
|
||||
parseInt(url.searchParams.get('tankId')!),
|
||||
);
|
||||
},
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -8,7 +8,7 @@ import {
|
||||
publicCommands,
|
||||
} from '../events/interactionCreate/index.js';
|
||||
|
||||
export default {
|
||||
export const helpCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -33,4 +33,4 @@ export default {
|
||||
)}\n\n*I am a new bot; I may make mistakes and go offline unexpectedly from time to time.*`,
|
||||
);
|
||||
},
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -16,7 +16,7 @@ import { ClanInfo } from '../types/clanInfo.js';
|
||||
|
||||
const DEFAULT_THRESHOLD = 7;
|
||||
|
||||
export default {
|
||||
export const inactiveCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -85,4 +85,4 @@ export default {
|
||||
},
|
||||
|
||||
autocomplete: autocompleteClan,
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -41,7 +41,7 @@ const COMP_TANKS = [
|
||||
6753, // type 71
|
||||
];
|
||||
|
||||
export default {
|
||||
export const ownedTanksCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -121,4 +121,4 @@ export default {
|
||||
},
|
||||
|
||||
autocomplete: autocompleteUsername,
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -1,7 +1,7 @@
|
||||
import { SlashCommandBuilder } from 'discord.js';
|
||||
import { CommandRegistry } from '../events/interactionCreate/index.js';
|
||||
|
||||
export default {
|
||||
export const pingCommand: CommandRegistry<true> = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -30,4 +30,4 @@ export default {
|
||||
const executionTime = Date.now() - executionStart;
|
||||
interaction.editReply(`Pong 🏓 - ${executionTime}ms`);
|
||||
},
|
||||
} satisfies CommandRegistry<true>;
|
||||
};
|
||||
@@ -16,7 +16,7 @@ import { AccountInfo } from '../types/accountInfo.js';
|
||||
|
||||
type SortBy = 'name' | 'count';
|
||||
|
||||
export default {
|
||||
export const playerAchievementsCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -75,4 +75,4 @@ export default {
|
||||
},
|
||||
|
||||
autocomplete: autocompleteUsername,
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -10,7 +10,7 @@ import { WARGAMING_APPLICATION_ID } from '../core/node/arguments.js';
|
||||
import { CommandRegistry } from '../events/interactionCreate/index.js';
|
||||
import { AccountInfo } from '../types/accountInfo.js';
|
||||
|
||||
export default {
|
||||
export const playerInfoCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -57,4 +57,4 @@ export default {
|
||||
},
|
||||
|
||||
autocomplete: autocompleteUsername,
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -9,7 +9,7 @@ import { WARGAMING_APPLICATION_ID } from '../core/node/arguments.js';
|
||||
import { CommandRegistry } from '../events/interactionCreate/index.js';
|
||||
import { ClanList } from '../types/clanList.js';
|
||||
|
||||
export default {
|
||||
export const searchClansCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -44,4 +44,4 @@ export default {
|
||||
.join('\n')}\n\`\`\``,
|
||||
);
|
||||
},
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -10,7 +10,7 @@ import { WARGAMING_APPLICATION_ID } from '../core/node/arguments.js';
|
||||
import { CommandRegistry } from '../events/interactionCreate/index.js';
|
||||
import { AccountList } from '../types/accountList.js';
|
||||
|
||||
export default {
|
||||
export const searchPlayersCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -52,4 +52,4 @@ export default {
|
||||
}\`\`\``,
|
||||
);
|
||||
},
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -6,7 +6,7 @@ import addTankChoices from '../core/discord/addTankChoices.js';
|
||||
import embedInfo from '../core/discord/embedInfo.js';
|
||||
import { CommandRegistry } from '../events/interactionCreate/index.js';
|
||||
|
||||
export default {
|
||||
export const searchTanksCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -37,4 +37,4 @@ export default {
|
||||
: `\`\`\`\n${results.join('\n')}\n\`\`\``,
|
||||
);
|
||||
},
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -18,9 +18,9 @@ import stats from '../renderers/stats.js';
|
||||
import { StatType } from '../renderers/statsfull.js';
|
||||
import { AccountInfo } from '../types/accountInfo.js';
|
||||
|
||||
export default {
|
||||
export const statsCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
|
||||
command: addStatTypeSubCommandGroups(
|
||||
@@ -81,4 +81,4 @@ export default {
|
||||
parseInt(url.searchParams.get('tankId')!),
|
||||
);
|
||||
},
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -17,7 +17,7 @@ import { CommandRegistry } from '../events/interactionCreate/index.js';
|
||||
import statsfull, { StatType } from '../renderers/statsfull.js';
|
||||
import { AccountInfo } from '../types/accountInfo.js';
|
||||
|
||||
export default {
|
||||
export const statsFullCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -80,4 +80,4 @@ export default {
|
||||
parseInt(url.searchParams.get('tankId')!),
|
||||
);
|
||||
},
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -12,7 +12,7 @@ import { CommandRegistry } from '../events/interactionCreate/index.js';
|
||||
import today from '../renderers/today.js';
|
||||
import { AccountInfo } from '../types/accountInfo.js';
|
||||
|
||||
export default {
|
||||
export const todayCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -49,4 +49,4 @@ export default {
|
||||
|
||||
return await today(player);
|
||||
},
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
@@ -12,7 +12,7 @@ import { CommandRegistry } from '../events/interactionCreate/index.js';
|
||||
import { AccountInfo } from '../types/accountInfo.js';
|
||||
import { PlayerClanData } from '../types/playerClanData.js';
|
||||
|
||||
export default {
|
||||
export const verifyCommand: CommandRegistry = {
|
||||
inProduction: true,
|
||||
inDevelopment: false,
|
||||
inPublic: true,
|
||||
@@ -80,4 +80,4 @@ export default {
|
||||
},
|
||||
|
||||
autocomplete: autocompleteUsername,
|
||||
} satisfies CommandRegistry;
|
||||
};
|
||||
Reference in new issue
Block a user