| 1203 | template <typename Memory> |
| 1204 | requires std::is_base_of_v<MemoryInterface, Memory> |
| 1205 | void Patch::writeCheat(Memory& memory, ExtendedState& state) |
| 1206 | { |
| 1207 | switch (state.last_type) |
| 1208 | { |
| 1209 | case 0x0: |
| 1210 | memory.IdempotentWrite8(state.prev_cheat_addr, state.iteration_increment & 0xFF); |
| 1211 | break; |
| 1212 | case 0x1: |
| 1213 | memory.IdempotentWrite16(state.prev_cheat_addr, state.iteration_increment & 0xFFFF); |
| 1214 | break; |
| 1215 | case 0x2: |
| 1216 | memory.IdempotentWrite32(state.prev_cheat_addr, state.iteration_increment); |
| 1217 | break; |
| 1218 | default: |
| 1219 | break; |
| 1220 | } |
| 1221 | } |
| 1222 | |
| 1223 | template <typename Memory> |
| 1224 | requires std::is_base_of_v<MemoryInterface, Memory> |
nothing calls this directly
no test coverage detected