mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-23 11:39:50 +02:00
feat: we don't talk about it
This commit is contained in:
1 parent
71e1ab1362
commit
8ef355c574
13 files changed
+20
-230
No files matched your search
@@ -16,6 +16,7 @@ export function CommandWrapper({ children, fat }: CommandWrapperProps) {
|
||||
gap: 16,
|
||||
width: '100%',
|
||||
color: theme.colors.textHighContrast,
|
||||
backgroundColor: theme.colors.appBackground1,
|
||||
position: 'relative',
|
||||
}}
|
||||
>
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import { imgur, isFunny } from '@blitzkit/core';
|
||||
import {
|
||||
ActionRowBuilder,
|
||||
AttachmentBuilder,
|
||||
@@ -9,7 +8,6 @@ import {
|
||||
MessageEditOptions,
|
||||
} from 'discord.js';
|
||||
import { InteractionReturnable } from '../../events/interactionCreate';
|
||||
import { theme } from '../../stitches.config';
|
||||
import { Writeable } from '../../types/writable';
|
||||
import { jsxToPngThreaded } from '../blitzkit/jsxToPngThreaded';
|
||||
import { RenderConfiguration } from '../blitzkit/renderConfiguration';
|
||||
@@ -48,78 +46,7 @@ export async function normalizeInteractionReturnable(
|
||||
} else if (item === null) {
|
||||
return;
|
||||
} else {
|
||||
let jsx: JSX.Element;
|
||||
|
||||
if (isFunny()) {
|
||||
const angle = (Math.random() * 2 - 1) * 10;
|
||||
jsx = (
|
||||
<div
|
||||
style={{
|
||||
display: 'flex',
|
||||
transform: `rotate(${angle}deg)`,
|
||||
backgroundColor: theme.colors.appBackground1,
|
||||
position: 'relative',
|
||||
}}
|
||||
>
|
||||
{item}
|
||||
|
||||
<img
|
||||
src={imgur('MWEny5u')}
|
||||
style={{
|
||||
display: 'block',
|
||||
position: 'absolute',
|
||||
top: 250,
|
||||
left: '10%',
|
||||
width: 100,
|
||||
transform: 'translateY(-50%)',
|
||||
backgroundSize: 'contain',
|
||||
backgroundRepeat: 'no-repeat',
|
||||
zIndex: 3,
|
||||
}}
|
||||
/>
|
||||
|
||||
<img
|
||||
src={imgur('SboPMXY')}
|
||||
style={{
|
||||
position: 'absolute',
|
||||
top: 280,
|
||||
width: 80,
|
||||
left: '50%',
|
||||
transform: 'translate(-50%, -50%)',
|
||||
}}
|
||||
/>
|
||||
|
||||
<img
|
||||
src={imgur('MWEny5u')}
|
||||
style={{
|
||||
display: 'block',
|
||||
position: 'absolute',
|
||||
top: 250,
|
||||
right: '10%',
|
||||
width: 100,
|
||||
transform: 'translateY(-50%)',
|
||||
backgroundSize: 'contain',
|
||||
backgroundRepeat: 'no-repeat',
|
||||
zIndex: 3,
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
} else {
|
||||
jsx = (
|
||||
<div
|
||||
style={{
|
||||
display: 'flex',
|
||||
position: 'relative',
|
||||
backgroundColor: theme.colors.appBackground1,
|
||||
}}
|
||||
>
|
||||
{item}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
const image = await jsxToPngThreaded(jsx, renderConfiguration);
|
||||
const image = await jsxToPngThreaded(item, renderConfiguration);
|
||||
images.push([index, image]);
|
||||
}
|
||||
}),
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
import { isFunny } from '@blitzkit/core';
|
||||
import {
|
||||
ActionRowBuilder,
|
||||
AttachmentBuilder,
|
||||
@@ -17,41 +16,11 @@ import { psa } from '../../../core/discord/psa';
|
||||
import { translator } from '../../../core/localization/translator';
|
||||
import { Writeable } from '../../../types/writable';
|
||||
|
||||
const funnyResponses = [
|
||||
"your dwecisions were calculawed buw man, you're bad at math 🥀🥀",
|
||||
'have you consiwered not lacking 😳',
|
||||
'lemme guess... it was your team? 🤬🤬🤬',
|
||||
'confiwence is key. unforwunawely you lost whe lock 🔒💔',
|
||||
"when they say live green, they dwn't mean your 🌳 winrate 🌳",
|
||||
'viewing your swats, hewe? you really are brawe 😎',
|
||||
'no surrie! your numwers are still no bueno 💔💔💔',
|
||||
"i would giwe you awvice, you won'w understand 🥀🥀",
|
||||
"i diwn'w beliewe in negawive numwers unwil i saw your stats 😳😳😳",
|
||||
'wawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawawaw',
|
||||
'https://tenor.com/tre3NETle2e.gif',
|
||||
'https://tenor.com/bVWoA.gif',
|
||||
'https://tenor.com/bARFp.gif',
|
||||
'https://tenor.com/jDFYXtzM27i.gif',
|
||||
'https://tenor.com/dZ6MB62R32r.gif',
|
||||
'https://tenor.com/bqOZf.gif',
|
||||
'https://tenor.com/tD2TjXsmGVx.gif',
|
||||
'https://tenor.com/bya9M.gif',
|
||||
];
|
||||
|
||||
export async function handleChatInputCommand(
|
||||
interaction: ChatInputCommandInteraction<CacheType>,
|
||||
) {
|
||||
await interaction.deferReply();
|
||||
|
||||
if (isFunny()) {
|
||||
const response =
|
||||
funnyResponses[Math.floor(Math.random() * funnyResponses.length)];
|
||||
const waitTime = response.length * 60;
|
||||
|
||||
await interaction.editReply(response);
|
||||
await new Promise((resolve) => setTimeout(resolve, waitTime));
|
||||
}
|
||||
|
||||
const awaitedCommands = await commands;
|
||||
const registry = awaitedCommands[interaction.commandName];
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { assertSecret, isFunny } from '@blitzkit/core';
|
||||
import { assertSecret } from '@blitzkit/core';
|
||||
import { ActivityType, ShardingManager } from 'discord.js';
|
||||
import {
|
||||
discoveredIdsDefinitions,
|
||||
@@ -66,7 +66,7 @@ const interval = setInterval(async () => {
|
||||
for (const guild of client.guilds.cache.values()) {
|
||||
try {
|
||||
const botMember = await guild.members.fetch(client.user.id);
|
||||
await botMember.setNickname(isFunny ? 'FreakKit' : 'BlitzKit');
|
||||
await botMember.setNickname('BlitzKit');
|
||||
} catch {}
|
||||
}
|
||||
},
|
||||
|
||||
Reference in new issue
Block a user