a bot that learns to play super mario bros. a work in progress. kinda sucks right now.
Go to file
2019-03-11 07:15:41 +01:00
ars.lua temp 4 2019-03-11 07:15:41 +01:00
Base.lua forgot this 2017-06-30 06:17:26 +00:00
binser.lua temp 4 2019-03-11 07:15:41 +01:00
config.lua temp 3 2019-02-26 21:53:38 +01:00
cossim_test.lua temp 4 2019-03-11 07:15:41 +01:00
eig.lua temp 4 2019-03-11 07:15:41 +01:00
es_test.lua temp 4 2019-03-11 07:15:41 +01:00
expm_test.lua temp 4 2019-03-11 07:15:41 +01:00
expm.lua temp 4 2019-03-11 07:15:41 +01:00
extra.lua temp 2018-06-30 20:13:54 +02:00
gameconfig.lua tweak inputs: add power-up status, remove top/bottom tile rows 2018-06-13 20:18:10 +02:00
guided.lua temp 3 2019-02-26 21:53:38 +01:00
main.lua temp 4 2019-03-11 07:15:41 +01:00
monitor_tiles.lua temp 2018-06-30 20:13:54 +02:00
nn.lua temp 4 2019-03-11 07:15:41 +01:00
pp_test.lua temp 4 2019-03-11 07:15:41 +01:00
presets.lua temp 4 2019-03-11 07:15:41 +01:00
qr_test.lua temp 4 2019-03-11 07:15:41 +01:00
qr.lua temp 4 2019-03-11 07:15:41 +01:00
qr2.lua temp 4 2019-03-11 07:15:41 +01:00
qr3.lua temp 4 2019-03-11 07:15:41 +01:00
README.txt add video link 2018-06-16 01:01:24 +02:00
rescale.lua temp 2018-06-30 20:13:54 +02:00
running.lua temp 2018-06-30 20:13:54 +02:00
seen_tiles.lua temp 2018-06-30 20:13:54 +02:00
serialize.lua temp 2018-06-30 20:13:54 +02:00
sign_test.lua temp 4 2019-03-11 07:15:41 +01:00
smb.lua temp 3 2019-02-26 21:53:38 +01:00
snes.lua temp 3 2019-02-26 21:53:38 +01:00
strict.lua split strictness to its own file 2018-05-03 16:48:12 +02:00
util.lua temp 4 2019-03-11 07:15:41 +01:00
xnes.lua temp 4 2019-03-11 07:15:41 +01:00

this program is largely incomplete and not in a presentable state.
please be mindful when sharing it.
however, feel free to copy any snippets of code you find useful.

video of it in action: https://youtu.be/cD43DWa-3fM

usage:
0. edit config.lua as you please
1. open FCEUX 2.2.3
2. load Super Mario Bros. (U) (CRC32: 3337EC46)
3. open a new Lua script window (it's in the File menu)
4. browse and open main.lua

TODOs: (that i can remember right now)
- normalize `for i=a,b` code style
- normalize and/or embed sprite type inputs
- settle on a network architecture
- compute how many input neurons the network needs instead of hardcoding
- add some detection for enemies later in the game
- fix cfg.enable_overlay (smb.lua doesn't see it being changed)
- maybe log the average distance from init?

naive:
- learn any combination of buttons, starting from title screen
- learn to run network without frameskip
- learn other games