diff options
Diffstat (limited to 'Source/RandomizerCore.h')
| -rw-r--r-- | Source/RandomizerCore.h | 15 |
1 files changed, 1 insertions, 14 deletions
| diff --git a/Source/RandomizerCore.h b/Source/RandomizerCore.h index 7ec8e33..27e5724 100644 --- a/Source/RandomizerCore.h +++ b/Source/RandomizerCore.h | |||
| @@ -1,9 +1,6 @@ | |||
| 1 | #pragma once | 1 | #pragma once |
| 2 | #include "Memory.h" | 2 | #include "Memory.h" |
| 3 | 3 | ||
| 4 | // #define GLOBALS 0x5B28C0 | ||
| 5 | #define GLOBALS 0x62A080 | ||
| 6 | |||
| 7 | __declspec(selectany) int SWAP_NONE = 0x0; | 4 | __declspec(selectany) int SWAP_NONE = 0x0; |
| 8 | __declspec(selectany) int SWAP_TARGETS = 0x1; | 5 | __declspec(selectany) int SWAP_TARGETS = 0x1; |
| 9 | __declspec(selectany) int SWAP_LINES = 0x2; | 6 | __declspec(selectany) int SWAP_LINES = 0x2; |
| @@ -20,20 +17,10 @@ public: | |||
| 20 | void ReassignTargets(const std::vector<int>& panels, const std::vector<int>& order, std::vector<int> targets = {}); | 17 | void ReassignTargets(const std::vector<int>& panels, const std::vector<int>& order, std::vector<int> targets = {}); |
| 21 | void ReassignNames(const std::vector<int>& panels, const std::vector<int>& order); | 18 | void ReassignNames(const std::vector<int>& panels, const std::vector<int>& order); |
| 22 | 19 | ||
| 23 | template <class T> | ||
| 24 | std::vector<T> ReadPanelData(int panel, int offset, size_t size) { | ||
| 25 | return _memory.ReadData<T>({GLOBALS, 0x18, panel*8, offset}, size); | ||
| 26 | } | ||
| 27 | |||
| 28 | template <class T> | ||
| 29 | void WritePanelData(int panel, int offset, const std::vector<T>& data) { | ||
| 30 | _memory.WriteData<T>({GLOBALS, 0x18, panel*8, offset}, data); | ||
| 31 | } | ||
| 32 | |||
| 33 | short ReadMetadata(); | 20 | short ReadMetadata(); |
| 34 | void WriteMetadata(short metadata); | 21 | void WriteMetadata(short metadata); |
| 35 | 22 | ||
| 36 | private: | 23 | // private: |
| 37 | Memory _memory = Memory("witness64_d3d11.exe"); | 24 | Memory _memory = Memory("witness64_d3d11.exe"); |
| 38 | }; | 25 | }; |
| 39 | 26 | ||
