mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-06-07 03:03:15 +00:00
Enable patches on cli builds (#897)
* patch support for cli * fix mac build * format
This commit is contained in:
parent
de183d3b80
commit
ab201398b2
8 changed files with 164 additions and 50 deletions
|
@ -2,6 +2,7 @@
|
|||
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||
|
||||
#include "common/config.h"
|
||||
#include "common/memory_patcher.h"
|
||||
#include "core/file_sys/fs.h"
|
||||
#include "emulator.h"
|
||||
#include "game_install_dialog.h"
|
||||
|
@ -36,6 +37,13 @@ int main(int argc, char* argv[]) {
|
|||
// Check for command line arguments
|
||||
if (has_command_line_argument) {
|
||||
Core::Emulator emulator;
|
||||
for (int i = 0; i < argc; i++) {
|
||||
std::string curArg = argv[i];
|
||||
if (curArg == "-p") {
|
||||
std::string patchFile = argv[i + 1];
|
||||
MemoryPatcher::patchFile = patchFile;
|
||||
}
|
||||
}
|
||||
emulator.Run(argv[1]);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue