jo, ta muzika, ta dává
This commit is contained in:
parent
3da87ed42e
commit
f2530c6754
2149
package-lock.json
generated
2149
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
10
package.json
10
package.json
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "denim_3001",
|
||||
"version": "3001.47.0",
|
||||
"version": "3001.47.1",
|
||||
"description": "Toto je velmi kvalitní bot.",
|
||||
"repository": {
|
||||
"url": "https://github.com/Histmy/Denim-Bot/"
|
||||
@ -14,8 +14,8 @@
|
||||
"author": "Histmy + det-fys",
|
||||
"license": "ISC",
|
||||
"dependencies": {
|
||||
"@discordjs/voice": "^0.14.0",
|
||||
"discord.js": "^14.7.1",
|
||||
"@discordjs/voice": "^0.15.0",
|
||||
"discord.js": "^14.8.0",
|
||||
"js-levenshtein": "^1.1.6",
|
||||
"node-fetch": "^2.6.1",
|
||||
"opusscript": "^0.0.8",
|
||||
@ -24,10 +24,10 @@
|
||||
"tweetnacl": "^1.0.3"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@types/jest": "^29.2.4",
|
||||
"@types/jest": "^29.5.0",
|
||||
"@types/js-levenshtein": "^1.1.1",
|
||||
"@types/node-fetch": "^2.6.2",
|
||||
"jest": "^29.3.1",
|
||||
"jest": "^29.5.0",
|
||||
"ts-node": "^10.9.1",
|
||||
"tsconfig-paths": "^4.1.2"
|
||||
}
|
||||
|
||||
@ -103,7 +103,7 @@ const exp: Modul = {
|
||||
if (!kju) return "nic nehraje";
|
||||
|
||||
const player = getCurrentPlayer(mes.guildId!);
|
||||
player.stop();
|
||||
player?.stop();
|
||||
mes.react(emouty.d3k);
|
||||
}
|
||||
},
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
import { AudioPlayerStatus, AudioResource, createAudioPlayer, createAudioResource, entersState, getVoiceConnection, joinVoiceChannel, PlayerSubscription, StreamType, VoiceConnection, VoiceConnectionStatus } from "@discordjs/voice";
|
||||
import { AudioPlayer, AudioPlayerStatus, AudioResource, createAudioPlayer, createAudioResource, entersState, getVoiceConnection, joinVoiceChannel, PlayerSubscription, StreamType, VoiceConnection, VoiceConnectionStatus } from "@discordjs/voice";
|
||||
import { ChannelType, Client, Guild, StageChannel, User, VoiceChannel } from "discord.js";
|
||||
import { once } from "events";
|
||||
import { JoinHovna, MuzikaFace, SRecord } from "./types";
|
||||
@ -110,7 +110,7 @@ const makeAudioPlayer = (co: string | MuzikaFace | Readable) => {
|
||||
};
|
||||
|
||||
export const play = (conn: VoiceConnection, co: string | string[] | MuzikaFace | MuzikaFace[] | Readable) => new Promise<void>(async (res, rej) => {
|
||||
if (conn.state.status !== VoiceConnectionStatus.Ready) return rej("conn není ready");
|
||||
if (conn.state.status !== VoiceConnectionStatus.Ready) return rej(`conn není ready ale ${conn.state.status}`);
|
||||
|
||||
const player = pripojeni[conn.joinConfig.guildId].player;
|
||||
if (!Array.isArray(co)) {
|
||||
@ -175,7 +175,7 @@ export function adminLog(client: Client, text: string) {
|
||||
}
|
||||
}
|
||||
|
||||
export const getCurrentPlayer = (guildId: string) => pripojeni[guildId]?.player;
|
||||
export const getCurrentPlayer = (guildId: string): AudioPlayer | undefined => pripojeni[guildId]?.player;
|
||||
|
||||
export const configureTimeAnouncment = (guild: string, state: boolean) => { timeAnouncability[guild] = state; };
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user