11-21-2021, 05:30 PM
I made a version in python but is doesn't work i think the error can be I don't understand @ha and @l maybe
the code:
import dolphin_memory_engine as dolphin_memory
dolphin_memory.hook()
def lwz(a,b):
return dolphin_memory.read_word(a+b)
def stw(a,b,c):
dolphin_memory.write_word(a+b,c)
def lhz(a,b):
v = hex(lwz(a, b))[2:]
return int(v[:4],16)
def ori(a,b):
a = hex(a)[2:]
b= hex(b)[2:]
return int(a[:-len(b)]+b,16)
def sth(a,b,c):
dolphin_memory.write_word(a+b,c)
def press_a():
r3 = 0x809c0000
r3 = lwz(r3, -0x28f4)
r3 = lwz(r3, 0x8)
r4 = lhz(r3, 0x20)
r4 = ori(r4,0x1)
r4 = lhz(r3, 0x20)
press_a()
the code:
import dolphin_memory_engine as dolphin_memory
dolphin_memory.hook()
def lwz(a,b):
return dolphin_memory.read_word(a+b)
def stw(a,b,c):
dolphin_memory.write_word(a+b,c)
def lhz(a,b):
v = hex(lwz(a, b))[2:]
return int(v[:4],16)
def ori(a,b):
a = hex(a)[2:]
b= hex(b)[2:]
return int(a[:-len(b)]+b,16)
def sth(a,b,c):
dolphin_memory.write_word(a+b,c)
def press_a():
r3 = 0x809c0000
r3 = lwz(r3, -0x28f4)
r3 = lwz(r3, 0x8)
r4 = lhz(r3, 0x20)
r4 = ori(r4,0x1)
r4 = lhz(r3, 0x20)
press_a()