View Single Post
  #11    
Old August 23rd, 2013, 08:37 AM
Aruaruu
 
Join Date: Sep 2011
Gender: Male
I fixed that part that was a typo and it is still restarting when I start the roxanne battle.

I got some images of what I am copying from the assembled .bin. Am I not copying everything or something?

Spoiler:


Spoiler:


Spoiler:


and here is the asm before compiling.

Spoiler:
Code:
#EV spread table format
#Each spread is 16 bytes
#first four bytes are filler
#0x4 = IVs (from 0-31, not 0-255, used for all IVs)
# (if you want hidden powers, recall the ai can't handle -- bp moves)
#0x5 = HP EVs
#0x6 = Atk EVs
#0x7 = Def EVs
#0x8 = Speed EVs
#0x9 = SAtk EVs
#0xA = SDef EVs
#0xB = Pokeball
#last four bytes are filler

.align 2
.thumb
.thumb_func

.org 0x38936
mov r0, r1
lsl r1, r1, #0x0
lsl r1, r1, #0x0
lsl r1, r1, #0x0
lsl r1, r1, #0x0

.org 0x67d68
lsl r1, r1, #0x0
lsl r1, r1, #0x0
ldr r1, .Method_Addr
bx r1

.Method_Addr: .word 0x08FFFDF1

.org 0xFFFDF0

LoadHPEV:
mov r0, sp
ldrb r0, [r0, #0x11]
lsl r0, r0, #0x4
ldr r2, .EV_Table
add r2, r0
add r2, #0x5
mov r1, #0x1A
mov r0, r7
bl Insert_Element

LoadAtkEV:
mov r0, sp
ldrb r0, [r0, #0x11]
lsl r0, r0, #0x4
ldr r2, .EV_Table
add r2, r0
add r2, #0x6
mov r1, #0x1B
mov r0, r7
bl Insert_Element

LoadDefEV:
mov r0, sp
ldrb r0, [r0, #0x11]
lsl r0, r0, #0x4
ldr r2, .EV_Table
add r2, r0
add r2, #0x7
mov r1, #0x1C
mov r0, r7
bl Insert_Element

LoadSpeedEV:
mov r0, sp
ldrb r0, [r0, #0x11]
lsl r0, r0, #0x4
ldr r2, .EV_Table
add r2, r0
add r2, #0x8
mov r1, #0x1D
mov r0, r7
bl Insert_Element

LoadSAtkEV:
mov r0, sp
ldrb r0, [r0, #0x11]
lsl r0, r0, #0x4
ldr r2, .EV_Table
add r2, r0
add r2, #0x9
mov r1, #0x1E
mov r0, r7
bl Insert_Element

LoadSDefEV:
mov r0, sp
ldrb r0, [r0, #0x11]
lsl r0, r0, #0x4
ldr r2, .EV_Table
add r2, r0
add r2, #0xA
mov r1, #0x1F
mov r0, r7
bl Insert_Element

LoadBall:
mov r0, sp
ldrb r0, [r0, #0x11]
lsl r0, r0, #0x4
ldr r2, .EV_Table
add r2, r0
add r2, #0xB
mov r1, #0x26
mov r0, r7
bl Insert_Element

LoadIVs:
mov r1, sp
ldrb r0, [r1, #0x11]
lsl r0, r0, #0x4
ldr r2, .EV_Table
add r2, r0
ldrb r2, [r2, #0x4]
strb r2, [r1, #0x11]

HPIV:
add r0, r7, #0x0
mov r1, #0x27
mov r2, sp
add r2, #0x11
bl Insert_Element

AtkIV:
add r0, r7, #0x0
mov r1, #0x28
mov r2, sp
add r2, #0x11
bl Insert_Element

End:
ldr r1, .Return_Addr
bx r1

Insert_Element:
ldr r3, .Insert_Addr
bx r3


.align 2
.Return_Addr: .word 0x08067d83
.EV_Table: .word 0x08E42710
.Insert_Addr: .word 0x0806AD9D


Thanks for bearing with me.
Reply With Quote