Skip to content
This repository was archived by the owner on Jun 6, 2022. It is now read-only.

Commit 703b162

Browse files
author
sprogcoder
committed
2 parents 2448bee + f0c9330 commit 703b162

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

README.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,36 @@
11
Java Memory Trainer Library (Windows)
22
=====================================
3+
A simple Java library used to Read and Write Memory from a Windows process, written using the Java Native Access and Google Guava api.
4+
5+
6+
Usage
7+
-----
8+
Basic example:
9+
```java
10+
// Relative memory address inside process
11+
final int MEMORY_ADDRESS = 0x00010ABF;
12+
13+
// Create JTrainer instance for Minesweeper process (window name)
14+
JTrainer jTrainer = new JTrainer(null, "Minesweeper");
15+
16+
// Write 4 bytes as hex 0x90 (nop) to process
17+
jTrainer.writeProcessMemory(MEMORY_ADDRESS, new int[] { 0x90, 0x90, 0x90, 0x90 });
18+
19+
// Read 4 bytes from process and print out the result
20+
byte[] bytes = jTrainer.readProcessMemory(MEMORY_ADDRESS, 4);
21+
System.out.println(Arrays.toString(MemoryUtils.convertByteArrayToHex(bytes));
22+
```
323

424
License
525
-------
626
The code in this project is licensed under the Apache
727
Software License 2.0, per the terms of the included LICENSE
828
file.
29+
30+
Dependencies
31+
------------
32+
* Google Guava (13.0.1)
33+
34+
* Java JNA Platform (3.4.0)
35+
36+
* Java JNA (3.3.0)

0 commit comments

Comments
 (0)