Commit e426a43e authored by Sven's avatar Sven Committed by James
Browse files

add memory hooks for cheat/rumble functionality

parent 64d7d9c3
......@@ -12,6 +12,16 @@ src/common/scm_rev.cpp
.vs/
.vscode/
CMakeLists.txt.user*
src/CMakeCache.txt
src/CMakeFiles/
src/CTestTestfile.cmake
src/Makefile
src/citra_libretro/CMakeCache.txt
src/citra_libretro/CMakeFiles/
src/cmake_install.cmake
src/dist/
src/externals/
src/src/
# *nix related
# Common convention for backup or temporary files
......
......@@ -22,6 +22,8 @@
#include "common/logging/filter.h"
#include "common/string_util.h"
#include "core/core.h"
#include "core/memory.h"
#include "core/hle/kernel/memory.h"
#include "core/loader/loader.h"
#include "core/settings.h"
#include "video_core/renderer_opengl/renderer_opengl.h"
......@@ -513,12 +515,16 @@ bool retro_unserialize(const void* data_, size_t size) {
}
void* retro_get_memory_data(unsigned id) {
(void)id;
if ( id == RETRO_MEMORY_SYSTEM_RAM )
return Kernel::memory_regions[0].linear_heap_memory->data() ;
return NULL;
}
size_t retro_get_memory_size(unsigned id) {
(void)id;
if ( id == RETRO_MEMORY_SYSTEM_RAM )
return Kernel::memory_regions[0].size ;
return 0;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment