jadeite/game_payload/include/game.h

32 lines
647 B
C
Raw Normal View History

2023-06-05 21:23:08 +00:00
#pragma once
#include <windows.h>
enum game_id {
GAME_INVALID,
2023-06-08 15:36:22 +00:00
GAME_HI3_GLB,
GAME_HSR_OS,
GAME_HSR_CN
2023-06-05 21:23:08 +00:00
};
2023-06-08 17:13:21 +00:00
#define INVOKE_CALLBACK(callback, ...) if (callback) { callback(__VA_ARGS__); }
typedef void (*unityplayer_callback_t)(HMODULE unityModule);
2023-06-05 21:23:08 +00:00
struct game_data {
enum game_id id; // Temporary
const char *name;
const char *assembly_name;
2023-06-05 21:23:08 +00:00
const char *tp6_section_name; // Unused for now
const char *tvm_section_name;
2023-06-08 17:13:21 +00:00
unityplayer_callback_t unityplayer_callback;
2023-06-05 21:23:08 +00:00
};
void game_detect(struct game_data *buf);
2023-06-06 18:14:21 +00:00
void hi3_fill_data(struct game_data *buf);
2023-06-08 15:36:22 +00:00
void hsr_fill_data(struct game_data *buf);