menu -> visual/menu, conditional compilation
This commit is contained in:
parent
b155f366e3
commit
ed1b252379
@ -22,18 +22,18 @@ proc=${arr[$inst]}
|
|||||||
echo Running instances: "${arr[@]}"
|
echo Running instances: "${arr[@]}"
|
||||||
echo Attaching to "$proc"
|
echo Attaching to "$proc"
|
||||||
|
|
||||||
sudo ./detach $inst bin/libcathook.so
|
sudo ./detach $inst build/bin/libcathook.so
|
||||||
|
|
||||||
if grep -q "$(realpath bin/libcathook.so)" /proc/"$proc"/maps; then
|
if grep -q "$(realpath build/bin/libcathook.so)" /proc/"$proc"/maps; then
|
||||||
echo already loaded
|
echo already loaded
|
||||||
exit
|
exit
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo loading "$(realpath bin/libcathook.so)" to "$proc"
|
echo loading "$(realpath build/bin/libcathook.so)" to "$proc"
|
||||||
gdb -n -q -batch \
|
gdb -n -q -batch \
|
||||||
-ex "attach $proc" \
|
-ex "attach $proc" \
|
||||||
-ex "set \$dlopen = (void*(*)(char*, int)) dlopen" \
|
-ex "set \$dlopen = (void*(*)(char*, int)) dlopen" \
|
||||||
-ex "call \$dlopen(\"$(realpath bin/libcathook.so)\", 1)" \
|
-ex "call \$dlopen(\"$(realpath build/bin/libcathook.so)\", 1)" \
|
||||||
-ex "call dlerror()" \
|
-ex "call dlerror()" \
|
||||||
-ex 'print (char *) $2' \
|
-ex 'print (char *) $2' \
|
||||||
-ex "catch syscall exit exit_group" \
|
-ex "catch syscall exit exit_group" \
|
||||||
|
@ -62,7 +62,9 @@ add_subdirectory(classinfo)
|
|||||||
add_subdirectory(copypasted)
|
add_subdirectory(copypasted)
|
||||||
add_subdirectory(hacks)
|
add_subdirectory(hacks)
|
||||||
add_subdirectory(hooks)
|
add_subdirectory(hooks)
|
||||||
add_subdirectory(menu)
|
|
||||||
add_subdirectory(reclasses)
|
add_subdirectory(reclasses)
|
||||||
add_subdirectory(sdk)
|
add_subdirectory(sdk)
|
||||||
add_subdirectory(visual)
|
|
||||||
|
if(EnableVisuals)
|
||||||
|
add_subdirectory(visual)
|
||||||
|
endif()
|
@ -9,4 +9,6 @@ target_sources(cathook PRIVATE
|
|||||||
"${CMAKE_CURRENT_LIST_DIR}/glez.h"
|
"${CMAKE_CURRENT_LIST_DIR}/glez.h"
|
||||||
"${CMAKE_CURRENT_LIST_DIR}/xoverlay.h")
|
"${CMAKE_CURRENT_LIST_DIR}/xoverlay.h")
|
||||||
|
|
||||||
|
add_subdirectory(menu)
|
||||||
|
|
||||||
target_include_directories(cathook PRIVATE "${CMAKE_CURRENT_LIST_DIR}")
|
target_include_directories(cathook PRIVATE "${CMAKE_CURRENT_LIST_DIR}")
|
@ -46,7 +46,9 @@ add_subdirectory(classinfo)
|
|||||||
add_subdirectory(copypasted)
|
add_subdirectory(copypasted)
|
||||||
add_subdirectory(hacks)
|
add_subdirectory(hacks)
|
||||||
add_subdirectory(hooks)
|
add_subdirectory(hooks)
|
||||||
add_subdirectory(menu)
|
|
||||||
add_subdirectory(reclasses)
|
add_subdirectory(reclasses)
|
||||||
add_subdirectory(sdk)
|
add_subdirectory(sdk)
|
||||||
add_subdirectory(visual)
|
|
||||||
|
if(EnableVisuals)
|
||||||
|
add_subdirectory(visual)
|
||||||
|
endif()
|
@ -61,13 +61,15 @@ uintptr_t CSignature::dwFindPattern(uintptr_t dwAddress, uintptr_t dwLength,
|
|||||||
{
|
{
|
||||||
if (!*pat)
|
if (!*pat)
|
||||||
return firstMatch;
|
return firstMatch;
|
||||||
if (*(uint8_t *) pat == '\?' || *(uint8_t *) pCur == getByte(pat))
|
if (*pat == '\?' || *(uint8_t *) pCur == getByte(pat))
|
||||||
{
|
{
|
||||||
if (!firstMatch)
|
if (!firstMatch)
|
||||||
firstMatch = pCur;
|
firstMatch = pCur;
|
||||||
if (!pat[2])
|
if (!pat[2])
|
||||||
return firstMatch;
|
return firstMatch;
|
||||||
if (*pat == '\?')
|
if (*pat == '\?')
|
||||||
|
pat += 2;
|
||||||
|
else
|
||||||
pat += 3;
|
pat += 3;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -5,4 +5,6 @@ target_sources(cathook PRIVATE
|
|||||||
"${CMAKE_CURRENT_LIST_DIR}/drawing.cpp"
|
"${CMAKE_CURRENT_LIST_DIR}/drawing.cpp"
|
||||||
"${CMAKE_CURRENT_LIST_DIR}/drawmgr.cpp"
|
"${CMAKE_CURRENT_LIST_DIR}/drawmgr.cpp"
|
||||||
"${CMAKE_CURRENT_LIST_DIR}/EffectChams.cpp"
|
"${CMAKE_CURRENT_LIST_DIR}/EffectChams.cpp"
|
||||||
"${CMAKE_CURRENT_LIST_DIR}/EffectGlow.cpp")
|
"${CMAKE_CURRENT_LIST_DIR}/EffectGlow.cpp")
|
||||||
|
|
||||||
|
add_subdirectory(menu)
|
Reference in New Issue
Block a user