Skip to main content

A gym-esque environment for Super Smash Bros. Melee.

Project description

melee-env

melee-env wraps the fantastic libmelee as a more gym-esque environment with less boilerplate and setup. Additionally, melee-env provides a convenient and highly flexible framework for creating your own agents. For more information on these topics and melee-env, see the README in the agents folder.

Code example:

from melee import enums
from melee_env.env import MeleeEnv
from melee_env.agents.basic import *
import argparse

players = [Rest(), NOOP(enums.Character.FOX)]

env = MeleeEnv('path/to/iso', players, fast_forward=True)

episodes = 10; reward = 0
env.start()

for episode in range(episodes):
    gamestate, done = env.setup(enums.Stage.BATTLEFIELD)
    while not done:
        for i in range(len(players)):
            players[i].act(gamestate)
        gamestate, done = env.step()

Video Demonstration

IClick me!

This library has been designed with flexibility in mind. The action space, observation space, and the agents are completely modular, and there are only a few requirements to build your own.

Note

This library requires Slippi, which in turn requires an SSBM 1.02 NTSC/PAL ISO. This library does not and will not distribute this. You must acquire this on your own!

Installation

Install from pip: pip install melee-env. Test by running agents_example.py --iso=/path/to/your/iso

Platform support

  • Linux
  • Windows

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

melee-env-0.30.0.tar.gz (13.2 kB view hashes)

Uploaded Source

Built Distribution

melee_env-0.30.0-py3-none-any.whl (15.3 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page