Skip to content

Conversation

@ashvin2005
Copy link

๐Ÿ“‹ Description

This PR adds a new /recent slash command that displays the 10 most recent players and their game activity, making it easy for users to see who's been playing and how they performed.

โœจ Features Added

  • ๐ŸŽฎ Recent Players List: Shows the last 10 players who participated in games
  • ๐Ÿ† Player Stats: Displays scores, win counts for each player
  • โฐ Time Tracking: Shows how long ago each player last played (e.g., "5m ago", "2h ago", "3d ago")
  • ๐Ÿฅ‡ Visual Ranking: Medal emojis (๐Ÿฅ‡๐Ÿฅˆ๐Ÿฅ‰) for the top 3 most recent players
  • ๐ŸŽจ TTC Branding: Consistent embed styling matching the bot's theme
  • โšก Fast Performance: Uses existing player data storage, no API calls needed

๐ŸŽฏ Use Cases

  • See who's been active recently
  • Check recent game performances
  • Encourage community engagement
  • Quick overview of player activity

๐Ÿ“ Files Changed

  • commands/recent.js - New command implementation
  • commands/README-recent.md - Complete documentation

๐Ÿงช Testing

  • โœ… Command responds correctly when players exist
  • โœ… Handles empty player list gracefully
  • โœ… Time formatting works for seconds, minutes, hours, and days
  • โœ… Embed displays correctly in Discord
  • โœ… Uses existing storage service (no breaking changes)

๐Ÿ“ธ Example Output

๐Ÿ”ง Technical Details

  • Built with Discord.js v14
  • Uses ES6 modules (consistent with codebase)
  • Integrates with existing storage.js service
  • No new dependencies required
  • Includes error handling

๐Ÿ“š Documentation

Comprehensive README included covering:

  • Feature overview
  • Usage instructions
  • Implementation details
  • Integration guide

๐ŸŽƒ Hacktoberfest 2025

This contribution is part of Hacktoberfest 2025!

โœ… Checklist

  • Code follows project conventions
  • Documentation included
  • No breaking changes
  • Tested functionality
  • ES6 modules format
  • Integrates with existing storage system

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant