[Tool] Cheat Engine 功能介紹

軟體:Cheat Engine
官網
官方論壇
官方 wiki
官方 github

功能:修改遊戲

修改變動大多數皆會被存檔進 CT,以供後續使用
修改範例可參考 Cheat Engine Tutorials by Stephen Chapman
找任意值

Fast Scan 設定
  • Alignment
    • 能被設定值整除的地址
    • 例:4,只會掃描尾數是 0, 4, 8, C 的地址
  • Last Digits
    • 僅掃描地址尾數與設定值匹配的地址


加入新掃描分頁

地址填值方式
  • 確切地址,例:0x002D7F58
  • 數學運算,例: 1 + 1
  • 靜態地址,例:Tutorial-i386.exe + 3,如果打對 symbol 會直接顯示值
  • Label 名字,例:AOB 代碼中的宣告 label
  • Group 下的 Child,例:+10,會直接將 Parent 的地址 +10


顯示值的方式

Group address list
  • 建立 Header
    • 在下方 address list 上,右鍵 -> Create Header
  • 建立 Group
    • 將其他 address 直接拉進其他 address 中,成為 Group,不限定需為 Header
  • Group Config (需為 parent,右鍵才會出現)
    • Hide children when deactivated
      • 不啟動時,則隱藏 children
    • Activating this entry activates it's children
      • 啟動時,同時啟動下一層的 children,並不影響下下一層的 children
    • Deactivating this entry deactivate it's children
      • 取消時,同時取消下一層的 children,並不影響下下一層的 children
    • Setting a value to this entry sets same value to children
      • 設定值時,連同將底下所有的 children 設定同樣的值
    • Allow left and right arrow keys to collapse and expand
      • 允許用方向鍵展開/縮合
    • Manual expand/collapse
      • 出現加號,可點擊展開/縮合

下拉式選單
  • 右鍵 address list,可設定
  • 兩種設定方法
    • 值:敘述
    • 延用其他設定 => (其他地址的敘述)
  • 額外設定
    • Disallow manual user input
      禁止使用者輸入其他值
    • Only show the description part
      選單選項只顯示敘述,不顯示值
    • Make the record display values like the dropdown list
      address list 的 value 表示與選單選項一致

設定外在 Tool
可用來設定遊戲的開啟,或是其他工具,像是計算機

Code list & Comments
  • Code list
    • 用來存放記錄的 asm code 或是曾經無效化的 asm code
  • Comments
    • 用來寫註解,以供記錄用


Base Address
  • 逐步往上尋找
    • 利用 Find out what access/write this address
    • 步驟:初始地址 -> what access -> [ebx + 00000480] -> 找 ebx 的值 -> what access ...
    • 用 write 有時會找不到,因為若是多級指針,到第二級寫入就意味著上級也改變,而失去往上的線索,所以用 access 較好
    • 加入 address list 選擇 Pointer
  • Pointer Scan
    • 可建立 pointer map 加快尋找速度,只限當次使用
    • 可與之前建立過的 pointer map 做交叉比對,但 address 需是當時的
    • 建議先找出第一次的 offset 值
    • 存檔 ptr 請記得存入資料夾,不然有時會很零碎
    • 步驟:右鍵 address -> pointer scan -> 關閉遊戲 ( CE 不要關) -> Rescan(也可找值)
      -> 關閉遊戲 ( CE 不要關) -> Rescan(也可找值) -> ...
    • 點擊兩下結果,可以直接加入 address list
  • 若地址已是靜態,但載入無作用,有時是需讓 CE 更新 symbol list,才會得到正確的地址

打開 memory view 對應的 address

memory view 轉成靜態地址表示

更改 register

memory view 加入註解

解構 structure
  • 要解構的地址為 [ebx + 00000480] 的 ebx 值
  • 若遊戲有使用 mono.dll,建議設定 Activate mono features,解構時會得到更好的結果

查詢使用同樣 function 的地址
因扣血可能是採用同一個 function,可用來找敵人的資訊,再套入解構 structure,可右鍵套入

選擇目前 function 的區域

直接跳到 jmp 指向的地址

加入斷點

AOB
  • 可直接建立 AOB 範本,若有需求,也可建立其他範本
    若無加入到 table,不會存在 CT 中
  • 加入到 table 中,可應用 group config 規則與 label 名字可使用在 address,變化出各種用法
  • 利用 aob scan 確認是單一結果,需將 Writable 設定為 option 或直接右鍵選擇 Scan all memory
    'x','?'和'*'被視為任意值
    可以寫為每個 byte 一個或每個字符一個
    如果用空格分隔,則通配符將被解釋為一個 byte,如下
    5x 48 8D 6x 24 E0
    5x 48 8D 6x 24 E0
    5? 48 8D 6? 24 E0
    5* 48 8D 6* 24 E0
    xx 48 8D xx 24 E0
    ?? 48 8D ?? 24 E0
    ** 48 8D ** 24 E0
    x  48 8D x  24 E0
    ?  48 8D ?  24 E0
    *  48 8D *  24 E0
    

Lua 自動附加

修改器製作

資料處理
XMM 賦值範例:
  • movss XMM [Address]
  • movss XMM XMM
  • 無法直接給值:movss XMM (float)100.0
Value Type Byte Integer 2-Byte Integer 4-Byte Integer 8-Byte Integer 4-Byte Floating Point 8-Byte Floating Point
Size Byte 2-Byte 4-Byte 8-Byte Float Double
Value Range 0 to 255
or
-128 to +127
0 to 2^16-1
or
-2^15 to 2^15-1
0 to 2^32-1
or
-2^31 to 2^31-1
0 to 2^64-1
or
-2^63 to 2^63-1
Approximatedly
1.175494e-38
to
3.402823e38
Approximatedly
2.225074e-308
to
1.797693e308
Prefix to Convert in Script (int) or #
ex: #26 or (int)47
(int) or #
ex: #26 or (int)47
(int) or #
ex: #26 or (int)47
(int) or #
ex: #26 or (int)47
(float)
ex: (float)100.20
(double)
ex: (double)200.22
Size Name Byte Word Double Word / Dword Quad Word / Qword Double Word / Dword Quad Word / Qword
Declare Custom Label / Register db
ex: db (int)50
dw
ex: dw (int)50
dd
ex: dd (int)50
dq
ex: dq (int)50
dd
ex: dd (float)100.20
dq
ex:
dq (double)200.22

64-Bit ASM General Registers
64-Bit
8-byte
Qword
32-Bit
4-byte
Dword
16-Bit
2-byte
Word
8-Bit(Upper)
byte
8-Bit(Lower)
byte
raxeaxaxahal
rbxebxbxbhbl
rcxecxcxchcl
rdxedxdxdhdl
rsiesisi
sil
rdiedidi
dil
rbpebpbp
bpl
rspespsp
spl
r8r8dr8w
r8b
r9r9dr9w
r9b
r10r10dr10w
r10b
r11r11dr11w
r11b
r12r12dr12w
r12b
r13r13dr13w
r13b
r14r14dr14w
r14b
r15r15dr15w
r15b

參考

Cheat Engine Tutorials by Stephen Chapman
Game Hacking #6 - How to find Memory static Addresses & Offsets with Cheat Engine for any Game
LUA Cheat Engine

留言