mirror of
https://github.com/HIllya51/LunaHook.git
synced 2024-12-28 06:04:12 +08:00
issues/11
This commit is contained in:
parent
3eedd0ec8d
commit
c0d38c25f1
@ -49,7 +49,7 @@ include(generate_product_version)
|
||||
|
||||
set(VERSION_MAJOR 2)
|
||||
set(VERSION_MINOR 10)
|
||||
set(VERSION_PATCH 0)
|
||||
set(VERSION_PATCH 1)
|
||||
set(VERSION_REVISION 0)
|
||||
|
||||
add_subdirectory(include)
|
||||
|
@ -100,6 +100,14 @@ void LunaHost::on_proc_connect(DWORD pid)
|
||||
if(auto pexe=GetModuleFilename(pid))
|
||||
{
|
||||
autoattachexes.insert(WideStringToString(pexe.value()));
|
||||
auto u8procname=WideStringToString(pexe.value());
|
||||
if(savedhookcontext.find(u8procname)!=savedhookcontext.end()){
|
||||
std::string name=safequeryjson(savedhookcontext[u8procname],"name",std::string());
|
||||
if(startWith(name,"UserHook")){
|
||||
if(auto hp=HookCode::Parse(StringToWideString(savedhookcontext[u8procname]["hookcode"])))
|
||||
Host::InsertHook(pid,hp.value());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -253,6 +261,7 @@ LunaHost::LunaHost(){
|
||||
{"hookcode",WideStringToString(tt->hp.hookcode)},
|
||||
{"ctx1",tt->tp.ctx},
|
||||
{"ctx2",tt->tp.ctx2},
|
||||
{"name",WideStringToString(tt->name)}
|
||||
};
|
||||
});
|
||||
menu.add(MenuForgetSelect,[&,tt](){
|
||||
|
Loading…
x
Reference in New Issue
Block a user