A simple, small library for hooking Java methods from C++ without using JVMTI.
JvmStructures.hpp
file to match your target version.
- Intercept method calls
- Get arguments of the intercepted method at runtime
- Change arguments of the intercepted method at runtime
Hook for the setFlySpeed method in Minecraft 1.8.8


Hook for the sendChatMessage method in Minecraft 1.8.8


Step 1: install JDK and include these folders in your project:
java_folder\jdk1.8.0_191\include
java_folder\jdk1.8.0_191\include\win32
java_folder\jdk1.8.0_191\include\win32\bridge
Also, link the jvm.lib
from: java_folder\jdk1.8.0_191\lib.
P.S: Java folder is usually located in C:\Program Files\Java
Step 2: Build udis86 and include it in your project:
Include udis_folder\BuildVS2010\Build\Include
And link libudis86.lib
from udis_folder\BuildVS2010\Build\Lib\x64
P.S: Build is usually located in udis_folder\BuildVS2010\Build
.
Visual Studio 2022 will be used as an example
- Clone the repository to a directory you are comfortable with
- Open your project in Visual Studio, right-click on the project in the Solution Explorer and select "Properties"
- In the "Configuration Properties" section, go to "VC++ Directories", select "Include Directories" and click on the dropdown menu. Click "Edit" and add cloned_repository/include there.
- Done!
x64 Windows 7, 8, 8.1, 10, 11