Sets up RPG system as a Redbot cog with core mechanics Implements character creation, class selection, and stat management Adds action commands for attacking and healing Provides inventory and shop functionality for item management Introduces interactive UI menus for user engagement
21 lines
528 B
Python
21 lines
528 B
Python
import discord
|
|
from redbot.core import commands
|
|
from .menu import RPGMenu
|
|
|
|
class RPGCommands(commands.Cog):
|
|
"""
|
|
Handles user commands (primarily menus) for the RPG system.
|
|
"""
|
|
|
|
def __init__(self, rpg_cog, bot):
|
|
self.rpg_cog = rpg_cog
|
|
self.bot = bot
|
|
super().__init__()
|
|
|
|
@commands.command(name="menu")
|
|
async def menu_command(self, ctx):
|
|
"""
|
|
Display the RPG menu.
|
|
"""
|
|
view = RPGMenu(self.rpg_cog)
|
|
await ctx.send("Choose an action:", view=view) |