Get started with Peachy now 🍑
PEACHYPEACHY
Emote

Shy

The `shy` command allows users to express a shy emotion with a random shy emoji in a Discord server. It can be triggered using the prefixes `P`, `p`, or the slash command `/`.

Command Details

  • Name: shy
  • Aliases: None
  • Category: Emotes
  • Description: Show off your most shy expression with a random shy emoji.
  • Usage: P shy, p shy, or /shy
  • Examples:
    • P shy
    • p shy
    • /shy
  • Cooldown: 3 seconds
  • Arguments: None
  • Slash Command: Enabled
  • Permissions:
    • Bot: SendMessages, ViewChannel, EmbedLinks
    • User: None
  • Player Requirements: None (no voice, DJ, or active player required)

Functionality

  • Selects a random shy emoji from a predefined list (emoji.emotes.shy or globalEmoji.emotes.shy).
  • Displays an embed with:
    • A title with customizable emojis.
    • A description mentioning the user's display name expressing shyness.
    • The selected shy emoji as an image.
    • A footer with the requester's display name and avatar.
  • Supports both prefix-based (P or p) and slash command (/) inputs.
  • Handles errors (e.g., issues with emoji retrieval or message sending) with a custom error message.

Code Overview

The command is built using a Command class structure and handles both message-based and interaction-based (slash command) inputs. It uses:

  • client.utils.getRandomElement to select a random shy emoji.
  • client.embed() to create a formatted embed with dynamic emojis and images.
  • client.utils.emojiToImage to convert the selected emoji into an image for the embed.
  • Language localization for messages and emojis.
  • Error handling for unexpected issues during execution.