Retro-Learning-Environment icon indicating copy to clipboard operation
Retro-Learning-Environment copied to clipboard

Sor2

Open jmichaux opened this issue 7 years ago • 2 comments

Added Streets of Rage 1-3 for 1 and 2 players. Added new function getExtraActions.

jmichaux avatar Dec 26 '17 21:12 jmichaux

Sorry for the late response, been busy lately. Very nice and comprehensive work! Good job finding the ram hack for setting different levels. A long term solution to this problem would be to simply load save states rather than the tedious work of working with predefined actions.

Some comments:

  • use_dfl shouldn't be on by default. Most python users use their own (or Gym's) viewer.
  • I prefer MK's default random position to be true.
  • Regarding the SOR options, what do they mean? please add some documentation.
  • Watch for indentation 1 2 3 4...
  • As far as I remember, in SOR1, there's no meaning to special + direction.
  • What is this testing code?
  • You should handle invalid input: bad character names, difficulties and stages. You can throw an exception with a appropriate error.
  • SOR3 is somewhat broken. Tried "axel" + lvl 5 and "skate" + lvl 8 and both results in episodes ending as they begin more or less.

nadavbh12 avatar Jan 31 '18 11:01 nadavbh12

Thanks for the comments. I can start fixing these bugs some time over the next few days. Here are some comments in response to yours:

  • USE_SDL shouldn't be on. That is my mistake
  • I must have inadvertently changed MK's default random position
  • You are right, special + direction has no meaning in SOR1. I also need to add a note somewhere that using special on the last level can cause severe glitches
  • The testing code was a way to ensure that reaching a terminal state would reset the environment. By constantly fixing the agents health and decreasing the enemies' health I could ensure that my agent would beat a given stage, even if the button presses were random subset of the actions.
  • I though about exception handling, but I figured it would be handled in a gym wrapper. I can add this.
  • SOR3 is a little different than SOR1 and SOR2 because it has in game achievements that determine the later levels. Also, for some difficulty settings, it is impossible to access lvls 5-8 (or 6-8) without a cheat. I'll look more into this.

My ideas for improvement:

  • Simplify the default settings for all three games. A user can choose their character and difficulty, but all of the other settings will be fixed like number of lives, start level (lvl 1) and end level (lvl 8). This would provide more structure and ensure that RLE/gym-rle are conducive to doing repeatable experiments.
  • Add the games to gym-rle.
  • Make a more specialized gym-streets-of-rage that would allow for more creative or one-off experiments.

jmichaux avatar Jan 31 '18 14:01 jmichaux