summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--plugins/timer/init.lua5
-rw-r--r--scripts/src/main.lua4
-rw-r--r--src/emu/emuopts.cpp1
-rw-r--r--src/emu/emuopts.h2
-rw-r--r--src/osd/windows/winmain.cpp1
5 files changed, 11 insertions, 2 deletions
diff --git a/plugins/timer/init.lua b/plugins/timer/init.lua
index 3f833b56eaa..c0f47836398 100644
--- a/plugins/timer/init.lua
+++ b/plugins/timer/init.lua
@@ -12,7 +12,8 @@ exports.author = { name = "Carl" }
local timer = exports
function timer.startplugin()
- local timer_db = "timer/timer.db"
+ local dir = lfs.env_replace(manager:options().entries.homepath:value())
+ local timer_db = dir .. "/timer/timer.db"
local timer_started = false
local total_time = 0
local start_time = 0
@@ -43,7 +44,7 @@ function timer.startplugin()
save()
end
timer_started = true
- lfs.mkdir('timer')
+ lfs.mkdir(dir .. '/timer')
local db = assert(sqlite3.open(timer_db))
local found=false
db:exec([[select * from sqlite_master where name='timer';]], function(...) found=true return 0 end)
diff --git a/scripts/src/main.lua b/scripts/src/main.lua
index 83f39e7487f..c3c4ac235be 100644
--- a/scripts/src/main.lua
+++ b/scripts/src/main.lua
@@ -90,10 +90,14 @@ end
-- Effects and Shaders
configuration { "winstore*" }
files {
+ MAME_DIR .. "artwork/*",
MAME_DIR .. "artwork/**/*",
+ MAME_DIR .. "bgfx/*",
MAME_DIR .. "bgfx/**/*",
MAME_DIR .. "hash/*",
+ MAME_DIR .. "language/*",
MAME_DIR .. "language/**/*",
+ MAME_DIR .. "plugins/*",
MAME_DIR .. "plugins/**/*",
}
configuration "**/*"
diff --git a/src/emu/emuopts.cpp b/src/emu/emuopts.cpp
index d9cde626d01..bf3afc5939f 100644
--- a/src/emu/emuopts.cpp
+++ b/src/emu/emuopts.cpp
@@ -28,6 +28,7 @@ const options_entry emu_options::s_option_entries[] =
// search path options
{ nullptr, nullptr, OPTION_HEADER, "CORE SEARCH PATH OPTIONS" },
+ { OPTION_HOMEPATH, ".", OPTION_STRING, "path to home drictory (read/write) location" },
{ OPTION_MEDIAPATH ";rp;biospath;bp", "roms", OPTION_STRING, "path to ROMsets and hard disk images" },
{ OPTION_HASHPATH ";hash_directory;hash", "hash", OPTION_STRING, "path to hash files" },
{ OPTION_SAMPLEPATH ";sp", "samples", OPTION_STRING, "path to samplesets" },
diff --git a/src/emu/emuopts.h b/src/emu/emuopts.h
index ec0ee216bbe..d8983101a3a 100644
--- a/src/emu/emuopts.h
+++ b/src/emu/emuopts.h
@@ -25,6 +25,7 @@
#define OPTION_WRITECONFIG "writeconfig"
// core search path options
+#define OPTION_HOMEPATH "homepath"
#define OPTION_MEDIAPATH "rompath"
#define OPTION_HASHPATH "hashpath"
#define OPTION_SAMPLEPATH "samplepath"
@@ -214,6 +215,7 @@ public:
bool write_config() const { return bool_value(OPTION_WRITECONFIG); }
// core search path options
+ const char *home_path() const { return value(OPTION_HOMEPATH); }
const char *media_path() const { return value(OPTION_MEDIAPATH); }
const char *hash_path() const { return value(OPTION_HASHPATH); }
const char *sample_path() const { return value(OPTION_SAMPLEPATH); }
diff --git a/src/osd/windows/winmain.cpp b/src/osd/windows/winmain.cpp
index bf34e35b40f..d6fde9d2f7a 100644
--- a/src/osd/windows/winmain.cpp
+++ b/src/osd/windows/winmain.cpp
@@ -439,6 +439,7 @@ windows_options::windows_options()
set_default_value(OPTION_DIFF_DIRECTORY, (osd::text::from_wstring((LPCWSTR)path->Data()) + diff_directory()).c_str());
set_default_value(OPTION_COMMENT_DIRECTORY, (osd::text::from_wstring((LPCWSTR)path->Data()) + comment_directory()).c_str());
+ set_default_value(OPTION_HOMEPATH, osd::text::from_wstring((LPCWSTR)path->Data()).c_str());
set_default_value(OPTION_MEDIAPATH, (osd::text::from_wstring((LPCWSTR)path->Data()) + media_path()).c_str());
#endif
}