Skip to content

Commit

Permalink
Added BizhawkDir variable
Browse files Browse the repository at this point in the history
Added BizhawkDir variable to config for easier setup. Changed absolute paths (C:/Users/..) to use BizhawkDir from config file.
  • Loading branch information
wts42 committed Apr 4, 2018
1 parent bb6e8aa commit 9c920eb
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
11 changes: 10 additions & 1 deletion neat-mario/config.lua
@@ -1,8 +1,17 @@
local _M = {}

--
-- Change BizhawkDir to your BizHawk directory.
--
--_M.BizhawkDir = "C:/Users/mmill/Downloads/BizHawk-2.2/"
_M.BizhawkDir = "X:/BizHawkLab/BizHawk-2.2.2/"

_M.StateDir = _M.BizhawkDir .. "Lua/SNES/neat-mario/state/"
_M.PoolDir = _M.BizhawkDir .. "Lua/SNES/neat-mario/pool/"

_M.NeatConfig = {
--Filename = "DP1.state",
Filename = "C:/Users/mmill/Downloads/BizHawk-2.2/Lua/SNES/neat-mario/pool/DP1.state",
Filename = _M.PoolDir .. "DP1.state",
Population = 300,
DeltaDisjoint = 2.0,
DeltaWeights = 0.4,
Expand Down
4 changes: 2 additions & 2 deletions neat-mario/mario-neat.lua
Expand Up @@ -969,7 +969,7 @@ function flipState()
end

function loadPool()
filename = forms.openfile("DP1.state.pool","C:/Users/mmill/Downloads/BizHawk-2.2/Lua/SNES/neat-mario/pool/")
filename = forms.openfile("DP1.state.pool",config.PoolDir)
--local filename = forms.gettext(saveLoadFile)
forms.settext(saveLoadFile, filename)
loadFile(filename)
Expand Down Expand Up @@ -1001,7 +1001,7 @@ function onExit()
forms.destroy(form)
end

writeFile("C:/Users/mmill/Downloads/BizHawk-2.2/Lua/SNES/neat-mario/pool/temp.pool")
writeFile(config.PoolDir.."temp.pool")

event.onexit(onExit)

Expand Down

0 comments on commit 9c920eb

Please sign in to comment.