Th10/Binary hacks

From Touhou Patch Center
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Bugs

Safe sprintf (call #1)
(sprintf_call_1)
Address
v1.00a0x447a7e, 0x447be9
Code
50
e8 [strings_vsprintf]
8944e4 18
push eax
call [strings_vsprintf]
mov dword ptr ss:[esp+0x18],eax
Safe sprintf (call #2)
(sprintf_call_2)
Address
v1.00a0x447b19
Code
50
e8 [strings_vsprintf]
8944e4 1c
push eax
call [strings_vsprintf]
mov dword ptr ss:[esp+0x1c],eax
Safe sprintf (replace pointer)
(sprintf_rep)
Address
v1.00a0x447aab, 0x447b7a, 0x447c40
Code
8b5ce4
mov ebx, dword ptr ss:[esp+

Text alignment

Move enemy text to the left (line 1)
(enemy_text_offset_1)
Description From the English patch.
Address
v1.00a0x41631a
Code
8d75 60
lea esi, [ebp+60h]
Move enemy text to the left (line 2)
(enemy_text_offset_2)
Description From the English patch.
Address
v1.00a0x416335
Code
83c0 07
add eax, 7

Spells

Spell card alignment
(spell_align)
Description This time, it just can't be done without killing the strlen() as well. :(
Address
v1.00a0x447b30
Code
8b8e 60030000
8bbe 94030000
d1e9
83e1 01
51
ffb4e4 a0000000
ff35 a0184900
ff74e4 1c
e8 [GetTextExtentForFont]
83c0 04
50
db04e4
58
90 90 90 90 90 90
85c0
mov ecx,dword ptr ds:[esi+0x360]
mov edi,dword ptr ds:[esi+0x394]
shr ecx,1
and ecx,00000001
push ecx
push dword ptr ss:[esp+0x0a0]
push dword ptr ds:[th10.font_spell]
push dword ptr ss:[esp+0x1c]
call [GetTextExtentForFont]
add eax,4
push eax
fild dword ptr ss:[esp]
pop eax
nop (*0x6)
test eax,eax

Player data

Remove spell "alignment" in the result screen
(result_spell_align)
Address
v1.00a0x447c39
Code
31c0
xor eax,eax