Compare commits

...

2 Commits

Author SHA1 Message Date
kry008 ba30c66dbb more repairs vol 5 2024-06-16 20:49:57 +02:00
kry008 913c12c01d error repair vol 3 2024-06-16 14:33:02 +02:00
5 changed files with 160 additions and 5 deletions

View File

@ -2,7 +2,9 @@
var emojis = [
'😀', '😃', '😄', '😁', '😆', '😅', '😂', '🤣', '😊', '😇', '🙂', '🙃', '😉', '😌', '😍', '🥰', '😘', '😗', '😙', '😚', '😋', '😛', '😝', '😜', '🤪', '🤨', '🧐', '🤓', '😎', '🤩', '🥳', '😏', '😒', '😞', '😔', '😟', '😕', '🙁', '☹️', '😣', '😖', '😫', '😩', '🥺', '😢', '😭', '😤', '😠', '😡', '🤬', '🤯', '😳', '🥵', '🥶', '😱', '😨', '😰', '😥', '😓', '🤗', '🤔', '🤭', '🤫', '🤥', '😶', '😐', '😑', '😬', '🙄', '😯', '😦', '😧', '😮', '😲', '🥱', '😴', '🤤', '😪', '😵', '🤐', '🥴', '🤢', '🤮', '🤧', '😷', '🤒', '🤕', '🤑', '🤠', '😈', '👿', '👹', '👺', '🤡', '💩', '👻', '💀', '☠️', '👽', '👾', '🤖', '🎃', '😺', '😸', '😹', '😻', '😼', '😽', '🙀', '😿', '😾', '🙈', '🙉',
'🙊', '💋', '💌', '💘', '💝', '💖', '💗', '💓', '💞', '💕', '💟', '❣️', '💔', '❤️', '🧡', '💛', '💚', '💙', '💜', '🤎', '🖤', '🤍', '💯', '💢', '💥', '💫', '💦', '💨', '🕳️', '💣', '💬', '👁️‍🗨️', '🗨️', '🗯️', '💭', '💤', '🗣️', '👤', '👥', '👣', '🧠', '🦾', '🦿', '🦻', '🦽', '🦼', '🦷', '🦴', '👀', '👂', '👃', '👅', '👄', '👶', '🧒', '👦', '👧', '🧑', '👱', '👨', '🧔', '👩', '🧓', '👴', '👵', '🙍', '🙎', '🙅', '🙆', '💁', '🙋', '🧏', '🧏‍♂️', '🧏‍♀️', '🙇', '🤦', '🤷', '👮', '🕵️', '💂', '👷', '🤴', '👸', '👳', '👲', '🧕', '🤵', '👰', '🤰', '🤱', '👼', '🎅', '🤶', '🦸', '🦹', '🧙', '🧚', '🧛', '🧜', '🧝', '🧞',
'🧟', '💆', '💇', '🚶', '🧍', '🧎', '🧑‍🦯', '🧑‍🦼', '🧑‍🦽', '🧑‍🦻', '🧑‍🦲', '🧑‍🦱', '🧑‍🦰', '🧑‍🦳', '🧑‍🦰', '🧑‍🦱', '🧑‍🦲', '🧑‍🦽', '🧑‍🦼', '🧑‍🦯', '🧍‍♂️', '🧍‍♀️', '🚶‍♂️', '🚶‍♀️', '💃', '🕺', '🕴️', '👯', '👯‍♂️', '👯‍♀️', '🧖', '🧖‍♂️', '🧖‍♀️', '🧗', '🧗‍♂️', '🧗‍♀️', '🏇', '⛷️', '🏂', '🏌️', '🏌️‍♂️', '🏌️‍♀️', '🏄', '🏄‍♂️', '🏄‍♀️', '🚣', '🚣‍♂️', '🚣‍♀️', '🏊', '🏊‍♂️', '🏊‍♀️', '⛹️', '⛹️‍♂️', '⛹️‍♀️', '🏋️', '🏋️‍♂️', '🏋️‍♀️', '🚴', '🚴‍♂️', '🚴‍♀️', '🚵', '🚵‍'
'🧟', '💆', '💇', '🚶', '🧍', '🧎', '🧑‍🦯', '🧑‍🦼', '🧑‍🦽', '🧑‍🦻', '🧑‍🦲', '🧑‍🦱', '🧑‍🦰', '🧑‍🦳', '🧑‍🦰', '🧑‍🦱', '🧑‍🦲', '🧑‍🦽', '🧑‍🦼', '🧑‍🦯', '🧍‍♂️', '🧍‍♀️', '🚶‍♂️', '🚶‍♀️', '💃', '🕺', '🕴️', '👯', '👯‍♂️', '👯‍♀️', '🧖', '🧖‍♂️', '🧖‍♀️', '🧗', '🧗‍♂️', '🧗‍♀️', '🏇', '⛷️', '🏂', '🏌️', '🏌️‍♂️', '🏌️‍♀️', '🏄', '🏄‍♂️', '🏄‍♀️', '🚣', '🚣‍♂️', '🚣‍♀️', '🏊', '🏊‍♂️', '🏊‍♀️', '⛹️', '⛹️‍♂️', '⛹️‍♀️', '🏋️', '🏋️‍♂️', '🏋️‍♀️', '🚴', '🚴‍♂️', '🚴‍♀️', '🚵', '🚵‍',
'🚵‍♂️', '🚵‍♀️', '🤸', '🤸‍♂️', '🤸‍♀️', '🤼', '🤼‍♂️', '🤼‍♀️', '🤽', '🤽‍♂️', '🤽‍♀️', '🤾', '🤾‍♂️', '🤾‍♀️', '🤹', '🤹‍♂️', '🤹‍♀️', '🧘', '🧘‍♂️', '🧘‍♀️', '🛀', '🛌', '🧑‍🤝‍🧑', '👭', '👫', '👬', '💏', '👨‍❤️‍💋‍👨', '👩‍❤️‍💋‍👩', '💑', '👨‍❤️‍👨', '👩‍❤️‍👩', '👪', '👨‍👩‍👦', '👨‍👩‍👧', '👨‍👩‍👧‍👦', '👨‍👩‍👦‍👦', '👨‍👩‍👧‍👧', '👨‍👨‍👦', '👨‍👨‍👧', '👨‍👨‍👧‍👦', '👨‍👨‍👦‍👦', '👨‍👨‍👧‍👧', '👩‍👩‍👦', '👩‍👩‍👧', '👩', '‍👩‍👧‍👦', '👩‍👩‍👧‍👧', '👩‍👩‍👦‍👦', '👩‍👩‍👧‍👧', '👨‍👦', '👨‍👧', '👨‍👧‍👦', '👨‍👦‍👦', '👨‍👧‍👧', '👩‍👦', '👩‍👧', '👩‍👧‍👦', '👩‍👦‍👦', '👩‍👧‍👧', '🧍‍♂️', '🧍‍♀️', '🧎‍♂️', '🧎‍♀️', '🧑‍🤝‍🧑', '👭', '👫', '👬', '💏', '👨‍❤️‍💋‍👨', '👩‍❤️‍💋‍👩', '💑', '👨‍❤️‍👨', '👩‍❤️‍👩', '👪', '👨‍👩‍👦', '👨‍👩‍👧', '👨‍👩‍👧‍👦', '👨‍👩‍👦‍👦', '👨‍👩‍👧‍👧', '👨‍👨‍👦', '👨‍👨‍👧', '👨‍👨‍👧‍👦', '👨‍👨‍👦‍👦', '👨‍👨‍👧‍👧', '👩‍👩‍👦', '👩‍👩‍👧', '👩‍👩‍👧‍👦', '👩‍👩‍👦‍👦', '👩‍👩‍👧‍👧', '👨‍👦', '👨‍👧', '👨‍👧‍👦', '👨‍👦‍👦', '👨‍👧‍👧', '👩‍👦', '👩‍👧', '👩‍👧‍👦', '👩‍👦‍👦', '👩‍👧‍👧', '🧍‍♂️', '🧍‍♀️', '🧎‍♂️', '🧎‍♀️', '🧑‍🤝‍🧑', '👭', '👫', '👬', '💏', '👨‍❤️‍💋‍👨', '👩‍❤️‍💋‍👩', '💑', '👨‍❤️‍👨', '👩‍❤️‍👩', '👪', '👨‍👩‍👦', '👨‍👩‍👧', '👨‍👩‍👧‍👦', '👨‍👩‍👦‍👦', '👨‍👩‍👧‍👧',
];
function returnEmoji() {
return emojis[Math.floor(Math.random() * emojis.length)];

View File

@ -41,6 +41,16 @@ module.exports = {
message.channel.send('This command can only be used as a slash command.');
},
executeSlash(interaction) {
//check if it is from guild
if (!interaction.guild) {
interaction.reply('This command can only be used in a server.');
return;
}
//check if bot is on this guild
if (!interaction.guild.available) {
interaction.reply('The bot is not available on this server.');
return;
}
//check if the user has the required permissions
if (!interaction.member.permissions.has('ADMINISTRATOR')) {
interaction.reply('You need to have the administrator permission to use this command.');

View File

@ -42,6 +42,16 @@ module.exports = {
message.channel.send('This command can only be used as a slash command.');
},
executeSlash(interaction) {
//check if it is from guild
if (!interaction.guild) {
interaction.reply('This command can only be used in a server.');
return;
}
//check if bot is on this guild
if (!interaction.guild.available) {
interaction.reply('The bot is not available on this server.');
return;
}
//check if the user has the required permissions
if (!interaction.member.permissions.has('ADMINISTRATOR')) {
interaction.reply('You need to have the administrator permission to use this command.');

View File

@ -874,6 +874,134 @@
"Poliwag is the first Water-type Pokémon in the National Pokédex."
],
"img": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/official-artwork/60.png"
},
{
"number": 61,
"name": "Poliwhirl",
"type": [
"Water"
],
"height": "1.0 m",
"weight": "20.0 kg",
"first_appeared": 1,
"some_facts": [
"Poliwhirl is the evolved form of Poliwag."
],
"img": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/official-artwork/61.png"
},
{
"number": 62,
"name": "Poliwrath",
"type": [
"Water",
"Fighting"
],
"height": "1.3 m",
"weight": "54.0 kg",
"first_appeared": 1,
"some_facts": [
"Poliwrath is the evolved form of Poliwhirl."
],
"img": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/official-artwork/62.png"
},
{
"number": 63,
"name": "Abra",
"type": [
"Psychic"
],
"height": "0.9 m",
"weight": "19.5 kg",
"first_appeared": 1,
"some_facts": [
"Abra is the first Psychic-type Pokémon in the National Pokédex."
],
"img": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/official-artwork/63.png"
},
{
"number": 64,
"name": "Kadabra",
"type": [
"Psychic"
],
"height": "1.3 m",
"weight": "56.5 kg",
"first_appeared": 1,
"some_facts": [
"Kadabra is the evolved form of Abra."
],
"img": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/official-artwork/64.png"
},
{
"number": 65,
"name": "Alakazam",
"type": [
"Psychic"
],
"height": "1.5 m",
"weight": "48.0 kg",
"first_appeared": 1,
"some_facts": [
"Alakazam is the evolved form of Kadabra."
],
"img": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/official-artwork/65.png"
},
{
"number": 66,
"name": "Machop",
"type": [
"Fighting"
],
"height": "0.8 m",
"weight": "19.5 kg",
"first_appeared": 1,
"some_facts": [
"Machop is the first Fighting-type Pokémon in the National Pokédex."
],
"img": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/official-artwork/66.png"
},
{
"number": 67,
"name": "Machoke",
"type": [
"Fighting"
],
"height": "1.5 m",
"weight": "70.5 kg",
"first_appeared": 1,
"some_facts": [
"Machoke is the evolved form of Machop."
],
"img": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/official-artwork/67.png"
},
{
"number": 68,
"name": "Machamp",
"type": [
"Fighting"
],
"height": "1.6 m",
"weight": "130.0 kg",
"first_appeared": 1,
"some_facts": [
"Machamp is the evolved form of Machoke."
],
"img": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/official-artwork/68.png"
},
{
"number": 69,
"name": "Bellsprout",
"type": [
"Grass",
"Poison"
],
"height": "0.7 m",
"weight": "4.0 kg",
"first_appeared": 1,
"some_facts": [
"It evolves into Weepinbell starting at level 21, which evolves into Victreebel when exposed to a Leaf Stone"
],
"img": "https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/official-artwork/69.png"
}
]

View File

@ -105,12 +105,17 @@ client.on(Events.InteractionCreate, async interaction => {
if (!command) return;
try {
if(command.admin && !interaction.member.permissions.has(PermissionsBitField.Flags.Administrator)) {
await interaction.reply({ content: 'You do not have permission to use this command!', ephemeral: true });
if (!command.canBeUsedInDm && !interaction.guild) {
await interaction.reply({ content: 'This command can only be used in a server where bot is available.', ephemeral: true });
return;
}
if (!command.canBeUsedInDm && !interaction.guild) {
await interaction.reply({ content: 'This command can only be used in a server!', ephemeral: true });
try {
if(command.admin && !interaction.member.permissions.has(PermissionsBitField.Flags.Administrator)) {
await interaction.reply({ content: 'You do not have permission to use this command!', ephemeral: true });
return;
}
} catch (error) {
interaction.reply('You need to run this command within a server.');
return;
}
if (command.requireKick && !interaction.member.permissions.has(PermissionsBitField.Flags.KickMembers)) {