mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-07-24 19:14:40 +00:00
more
This commit is contained in:
parent
f26b74efd8
commit
6d70be9561
@ -63,8 +63,8 @@ Emulator::~Emulator() {
|
||||
Config::saveMainWindow(config_dir / "config.toml");
|
||||
}
|
||||
|
||||
void Emulator::Run(std::filesystem::path file, const std::vector<std::string> args,
|
||||
bool ignore_game_patch) {
|
||||
void Emulator::Run(std::filesystem::path file, const std::vector<std::string> args
|
||||
) {
|
||||
if (std::filesystem::is_directory(file)) {
|
||||
file /= "eboot.bin";
|
||||
}
|
||||
@ -85,7 +85,6 @@ void Emulator::Run(std::filesystem::path file, const std::vector<std::string> ar
|
||||
|
||||
// Applications expect to be run from /app0 so mount the file's parent path as app0.
|
||||
auto* mnt = Common::Singleton<Core::FileSys::MntPoints>::Instance();
|
||||
Core::FileSys::MntPoints::ignore_game_patches = ignore_game_patch;
|
||||
|
||||
mnt->Mount(game_folder, "/app0", true);
|
||||
// Certain games may use /hostapp as well such as CUSA001100
|
||||
|
@ -25,8 +25,7 @@ public:
|
||||
Emulator();
|
||||
~Emulator();
|
||||
|
||||
void Run(std::filesystem::path file, const std::vector<std::string> args = {},
|
||||
bool ignore_game_patch = false);
|
||||
void Run(std::filesystem::path file, const std::vector<std::string> args = {});
|
||||
void UpdatePlayTime(const std::string& serial);
|
||||
|
||||
private:
|
||||
|
@ -28,7 +28,6 @@ int main(int argc, char* argv[]) {
|
||||
Config::load(user_dir / "config.toml");
|
||||
|
||||
bool has_game_argument = false;
|
||||
bool ignore_game_patch = false;
|
||||
std::string game_path;
|
||||
std::vector<std::string> game_args{};
|
||||
|
||||
@ -75,7 +74,7 @@ int main(int argc, char* argv[]) {
|
||||
}
|
||||
}},
|
||||
{"--patch", [&](int& i) { arg_map["-p"](i); }},
|
||||
{"-i", [&](int&) { ignore_game_patch = true; }},
|
||||
{"-i", [&](int&) { Core::FileSys::MntPoints::ignore_game_patches = true; }},
|
||||
{"--ignore-game-patch", [&](int& i) { arg_map["-i"](i); }},
|
||||
{"-f",
|
||||
[&](int& i) {
|
||||
@ -190,7 +189,7 @@ int main(int argc, char* argv[]) {
|
||||
|
||||
// Run the emulator with the resolved eboot path
|
||||
Core::Emulator emulator;
|
||||
emulator.Run(eboot_path, game_args, ignore_game_patch);
|
||||
emulator.Run(eboot_path, game_args);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@ -34,7 +34,6 @@ int main(int argc, char* argv[]) {
|
||||
|
||||
bool has_command_line_argument = argc > 1;
|
||||
bool show_gui = false, has_game_argument = false;
|
||||
bool ignore_game_patch = false;
|
||||
std::string game_path;
|
||||
std::vector<std::string> game_args{};
|
||||
|
||||
@ -87,7 +86,7 @@ int main(int argc, char* argv[]) {
|
||||
}
|
||||
}},
|
||||
{"--patch", [&](int& i) { arg_map["-p"](i); }},
|
||||
{"-i", [&](int&) { ignore_game_patch = true; }},
|
||||
{"-i", [&](int&) { Core::FileSys::MntPoints::ignore_game_patches = true; }},
|
||||
{"--ignore-game-patch", [&](int& i) { arg_map["-i"](i); }},
|
||||
{"-f",
|
||||
[&](int& i) {
|
||||
@ -206,7 +205,7 @@ int main(int argc, char* argv[]) {
|
||||
|
||||
// Run the emulator with the resolved game path
|
||||
Core::Emulator emulator;
|
||||
emulator.Run(game_file_path.string(), game_args, ignore_game_patch);
|
||||
emulator.Run(game_file_path.string(), game_args);
|
||||
if (!show_gui) {
|
||||
return 0; // Exit after running the emulator without showing the GUI
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user