2024-08-01

·Visit Project

ELRoyal Tournaments

Create tournaments on Discord and manage them easily.

Table of Contents

Introudction

Create tournaments on Discord and manage them easily.

Tournament Management Commands

  1. /tournament-create - Command

    • Description: Instantiates a comprehensive tournament schema with extensive parameters and metadata, including match format.
    • Parameters:
      • Tournament Title: [Designated Name]
      • Match Format: [1v1 or 2v2]
      • Participants Overview (Varies by Match Format):
        • For 1v1:
          Competitor 1       | Competitor 2
          -------------------+--------------------
          ELRoyal            | Guest
          
        • For 2v2:
          Team 1              | Team 2
          --------------------+--------------------
          ELRoyal, Teammate   | Someone, Someone
          
      • Game Title: [Selected Game] (Permissible Entries: VALORANT, COD, CS2, FORTNITE, APEX LEGENDS, ROBLOX)
      • Event Date: [Date Placeholder] (To Be Determined)
      • Total Enrollments: [Count Placeholder] (Not Applicable until Registration Commencement)
      • Designated Victor: [Winner Placeholder] (To Be Declared Post-Event)
    • Interactive Element:
      • REGISTER Button: Triggers a modal interface requiring users to input their User Tag and Clan Affiliation for enrollment.
    • Image Generation:
      • Utilizes the canvacord library to dynamically generate an image of the tournament table, providing a visually engaging representation of the participants and clan affiliations. The format of the image will adapt based on the selected match format (1v1 or 2v2).
  2. /setwinner - Command

    • Description: Facilitates the modification of tournament metadata to officially designate a victor.
    • Parameters:
      • msgid: [Identifier for the tournament announcement message]
      • usertag: [Tag of the victorious participant]
    • Functionality: Alters the designated message to update the tournament’s winner status and amend the relevant data fields. Updates the associated image generated by canvacord to reflect the new winner.
  3. /tournament-show - Command

    • Description: Presents a curated overview of ongoing and forthcoming tournaments.
    • Output: An integrated summary displaying the status and essential details of all current and scheduled tournaments, including any dynamically generated images of tournament tables.
  4. /tournament-list - Command

    • Description: Delivers a comprehensive catalog of all tournaments that have been instantiated to date.
    • Output: A register enumerating each Tournament Title along with the corresponding Declared Winner.

Profile Management Commands

  1. /setprofile - Command

    • Description: Configures or updates user profiles by delineating game preferences within a structured data repository.
    • Interactive Component:
      • An embedded interface featuring a selection menu for available game options.
      • User selections are persistently stored within a JSON-based datastore. If no preference is indicated, the entry is recorded as NULL.
  2. /viewprofile - Command

    • Description: Retrieves and presents detailed profile information for a specified user.
    • Parameters:
      • userid: [Unique Identifier for the target user profile]
    • Output: An embedded data view showcasing the user’s game preferences and other pertinent profile information.

JSON Schema for Tournament Data

{
  "tournaments": [
    {
      "tournamentId": "string",  // Unique identifier for the tournament
      "title": "string",         // Title of the tournament
      "matchFormat": "string",   // Format of the match (1v1 or 2v2)
      "game": "string",          // Game title (e.g., VALORANT, COD, CS2)
      "date": "string",          // Date of the tournament (ISO 8601 format)
      "totalRegistrations": "number",  // Number of registrations
      "winner": "string",        // UserTag of the winner (if determined)
      "participants": [
        {
          "team": "string",      // Team name or individual participant identifier
          "members": [
            {
              "userTag": "string",   // Discord UserTag of the participant
              "clan": "string"       // Clan name
            }
          ]
        }
      ],
      "imageUrl": "string"       // URL to the generated image of the tournament table
    }
  ]
}

JSON Schema for User Profiles

{
  "profiles": [
    {
      "userId": "string",        // Unique identifier for the user
      "userTag": "string",       // Discord UserTag of the user
      "gamePreferences": [
        {
          "game": "string",      // Game title (e.g., VALORANT, COD)
          "preference": "string" // User's preference level or role
        }
      ]
    }
  ]
}

Explanation

  • Tournaments Collection:

    • tournamentId: A unique string identifier for each tournament.
    • title: The name of the tournament.
    • matchFormat: Indicates whether the tournament is 1v1 or 2v2.
    • game: The title of the game being played.
    • date: The date of the tournament, formatted in ISO 8601.
    • totalRegistrations: The total number of participants registered.
    • winner: The UserTag of the winning participant, if determined.
    • participants: An array of participant objects, each containing:
      • members: An array of members in the team or individual participants with their UserTag and clan.
    • imageUrl: URL to the image generated by canvacord representing the tournament table.
  • Profiles Collection:

    • userId: A unique identifier for each user.
    • userTag: The Discord UserTag of the user.
    • gamePreferences: An array of objects representing the user's game preferences, including:
      • game: The title of the game.
      • preference: The user's preference level or role within the game.

#Tags

discord
bot
json
tournaments

Contact

Need more project details, have any doubts in mind, or interested in working together? Reach out to me directly at krushnavyas066@gmail.com. I'd be happy to connect and talk!

← All Projects