我创建了一个这样的结构:
struct Options {
double bindableKeys = 567;
double graphicLocation = 150;
double textures = 300;
};
Options options;
Run Code Online (Sandbox Code Playgroud)
在此声明之后,在另一个进程中,我打开包含该结构的进程并使用结构的双精度搜索字节数组,但未找到任何内容。
要获得结果,我需要std::cout << options.bindableKeys;在声明之后添加类似的内容。然后我从我的模式搜索中得到结果。为什么会有这样的行为?有什么解决办法吗?
最小可重现示例:
struct Options {
double bindableKeys = 567;
double graphicLocation = 150;
double textures = 300;
};
Options options;
while(true) {
double val = options.bindableKeys;
if(val > 10)
std::cout << "test" << std::endl;
}
Run Code Online (Sandbox Code Playgroud)
您可以使用 CheatEngine 或其他模式查找器搜索数组