diff --git a/server/source/noexs/054e4f4558454000.zip b/server/source/noexs/054e4f4558454000.zip index e8896f4..4e1e081 100644 Binary files a/server/source/noexs/054e4f4558454000.zip and b/server/source/noexs/054e4f4558454000.zip differ diff --git a/server/source/noexs/054e4f4558454000/exefs.nsp b/server/source/noexs/054e4f4558454000/exefs.nsp index fb0ae9b..22b53fb 100644 Binary files a/server/source/noexs/054e4f4558454000/exefs.nsp and b/server/source/noexs/054e4f4558454000/exefs.nsp differ diff --git a/server/source/noexs/exefs.nsp b/server/source/noexs/exefs.nsp index fb0ae9b..22b53fb 100644 Binary files a/server/source/noexs/exefs.nsp and b/server/source/noexs/exefs.nsp differ diff --git a/server/source/noexs/include/gecko.h b/server/source/noexs/include/gecko.h index d0803a5..d8ba1bc 100644 --- a/server/source/noexs/include/gecko.h +++ b/server/source/noexs/include/gecko.h @@ -12,7 +12,7 @@ #define VER_MAJOR (1) #define VER_MINOR (1) -#define VER_PATCH (147) +#define VER_PATCH (148) #define GECKO_BUFFER_SIZE (2048 * 32) #define GECKO_BUFFER_SIZE2 (2048 * 4) diff --git a/server/source/noexs/noexs.nso b/server/source/noexs/noexs.nso index f931ee6..c93a3c1 100644 Binary files a/server/source/noexs/noexs.nso and b/server/source/noexs/noexs.nso differ diff --git a/server/source/noexs/noexs.nsp b/server/source/noexs/noexs.nsp index fb0ae9b..22b53fb 100644 Binary files a/server/source/noexs/noexs.nsp and b/server/source/noexs/noexs.nsp differ diff --git a/server/source/noexs/source/commands.cpp b/server/source/noexs/source/commands.cpp index e91613a..35c4e7f 100644 --- a/server/source/noexs/source/commands.cpp +++ b/server/source/noexs/source/commands.cpp @@ -741,8 +741,27 @@ static Result _getbookmark(Gecko::Context& ctx){ return 0; } //0x1C -static Result _dmnt_pause(Gecko::Context& ctx){ - return dmntchtPauseCheatProcess(); +static Result _putbookmark(Gecko::Context& ctx){ + // printf("_putbookmark\n"); + g_memdumpFile = fopen("/switch/EdiZon/DirectTransfer.bmk", "w+b"); + if (g_memdumpFile == nullptr) + return FILE_ACCESS_ERROR; + WRITE_CHECKED(ctx, 0); + u32 size, len, index; + index = 0; + // do { + READ_CHECKED(ctx, size); + while (size > 0) { + len = (size < GECKO_BUFFER_SIZE) ? size : GECKO_BUFFER_SIZE; + READ_BUFFER_CHECKED(ctx, outbuffer, len); + fseek(g_memdumpFile, index, SEEK_SET); + fwrite(outbuffer, 1, len, g_memdumpFile); + index += len; + size -= len; + } + // } while (size > 0); + fclose(g_memdumpFile); + return 0; } //0x1D static Result _dmnt_resume(Gecko::Context& ctx){ @@ -755,7 +774,7 @@ Result cmd_decode(Gecko::Context& ctx, int cmd){ _querymem_multi, _current_pid, _attached_pid, _list_pids, _get_titleid, _disconnect, _readmem_multi, _set_breakpoint, _freeze_address, _search_local, _fetch_result, _detach_dmnt, _dump_ptr, _attach_dmnt, - _getbookmark, _dmnt_pause, _dmnt_resume}; + _getbookmark, _putbookmark, _dmnt_resume}; Result rc = 0; if(cmds[cmd]){ rc = cmds[cmd](ctx);