mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-04-08 23:25:40 +12:00
30 lines
No EOL
684 B
C++
30 lines
No EOL
684 B
C++
#include "services/ac.hpp"
|
|
|
|
namespace ACCommands {
|
|
enum : u32 {
|
|
SetClientVersion = 0x00400042
|
|
};
|
|
}
|
|
|
|
namespace Result {
|
|
enum : u32 {
|
|
Success = 0,
|
|
};
|
|
}
|
|
|
|
void ACService::reset() {}
|
|
|
|
void ACService::handleSyncRequest(u32 messagePointer) {
|
|
const u32 command = mem.read32(messagePointer);
|
|
switch (command) {
|
|
case ACCommands::SetClientVersion: setClientVersion(messagePointer); break;
|
|
default: Helpers::panic("AC service requested. Command: %08X\n", command);
|
|
}
|
|
}
|
|
|
|
void ACService::setClientVersion(u32 messagePointer) {
|
|
u32 version = mem.read32(messagePointer + 4);
|
|
log("AC::SetClientVersion (version = %d)\n", version);
|
|
|
|
mem.write32(messagePointer + 4, Result::Success);
|
|
} |