Updated all files based on eslintrc
This commit is contained in:
@@ -12,7 +12,7 @@ export = {
|
|||||||
data: new SlashCommandBuilder()
|
data: new SlashCommandBuilder()
|
||||||
.setName("help")
|
.setName("help")
|
||||||
.setDescription("List's all commands usable by a member")
|
.setDescription("List's all commands usable by a member")
|
||||||
.setDMPermission(true),
|
.setDMPermission(false),
|
||||||
|
|
||||||
async execute(interaction, client) {
|
async execute(interaction, client) {
|
||||||
await interaction.deferReply({ ephemeral: true })
|
await interaction.deferReply({ ephemeral: true })
|
||||||
@@ -72,9 +72,7 @@ export = {
|
|||||||
fields: commandList,
|
fields: commandList,
|
||||||
color: embedColor,
|
color: embedColor,
|
||||||
thumbnail: {
|
thumbnail: {
|
||||||
url: interaction?.guild?.iconURL({
|
url: interaction.guild!.iconURL({ forceStatic: true, })!,
|
||||||
forceStatic: true,
|
|
||||||
})!,
|
|
||||||
},
|
},
|
||||||
footer: {
|
footer: {
|
||||||
icon_url: footerIcon!,
|
icon_url: footerIcon!,
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ export async function updateDiscordRoles(
|
|||||||
await interaction.editReply({
|
await interaction.editReply({
|
||||||
embeds: [
|
embeds: [
|
||||||
{
|
{
|
||||||
description: `You do not have permission to use this command.`,
|
description: "You do not have permission to use this command.",
|
||||||
color: embedColor,
|
color: embedColor,
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
@@ -196,7 +196,7 @@ export async function updateDiscordRoles(
|
|||||||
await interaction.editReply({
|
await interaction.editReply({
|
||||||
embeds: [
|
embeds: [
|
||||||
{
|
{
|
||||||
description: `Successfully updated all roles.`,
|
description: "Successfully updated all roles.",
|
||||||
color: embedColor,
|
color: embedColor,
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
|||||||
@@ -4,5 +4,6 @@ export default interface Autocomplete {
|
|||||||
name: string
|
name: string
|
||||||
description: string
|
description: string
|
||||||
type: "autocomplete"
|
type: "autocomplete"
|
||||||
execute: (interaction: AutocompleteInteraction) => Promise<void>
|
// eslint-disable-next-line no-unused-vars
|
||||||
|
execute: (interacion: AutocompleteInteraction) => Promise<void>
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,5 +4,6 @@ export default interface Button {
|
|||||||
name: string
|
name: string
|
||||||
description: string
|
description: string
|
||||||
type: "button"
|
type: "button"
|
||||||
|
// eslint-disable-next-line no-unused-vars
|
||||||
execute: (interaction: ButtonInteraction) => Promise<void>
|
execute: (interaction: ButtonInteraction) => Promise<void>
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -12,8 +12,6 @@ export default interface Command {
|
|||||||
"addSubcommand" | "addSubcommandGroup" | "addIntegerOption"
|
"addSubcommand" | "addSubcommandGroup" | "addIntegerOption"
|
||||||
>
|
>
|
||||||
subcommands?: boolean
|
subcommands?: boolean
|
||||||
execute: (
|
// eslint-disable-next-line no-unused-vars
|
||||||
interaction: ChatInputCommandInteraction,
|
execute: ( interaction: ChatInputCommandInteraction, client: Client,) => Promise<void>
|
||||||
client: Client,
|
|
||||||
) => Promise<void>
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,5 +9,6 @@ export default interface ContextMenu {
|
|||||||
type: "contextmenu"
|
type: "contextmenu"
|
||||||
dev?: boolean
|
dev?: boolean
|
||||||
data: ContextMenuCommandBuilder
|
data: ContextMenuCommandBuilder
|
||||||
|
// eslint-disable-next-line no-unused-vars
|
||||||
execute: (interaction: ContextMenuCommandInteraction) => Promise<void>
|
execute: (interaction: ContextMenuCommandInteraction) => Promise<void>
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,5 +5,6 @@ export default interface Event {
|
|||||||
description: string
|
description: string
|
||||||
type: "event"
|
type: "event"
|
||||||
event: keyof ClientEvents
|
event: keyof ClientEvents
|
||||||
|
// eslint-disable-next-line no-unused-vars
|
||||||
execute(...args: any[]): void
|
execute(...args: any[]): void
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,5 +4,6 @@ export default interface Modal {
|
|||||||
name: string
|
name: string
|
||||||
description: string
|
description: string
|
||||||
type: "modal"
|
type: "modal"
|
||||||
|
// eslint-disable-next-line no-unused-vars
|
||||||
execute: (interaction: ModalSubmitInteraction) => Promise<void>
|
execute: (interaction: ModalSubmitInteraction) => Promise<void>
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,8 +8,6 @@ const client = new Client()
|
|||||||
const redis = new Redis(env.prod.redisURI!)
|
const redis = new Redis(env.prod.redisURI!)
|
||||||
|
|
||||||
class Bot {
|
class Bot {
|
||||||
constructor() {}
|
|
||||||
|
|
||||||
async start() {
|
async start() {
|
||||||
init()
|
init()
|
||||||
client.start()
|
client.start()
|
||||||
|
|||||||
@@ -10,14 +10,14 @@ function getExpForLevel(level: number): number {
|
|||||||
}
|
}
|
||||||
|
|
||||||
switch (respectedLevel) {
|
switch (respectedLevel) {
|
||||||
case 1:
|
case 1:
|
||||||
return 500
|
return 500
|
||||||
case 2:
|
case 2:
|
||||||
return 1000
|
return 1000
|
||||||
case 3:
|
case 3:
|
||||||
return 2000
|
return 2000
|
||||||
case 4:
|
case 4:
|
||||||
return 3500
|
return 3500
|
||||||
}
|
}
|
||||||
return 5000
|
return 5000
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -12,10 +12,10 @@ function getLevel(exp: number): number {
|
|||||||
return exp <= 1
|
return exp <= 1
|
||||||
? 1
|
? 1
|
||||||
: Math.floor(
|
: Math.floor(
|
||||||
1 +
|
1 +
|
||||||
REVERSE_PQ_PREFIX +
|
REVERSE_PQ_PREFIX +
|
||||||
Math.sqrt(REVERSE_CONST + GROWTH_DIVIDES_2 * exp),
|
Math.sqrt(REVERSE_CONST + GROWTH_DIVIDES_2 * exp),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
function hypixelLevel(exp: number): number {
|
function hypixelLevel(exp: number): number {
|
||||||
|
|||||||
Reference in New Issue
Block a user