Merge pull request #348 from DizzyEggg/anim_files
Decompile/Port battle_anim_80A5C6C
This commit is contained in:
commit
807050a048
25 changed files with 4058 additions and 10168 deletions
File diff suppressed because it is too large
Load diff
|
@ -1,930 +0,0 @@
|
|||
.include "asm/macros.inc"
|
||||
.include "constants/constants.inc"
|
||||
|
||||
.syntax unified
|
||||
|
||||
.text
|
||||
|
||||
|
||||
thumb_func_start sub_80A9C70
|
||||
sub_80A9C70: @ 80A9C70
|
||||
push {r4-r7,lr}
|
||||
mov r7, r8
|
||||
push {r7}
|
||||
adds r4, r0, 0
|
||||
adds r5, r1, 0
|
||||
lsls r4, 24
|
||||
lsrs r4, 24
|
||||
lsls r5, 24
|
||||
lsrs r5, 24
|
||||
ldr r0, =gBattlerSpriteIds
|
||||
adds r0, r4, r0
|
||||
ldrb r6, [r0]
|
||||
ldr r0, =sub_80A9DB4
|
||||
movs r1, 0xA
|
||||
bl CreateTask
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
mov r8, r0
|
||||
ldr r0, =gBattleAnimPicTable + 0x440
|
||||
bl LoadCompressedObjectPicUsingHeap
|
||||
ldr r0, =gBattleAnimPaletteTable + 0x440
|
||||
bl LoadCompressedObjectPaletteUsingHeap
|
||||
ldr r1, =gTasks
|
||||
mov r2, r8
|
||||
lsls r0, r2, 2
|
||||
add r0, r8
|
||||
lsls r0, 3
|
||||
adds r1, r0, r1
|
||||
strh r4, [r1, 0x8]
|
||||
cmp r5, 0
|
||||
beq _080A9D30
|
||||
movs r0, 0x1F
|
||||
strh r0, [r1, 0xA]
|
||||
movs r5, 0
|
||||
lsls r0, r6, 4
|
||||
ldr r7, =gSprites
|
||||
adds r0, r6
|
||||
lsls r0, 2
|
||||
adds r6, r0, r7
|
||||
_080A9CC4:
|
||||
movs r0, 0x20
|
||||
ldrsh r1, [r6, r0]
|
||||
ldrh r2, [r6, 0x22]
|
||||
adds r2, 0x20
|
||||
lsls r2, 16
|
||||
asrs r2, 16
|
||||
ldr r0, =gUnknown_0853EF60
|
||||
movs r3, 0
|
||||
bl CreateSprite
|
||||
lsls r0, 24
|
||||
lsrs r4, r0, 24
|
||||
lsls r0, r4, 4
|
||||
adds r0, r4
|
||||
lsls r0, 2
|
||||
adds r3, r0, r7
|
||||
lsls r0, r5, 1
|
||||
adds r0, r5
|
||||
lsls r1, r0, 4
|
||||
adds r0, r1
|
||||
strh r0, [r3, 0x2E]
|
||||
movs r0, 0xFF
|
||||
lsls r0, 8
|
||||
strh r0, [r3, 0x30]
|
||||
adds r2, r3, 0
|
||||
adds r2, 0x3E
|
||||
ldrb r0, [r2]
|
||||
movs r1, 0x4
|
||||
orrs r0, r1
|
||||
strb r0, [r2]
|
||||
cmp r5, 0x4
|
||||
bls _080A9D08
|
||||
movs r0, 0x15
|
||||
strh r0, [r3, 0x3A]
|
||||
_080A9D08:
|
||||
adds r0, r5, 0x1
|
||||
lsls r0, 24
|
||||
lsrs r5, r0, 24
|
||||
cmp r5, 0x9
|
||||
bls _080A9CC4
|
||||
b _080A9D90
|
||||
.pool
|
||||
_080A9D30:
|
||||
movs r0, 0xF8
|
||||
lsls r0, 7
|
||||
strh r0, [r1, 0xA]
|
||||
movs r5, 0
|
||||
lsls r0, r6, 4
|
||||
ldr r7, =gSprites
|
||||
adds r0, r6
|
||||
lsls r0, 2
|
||||
adds r6, r0, r7
|
||||
_080A9D42:
|
||||
movs r2, 0x20
|
||||
ldrsh r1, [r6, r2]
|
||||
ldrh r2, [r6, 0x22]
|
||||
subs r2, 0x20
|
||||
lsls r2, 16
|
||||
asrs r2, 16
|
||||
ldr r0, =gUnknown_0853EF60
|
||||
movs r3, 0
|
||||
bl CreateSprite
|
||||
lsls r0, 24
|
||||
lsrs r4, r0, 24
|
||||
lsls r0, r4, 4
|
||||
adds r0, r4
|
||||
lsls r0, 2
|
||||
adds r3, r0, r7
|
||||
lsls r0, r5, 1
|
||||
adds r0, r5
|
||||
lsls r1, r0, 4
|
||||
adds r0, r1
|
||||
strh r0, [r3, 0x2E]
|
||||
movs r0, 0x80
|
||||
lsls r0, 1
|
||||
strh r0, [r3, 0x30]
|
||||
adds r2, r3, 0
|
||||
adds r2, 0x3E
|
||||
ldrb r0, [r2]
|
||||
movs r1, 0x4
|
||||
orrs r0, r1
|
||||
strb r0, [r2]
|
||||
cmp r5, 0x4
|
||||
bls _080A9D86
|
||||
movs r0, 0x15
|
||||
strh r0, [r3, 0x3A]
|
||||
_080A9D86:
|
||||
adds r0, r5, 0x1
|
||||
lsls r0, 24
|
||||
lsrs r5, r0, 24
|
||||
cmp r5, 0x9
|
||||
bls _080A9D42
|
||||
_080A9D90:
|
||||
ldr r0, =gSprites
|
||||
lsls r1, r4, 4
|
||||
adds r1, r4
|
||||
lsls r1, 2
|
||||
adds r1, r0
|
||||
movs r0, 0x1
|
||||
strh r0, [r1, 0x3C]
|
||||
mov r0, r8
|
||||
pop {r3}
|
||||
mov r8, r3
|
||||
pop {r4-r7}
|
||||
pop {r1}
|
||||
bx r1
|
||||
.pool
|
||||
thumb_func_end sub_80A9C70
|
||||
|
||||
thumb_func_start sub_80A9DB4
|
||||
sub_80A9DB4: @ 80A9DB4
|
||||
push {r4,r5,lr}
|
||||
lsls r0, 24
|
||||
lsrs r5, r0, 24
|
||||
ldr r1, =gTasks
|
||||
lsls r0, r5, 2
|
||||
adds r0, r5
|
||||
lsls r0, 3
|
||||
adds r4, r0, r1
|
||||
ldrh r1, [r4, 0xC]
|
||||
movs r2, 0xC
|
||||
ldrsh r0, [r4, r2]
|
||||
cmp r0, 0x2
|
||||
bne _080A9E3A
|
||||
movs r0, 0
|
||||
strh r0, [r4, 0xC]
|
||||
movs r1, 0x8
|
||||
ldrsh r0, [r4, r1]
|
||||
lsls r0, 20
|
||||
movs r2, 0x80
|
||||
lsls r2, 17
|
||||
adds r0, r2
|
||||
lsrs r0, 16
|
||||
ldrb r2, [r4, 0x10]
|
||||
ldrh r3, [r4, 0xA]
|
||||
movs r1, 0x10
|
||||
bl BlendPalette
|
||||
ldrh r2, [r4, 0x12]
|
||||
movs r1, 0x12
|
||||
ldrsh r0, [r4, r1]
|
||||
cmp r0, 0
|
||||
bne _080A9E10
|
||||
ldrh r0, [r4, 0x10]
|
||||
adds r0, 0x1
|
||||
strh r0, [r4, 0x10]
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0x8
|
||||
ble _080A9E3E
|
||||
movs r0, 0x1
|
||||
eors r0, r2
|
||||
strh r0, [r4, 0x12]
|
||||
b _080A9E3E
|
||||
.pool
|
||||
_080A9E10:
|
||||
ldrh r1, [r4, 0x10]
|
||||
subs r0, r1, 0x1
|
||||
strh r0, [r4, 0x10]
|
||||
lsls r0, 16
|
||||
cmp r0, 0
|
||||
bge _080A9E3E
|
||||
strh r1, [r4, 0x10]
|
||||
movs r0, 0x1
|
||||
eors r0, r2
|
||||
strh r0, [r4, 0x12]
|
||||
ldrh r0, [r4, 0xE]
|
||||
adds r0, 0x1
|
||||
strh r0, [r4, 0xE]
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0x2
|
||||
bne _080A9E3E
|
||||
adds r0, r5, 0
|
||||
bl DestroyTask
|
||||
b _080A9E3E
|
||||
_080A9E3A:
|
||||
adds r0, r1, 0x1
|
||||
strh r0, [r4, 0xC]
|
||||
_080A9E3E:
|
||||
pop {r4,r5}
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_80A9DB4
|
||||
|
||||
thumb_func_start sub_80A9E44
|
||||
sub_80A9E44: @ 80A9E44
|
||||
push {lr}
|
||||
adds r2, r0, 0
|
||||
ldrh r1, [r2, 0x3A]
|
||||
movs r3, 0x3A
|
||||
ldrsh r0, [r2, r3]
|
||||
cmp r0, 0
|
||||
bne _080A9E70
|
||||
adds r3, r2, 0
|
||||
adds r3, 0x3E
|
||||
ldrb r0, [r3]
|
||||
movs r1, 0x5
|
||||
negs r1, r1
|
||||
ands r1, r0
|
||||
strb r1, [r3]
|
||||
ldr r1, =sub_80A9E78
|
||||
str r1, [r2, 0x1C]
|
||||
adds r0, r2, 0
|
||||
bl _call_via_r1
|
||||
b _080A9E74
|
||||
.pool
|
||||
_080A9E70:
|
||||
subs r0, r1, 0x1
|
||||
strh r0, [r2, 0x3A]
|
||||
_080A9E74:
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_80A9E44
|
||||
|
||||
thumb_func_start sub_80A9E78
|
||||
sub_80A9E78: @ 80A9E78
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
movs r1, 0x2E
|
||||
ldrsh r0, [r4, r1]
|
||||
movs r1, 0x20
|
||||
bl Cos
|
||||
strh r0, [r4, 0x24]
|
||||
movs r1, 0x2E
|
||||
ldrsh r0, [r4, r1]
|
||||
movs r1, 0x8
|
||||
bl Sin
|
||||
strh r0, [r4, 0x26]
|
||||
movs r1, 0x2E
|
||||
ldrsh r0, [r4, r1]
|
||||
cmp r0, 0x7F
|
||||
bgt _080A9EA4
|
||||
adds r1, r4, 0
|
||||
adds r1, 0x43
|
||||
movs r0, 0x1D
|
||||
b _080A9EAA
|
||||
_080A9EA4:
|
||||
adds r1, r4, 0
|
||||
adds r1, 0x43
|
||||
movs r0, 0x1F
|
||||
_080A9EAA:
|
||||
strb r0, [r1]
|
||||
ldrh r0, [r4, 0x2E]
|
||||
adds r0, 0x8
|
||||
movs r1, 0xFF
|
||||
ands r0, r1
|
||||
strh r0, [r4, 0x2E]
|
||||
ldrh r0, [r4, 0x30]
|
||||
ldrh r1, [r4, 0x38]
|
||||
adds r0, r1
|
||||
strh r0, [r4, 0x38]
|
||||
lsls r0, 16
|
||||
asrs r0, 24
|
||||
ldrh r1, [r4, 0x26]
|
||||
adds r0, r1
|
||||
strh r0, [r4, 0x26]
|
||||
ldrh r0, [r4, 0x32]
|
||||
adds r0, 0x1
|
||||
strh r0, [r4, 0x32]
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0x34
|
||||
bne _080A9EEC
|
||||
movs r1, 0x3C
|
||||
ldrsh r0, [r4, r1]
|
||||
cmp r0, 0
|
||||
beq _080A9EE6
|
||||
adds r0, r4, 0
|
||||
bl DestroySpriteAndFreeResources
|
||||
b _080A9EEC
|
||||
_080A9EE6:
|
||||
adds r0, r4, 0
|
||||
bl DestroySprite
|
||||
_080A9EEC:
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_80A9E78
|
||||
|
||||
thumb_func_start sub_80A9EF4
|
||||
sub_80A9EF4: @ 80A9EF4
|
||||
push {r4-r6,lr}
|
||||
lsls r0, 24
|
||||
lsrs r6, r0, 24
|
||||
ldr r4, =gBattleAnimTarget
|
||||
ldrb r0, [r4]
|
||||
movs r1, 0x2
|
||||
bl GetBattlerSpriteCoord
|
||||
lsls r0, 24
|
||||
lsrs r0, 8
|
||||
ldr r1, =0xffe00000
|
||||
adds r0, r1
|
||||
lsrs r5, r0, 16
|
||||
ldrb r0, [r4]
|
||||
movs r1, 0x3
|
||||
bl GetBattlerSpriteCoord
|
||||
lsls r0, 24
|
||||
lsrs r0, 8
|
||||
ldr r1, =0xffdc0000
|
||||
adds r0, r1
|
||||
lsrs r4, r0, 16
|
||||
bl IsContest
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _080A9F32
|
||||
lsls r0, r5, 16
|
||||
ldr r1, =0xfffa0000
|
||||
adds r0, r1
|
||||
lsrs r5, r0, 16
|
||||
_080A9F32:
|
||||
movs r1, 0xFD
|
||||
lsls r1, 6
|
||||
movs r0, 0x50
|
||||
bl SetGpuReg
|
||||
movs r1, 0x80
|
||||
lsls r1, 5
|
||||
movs r0, 0x52
|
||||
bl SetGpuReg
|
||||
ldr r0, =gUnknown_0853EF48
|
||||
lsls r1, r5, 16
|
||||
asrs r1, 16
|
||||
lsls r2, r4, 16
|
||||
asrs r2, 16
|
||||
movs r3, 0x4
|
||||
bl CreateSprite
|
||||
lsls r0, 24
|
||||
lsrs r4, r0, 24
|
||||
ldr r0, =0x0000271a
|
||||
bl GetSpriteTileStartByTag
|
||||
lsls r0, 16
|
||||
ldr r1, =0xffff0000
|
||||
cmp r0, r1
|
||||
bne _080A9F7C
|
||||
ldr r1, =gSprites
|
||||
lsls r0, r4, 4
|
||||
adds r0, r4
|
||||
lsls r0, 2
|
||||
adds r0, r1
|
||||
adds r0, 0x3E
|
||||
ldrb r1, [r0]
|
||||
movs r2, 0x4
|
||||
orrs r1, r2
|
||||
strb r1, [r0]
|
||||
_080A9F7C:
|
||||
lsls r0, r4, 4
|
||||
adds r0, r4
|
||||
lsls r0, 2
|
||||
ldr r1, =gSprites
|
||||
adds r0, r1
|
||||
ldr r1, =gUnknown_0853EF40
|
||||
bl SetSubspriteTables
|
||||
ldr r1, =gTasks
|
||||
lsls r0, r6, 2
|
||||
adds r0, r6
|
||||
lsls r0, 3
|
||||
adds r0, r1
|
||||
strh r4, [r0, 0x26]
|
||||
ldr r1, =sub_80A9FD0
|
||||
str r1, [r0]
|
||||
pop {r4-r6}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.pool
|
||||
thumb_func_end sub_80A9EF4
|
||||
|
||||
thumb_func_start sub_80A9FD0
|
||||
sub_80A9FD0: @ 80A9FD0
|
||||
push {lr}
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
ldr r2, =gTasks
|
||||
lsls r1, r0, 2
|
||||
adds r1, r0
|
||||
lsls r1, 3
|
||||
adds r1, r2
|
||||
ldrh r0, [r1, 0xA]
|
||||
adds r0, 0x1
|
||||
adds r2, r0, 0
|
||||
strh r0, [r1, 0xA]
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0xA
|
||||
bne _080AA004
|
||||
ldr r0, =sub_80AA020
|
||||
str r0, [r1]
|
||||
movs r0, 0
|
||||
strh r0, [r1, 0xA]
|
||||
b _080AA01A
|
||||
.pool
|
||||
_080AA004:
|
||||
lsls r0, r2, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x10
|
||||
subs r1, r0
|
||||
lsls r1, 8
|
||||
orrs r1, r0
|
||||
lsls r1, 16
|
||||
lsrs r1, 16
|
||||
movs r0, 0x52
|
||||
bl SetGpuReg
|
||||
_080AA01A:
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_80A9FD0
|
||||
|
||||
thumb_func_start sub_80AA020
|
||||
sub_80AA020: @ 80AA020
|
||||
push {r4-r6,lr}
|
||||
adds r4, r0, 0
|
||||
lsls r4, 24
|
||||
lsrs r4, 24
|
||||
ldr r0, =0x0000271a
|
||||
bl IndexOfSpritePaletteTag
|
||||
lsls r0, 24
|
||||
lsrs r2, r0, 24
|
||||
ldr r1, =gTasks
|
||||
lsls r0, r4, 2
|
||||
adds r0, r4
|
||||
lsls r0, 3
|
||||
adds r5, r0, r1
|
||||
ldrh r0, [r5, 0xA]
|
||||
adds r1, r0, 0x1
|
||||
strh r1, [r5, 0xA]
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0xD
|
||||
ble _080AA0B0
|
||||
ldrh r0, [r5, 0xC]
|
||||
adds r0, 0x1
|
||||
movs r6, 0
|
||||
strh r0, [r5, 0xC]
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0x3
|
||||
bne _080AA0B0
|
||||
ldr r3, =gPlttBufferFaded
|
||||
lsls r2, 4
|
||||
mov r12, r2
|
||||
ldr r1, =0x0000010d
|
||||
add r1, r12
|
||||
lsls r1, 1
|
||||
adds r1, r3
|
||||
ldrh r4, [r1]
|
||||
movs r2, 0x87
|
||||
lsls r2, 1
|
||||
add r2, r12
|
||||
lsls r2, 1
|
||||
adds r2, r3
|
||||
ldrh r0, [r2]
|
||||
strh r0, [r1]
|
||||
ldr r0, =0x0000010f
|
||||
add r0, r12
|
||||
lsls r0, 1
|
||||
adds r0, r3
|
||||
ldrh r1, [r0]
|
||||
strh r1, [r2]
|
||||
strh r4, [r0]
|
||||
strh r6, [r5, 0xC]
|
||||
ldrh r0, [r5, 0xE]
|
||||
adds r0, 0x1
|
||||
strh r0, [r5, 0xE]
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0x3
|
||||
bne _080AA0B0
|
||||
strh r6, [r5, 0xE]
|
||||
strh r6, [r5, 0xA]
|
||||
ldrh r0, [r5, 0x10]
|
||||
adds r0, 0x1
|
||||
strh r0, [r5, 0x10]
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0x2
|
||||
bne _080AA0B0
|
||||
movs r0, 0x9
|
||||
strh r0, [r5, 0xA]
|
||||
ldr r0, =sub_80AA0D0
|
||||
str r0, [r5]
|
||||
_080AA0B0:
|
||||
pop {r4-r6}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.pool
|
||||
thumb_func_end sub_80AA020
|
||||
|
||||
thumb_func_start sub_80AA0D0
|
||||
sub_80AA0D0: @ 80AA0D0
|
||||
push {lr}
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
ldr r2, =gTasks
|
||||
lsls r1, r0, 2
|
||||
adds r1, r0
|
||||
lsls r1, 3
|
||||
adds r2, r1, r2
|
||||
ldrh r0, [r2, 0xA]
|
||||
subs r0, 0x1
|
||||
adds r3, r0, 0
|
||||
strh r0, [r2, 0xA]
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
movs r1, 0x1
|
||||
negs r1, r1
|
||||
cmp r0, r1
|
||||
bne _080AA108
|
||||
ldr r0, =sub_80AA124
|
||||
str r0, [r2]
|
||||
movs r0, 0
|
||||
strh r0, [r2, 0xA]
|
||||
b _080AA11E
|
||||
.pool
|
||||
_080AA108:
|
||||
lsls r0, r3, 24
|
||||
lsrs r0, 24
|
||||
movs r1, 0x10
|
||||
subs r1, r0
|
||||
lsls r1, 8
|
||||
orrs r1, r0
|
||||
lsls r1, 16
|
||||
lsrs r1, 16
|
||||
movs r0, 0x52
|
||||
bl SetGpuReg
|
||||
_080AA11E:
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_80AA0D0
|
||||
|
||||
thumb_func_start sub_80AA124
|
||||
sub_80AA124: @ 80AA124
|
||||
push {r4,lr}
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
adds r4, r0, 0
|
||||
ldr r1, =gTasks
|
||||
lsls r0, r4, 2
|
||||
adds r0, r4
|
||||
lsls r0, 3
|
||||
adds r1, r0, r1
|
||||
ldrh r0, [r1, 0xA]
|
||||
adds r0, 0x1
|
||||
strh r0, [r1, 0xA]
|
||||
lsls r0, 16
|
||||
asrs r0, 16
|
||||
cmp r0, 0x25
|
||||
bne _080AA16C
|
||||
ldrh r0, [r1, 0x26]
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
lsls r4, r0, 4
|
||||
adds r4, r0
|
||||
lsls r4, 2
|
||||
ldr r0, =gSprites
|
||||
adds r4, r0
|
||||
adds r0, r4, 0
|
||||
bl FreeSpriteOamMatrix
|
||||
adds r0, r4, 0
|
||||
bl DestroySprite
|
||||
b _080AA186
|
||||
.pool
|
||||
_080AA16C:
|
||||
cmp r0, 0x27
|
||||
bne _080AA186
|
||||
movs r0, 0x50
|
||||
movs r1, 0
|
||||
bl SetGpuReg
|
||||
movs r0, 0x52
|
||||
movs r1, 0
|
||||
bl SetGpuReg
|
||||
adds r0, r4, 0
|
||||
bl DestroyAnimVisualTask
|
||||
_080AA186:
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end sub_80AA124
|
||||
|
||||
thumb_func_start AnimTask_StatsChange
|
||||
AnimTask_StatsChange: @ 80AA18C
|
||||
push {r4,r5,lr}
|
||||
lsls r0, 24
|
||||
lsrs r4, r0, 24
|
||||
movs r3, 0
|
||||
ldr r0, =gBattleSpritesDataPtr
|
||||
ldr r0, [r0]
|
||||
ldr r0, [r0, 0x8]
|
||||
ldrh r0, [r0]
|
||||
subs r0, 0xF
|
||||
cmp r0, 0x2B
|
||||
bls _080AA1A4
|
||||
b _080AA328
|
||||
_080AA1A4:
|
||||
lsls r0, 2
|
||||
ldr r1, =_080AA1B8
|
||||
adds r0, r1
|
||||
ldr r0, [r0]
|
||||
mov pc, r0
|
||||
.pool
|
||||
.align 2, 0
|
||||
_080AA1B8:
|
||||
.4byte _080AA268
|
||||
.4byte _080AA26E
|
||||
.4byte _080AA274
|
||||
.4byte _080AA27A
|
||||
.4byte _080AA280
|
||||
.4byte _080AA286
|
||||
.4byte _080AA28C
|
||||
.4byte _080AA292
|
||||
.4byte _080AA298
|
||||
.4byte _080AA29E
|
||||
.4byte _080AA2A4
|
||||
.4byte _080AA2AA
|
||||
.4byte _080AA2B0
|
||||
.4byte _080AA2B6
|
||||
.4byte _080AA328
|
||||
.4byte _080AA328
|
||||
.4byte _080AA328
|
||||
.4byte _080AA328
|
||||
.4byte _080AA328
|
||||
.4byte _080AA328
|
||||
.4byte _080AA328
|
||||
.4byte _080AA328
|
||||
.4byte _080AA328
|
||||
.4byte _080AA328
|
||||
.4byte _080AA2BC
|
||||
.4byte _080AA2C0
|
||||
.4byte _080AA2C4
|
||||
.4byte _080AA2C8
|
||||
.4byte _080AA2CC
|
||||
.4byte _080AA2D0
|
||||
.4byte _080AA2D4
|
||||
.4byte _080AA2D8
|
||||
.4byte _080AA2E0
|
||||
.4byte _080AA2E8
|
||||
.4byte _080AA2F0
|
||||
.4byte _080AA2F8
|
||||
.4byte _080AA300
|
||||
.4byte _080AA308
|
||||
.4byte _080AA328
|
||||
.4byte _080AA328
|
||||
.4byte _080AA310
|
||||
.4byte _080AA314
|
||||
.4byte _080AA318
|
||||
.4byte _080AA320
|
||||
_080AA268:
|
||||
movs r5, 0
|
||||
movs r2, 0
|
||||
b _080AA330
|
||||
_080AA26E:
|
||||
movs r5, 0
|
||||
movs r2, 0x1
|
||||
b _080AA330
|
||||
_080AA274:
|
||||
movs r5, 0
|
||||
movs r2, 0x3
|
||||
b _080AA330
|
||||
_080AA27A:
|
||||
movs r5, 0
|
||||
movs r2, 0x5
|
||||
b _080AA330
|
||||
_080AA280:
|
||||
movs r5, 0
|
||||
movs r2, 0x6
|
||||
b _080AA330
|
||||
_080AA286:
|
||||
movs r5, 0
|
||||
movs r2, 0x2
|
||||
b _080AA330
|
||||
_080AA28C:
|
||||
movs r5, 0
|
||||
movs r2, 0x4
|
||||
b _080AA330
|
||||
_080AA292:
|
||||
movs r5, 0x1
|
||||
movs r2, 0
|
||||
b _080AA330
|
||||
_080AA298:
|
||||
movs r5, 0x1
|
||||
movs r2, 0x1
|
||||
b _080AA330
|
||||
_080AA29E:
|
||||
movs r5, 0x1
|
||||
movs r2, 0x3
|
||||
b _080AA330
|
||||
_080AA2A4:
|
||||
movs r5, 0x1
|
||||
movs r2, 0x5
|
||||
b _080AA330
|
||||
_080AA2AA:
|
||||
movs r5, 0x1
|
||||
movs r2, 0x6
|
||||
b _080AA330
|
||||
_080AA2B0:
|
||||
movs r5, 0x1
|
||||
movs r2, 0x2
|
||||
b _080AA330
|
||||
_080AA2B6:
|
||||
movs r5, 0x1
|
||||
movs r2, 0x4
|
||||
b _080AA330
|
||||
_080AA2BC:
|
||||
movs r5, 0
|
||||
b _080AA2DA
|
||||
_080AA2C0:
|
||||
movs r5, 0
|
||||
b _080AA2E2
|
||||
_080AA2C4:
|
||||
movs r5, 0
|
||||
b _080AA2EA
|
||||
_080AA2C8:
|
||||
movs r5, 0
|
||||
b _080AA2F2
|
||||
_080AA2CC:
|
||||
movs r5, 0
|
||||
b _080AA2FA
|
||||
_080AA2D0:
|
||||
movs r5, 0
|
||||
b _080AA302
|
||||
_080AA2D4:
|
||||
movs r5, 0
|
||||
b _080AA30A
|
||||
_080AA2D8:
|
||||
movs r5, 0x1
|
||||
_080AA2DA:
|
||||
movs r2, 0
|
||||
movs r3, 0x1
|
||||
b _080AA330
|
||||
_080AA2E0:
|
||||
movs r5, 0x1
|
||||
_080AA2E2:
|
||||
movs r2, 0x1
|
||||
movs r3, 0x1
|
||||
b _080AA330
|
||||
_080AA2E8:
|
||||
movs r5, 0x1
|
||||
_080AA2EA:
|
||||
movs r2, 0x3
|
||||
movs r3, 0x1
|
||||
b _080AA330
|
||||
_080AA2F0:
|
||||
movs r5, 0x1
|
||||
_080AA2F2:
|
||||
movs r2, 0x5
|
||||
movs r3, 0x1
|
||||
b _080AA330
|
||||
_080AA2F8:
|
||||
movs r5, 0x1
|
||||
_080AA2FA:
|
||||
movs r2, 0x6
|
||||
movs r3, 0x1
|
||||
b _080AA330
|
||||
_080AA300:
|
||||
movs r5, 0x1
|
||||
_080AA302:
|
||||
movs r2, 0x2
|
||||
movs r3, 0x1
|
||||
b _080AA330
|
||||
_080AA308:
|
||||
movs r5, 0x1
|
||||
_080AA30A:
|
||||
movs r2, 0x4
|
||||
movs r3, 0x1
|
||||
b _080AA330
|
||||
_080AA310:
|
||||
movs r5, 0
|
||||
b _080AA31A
|
||||
_080AA314:
|
||||
movs r5, 0
|
||||
b _080AA322
|
||||
_080AA318:
|
||||
movs r5, 0x1
|
||||
_080AA31A:
|
||||
movs r2, 0xFF
|
||||
movs r3, 0
|
||||
b _080AA330
|
||||
_080AA320:
|
||||
movs r5, 0x1
|
||||
_080AA322:
|
||||
movs r2, 0xFF
|
||||
movs r3, 0x1
|
||||
b _080AA330
|
||||
_080AA328:
|
||||
adds r0, r4, 0
|
||||
bl DestroyAnimVisualTask
|
||||
b _080AA352
|
||||
_080AA330:
|
||||
ldr r0, =gBattleAnimArgs
|
||||
movs r1, 0
|
||||
strh r5, [r0]
|
||||
strh r2, [r0, 0x2]
|
||||
strh r1, [r0, 0x4]
|
||||
strh r1, [r0, 0x6]
|
||||
strh r3, [r0, 0x8]
|
||||
ldr r1, =gTasks
|
||||
lsls r0, r4, 2
|
||||
adds r0, r4
|
||||
lsls r0, 3
|
||||
adds r0, r1
|
||||
ldr r1, =sub_8116EB4
|
||||
str r1, [r0]
|
||||
adds r0, r4, 0
|
||||
bl _call_via_r1
|
||||
_080AA352:
|
||||
pop {r4,r5}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.pool
|
||||
thumb_func_end AnimTask_StatsChange
|
||||
|
||||
thumb_func_start LaunchStatusAnimation
|
||||
LaunchStatusAnimation: @ 80AA364
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
lsls r4, 24
|
||||
lsrs r4, 24
|
||||
lsls r1, 24
|
||||
lsrs r1, 24
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
strb r4, [r0]
|
||||
ldr r0, =gBattleAnimTarget
|
||||
strb r4, [r0]
|
||||
ldr r0, =gBattleAnims_StatusConditions
|
||||
movs r2, 0
|
||||
bl LaunchBattleAnimation
|
||||
ldr r0, =task0A_80788BC
|
||||
movs r1, 0xA
|
||||
bl CreateTask
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
ldr r2, =gTasks
|
||||
lsls r1, r0, 2
|
||||
adds r1, r0
|
||||
lsls r1, 3
|
||||
adds r1, r2
|
||||
strh r4, [r1, 0x8]
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.pool
|
||||
thumb_func_end LaunchStatusAnimation
|
||||
|
||||
thumb_func_start task0A_80788BC
|
||||
task0A_80788BC: @ 80AA3B4
|
||||
push {r4,lr}
|
||||
lsls r0, 24
|
||||
lsrs r4, r0, 24
|
||||
ldr r0, =gAnimScriptCallback
|
||||
ldr r0, [r0]
|
||||
bl _call_via_r0
|
||||
ldr r0, =gAnimScriptActive
|
||||
ldrb r0, [r0]
|
||||
cmp r0, 0
|
||||
bne _080AA3F6
|
||||
ldr r0, =gBattleSpritesDataPtr
|
||||
ldr r2, [r0]
|
||||
ldr r1, =gTasks
|
||||
lsls r0, r4, 2
|
||||
adds r0, r4
|
||||
lsls r0, 3
|
||||
adds r0, r1
|
||||
movs r1, 0x8
|
||||
ldrsh r0, [r0, r1]
|
||||
ldr r2, [r2, 0x4]
|
||||
lsls r1, r0, 1
|
||||
adds r1, r0
|
||||
lsls r1, 2
|
||||
adds r1, r2
|
||||
ldrb r2, [r1]
|
||||
movs r0, 0x11
|
||||
negs r0, r0
|
||||
ands r0, r2
|
||||
strb r0, [r1]
|
||||
adds r0, r4, 0
|
||||
bl DestroyTask
|
||||
_080AA3F6:
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.pool
|
||||
thumb_func_end task0A_80788BC
|
||||
|
||||
.align 2, 0 @ Don't pad with nop.
|
File diff suppressed because it is too large
Load diff
|
@ -183,7 +183,7 @@ sub_80FE988: @ 80FE988
|
|||
lsrs r0, 24
|
||||
strh r0, [r4, 0x36]
|
||||
adds r0, r4, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldrh r0, [r6, 0x6]
|
||||
strh r0, [r4, 0x38]
|
||||
ldr r1, =sub_80FE9E4
|
||||
|
@ -200,7 +200,7 @@ sub_80FE988: @ 80FE988
|
|||
sub_80FE9E4: @ 80FE9E4
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _080FE9FA
|
||||
|
@ -350,7 +350,7 @@ sub_80FEAD8: @ 80FEAD8
|
|||
sub_80FEB28: @ 80FEB28
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _080FEB3C
|
||||
|
@ -541,7 +541,7 @@ _080FEC68:
|
|||
sub_80FECB8: @ 80FECB8
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _080FECE2
|
||||
|
@ -781,7 +781,7 @@ sub_80FEE78: @ 80FEE78
|
|||
adds r0, r5
|
||||
strh r0, [r4, 0x36]
|
||||
adds r0, r4, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
movs r0, 0x40
|
||||
strh r0, [r4, 0x38]
|
||||
ldr r1, =sub_80FEECC
|
||||
|
@ -798,7 +798,7 @@ sub_80FEE78: @ 80FEE78
|
|||
sub_80FEECC: @ 80FEECC
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _080FEF38
|
||||
|
@ -878,7 +878,7 @@ sub_80FEF44: @ 80FEF44
|
|||
adds r0, r5
|
||||
strh r0, [r4, 0x36]
|
||||
adds r0, r4, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
movs r0, 0x40
|
||||
strh r0, [r4, 0x38]
|
||||
ldr r1, =sub_80FEF98
|
||||
|
@ -895,7 +895,7 @@ sub_80FEF44: @ 80FEF44
|
|||
sub_80FEF98: @ 80FEF98
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _080FEFF0
|
||||
|
@ -1124,7 +1124,7 @@ _080FF154:
|
|||
adds r3, r5, 0
|
||||
adds r3, 0x36
|
||||
movs r1, 0x1
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
ldrh r0, [r6, 0x4]
|
||||
ldrh r1, [r5, 0x32]
|
||||
adds r0, r1
|
||||
|
@ -1175,7 +1175,7 @@ sub_80FF1C0: @ 80FF1C0
|
|||
movs r0, 0x1
|
||||
strh r0, [r6, 0x2E]
|
||||
adds r0, r6, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
ldrh r0, [r6, 0x3C]
|
||||
strh r5, [r6, 0x2E]
|
||||
lsls r4, 16
|
||||
|
@ -1272,7 +1272,7 @@ sub_80FF268: @ 80FF268
|
|||
adds r3, r4, 0
|
||||
adds r3, 0x22
|
||||
movs r1, 0x1
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
_080FF28A:
|
||||
ldrh r0, [r4, 0x22]
|
||||
adds r0, 0x20
|
||||
|
@ -3161,7 +3161,7 @@ _08100180:
|
|||
adds r1, r2, 0
|
||||
bl sub_8100524
|
||||
adds r0, r4, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _08100196
|
||||
|
@ -3190,7 +3190,7 @@ _081001B4:
|
|||
adds r1, r2, 0
|
||||
bl sub_8100524
|
||||
adds r0, r4, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _081001CA
|
||||
|
@ -3219,7 +3219,7 @@ _081001E6:
|
|||
adds r1, r2, 0
|
||||
bl sub_8100524
|
||||
adds r0, r4, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _081001FC
|
||||
|
@ -3272,7 +3272,7 @@ _08100254:
|
|||
adds r1, r2, 0
|
||||
bl sub_8100524
|
||||
adds r0, r4, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _0810026A
|
||||
|
@ -3403,7 +3403,7 @@ _08100362:
|
|||
adds r1, r2, 0
|
||||
bl sub_8100524
|
||||
adds r0, r4, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _08100378
|
||||
|
@ -3514,7 +3514,7 @@ _08100448:
|
|||
adds r1, r2, 0
|
||||
bl sub_8100524
|
||||
adds r0, r4, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _081004FC
|
||||
|
@ -3566,7 +3566,7 @@ _081004B6:
|
|||
adds r1, r2, 0
|
||||
bl sub_8100524
|
||||
adds r0, r4, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _081004FC
|
||||
|
@ -4152,7 +4152,7 @@ _08100918:
|
|||
subs r1, r5
|
||||
lsls r1, 16
|
||||
asrs r1, 16
|
||||
bl sub_80A74F4
|
||||
bl ArcTan2Neg
|
||||
lsls r0, 16
|
||||
lsrs r4, r0, 16
|
||||
bl IsContest
|
||||
|
@ -4869,7 +4869,7 @@ _08100F06:
|
|||
ldr r6, =gBattleAnimAttacker
|
||||
ldrb r0, [r6]
|
||||
movs r1, 0
|
||||
bl sub_80A60AC
|
||||
bl GetBattlerSpriteCoord2
|
||||
lsls r0, 24
|
||||
ldr r4, =gBattleAnimArgs
|
||||
lsrs r0, 24
|
||||
|
@ -4878,7 +4878,7 @@ _08100F06:
|
|||
strh r0, [r5, 0x20]
|
||||
ldrb r0, [r6]
|
||||
movs r1, 0x1
|
||||
bl sub_80A60AC
|
||||
bl GetBattlerSpriteCoord2
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
ldrh r4, [r4, 0x2]
|
||||
|
@ -5451,7 +5451,7 @@ _0810137A:
|
|||
adds r3, r5, 0
|
||||
adds r3, 0x22
|
||||
adds r0, r6, 0
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
movs r2, 0
|
||||
ldrsh r1, [r4, r2]
|
||||
adds r0, r5, 0
|
||||
|
@ -9082,7 +9082,7 @@ _08103074:
|
|||
subs r0, 0x28
|
||||
strh r0, [r4, 0x36]
|
||||
adds r0, r4, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldrh r0, [r5, 0x6]
|
||||
strh r0, [r4, 0x38]
|
||||
ldr r0, =sub_81030B0
|
||||
|
@ -9097,7 +9097,7 @@ _08103074:
|
|||
sub_81030B0: @ 81030B0
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _08103100
|
||||
|
@ -10172,7 +10172,7 @@ _0810390E:
|
|||
subs r1, r2
|
||||
lsls r1, 16
|
||||
asrs r1, 16
|
||||
bl sub_80A74F4
|
||||
bl ArcTan2Neg
|
||||
lsls r0, 16
|
||||
movs r1, 0xF0
|
||||
lsls r1, 24
|
||||
|
@ -10754,7 +10754,7 @@ _08103DB6:
|
|||
movs r1, 0
|
||||
mov r2, sp
|
||||
mov r3, r10
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
b _08103E42
|
||||
.pool
|
||||
_08103E20:
|
||||
|
@ -11093,7 +11093,7 @@ _081040CC:
|
|||
subs r1, r2
|
||||
lsls r1, 16
|
||||
asrs r1, 16
|
||||
bl sub_80A74F4
|
||||
bl ArcTan2Neg
|
||||
lsls r0, 16
|
||||
movs r1, 0xC0
|
||||
lsls r1, 24
|
||||
|
@ -11528,7 +11528,7 @@ _08104448:
|
|||
adds r0, r6
|
||||
strh r0, [r5, 0x36]
|
||||
adds r0, r5, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldrh r0, [r7]
|
||||
strh r0, [r5, 0x38]
|
||||
ldrh r0, [r5, 0x2E]
|
||||
|
@ -11548,7 +11548,7 @@ _08104448:
|
|||
sub_81044BC: @ 81044BC
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _08104520
|
||||
|
@ -11659,7 +11659,7 @@ _0810458A:
|
|||
sub_8104594: @ 8104594
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _081045A8
|
||||
|
@ -12761,7 +12761,7 @@ sub_8104E74: @ 8104E74
|
|||
adds r5, r1, r0
|
||||
ldr r4, =gBattleAnimTarget
|
||||
ldrb r0, [r4]
|
||||
bl sub_80A6190
|
||||
bl GetBattlerYCoordWithElevation
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
adds r0, 0x20
|
||||
|
@ -12969,7 +12969,7 @@ sub_810501C: @ 810501C
|
|||
movs r5, 0
|
||||
strh r0, [r4, 0x20]
|
||||
ldrb r0, [r6]
|
||||
bl sub_80A6190
|
||||
bl GetBattlerYCoordWithElevation
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
adds r0, 0x10
|
||||
|
@ -13220,7 +13220,7 @@ _081051F2:
|
|||
adds r1, r4, 0
|
||||
mov r2, sp
|
||||
adds r3, r7, 0
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
cmp r4, 0
|
||||
bne _08105230
|
||||
adds r0, r5, 0
|
||||
|
@ -13271,7 +13271,7 @@ _0810526A:
|
|||
sub_8105284: @ 8105284
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0810529E
|
||||
|
@ -13466,7 +13466,7 @@ _081053FA:
|
|||
mov r2, sp
|
||||
mov r3, sp
|
||||
adds r3, 0x2
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
b _0810546C
|
||||
.pool
|
||||
_0810544C:
|
||||
|
@ -13526,7 +13526,7 @@ _0810549E:
|
|||
ldrh r0, [r2]
|
||||
strh r0, [r5, 0x2E]
|
||||
adds r0, r5, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldr r1, =sub_8105284
|
||||
str r1, [r5, 0x1C]
|
||||
adds r0, r5, 0
|
||||
|
@ -15088,7 +15088,7 @@ sub_8106140: @ 8106140
|
|||
lsrs r0, 24
|
||||
strh r0, [r4, 0x36]
|
||||
adds r0, r4, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldr r0, =sub_810618C
|
||||
str r0, [r4, 0x1C]
|
||||
pop {r4,r5}
|
||||
|
@ -15101,7 +15101,7 @@ sub_8106140: @ 8106140
|
|||
sub_810618C: @ 810618C
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _081061B6
|
||||
|
@ -17006,7 +17006,7 @@ sub_81070AC: @ 81070AC
|
|||
adds r3, r5, 0
|
||||
adds r3, 0x22
|
||||
movs r1, 0
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
ldrh r0, [r5, 0x22]
|
||||
adds r0, 0x28
|
||||
strh r0, [r5, 0x22]
|
||||
|
@ -17269,7 +17269,7 @@ _081072D8:
|
|||
lsrs r0, 24
|
||||
strh r0, [r6, 0x36]
|
||||
adds r0, r6, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldr r0, =SpriteCallbackDummy
|
||||
bl CreateInvisibleSpriteWithCallback
|
||||
adds r4, r0, 0
|
||||
|
@ -17339,7 +17339,7 @@ sub_8107380: @ 8107380
|
|||
movs r0, 0x1
|
||||
strh r0, [r5, 0x2E]
|
||||
adds r0, r5, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
mov r1, r8
|
||||
lsrs r6, r1, 8
|
||||
movs r0, 0x2E
|
||||
|
@ -17464,7 +17464,7 @@ _08107482:
|
|||
adds r0, r7
|
||||
strh r0, [r5, 0x36]
|
||||
adds r0, r5, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldr r0, =sub_81074E4
|
||||
str r0, [r5, 0x1C]
|
||||
adds r2, r5, 0
|
||||
|
@ -17502,7 +17502,7 @@ sub_81074E4: @ 81074E4
|
|||
strb r0, [r2]
|
||||
_08107506:
|
||||
adds r0, r4, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _08107518
|
||||
|
@ -17637,7 +17637,7 @@ sub_81075EC: @ 81075EC
|
|||
lsrs r0, 24
|
||||
strh r0, [r5, 0x36]
|
||||
adds r0, r5, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
movs r0, 0x2E
|
||||
ldrsh r1, [r5, r0]
|
||||
movs r0, 0xD2
|
||||
|
@ -17678,7 +17678,7 @@ _08107660:
|
|||
sub_8107674: @ 8107674
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _08107688
|
||||
|
@ -20234,7 +20234,7 @@ _08108B1A:
|
|||
sub_8108B2C: @ 8108B2C
|
||||
push {r4-r6,lr}
|
||||
adds r6, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _08108B86
|
||||
|
@ -20283,7 +20283,7 @@ _08108B86:
|
|||
sub_8108B94: @ 8108B94
|
||||
push {r4-r6,lr}
|
||||
adds r5, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _08108BD0
|
||||
|
@ -21144,7 +21144,7 @@ sub_8109244: @ 8109244
|
|||
lsrs r0, 24
|
||||
strh r0, [r5, 0x36]
|
||||
adds r0, r5, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldr r0, =sub_810929C
|
||||
str r0, [r5, 0x1C]
|
||||
_0810928E:
|
||||
|
@ -21158,7 +21158,7 @@ _0810928E:
|
|||
sub_810929C: @ 810929C
|
||||
push {r4-r6,lr}
|
||||
adds r6, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _081092E4
|
||||
|
@ -22386,7 +22386,7 @@ _08109C3E:
|
|||
sub_8109C4C: @ 8109C4C
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _08109CA4
|
||||
|
@ -23433,7 +23433,7 @@ sub_810A46C: @ 810A46C
|
|||
lsrs r0, 24
|
||||
strh r0, [r4, 0x36]
|
||||
adds r0, r4, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldrh r0, [r5, 0x4]
|
||||
strh r0, [r4, 0x38]
|
||||
ldrh r0, [r5, 0xA]
|
||||
|
@ -23468,7 +23468,7 @@ sub_810A46C: @ 810A46C
|
|||
sub_810A4F4: @ 810A4F4
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _0810A55E
|
||||
|
@ -24336,7 +24336,7 @@ sub_810AB78: @ 810AB78
|
|||
strh r0, [r4, 0x36]
|
||||
strh r6, [r4, 0x38]
|
||||
adds r0, r4, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldr r1, =sub_810ACC0
|
||||
adds r0, r4, 0
|
||||
bl StoreSpriteCallbackInData6
|
||||
|
@ -24394,7 +24394,7 @@ _0810AC86:
|
|||
sub_810AC8C: @ 810AC8C
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0810ACB4
|
||||
|
@ -26048,7 +26048,7 @@ _0810B990:
|
|||
adds r3, r4, 0
|
||||
adds r3, 0x22
|
||||
movs r1, 0x1
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
ldrb r0, [r0]
|
||||
bl GetBattlerSide
|
||||
|
@ -26155,7 +26155,7 @@ _0810BA74:
|
|||
adds r3, r5, 0
|
||||
adds r3, 0x36
|
||||
movs r1, 0x1
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
_0810BA86:
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
ldrb r0, [r0]
|
||||
|
@ -26454,7 +26454,7 @@ _0810BCE0:
|
|||
adds r3, r5, 0
|
||||
adds r3, 0x36
|
||||
movs r1, 0x1
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
_0810BCF2:
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
ldrb r0, [r0]
|
||||
|
@ -26652,7 +26652,7 @@ _0810BE6C:
|
|||
adds r3, r4, 0
|
||||
adds r3, 0x22
|
||||
movs r1, 0
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
ldrb r0, [r0]
|
||||
bl GetBattlerSide
|
||||
|
@ -26719,7 +26719,7 @@ _0810BEF4:
|
|||
adds r3, r5, 0
|
||||
adds r3, 0x22
|
||||
movs r1, 0
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
ldrb r0, [r4]
|
||||
bl GetBattlerSide
|
||||
lsls r0, 24
|
||||
|
@ -26762,7 +26762,7 @@ _0810BF52:
|
|||
adds r3, r5, 0
|
||||
adds r3, 0x22
|
||||
movs r1, 0
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
ldrb r0, [r4]
|
||||
bl GetBattlerSide
|
||||
lsls r0, 24
|
||||
|
@ -26828,7 +26828,7 @@ _0810BFCC:
|
|||
adds r0, r1
|
||||
strh r0, [r5, 0x36]
|
||||
adds r0, r5, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
movs r0, 0x40
|
||||
strh r0, [r5, 0x38]
|
||||
ldr r1, =sub_810C008
|
||||
|
@ -26845,7 +26845,7 @@ _0810BFCC:
|
|||
sub_810C008: @ 810C008
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _0810C092
|
||||
|
@ -27192,7 +27192,7 @@ sub_810C2F0: @ 810C2F0
|
|||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
strh r0, [r4, 0x22]
|
||||
ldr r0, =sub_80A7820
|
||||
ldr r0, =TranslateAnimSpriteToTargetMonLocation
|
||||
str r0, [r4, 0x1C]
|
||||
pop {r4,r5}
|
||||
pop {r0}
|
||||
|
@ -27608,7 +27608,7 @@ _0810C684:
|
|||
strb r0, [r1]
|
||||
_0810C6B8:
|
||||
adds r0, r5, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldr r0, =sub_810C6D4
|
||||
str r0, [r5, 0x1C]
|
||||
pop {r3}
|
||||
|
@ -27642,7 +27642,7 @@ _0810C6F4:
|
|||
b _0810C90C
|
||||
_0810C6F6:
|
||||
adds r0, r4, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
ldr r1, =gSineTable
|
||||
movs r2, 0x38
|
||||
ldrsh r0, [r4, r2]
|
||||
|
@ -27731,12 +27731,12 @@ _0810C78E:
|
|||
ands r0, r1
|
||||
strh r0, [r4, 0x38]
|
||||
adds r0, r4, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
b _0810C90C
|
||||
.pool
|
||||
_0810C7BC:
|
||||
adds r0, r4, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
ldr r1, =gSineTable
|
||||
movs r2, 0x38
|
||||
ldrsh r0, [r4, r2]
|
||||
|
@ -27872,7 +27872,7 @@ _0810C8B6:
|
|||
.pool
|
||||
_0810C8D0:
|
||||
adds r0, r4, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0810C90C
|
||||
|
@ -28414,7 +28414,7 @@ _0810CCCE:
|
|||
sub_810CD1C: @ 810CD1C
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0810CD3E
|
||||
|
@ -29021,7 +29021,7 @@ _0810D1FE:
|
|||
strh r0, [r6, 0x34]
|
||||
strh r0, [r6, 0x36]
|
||||
adds r0, r6, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldrh r0, [r4, 0xA]
|
||||
strh r0, [r6, 0x38]
|
||||
ldrh r0, [r4, 0x8]
|
||||
|
@ -29039,7 +29039,7 @@ _0810D1FE:
|
|||
sub_810D240: @ 810D240
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _0810D26C
|
||||
|
@ -29616,7 +29616,7 @@ sub_810D6A8: @ 810D6A8
|
|||
lsrs r0, 24
|
||||
strh r0, [r4, 0x36]
|
||||
adds r0, r4, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldr r1, =move_anim_8074EE0
|
||||
adds r0, r4, 0
|
||||
bl StoreSpriteCallbackInData6
|
||||
|
@ -29892,7 +29892,7 @@ _0810D918:
|
|||
lsrs r0, 24
|
||||
strh r0, [r5, 0x36]
|
||||
adds r0, r5, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldr r1, =DestroyAnimSprite
|
||||
adds r0, r5, 0
|
||||
bl StoreSpriteCallbackInData6
|
||||
|
@ -30234,7 +30234,7 @@ _0810DBC2:
|
|||
sub_810DC10: @ 810DC10
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0810DC24
|
||||
|
@ -30270,7 +30270,7 @@ _0810DC44:
|
|||
movs r1, 0x1
|
||||
mov r2, sp
|
||||
adds r3, r6, 0
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
ldrb r0, [r0]
|
||||
bl GetBattlerSide
|
||||
|
@ -30309,7 +30309,7 @@ _0810DC72:
|
|||
sub_810DCB4: @ 810DCB4
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0810DCC8
|
||||
|
@ -30396,7 +30396,7 @@ sub_810DD50: @ 810DD50
|
|||
adds r3, r4, 0
|
||||
adds r3, 0x22
|
||||
movs r1, 0x1
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
ldrb r0, [r0]
|
||||
bl GetBattlerSide
|
||||
|
@ -30457,7 +30457,7 @@ _0810DDE0:
|
|||
adds r3, r4, 0
|
||||
adds r3, 0x22
|
||||
movs r1, 0x1
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
ldrb r0, [r0]
|
||||
bl GetBattlerSide
|
||||
|
@ -30716,7 +30716,7 @@ _0810DFC8:
|
|||
adds r0, r4
|
||||
strh r0, [r6, 0x36]
|
||||
adds r0, r6, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldr r0, =sub_80A67BC
|
||||
str r0, [r6, 0x1C]
|
||||
ldr r1, =sub_810E028
|
||||
|
@ -30732,7 +30732,7 @@ _0810DFC8:
|
|||
sub_810E028: @ 810E028
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0810E03C
|
||||
|
@ -30828,7 +30828,7 @@ _0810E0EC:
|
|||
adds r3, r5, 0
|
||||
adds r3, 0x36
|
||||
movs r1, 0x1
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
_0810E0FE:
|
||||
ldr r4, =gBattleAnimArgs
|
||||
ldrh r0, [r4, 0x4]
|
||||
|
@ -30971,7 +30971,7 @@ _0810E1FE:
|
|||
lsrs r0, 24
|
||||
strh r0, [r5, 0x36]
|
||||
adds r0, r5, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
ldr r0, =sub_810E24C
|
||||
str r0, [r5, 0x1C]
|
||||
pop {r4,r5}
|
||||
|
@ -30987,7 +30987,7 @@ sub_810E24C: @ 810E24C
|
|||
movs r0, 0x1
|
||||
strh r0, [r4, 0x2E]
|
||||
adds r0, r4, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
ldrh r1, [r4, 0x34]
|
||||
lsrs r0, r1, 8
|
||||
cmp r0, 0xC8
|
||||
|
@ -32074,7 +32074,7 @@ sub_810EA4C: @ 810EA4C
|
|||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
strh r0, [r4, 0x22]
|
||||
ldr r0, =sub_80A7820
|
||||
ldr r0, =TranslateAnimSpriteToTargetMonLocation
|
||||
str r0, [r4, 0x1C]
|
||||
pop {r4,r5}
|
||||
pop {r0}
|
||||
|
@ -32913,7 +32913,7 @@ sub_810F084: @ 810F084
|
|||
asrs r5, 16
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl sub_80A74F4
|
||||
bl ArcTan2Neg
|
||||
lsls r0, 16
|
||||
movs r1, 0xC0
|
||||
lsls r1, 24
|
||||
|
@ -34508,7 +34508,7 @@ _0810FDE8:
|
|||
sub_810FDF0: @ 810FDF0
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0810FE0E
|
||||
|
@ -34537,7 +34537,7 @@ sub_810FE14: @ 810FE14
|
|||
adds r4, r1, r0
|
||||
ldr r0, =gBattleAnimTarget
|
||||
ldrb r0, [r0]
|
||||
bl sub_80A6190
|
||||
bl GetBattlerYCoordWithElevation
|
||||
lsls r0, 24
|
||||
lsrs r1, r0, 24
|
||||
adds r0, r1, 0
|
||||
|
@ -35235,7 +35235,7 @@ _081103C4:
|
|||
ldr r5, =gBattleAnimTarget
|
||||
ldrb r0, [r5]
|
||||
movs r1, 0x2
|
||||
bl sub_80A60AC
|
||||
bl GetBattlerSpriteCoord2
|
||||
lsls r0, 24
|
||||
ldr r4, =gBattleAnimArgs
|
||||
lsrs r0, 24
|
||||
|
@ -35244,7 +35244,7 @@ _081103C4:
|
|||
strh r0, [r6, 0x20]
|
||||
ldrb r0, [r5]
|
||||
movs r1, 0x3
|
||||
bl sub_80A60AC
|
||||
bl GetBattlerSpriteCoord2
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
ldrh r1, [r4, 0x2]
|
||||
|
@ -35314,7 +35314,7 @@ _08110478:
|
|||
ldr r5, =gBattleAnimTarget
|
||||
ldrb r0, [r5]
|
||||
movs r1, 0x2
|
||||
bl sub_80A60AC
|
||||
bl GetBattlerSpriteCoord2
|
||||
lsls r0, 24
|
||||
ldr r4, =gBattleAnimArgs
|
||||
lsrs r0, 24
|
||||
|
@ -35323,7 +35323,7 @@ _08110478:
|
|||
strh r0, [r6, 0x20]
|
||||
ldrb r0, [r5]
|
||||
movs r1, 0x3
|
||||
bl sub_80A60AC
|
||||
bl GetBattlerSpriteCoord2
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
ldrh r1, [r4, 0x2]
|
||||
|
@ -35407,7 +35407,7 @@ _08110548:
|
|||
adds r3, r5, 0
|
||||
adds r3, 0x36
|
||||
movs r1, 0x1
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
_0811055A:
|
||||
adds r0, r5, 0
|
||||
bl sub_80A6FD4
|
||||
|
@ -35426,7 +35426,7 @@ _0811055A:
|
|||
sub_811057C: @ 811057C
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _08110592
|
||||
|
@ -35464,7 +35464,7 @@ sub_81105B4: @ 81105B4
|
|||
adds r3, r4, 0
|
||||
adds r3, 0x22
|
||||
movs r1, 0
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
ldrb r0, [r0]
|
||||
bl GetBattlerSide
|
||||
|
@ -35745,7 +35745,7 @@ _081107B2:
|
|||
subs r1, r2
|
||||
lsls r1, 16
|
||||
asrs r1, 16
|
||||
bl sub_80A74F4
|
||||
bl ArcTan2Neg
|
||||
lsls r0, 16
|
||||
movs r1, 0xC0
|
||||
lsls r1, 24
|
||||
|
@ -35844,7 +35844,7 @@ sub_81108CC: @ 81108CC
|
|||
ands r1, r0
|
||||
strb r1, [r2]
|
||||
adds r0, r4, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _081108F8
|
||||
|
@ -35879,7 +35879,7 @@ _0811090E:
|
|||
lsls r0, 16
|
||||
lsrs r6, r0, 16
|
||||
adds r0, r4, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
bne _08110988
|
||||
|
@ -35899,7 +35899,7 @@ _0811090E:
|
|||
subs r1, r2
|
||||
lsls r1, 16
|
||||
asrs r1, 16
|
||||
bl sub_80A74F4
|
||||
bl ArcTan2Neg
|
||||
lsls r0, 16
|
||||
movs r1, 0xC0
|
||||
lsls r1, 24
|
||||
|
@ -35987,7 +35987,7 @@ sub_81109F0: @ 81109F0
|
|||
adds r3, r5, 0
|
||||
adds r3, 0x22
|
||||
movs r1, 0
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
_08110A10:
|
||||
ldrh r0, [r6]
|
||||
ldrh r1, [r5, 0x20]
|
||||
|
@ -37059,7 +37059,7 @@ _08111304:
|
|||
sub_811131C: @ 811131C
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0811134E
|
||||
|
@ -37205,7 +37205,7 @@ sub_8111418: @ 8111418
|
|||
bl StartSpriteAffineAnim
|
||||
_08111434:
|
||||
adds r0, r4, 0
|
||||
bl sub_80A7820
|
||||
bl TranslateAnimSpriteToTargetMonLocation
|
||||
pop {r4}
|
||||
pop {r0}
|
||||
bx r0
|
||||
|
@ -37483,7 +37483,7 @@ sub_8111674: @ 8111674
|
|||
adds r4, r0, 0
|
||||
bl sub_8111764
|
||||
adds r0, r4, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _08111694
|
||||
|
@ -37541,7 +37541,7 @@ sub_81116E8: @ 81116E8
|
|||
movs r0, 0x1
|
||||
strh r0, [r4, 0x2E]
|
||||
adds r0, r4, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
movs r1, 0x38
|
||||
ldrsh r0, [r4, r1]
|
||||
movs r1, 0xA
|
||||
|
@ -40203,7 +40203,7 @@ sub_8112C6C: @ 8112C6C
|
|||
lsrs r0, 24
|
||||
strh r0, [r4, 0x1A]
|
||||
ldrb r0, [r5]
|
||||
bl sub_80A6190
|
||||
bl GetBattlerYCoordWithElevation
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
strh r0, [r4, 0x1C]
|
||||
|
@ -41135,7 +41135,7 @@ _0811342A:
|
|||
strb r5, [r0, 0x9]
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
ldrb r0, [r0]
|
||||
bl sub_80A6190
|
||||
bl GetBattlerYCoordWithElevation
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
adds r1, r0, 0
|
||||
|
@ -42031,7 +42031,7 @@ _08113B60:
|
|||
sub_8113B90: @ 8113B90
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _08113BA4
|
||||
|
@ -43699,7 +43699,7 @@ sub_8114994: @ 8114994
|
|||
sub_81149FC: @ 81149FC
|
||||
push {r4,r5,lr}
|
||||
adds r5, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _08114A50
|
||||
|
@ -43746,7 +43746,7 @@ _08114A50:
|
|||
sub_8114A60: @ 8114A60
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _08114A74
|
||||
|
@ -43817,13 +43817,13 @@ sub_8114AF0: @ 8114AF0
|
|||
ldr r4, =gBattleAnimTarget
|
||||
ldrb r0, [r4]
|
||||
movs r1, 0x2
|
||||
bl sub_80A60AC
|
||||
bl GetBattlerSpriteCoord2
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
mov r8, r0
|
||||
ldrb r0, [r4]
|
||||
movs r1, 0x3
|
||||
bl sub_80A60AC
|
||||
bl GetBattlerSpriteCoord2
|
||||
lsls r0, 24
|
||||
lsrs r7, r0, 24
|
||||
bl Random2
|
||||
|
@ -44120,7 +44120,7 @@ _08114D78:
|
|||
strh r0, [r4, 0x22]
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
ldrb r0, [r0]
|
||||
bl sub_80A6190
|
||||
bl GetBattlerYCoordWithElevation
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
adds r1, r0, 0
|
||||
|
@ -44460,7 +44460,7 @@ _08115046:
|
|||
strh r0, [r4, 0x20]
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
ldrb r0, [r0]
|
||||
bl sub_80A6190
|
||||
bl GetBattlerYCoordWithElevation
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
adds r1, r0, 0
|
||||
|
@ -44663,7 +44663,7 @@ _081151DA:
|
|||
adds r0, r6
|
||||
strh r0, [r5, 0x20]
|
||||
adds r0, r4, 0
|
||||
bl sub_80A6190
|
||||
bl GetBattlerYCoordWithElevation
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
adds r0, 0x1E
|
||||
|
@ -44693,7 +44693,7 @@ _081151DA:
|
|||
sub_8115228: @ 8115228
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0811523C
|
||||
|
@ -44735,7 +44735,7 @@ _08115262:
|
|||
adds r0, r1
|
||||
strh r0, [r6, 0x20]
|
||||
adds r0, r5, 0
|
||||
bl sub_80A6190
|
||||
bl GetBattlerYCoordWithElevation
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
adds r0, 0x20
|
||||
|
@ -50366,8 +50366,8 @@ _08118132:
|
|||
.pool
|
||||
thumb_func_end SetAnimBgAttribute
|
||||
|
||||
thumb_func_start sub_8118140
|
||||
sub_8118140: @ 8118140
|
||||
thumb_func_start GetAnimBgAttribute
|
||||
GetAnimBgAttribute: @ 8118140
|
||||
push {r4,lr}
|
||||
sub sp, 0x4
|
||||
lsls r0, 24
|
||||
|
@ -50441,7 +50441,7 @@ _081181CA:
|
|||
pop {r4}
|
||||
pop {r1}
|
||||
bx r1
|
||||
thumb_func_end sub_8118140
|
||||
thumb_func_end GetAnimBgAttribute
|
||||
|
||||
thumb_func_start HandleIntroSlide
|
||||
HandleIntroSlide: @ 81181D4
|
||||
|
|
|
@ -231,7 +231,7 @@ sub_815A254: @ 815A254
|
|||
subs r1, r6
|
||||
lsls r1, 16
|
||||
asrs r1, 16
|
||||
bl sub_80A74F4
|
||||
bl ArcTan2Neg
|
||||
lsls r0, 16
|
||||
movs r1, 0xC0
|
||||
lsls r1, 23
|
||||
|
@ -775,7 +775,7 @@ sub_815A6C4: @ 815A6C4
|
|||
movs r1, 0
|
||||
mov r2, sp
|
||||
adds r3, r5, 0
|
||||
bl sub_80A8924
|
||||
bl SetAverageBattlerPositions
|
||||
ldr r0, =gBattleAnimAttacker
|
||||
ldrb r0, [r0]
|
||||
bl GetBattlerSide
|
||||
|
@ -816,7 +816,7 @@ _0815A6F8:
|
|||
sub_815A73C: @ 815A73C
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0815A75E
|
||||
|
@ -1625,7 +1625,7 @@ _0815ADDC:
|
|||
ldr r4, =gBattleAnimTarget
|
||||
_0815ADDE:
|
||||
ldrb r0, [r4]
|
||||
bl sub_80A6190
|
||||
bl GetBattlerYCoordWithElevation
|
||||
lsls r0, 24
|
||||
lsrs r6, r0, 24
|
||||
ldrb r0, [r4]
|
||||
|
@ -6104,7 +6104,7 @@ _0815D26E:
|
|||
strh r0, [r4, 0x18]
|
||||
_0815D2A0:
|
||||
adds r0, r5, 0
|
||||
bl sub_80A6190
|
||||
bl GetBattlerYCoordWithElevation
|
||||
lsls r0, 24
|
||||
lsrs r0, 24
|
||||
subs r0, 0x22
|
||||
|
@ -8524,7 +8524,7 @@ _0815E5FE:
|
|||
lsls r0, 2
|
||||
ldr r1, =gSprites
|
||||
adds r0, r1
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
ldrh r0, [r4, 0xC]
|
||||
adds r0, 0x1
|
||||
strh r0, [r4, 0xC]
|
||||
|
@ -8542,7 +8542,7 @@ _0815E634:
|
|||
lsls r0, 2
|
||||
ldr r1, =gSprites
|
||||
adds r0, r1
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0815E6D2
|
||||
|
@ -9804,11 +9804,11 @@ _0815F022:
|
|||
strh r0, [r4, 0x34]
|
||||
strh r1, [r4, 0x36]
|
||||
adds r0, r4, 0
|
||||
bl obj_translate_based_on_private_1_2_3_4
|
||||
bl InitAnimLinearTranslation
|
||||
b _0815F0F8
|
||||
_0815F038:
|
||||
adds r0, r4, 0
|
||||
bl sub_80A6F3C
|
||||
bl TranslateAnimLinear
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _0815F106
|
||||
|
|
|
@ -1487,7 +1487,7 @@ sub_8171134: @ 8171134
|
|||
push {r4,r5,lr}
|
||||
sub sp, 0x4
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _081711D2
|
||||
|
@ -2671,7 +2671,7 @@ sub_8171AAC: @ 8171AAC
|
|||
orrs r0, r1
|
||||
strb r0, [r3]
|
||||
adds r0, r4, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _08171ADC
|
||||
|
@ -5652,7 +5652,7 @@ _081733C0:
|
|||
sub_81733D4: @ 81733D4
|
||||
push {r4,lr}
|
||||
adds r4, r0, 0
|
||||
bl AnimateBallThrow
|
||||
bl TranslateAnimArc
|
||||
lsls r0, 24
|
||||
cmp r0, 0
|
||||
beq _081733F6
|
||||
|
|
|
@ -86,20 +86,3 @@ gUnknown_0853EF14:: @ 853EF14
|
|||
.align 2
|
||||
gUnknown_0853EF18:: @ 853EF18
|
||||
spr_template 0x2714, 0x2714, gUnknown_085249CC, gUnknown_0853EEF8, NULL, gUnknown_0853EF14, sub_80A8A6C
|
||||
|
||||
.align 2
|
||||
gUnknown_0853EF30:: @ 853EF30
|
||||
.byte 0xf0, 0xf0, 0x0c, 0x80, 0xf0, 0x30, 0x0d, 0x84, 0x30, 0xf0, 0x0e, 0x86, 0x30, 0x30, 0x08, 0x88
|
||||
|
||||
.align 2
|
||||
gUnknown_0853EF40:: @ 853EF40
|
||||
.4byte 0x00000004, gUnknown_0853EF30
|
||||
|
||||
.align 2
|
||||
gUnknown_0853EF48:: @ 853EF48
|
||||
spr_template 0x271a, 0x271a, gUnknown_08524A3C, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, SpriteCallbackDummy
|
||||
|
||||
.align 2
|
||||
gUnknown_0853EF60:: @ 853EF60
|
||||
spr_template 0x2798, 0x2798, gUnknown_08524904, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, sub_80A9E44
|
||||
|
||||
|
|
|
@ -828,7 +828,7 @@ gUnknown_08592DE4:: @ 8592DE4
|
|||
|
||||
.align 2
|
||||
gUnknown_08592DFC:: @ 8592DFC
|
||||
spr_template 0x2721, 0x2721, gUnknown_08524904, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, sub_80A7820
|
||||
spr_template 0x2721, 0x2721, gUnknown_08524904, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, TranslateAnimSpriteToTargetMonLocation
|
||||
|
||||
.align 2
|
||||
gUnknown_08592E14:: @ 8592E14
|
||||
|
@ -1190,15 +1190,15 @@ gUnknown_08593424:: @ 8593424
|
|||
|
||||
.align 2
|
||||
gSupersonicWaveSpriteTemplate:: @ 8593428
|
||||
spr_template 0x27b3, 0x27b3, gUnknown_08524A14, gDummySpriteAnimTable, NULL, gUnknown_08593420, sub_80A7820
|
||||
spr_template 0x27b3, 0x27b3, gUnknown_08524A14, gDummySpriteAnimTable, NULL, gUnknown_08593420, TranslateAnimSpriteToTargetMonLocation
|
||||
|
||||
.align 2
|
||||
gScreechWaveSpriteTemplate:: @ 8593440
|
||||
spr_template 0x27b4, 0x27b4, gUnknown_08524A14, gDummySpriteAnimTable, NULL, gUnknown_08593420, sub_80A7820
|
||||
spr_template 0x27b4, 0x27b4, gUnknown_08524A14, gDummySpriteAnimTable, NULL, gUnknown_08593420, TranslateAnimSpriteToTargetMonLocation
|
||||
|
||||
.align 2
|
||||
gUnknown_08593458:: @ 8593458
|
||||
spr_template 0x2814, 0x2814, gUnknown_08524A1C, gDummySpriteAnimTable, NULL, gUnknown_08593420, sub_80A7820
|
||||
spr_template 0x2814, 0x2814, gUnknown_08524A1C, gDummySpriteAnimTable, NULL, gUnknown_08593420, TranslateAnimSpriteToTargetMonLocation
|
||||
|
||||
.align 2
|
||||
gUnknown_08593470:: @ 8593470
|
||||
|
@ -1991,7 +1991,7 @@ gUnknown_085954D0:: @ 85954D0
|
|||
|
||||
.align 2
|
||||
gEmberSpriteTemplate:: @ 85954D4
|
||||
spr_template 0x272d, 0x272d, gUnknown_08524914, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, sub_80A7820
|
||||
spr_template 0x272d, 0x272d, gUnknown_08524914, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, TranslateAnimSpriteToTargetMonLocation
|
||||
|
||||
.align 2
|
||||
gEmberFlareSpriteTemplate:: @ 85954EC
|
||||
|
@ -2143,7 +2143,7 @@ gBattleAnimSpriteTemplate_859574C:: @ 859574C
|
|||
|
||||
.align 2
|
||||
gUnknown_08595764:: @ 8595764
|
||||
spr_template 0x27bb, 0x27bb, gUnknown_0852490C, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, sub_80A7820
|
||||
spr_template 0x27bb, 0x27bb, gUnknown_0852490C, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, TranslateAnimSpriteToTargetMonLocation
|
||||
|
||||
.align 2
|
||||
gUnknown_0859577C:: @ 859577C
|
||||
|
@ -3067,7 +3067,7 @@ gUnknown_08596624:: @ 8596624
|
|||
|
||||
.align 2
|
||||
gUnknown_0859663C:: @ 859663C
|
||||
spr_template 0x27b3, 0x27b3, gUnknown_08524954, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, sub_80A7820
|
||||
spr_template 0x27b3, 0x27b3, gUnknown_08524954, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, TranslateAnimSpriteToTargetMonLocation
|
||||
|
||||
.align 2
|
||||
gUnknown_08596654:: @ 8596654
|
||||
|
|
|
@ -6166,7 +6166,7 @@ Move_WING_ATTACK:
|
|||
monbgprio_28 ANIM_TARGET
|
||||
setalpha 12, 8
|
||||
loopsewithpan SE_W017, -64, 20, 2
|
||||
createvisualtask sub_80D5738, 2, 0, 12, 4, 1, 4
|
||||
createvisualtask AnimTask_TranslateMonElliptical, 2, 0, 12, 4, 1, 4
|
||||
createvisualtask sub_810DED8, 5, 1, 70
|
||||
createsprite gBattleAnimSpriteTemplate_85962A4, 2, -25, 0, 0, 0, 20
|
||||
createsprite gBattleAnimSpriteTemplate_85962A4, 2, 25, 0, 0, 0, 20
|
||||
|
@ -6694,8 +6694,8 @@ Move_SUBMISSION:
|
|||
waitplaysewithpan SE_W004, +63, 70
|
||||
waitplaysewithpan SE_W104, -64, 80
|
||||
waitplaysewithpan SE_W004, +63, 0x5A
|
||||
createvisualtask sub_80D5738, 2, 0, -18, 6, 6, 4
|
||||
createvisualtask sub_80D5738, 2, 1, 18, 6, 6, 4
|
||||
createvisualtask AnimTask_TranslateMonElliptical, 2, 0, -18, 6, 6, 4
|
||||
createvisualtask AnimTask_TranslateMonElliptical, 2, 1, 18, 6, 6, 4
|
||||
call Submission1
|
||||
call Submission1
|
||||
call Submission1
|
||||
|
@ -7219,7 +7219,7 @@ Move_STEEL_WING:
|
|||
monbgprio_28 ANIM_TARGET
|
||||
setalpha 12, 8
|
||||
loopsewithpan SE_W017, -64, 20, 2
|
||||
createvisualtask sub_80D5738, 2, 0, 12, 4, 1, 4
|
||||
createvisualtask AnimTask_TranslateMonElliptical, 2, 0, 12, 4, 1, 4
|
||||
createvisualtask sub_810DED8, 5, 1, 70
|
||||
createsprite gBattleAnimSpriteTemplate_85962A4, 2, -25, 0, 0, 0, 20
|
||||
createsprite gBattleAnimSpriteTemplate_85962A4, 2, 25, 0, 0, 0, 20
|
||||
|
|
|
@ -1,34 +0,0 @@
|
|||
.include "asm/macros.inc"
|
||||
.include "constants/constants.inc"
|
||||
|
||||
.section .rodata
|
||||
|
||||
.align 2
|
||||
gUnknown_08525F58:: @ 8525F58
|
||||
.byte 0x48, 0x50, 0x00, 0x00, 0xb0, 0x28, 0x00, 0x00
|
||||
.byte 0x30, 0x28, 0x00, 0x00, 0x70, 0x50, 0x00, 0x00
|
||||
.byte 0x20, 0x50, 0x00, 0x00, 0xc8, 0x28, 0x00, 0x00
|
||||
.byte 0x5a, 0x58, 0x00, 0x00, 0x98, 0x20, 0x00, 0x00
|
||||
|
||||
.align 2
|
||||
gCastformFrontSpriteCoords:: @ 8525F78
|
||||
.byte 0x44, 0x11, 0x00, 0x00, 0x66, 0x09, 0x00, 0x00
|
||||
.byte 0x46, 0x09, 0x00, 0x00, 0x86, 0x08, 0x00, 0x00
|
||||
|
||||
.align 2
|
||||
gUnknown_08525F88:: @ 8525F88
|
||||
.byte 0x0d, 0x0e, 0x0d, 0x0d
|
||||
|
||||
.align 2
|
||||
gUnknown_08525F8C:: @ 8525F8C
|
||||
.byte 0x00, 0x00, 0x00, 0x00
|
||||
|
||||
.align 2
|
||||
gUnknown_08525F90:: @ 8525F90
|
||||
spr_template 0xd755, 0xd755, gUnknown_0852497C, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, SpriteCallbackDummy
|
||||
spr_template 0xd756, 0xd756, gUnknown_0852497C, gDummySpriteAnimTable, NULL, gDummySpriteAffineAnimTable, SpriteCallbackDummy
|
||||
|
||||
.align 2
|
||||
gUnknown_08525FC0:: @ 8525FC0
|
||||
obj_tiles gMiscBlank_Gfx, 0x0800, 0xd755
|
||||
obj_tiles gMiscBlank_Gfx, 0x0800, 0xd756
|
|
@ -14,11 +14,11 @@ enum
|
|||
|
||||
struct UnknownAnimStruct2
|
||||
{
|
||||
void *unk0;
|
||||
u8 *bgTiles;
|
||||
u16 *unk4;
|
||||
u8 unk8;
|
||||
u8 unk9;
|
||||
u16 unkA;
|
||||
u8 bgId;
|
||||
u16 tilesOffset;
|
||||
u16 unkC;
|
||||
};
|
||||
|
||||
|
@ -39,7 +39,7 @@ extern bool8 gAnimScriptActive;
|
|||
extern u8 gAnimVisualTaskCount;
|
||||
extern u8 gAnimSoundTaskCount;
|
||||
extern struct DisableStruct *gAnimDisableStructPtr;
|
||||
extern u32 gAnimMoveDmg;
|
||||
extern s32 gAnimMoveDmg;
|
||||
extern u16 gAnimMovePower;
|
||||
extern u8 gAnimFriendship;
|
||||
extern u16 gWeatherMoveAnim;
|
||||
|
@ -63,36 +63,48 @@ s8 BattleAnimAdjustPanning(s8 pan);
|
|||
s8 BattleAnimAdjustPanning2(s8 pan);
|
||||
s16 KeepPanInRange(s16 a);
|
||||
s16 CalculatePanIncrement(s16 sourcePan, s16 targetPan, s16 incrementPan);
|
||||
void sub_80A4720(u16 a, u16 *b, u32 c, u8 d);
|
||||
|
||||
// battle_anim_80FE840.s
|
||||
void SetAnimBgAttribute(u8 bgId, u8 attributeId, u8 value);
|
||||
void sub_8118FBC(u8 arg0, u8 arg1, u8 arg2, u8 bankIdentity, u8 arg4, void *arg5, u16 *arg6, u16 arg7);
|
||||
void sub_8118FBC(u8 arg0, u8 arg1, u8 arg2, u8 battlerPosition, u8 arg4, void *arg5, u16 *arg6, u16 arg7);
|
||||
void HandleIntroSlide(u8 terrainId);
|
||||
u32 GetAnimBgAttribute(u8 bgId, u8 attributeId);
|
||||
|
||||
// battle_anim_80A5C6C.s
|
||||
void sub_80A6EEC(struct Sprite *sprite);
|
||||
void sub_80A68D4(struct Sprite *sprite);
|
||||
void sub_80A6F3C(struct Sprite *sprite);
|
||||
bool8 TranslateAnimLinear(struct Sprite *sprite);
|
||||
void sub_80A8278(void);
|
||||
void sub_80A6B30(struct UnknownAnimStruct2*);
|
||||
void sub_80A6B90(struct UnknownAnimStruct2*, u32 arg1);
|
||||
u8 sub_80A82E4(u8 battlerId);
|
||||
bool8 AnimateBallThrow(struct Sprite *sprite);
|
||||
bool8 TranslateAnimArc(struct Sprite *sprite);
|
||||
void sub_80A6630(struct Sprite *sprite);
|
||||
void sub_80A6680(struct Sprite *sprite);
|
||||
void sub_80A7344(u8 spriteId);
|
||||
void obj_id_set_rotscale(u8 spriteId, s16 xScale, s16 yScale, u16 rotation);
|
||||
void sub_80A6E14(struct Sprite *sprite);
|
||||
void sub_80A7270(u8 spriteId, u8 objMode);
|
||||
void sub_80A73A0(u8 spriteId);
|
||||
|
||||
enum
|
||||
{
|
||||
BANK_X_POS,
|
||||
BANK_Y_POS,
|
||||
BATTLER_COORD_X,
|
||||
BATTLER_COORD_Y,
|
||||
BATTLER_COORD_X_2,
|
||||
BATTLER_COORD_3,
|
||||
BATTLER_COORD_4,
|
||||
};
|
||||
|
||||
u8 GetBattlerSpriteCoord(u8 battlerId, u8 attributeId);
|
||||
|
||||
bool8 IsBattlerSpritePresent(u8 battlerId);
|
||||
void sub_80A6C68(u8 arg0);
|
||||
void sub_80A6C68(u32 arg0);
|
||||
u8 GetAnimBattlerSpriteId(u8 wantedBattler);
|
||||
bool8 IsDoubleBattle(void);
|
||||
u8 sub_80A6D94(void);
|
||||
u8 sub_80A8364(u8);
|
||||
u8 sub_80A8364(u8 battlerId);
|
||||
void StoreSpriteCallbackInData6(struct Sprite *sprite, void (*spriteCallback)(struct Sprite*));
|
||||
void oamt_add_pos2_onto_pos1(struct Sprite *sprite);
|
||||
u8 GetBattlerSpriteDefault_Y(u8 battlerId);
|
||||
|
@ -100,6 +112,14 @@ u8 sub_80A82E4(u8 battlerId);
|
|||
u8 GetSubstituteSpriteDefault_Y(u8 battlerId);
|
||||
|
||||
// battle_anim_80A9C70.s
|
||||
#define STAT_ANIM_PLUS1 15
|
||||
#define STAT_ANIM_PLUS2 39
|
||||
#define STAT_ANIM_MINUS1 22
|
||||
#define STAT_ANIM_MINUS2 46
|
||||
#define STAT_ANIM_MULTIPLE_PLUS1 55
|
||||
#define STAT_ANIM_MULTIPLE_PLUS2 56
|
||||
#define STAT_ANIM_MULTIPLE_MINUS1 57
|
||||
#define STAT_ANIM_MULTIPLE_MINUS2 58
|
||||
void LaunchStatusAnimation(u8 battlerId, u8 statusAnimId);
|
||||
|
||||
// battle_anim_8170478.s
|
||||
|
@ -107,6 +127,6 @@ u8 ItemIdToBallId(u16 itemId);
|
|||
u8 LaunchBallStarsTask(u8 x, u8 y, u8 kindOfStars, u8 arg3, u8 ballId);
|
||||
u8 LaunchBallFadeMonTask(bool8 unFadeLater, u8 battlerId, u32 arg2, u8 ballId);
|
||||
|
||||
u8 sub_80A600C(u8, u16, u8);
|
||||
u8 GetBattlerSpriteFinal_Y(u8, u16, u8);
|
||||
|
||||
#endif // GUARD_BATTLE_ANIM_H
|
||||
|
|
|
@ -239,14 +239,13 @@ struct Shared18000
|
|||
|
||||
struct ContestStruct_field_18
|
||||
{
|
||||
// unknown size
|
||||
u16 field_0;
|
||||
u16 field_2;
|
||||
u16 field_4;
|
||||
u16 field_6;
|
||||
u32 field_8;
|
||||
u32 field_C;
|
||||
u32 field_10;
|
||||
u16 unk0;
|
||||
u16 unk2;
|
||||
u8 unk4_0:1;
|
||||
u8 unk5;
|
||||
u32 unk8;
|
||||
u32 unkC;
|
||||
u32 unk10;
|
||||
};
|
||||
|
||||
struct Contest
|
||||
|
@ -411,6 +410,7 @@ extern struct ContestResources *gContestResources;
|
|||
#define eContestAI (gContestResources->field_C)
|
||||
#define shared19328 (*gContestResources->field_10)
|
||||
#define shared19338 (*gContestResources->field_14)
|
||||
#define shared19348 (*gContestResources->field_18)
|
||||
|
||||
#define shared15800 (gHeap + 0x18000)
|
||||
#define shared18000 (*(struct Shared18000 *)(gHeap + 0x1a000))
|
||||
|
|
|
@ -111,10 +111,10 @@ SECTIONS {
|
|||
src/palette.o(.text);
|
||||
src/sound.o(.text);
|
||||
src/battle_anim.o(.text);
|
||||
asm/battle_anim_80A5C6C.o(.text);
|
||||
src/battle_anim_80A5C6C.o(.text);
|
||||
src/task.o(.text);
|
||||
src/reshow_battle_screen.o(.text);
|
||||
asm/battle_anim_80A9C70.o(.text);
|
||||
src/battle_anim_80A9C70.o(.text);
|
||||
src/title_screen.o(.text);
|
||||
asm/field_screen.o(.text);
|
||||
src/battle_setup.o(.text);
|
||||
|
@ -134,7 +134,7 @@ SECTIONS {
|
|||
src/mail_data.o(.text);
|
||||
src/map_name_popup.o(.text);
|
||||
src/item_menu_icons.o(.text);
|
||||
asm/battle_anim_80D51AC.o(.text);
|
||||
src/battle_anim_80D51AC.o(.text);
|
||||
src/item.o(.text);
|
||||
src/contest.o(.text);
|
||||
asm/contest.o(.text);
|
||||
|
@ -420,9 +420,10 @@ SECTIONS {
|
|||
data/fanfares.o(.rodata);
|
||||
data/battle_anims.o(.rodata);
|
||||
src/battle_anim.o(.rodata);
|
||||
data/rom_8525F58.o(.rodata);
|
||||
src/battle_anim_80A5C6C.o(.rodata);
|
||||
data/map_events.o(.rodata);
|
||||
data/battle_anim_80A9C70.o(.rodata);
|
||||
src/battle_anim_80A9C70.o(.rodata);
|
||||
src/title_screen.o(.rodata);
|
||||
data/field_screen.o(.rodata);
|
||||
src/battle_setup.o(.rodata);
|
||||
|
|
|
@ -107,7 +107,7 @@ EWRAM_DATA bool8 gAnimScriptActive = FALSE;
|
|||
EWRAM_DATA u8 gAnimVisualTaskCount = 0;
|
||||
EWRAM_DATA u8 gAnimSoundTaskCount = 0;
|
||||
EWRAM_DATA struct DisableStruct *gAnimDisableStructPtr = NULL;
|
||||
EWRAM_DATA u32 gAnimMoveDmg = 0;
|
||||
EWRAM_DATA s32 gAnimMoveDmg = 0;
|
||||
EWRAM_DATA u16 gAnimMovePower = 0;
|
||||
EWRAM_DATA static u16 sAnimSpriteIndexArray[ANIM_SPRITE_INDEX_COUNT] = {0};
|
||||
EWRAM_DATA u8 gAnimFriendship = 0;
|
||||
|
@ -234,7 +234,7 @@ void LaunchBattleAnimation(const u8 *const animsTable[], u16 tableId, bool8 isMo
|
|||
else
|
||||
{
|
||||
for (i = 0; i < 4; i++)
|
||||
gAnimBattlerSpecies[i] = gContestResources->field_18->field_0;
|
||||
gAnimBattlerSpecies[i] = gContestResources->field_18->unk0;
|
||||
}
|
||||
|
||||
if (!isMoveAnim)
|
||||
|
@ -681,7 +681,7 @@ void sub_80A438C(u8 battlerId, bool8 toBG_2, bool8 setSpriteInvisible)
|
|||
}
|
||||
|
||||
sub_80A6B30(&unknownStruct);
|
||||
CpuFill16(0, unknownStruct.unk0, 0x1000);
|
||||
CpuFill16(0, unknownStruct.bgTiles, 0x1000);
|
||||
CpuFill16(0xFF, unknownStruct.unk4, 0x800);
|
||||
|
||||
SetAnimBgAttribute(1, BG_ANIM_PRIORITY, 2);
|
||||
|
@ -691,7 +691,7 @@ void sub_80A438C(u8 battlerId, bool8 toBG_2, bool8 setSpriteInvisible)
|
|||
battlerSpriteId = gBattlerSpriteIds[battlerId];
|
||||
|
||||
gBattle_BG1_X = -(gSprites[battlerSpriteId].pos1.x + gSprites[battlerSpriteId].pos2.x) + 0x20;
|
||||
if (IsContest() && IsSpeciesNotUnown(gContestResources->field_18->field_0))
|
||||
if (IsContest() && IsSpeciesNotUnown(gContestResources->field_18->unk0))
|
||||
gBattle_BG1_X--;
|
||||
|
||||
gBattle_BG1_Y = -(gSprites[battlerSpriteId].pos1.y + gSprites[battlerSpriteId].pos2.y) + 0x20;
|
||||
|
@ -709,7 +709,7 @@ void sub_80A438C(u8 battlerId, bool8 toBG_2, bool8 setSpriteInvisible)
|
|||
else
|
||||
battlerPosition = GetBattlerPosition(battlerId);
|
||||
|
||||
sub_8118FBC(1, 0, 0, battlerPosition, unknownStruct.unk8, unknownStruct.unk0, unknownStruct.unk4, unknownStruct.unkA);
|
||||
sub_8118FBC(1, 0, 0, battlerPosition, unknownStruct.unk8, unknownStruct.bgTiles, unknownStruct.unk4, unknownStruct.tilesOffset);
|
||||
|
||||
if (IsContest())
|
||||
sub_80A46A0();
|
||||
|
@ -719,7 +719,7 @@ void sub_80A438C(u8 battlerId, bool8 toBG_2, bool8 setSpriteInvisible)
|
|||
RequestDma3Fill(0, (void*)(VRAM + 0x6000), 0x2000, 1);
|
||||
RequestDma3Fill(0, (void*)(VRAM + 0xF000), 0x1000, 1);
|
||||
sub_80A6B90(&unknownStruct, 2);
|
||||
CpuFill16(0, unknownStruct.unk0 + 0x1000, 0x1000);
|
||||
CpuFill16(0, unknownStruct.bgTiles + 0x1000, 0x1000);
|
||||
CpuFill16(0, unknownStruct.unk4 + 0x400, 0x800);
|
||||
SetAnimBgAttribute(2, BG_ANIM_PRIORITY, 2);
|
||||
SetAnimBgAttribute(2, BG_ANIM_SCREEN_SIZE, 1);
|
||||
|
@ -739,7 +739,7 @@ void sub_80A438C(u8 battlerId, bool8 toBG_2, bool8 setSpriteInvisible)
|
|||
LoadPalette(&gPlttBufferUnfaded[0x100 + battlerId * 16], 0x90, 0x20);
|
||||
CpuCopy32(&gPlttBufferUnfaded[0x100 + battlerId * 16], (void*)(BG_PLTT + 0x120), 0x20);
|
||||
|
||||
sub_8118FBC(2, 0, 0, GetBattlerPosition(battlerId), unknownStruct.unk8, unknownStruct.unk0 + 0x1000, unknownStruct.unk4 + 0x400, unknownStruct.unkA);
|
||||
sub_8118FBC(2, 0, 0, GetBattlerPosition(battlerId), unknownStruct.unk8, unknownStruct.bgTiles + 0x1000, unknownStruct.unk4 + 0x400, unknownStruct.tilesOffset);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -749,7 +749,7 @@ static void sub_80A46A0(void)
|
|||
struct UnknownAnimStruct2 unknownStruct;
|
||||
u16 *ptr;
|
||||
|
||||
if (IsSpeciesNotUnown(gContestResources->field_18->field_0))
|
||||
if (IsSpeciesNotUnown(gContestResources->field_18->unk0))
|
||||
{
|
||||
sub_80A6B30(&unknownStruct);
|
||||
ptr = unknownStruct.unk4;
|
||||
|
|
2460
src/battle_anim_80A5C6C.c
Normal file
2460
src/battle_anim_80A5C6C.c
Normal file
File diff suppressed because it is too large
Load diff
360
src/battle_anim_80A9C70.c
Normal file
360
src/battle_anim_80A9C70.c
Normal file
|
@ -0,0 +1,360 @@
|
|||
#include "global.h"
|
||||
#include "battle.h"
|
||||
#include "battle_anim.h"
|
||||
#include "constants/battle_anim.h"
|
||||
#include "constants/rgb.h"
|
||||
#include "blend_palette.h"
|
||||
#include "decompress.h"
|
||||
#include "palette.h"
|
||||
#include "sprite.h"
|
||||
#include "task.h"
|
||||
#include "trig.h"
|
||||
#include "gpu_regs.h"
|
||||
|
||||
extern const struct CompressedSpriteSheet gBattleAnimPicTable[];
|
||||
extern const struct CompressedSpritePalette gBattleAnimPaletteTable[];
|
||||
extern const u8 *const gBattleAnims_StatusConditions[];
|
||||
extern const struct OamData gUnknown_08524904;
|
||||
extern const struct OamData gUnknown_08524A3C;
|
||||
|
||||
extern void sub_8116EB4(u8 taskId);
|
||||
|
||||
// This file's functions.
|
||||
static void sub_80A9DB4(u8 taskId);
|
||||
static void sub_80A9FD0(u8 taskId);
|
||||
static void sub_80AA020(u8 taskId);
|
||||
static void sub_80AA0D0(u8 taskId);
|
||||
static void sub_80AA124(u8 taskId);
|
||||
static void Task_DoStatusAnimation(u8 taskId);
|
||||
static void sub_80A9E44(struct Sprite *sprite);
|
||||
static void sub_80A9E78(struct Sprite *sprite);
|
||||
|
||||
// const rom data
|
||||
static const struct Subsprite gUnknown_0853EF30[] =
|
||||
{
|
||||
{.x = -16, .y = -16, .shape = ST_OAM_SQUARE, .size = 3, .tileOffset = 0, .priority = 2},
|
||||
{.x = -16, .y = 48, .shape = ST_OAM_H_RECTANGLE, .size = 3, .tileOffset = 64, .priority = 2},
|
||||
{.x = 48, .y = -16, .shape = ST_OAM_V_RECTANGLE, .size = 3, .tileOffset = 96, .priority = 2},
|
||||
{.x = 48, .y = 48, .shape = ST_OAM_SQUARE, .size = 2, .tileOffset = 128, .priority = 2},
|
||||
};
|
||||
|
||||
static const struct SubspriteTable gUnknown_0853EF40[] =
|
||||
{
|
||||
{ARRAY_COUNT(gUnknown_0853EF30), gUnknown_0853EF30},
|
||||
};
|
||||
|
||||
static const struct SpriteTemplate gUnknown_0853EF48 =
|
||||
{
|
||||
.tileTag = ANIM_TAG_ICE_CUBE,
|
||||
.paletteTag = ANIM_TAG_ICE_CUBE,
|
||||
.oam = &gUnknown_08524A3C,
|
||||
.anims = gDummySpriteAnimTable,
|
||||
.images = NULL,
|
||||
.affineAnims = gDummySpriteAffineAnimTable,
|
||||
.callback = SpriteCallbackDummy,
|
||||
};
|
||||
|
||||
static const struct SpriteTemplate gUnknown_0853EF60 =
|
||||
{
|
||||
.tileTag = ANIM_TAG_136,
|
||||
.paletteTag = ANIM_TAG_136,
|
||||
.oam = &gUnknown_08524904,
|
||||
.anims = gDummySpriteAnimTable,
|
||||
.images = NULL,
|
||||
.affineAnims = gDummySpriteAffineAnimTable,
|
||||
.callback = sub_80A9E44,
|
||||
};
|
||||
|
||||
// code
|
||||
u8 sub_80A9C70(u8 battlerId, bool8 b)
|
||||
{
|
||||
u8 battlerSpriteId = gBattlerSpriteIds[battlerId];
|
||||
u8 taskId = CreateTask(sub_80A9DB4, 10);
|
||||
u8 spriteId2;
|
||||
u8 i;
|
||||
|
||||
LoadCompressedObjectPicUsingHeap(&gBattleAnimPicTable[GET_TRUE_SPRITE_INDEX(ANIM_TAG_136)]);
|
||||
LoadCompressedObjectPaletteUsingHeap(&gBattleAnimPaletteTable[GET_TRUE_SPRITE_INDEX(ANIM_TAG_136)]);
|
||||
gTasks[taskId].data[0] = battlerId;
|
||||
if (b)
|
||||
{
|
||||
gTasks[taskId].data[1] = RGB_RED;
|
||||
for (i = 0; i < 10; i++)
|
||||
{
|
||||
spriteId2 = CreateSprite(&gUnknown_0853EF60, gSprites[battlerSpriteId].pos1.x, gSprites[battlerSpriteId].pos1.y + 32, 0);
|
||||
gSprites[spriteId2].data[0] = i * 51;
|
||||
gSprites[spriteId2].data[1] = -256;
|
||||
gSprites[spriteId2].invisible = TRUE;
|
||||
if (i > 4)
|
||||
gSprites[spriteId2].data[6] = 21;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
gTasks[taskId].data[1] = RGB_BLUE;
|
||||
for (i = 0; i < 10; i++)
|
||||
{
|
||||
spriteId2 = CreateSprite(&gUnknown_0853EF60, gSprites[battlerSpriteId].pos1.x, gSprites[battlerSpriteId].pos1.y - 32, 0);
|
||||
gSprites[spriteId2].data[0] = i * 51;
|
||||
gSprites[spriteId2].data[1] = 256;
|
||||
gSprites[spriteId2].invisible = TRUE;
|
||||
if (i > 4)
|
||||
gSprites[spriteId2].data[6] = 21;
|
||||
}
|
||||
}
|
||||
gSprites[spriteId2].data[7] = 1;
|
||||
return taskId;
|
||||
}
|
||||
|
||||
static void sub_80A9DB4(u8 taskId)
|
||||
{
|
||||
if (gTasks[taskId].data[2] == 2)
|
||||
{
|
||||
gTasks[taskId].data[2] = 0;
|
||||
BlendPalette(0x100 + gTasks[taskId].data[0] * 16, 16, gTasks[taskId].data[4], gTasks[taskId].data[1]);
|
||||
if (gTasks[taskId].data[5] == 0)
|
||||
{
|
||||
gTasks[taskId].data[4]++;
|
||||
if (gTasks[taskId].data[4] > 8)
|
||||
gTasks[taskId].data[5] ^= 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
u16 var = gTasks[taskId].data[4];
|
||||
|
||||
gTasks[taskId].data[4]--;
|
||||
if (gTasks[taskId].data[4] < 0)
|
||||
{
|
||||
gTasks[taskId].data[4] = var;
|
||||
gTasks[taskId].data[5] ^= 1;
|
||||
gTasks[taskId].data[3]++;
|
||||
if (gTasks[taskId].data[3] == 2)
|
||||
DestroyTask(taskId);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
gTasks[taskId].data[2]++;
|
||||
}
|
||||
}
|
||||
|
||||
static void sub_80A9E44(struct Sprite *sprite)
|
||||
{
|
||||
if (sprite->data[6] == 0)
|
||||
{
|
||||
sprite->invisible = FALSE;
|
||||
sprite->callback = sub_80A9E78;
|
||||
sub_80A9E78(sprite);
|
||||
}
|
||||
else
|
||||
{
|
||||
sprite->data[6]--;
|
||||
}
|
||||
}
|
||||
|
||||
static void sub_80A9E78(struct Sprite *sprite)
|
||||
{
|
||||
sprite->pos2.x = Cos(sprite->data[0], 32);
|
||||
sprite->pos2.y = Sin(sprite->data[0], 8);
|
||||
if (sprite->data[0] < 128)
|
||||
sprite->subpriority = 29;
|
||||
else
|
||||
sprite->subpriority = 31;
|
||||
sprite->data[0] = (sprite->data[0] + 8) & 0xFF;
|
||||
sprite->data[5] += sprite->data[1];
|
||||
sprite->pos2.y += sprite->data[5] >> 8;
|
||||
sprite->data[2]++;
|
||||
if (sprite->data[2] == 52)
|
||||
{
|
||||
if (sprite->data[7])
|
||||
DestroySpriteAndFreeResources(sprite);
|
||||
else
|
||||
DestroySprite(sprite);
|
||||
}
|
||||
}
|
||||
|
||||
void sub_80A9EF4(u8 taskId)
|
||||
{
|
||||
s16 x = GetBattlerSpriteCoord(gBattleAnimTarget, BATTLER_COORD_X_2) - 32;
|
||||
s16 y = GetBattlerSpriteCoord(gBattleAnimTarget, BATTLER_COORD_3) - 36;
|
||||
u8 spriteId;
|
||||
|
||||
if (IsContest())
|
||||
x -= 6;
|
||||
SetGpuReg(REG_OFFSET_BLDCNT, BLDCNT_EFFECT_BLEND | BLDCNT_TGT2_ALL);
|
||||
SetGpuReg(REG_OFFSET_BLDALPHA, BLDALPHA_BLEND(0, 16));
|
||||
spriteId = CreateSprite(&gUnknown_0853EF48, x, y, 4);
|
||||
if (GetSpriteTileStartByTag(ANIM_TAG_ICE_CUBE) == 0xFFFF)
|
||||
gSprites[spriteId].invisible = TRUE;
|
||||
SetSubspriteTables(&gSprites[spriteId], gUnknown_0853EF40);
|
||||
gTasks[taskId].data[15] = spriteId;
|
||||
gTasks[taskId].func = sub_80A9FD0;
|
||||
}
|
||||
|
||||
static void sub_80A9FD0(u8 taskId)
|
||||
{
|
||||
gTasks[taskId].data[1]++;
|
||||
if (gTasks[taskId].data[1] == 10)
|
||||
{
|
||||
gTasks[taskId].func = sub_80AA020;
|
||||
gTasks[taskId].data[1] = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
u8 var = gTasks[taskId].data[1];
|
||||
|
||||
SetGpuReg(REG_OFFSET_BLDALPHA, BLDALPHA_BLEND(var, 16 - var));
|
||||
}
|
||||
}
|
||||
|
||||
static void sub_80AA020(u8 taskId)
|
||||
{
|
||||
u8 palIndex = IndexOfSpritePaletteTag(ANIM_TAG_ICE_CUBE);
|
||||
|
||||
if (gTasks[taskId].data[1]++ > 13)
|
||||
{
|
||||
gTasks[taskId].data[2]++;
|
||||
if (gTasks[taskId].data[2] == 3)
|
||||
{
|
||||
u16 temp;
|
||||
|
||||
temp = gPlttBufferFaded[0x100 + palIndex * 16 + 13];
|
||||
gPlttBufferFaded[0x100 + palIndex * 16 + 13] = gPlttBufferFaded[0x100 + palIndex * 16 + 14];
|
||||
gPlttBufferFaded[0x100 + palIndex * 16 + 14] = gPlttBufferFaded[0x100 + palIndex * 16 + 15];
|
||||
gPlttBufferFaded[0x100 + palIndex * 16 + 15] = temp;
|
||||
|
||||
gTasks[taskId].data[2] = 0;
|
||||
gTasks[taskId].data[3]++;
|
||||
if (gTasks[taskId].data[3] == 3)
|
||||
{
|
||||
gTasks[taskId].data[3] = 0;
|
||||
gTasks[taskId].data[1] = 0;
|
||||
gTasks[taskId].data[4]++;
|
||||
if (gTasks[taskId].data[4] == 2)
|
||||
{
|
||||
gTasks[taskId].data[1] = 9;
|
||||
gTasks[taskId].func = sub_80AA0D0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void sub_80AA0D0(u8 taskId)
|
||||
{
|
||||
gTasks[taskId].data[1]--;
|
||||
if (gTasks[taskId].data[1] == -1)
|
||||
{
|
||||
gTasks[taskId].func = sub_80AA124;
|
||||
gTasks[taskId].data[1] = 0;
|
||||
}
|
||||
else
|
||||
{
|
||||
u8 var = gTasks[taskId].data[1];
|
||||
|
||||
SetGpuReg(REG_OFFSET_BLDALPHA, BLDALPHA_BLEND(var, 16 - var));
|
||||
}
|
||||
}
|
||||
|
||||
static void sub_80AA124(u8 taskId)
|
||||
{
|
||||
gTasks[taskId].data[1]++;
|
||||
if (gTasks[taskId].data[1] == 37)
|
||||
{
|
||||
u8 spriteId = gTasks[taskId].data[15];
|
||||
|
||||
FreeSpriteOamMatrix(&gSprites[spriteId]);
|
||||
DestroySprite(&gSprites[spriteId]);
|
||||
}
|
||||
else if (gTasks[taskId].data[1] == 39)
|
||||
{
|
||||
SetGpuReg(REG_OFFSET_BLDCNT, 0);
|
||||
SetGpuReg(REG_OFFSET_BLDALPHA, 0);
|
||||
DestroyAnimVisualTask(taskId);
|
||||
}
|
||||
}
|
||||
|
||||
#define CASE(by, stat) case (STAT_ANIM_##by + stat - 1)
|
||||
|
||||
void AnimTask_StatsChange(u8 taskId)
|
||||
{
|
||||
bool16 goesDown = FALSE;
|
||||
s16 animStatId = 0;
|
||||
bool16 sharply = FALSE;
|
||||
|
||||
switch (gBattleSpritesDataPtr->animationData->animArg)
|
||||
{
|
||||
CASE(PLUS1, STAT_ATK): goesDown = FALSE; animStatId = 0; break;
|
||||
CASE(PLUS1, STAT_DEF): goesDown = FALSE; animStatId = 1; break;
|
||||
CASE(PLUS1, STAT_SPEED): goesDown = FALSE; animStatId = 3; break;
|
||||
CASE(PLUS1, STAT_SPATK): goesDown = FALSE; animStatId = 5; break;
|
||||
CASE(PLUS1, STAT_SPDEF): goesDown = FALSE; animStatId = 6; break;
|
||||
CASE(PLUS1, STAT_ACC): goesDown = FALSE; animStatId = 2; break;
|
||||
CASE(PLUS1, STAT_EVASION): goesDown = FALSE; animStatId = 4; break;
|
||||
|
||||
CASE(MINUS1, STAT_ATK): goesDown = TRUE; animStatId = 0; break;
|
||||
CASE(MINUS1, STAT_DEF): goesDown = TRUE; animStatId = 1; break;
|
||||
CASE(MINUS1, STAT_SPEED): goesDown = TRUE; animStatId = 3; break;
|
||||
CASE(MINUS1, STAT_SPATK): goesDown = TRUE; animStatId = 5; break;
|
||||
CASE(MINUS1, STAT_SPDEF): goesDown = TRUE; animStatId = 6; break;
|
||||
CASE(MINUS1, STAT_ACC): goesDown = TRUE; animStatId = 2; break;
|
||||
CASE(MINUS1, STAT_EVASION): goesDown = TRUE; animStatId = 4; break;
|
||||
|
||||
CASE(PLUS2, STAT_ATK): goesDown = FALSE; animStatId = 0; sharply = TRUE; break;
|
||||
CASE(PLUS2, STAT_DEF): goesDown = FALSE; animStatId = 1; sharply = TRUE; break;
|
||||
CASE(PLUS2, STAT_SPEED): goesDown = FALSE; animStatId = 3; sharply = TRUE; break;
|
||||
CASE(PLUS2, STAT_SPATK): goesDown = FALSE; animStatId = 5; sharply = TRUE; break;
|
||||
CASE(PLUS2, STAT_SPDEF): goesDown = FALSE; animStatId = 6; sharply = TRUE; break;
|
||||
CASE(PLUS2, STAT_ACC): goesDown = FALSE; animStatId = 2; sharply = TRUE; break;
|
||||
CASE(PLUS2, STAT_EVASION): goesDown = FALSE; animStatId = 4; sharply = TRUE; break;
|
||||
|
||||
CASE(MINUS2, STAT_ATK): goesDown = TRUE; animStatId = 0; sharply = TRUE; break;
|
||||
CASE(MINUS2, STAT_DEF): goesDown = TRUE; animStatId = 1; sharply = TRUE; break;
|
||||
CASE(MINUS2, STAT_SPEED): goesDown = TRUE; animStatId = 3; sharply = TRUE; break;
|
||||
CASE(MINUS2, STAT_SPATK): goesDown = TRUE; animStatId = 5; sharply = TRUE; break;
|
||||
CASE(MINUS2, STAT_SPDEF): goesDown = TRUE; animStatId = 6; sharply = TRUE; break;
|
||||
CASE(MINUS2, STAT_ACC): goesDown = TRUE; animStatId = 2; sharply = TRUE; break;
|
||||
CASE(MINUS2, STAT_EVASION): goesDown = TRUE; animStatId = 4; sharply = TRUE; break;
|
||||
|
||||
case STAT_ANIM_MULTIPLE_PLUS1: goesDown = FALSE; animStatId = 0xFF; sharply = FALSE; break;
|
||||
case STAT_ANIM_MULTIPLE_PLUS2: goesDown = FALSE; animStatId = 0xFF; sharply = TRUE; break;
|
||||
case STAT_ANIM_MULTIPLE_MINUS1: goesDown = TRUE; animStatId = 0xFF; sharply = FALSE; break;
|
||||
case STAT_ANIM_MULTIPLE_MINUS2: goesDown = TRUE; animStatId = 0xFF; sharply = TRUE; break;
|
||||
|
||||
default:
|
||||
DestroyAnimVisualTask(taskId);
|
||||
return;
|
||||
}
|
||||
|
||||
gBattleAnimArgs[0] = goesDown;
|
||||
gBattleAnimArgs[1] = animStatId;
|
||||
gBattleAnimArgs[2] = 0;
|
||||
gBattleAnimArgs[3] = 0;
|
||||
gBattleAnimArgs[4] = sharply;
|
||||
gTasks[taskId].func = sub_8116EB4;
|
||||
sub_8116EB4(taskId);
|
||||
}
|
||||
|
||||
#undef CASE
|
||||
|
||||
void LaunchStatusAnimation(u8 battlerId, u8 statusAnimId)
|
||||
{
|
||||
u8 taskId;
|
||||
|
||||
gBattleAnimAttacker = battlerId;
|
||||
gBattleAnimTarget = battlerId;
|
||||
LaunchBattleAnimation(gBattleAnims_StatusConditions, statusAnimId, 0);
|
||||
taskId = CreateTask(Task_DoStatusAnimation, 10);
|
||||
gTasks[taskId].data[0] = battlerId;
|
||||
}
|
||||
|
||||
static void Task_DoStatusAnimation(u8 taskId)
|
||||
{
|
||||
gAnimScriptCallback();
|
||||
if (!gAnimScriptActive)
|
||||
{
|
||||
gBattleSpritesDataPtr->healthBoxesData[gTasks[taskId].data[0]].statusAnimActive = FALSE;
|
||||
DestroyTask(taskId);
|
||||
}
|
||||
}
|
1004
src/battle_anim_80D51AC.c
Normal file
1004
src/battle_anim_80D51AC.c
Normal file
File diff suppressed because it is too large
Load diff
|
@ -131,7 +131,7 @@ void sub_8158D8C(u8 taskId)
|
|||
if (IsContest())
|
||||
{
|
||||
if (gBattleAnimArgs[0] == ANIM_ATTACKER)
|
||||
species = gContestResources->field_18->field_0;
|
||||
species = gContestResources->field_18->unk0;
|
||||
else
|
||||
DestroyAnimVisualTask(taskId); // UB: function should return upon destroying task.
|
||||
}
|
||||
|
@ -177,7 +177,7 @@ void sub_8158E9C(u8 taskId)
|
|||
if (IsContest())
|
||||
{
|
||||
if (gBattleAnimArgs[0] == ANIM_ATTACKER)
|
||||
species = gContestResources->field_18->field_0;
|
||||
species = gContestResources->field_18->unk0;
|
||||
else
|
||||
DestroyAnimVisualTask(taskId); // UB: function should return upon destroying task.
|
||||
}
|
||||
|
@ -281,7 +281,7 @@ void sub_81590B8(u8 taskId)
|
|||
pan = BattleAnimAdjustPanning(PAN_SIDE_PLAYER);
|
||||
|
||||
if (IsContest())
|
||||
species = gContestResources->field_18->field_0;
|
||||
species = gContestResources->field_18->unk0;
|
||||
else
|
||||
species = gAnimBattlerSpecies[gBattleAnimAttacker];
|
||||
|
||||
|
|
|
@ -899,14 +899,14 @@ void HandleSpeciesGfxDataChange(u8 battlerAtk, u8 battlerDef, bool8 notTransform
|
|||
if (IsContest())
|
||||
{
|
||||
position = 0;
|
||||
targetSpecies = gContestResources->field_18->field_2;
|
||||
personalityValue = gContestResources->field_18->field_8;
|
||||
otId = gContestResources->field_18->field_C;
|
||||
targetSpecies = gContestResources->field_18->unk2;
|
||||
personalityValue = gContestResources->field_18->unk8;
|
||||
otId = gContestResources->field_18->unkC;
|
||||
|
||||
HandleLoadSpecialPokePic_DontHandleDeoxys(&gMonBackPicTable[targetSpecies],
|
||||
gMonSpritesGfxPtr->sprites[0],
|
||||
targetSpecies,
|
||||
gContestResources->field_18->field_10);
|
||||
gContestResources->field_18->unk10);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
#include "constants/battle_move_effects.h"
|
||||
#include "constants/battle_script_commands.h"
|
||||
#include "battle_message.h"
|
||||
#include "battle_anim.h"
|
||||
#include "battle_ai_script_commands.h"
|
||||
#include "battle_scripts.h"
|
||||
#include "constants/moves.h"
|
||||
|
@ -4381,16 +4382,16 @@ static void atk47_setgraphicalstatchangevalues(void)
|
|||
switch (GET_STAT_BUFF_VALUE2(gBattleScripting.statChanger))
|
||||
{
|
||||
case SET_STAT_BUFF_VALUE(1): // +1
|
||||
value = 0xF;
|
||||
value = STAT_ANIM_PLUS1;
|
||||
break;
|
||||
case SET_STAT_BUFF_VALUE(2): // +2
|
||||
value = 0x27;
|
||||
value = STAT_ANIM_PLUS2;
|
||||
break;
|
||||
case SET_STAT_BUFF_VALUE(1) | STAT_BUFF_NEGATIVE: // -1
|
||||
value = 0x16;
|
||||
value = STAT_ANIM_MINUS1;
|
||||
break;
|
||||
case SET_STAT_BUFF_VALUE(2) | STAT_BUFF_NEGATIVE: // -2
|
||||
value = 0x2E;
|
||||
value = STAT_ANIM_MINUS2;
|
||||
break;
|
||||
}
|
||||
gBattleScripting.animArg1 = GET_STAT_BUFF_ID(gBattleScripting.statChanger) + value - 1;
|
||||
|
@ -4412,9 +4413,9 @@ static void atk48_playstatchangeanimation(void)
|
|||
{
|
||||
s16 startingStatAnimId;
|
||||
if (gBattlescriptCurrInstr[3] & ATK48_STAT_BY_TWO)
|
||||
startingStatAnimId = 0x2D;
|
||||
startingStatAnimId = STAT_ANIM_MINUS2 - 1;
|
||||
else
|
||||
startingStatAnimId = 0x15;
|
||||
startingStatAnimId = STAT_ANIM_MINUS1 - 1;
|
||||
|
||||
while (statsToCheck != 0)
|
||||
{
|
||||
|
@ -4447,18 +4448,18 @@ static void atk48_playstatchangeanimation(void)
|
|||
if (changeableStatsCount > 1) // more than one stat, so the color is gray
|
||||
{
|
||||
if (gBattlescriptCurrInstr[3] & ATK48_STAT_BY_TWO)
|
||||
statAnimId = 0x3A;
|
||||
statAnimId = STAT_ANIM_MULTIPLE_MINUS2;
|
||||
else
|
||||
statAnimId = 0x39;
|
||||
statAnimId = STAT_ANIM_MULTIPLE_MINUS1;
|
||||
}
|
||||
}
|
||||
else // goes up
|
||||
{
|
||||
s16 startingStatAnimId;
|
||||
if (gBattlescriptCurrInstr[3] & ATK48_STAT_BY_TWO)
|
||||
startingStatAnimId = 0x26;
|
||||
startingStatAnimId = STAT_ANIM_PLUS2 - 1;
|
||||
else
|
||||
startingStatAnimId = 0xE;
|
||||
startingStatAnimId = STAT_ANIM_PLUS1 - 1;
|
||||
|
||||
while (statsToCheck != 0)
|
||||
{
|
||||
|
@ -4473,9 +4474,9 @@ static void atk48_playstatchangeanimation(void)
|
|||
if (changeableStatsCount > 1) // more than one stat, so the color is gray
|
||||
{
|
||||
if (gBattlescriptCurrInstr[3] & ATK48_STAT_BY_TWO)
|
||||
statAnimId = 0x38;
|
||||
statAnimId = STAT_ANIM_MULTIPLE_PLUS2;
|
||||
else
|
||||
statAnimId = 0x37;
|
||||
statAnimId = STAT_ANIM_MULTIPLE_PLUS1;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -2535,7 +2535,7 @@ u8 sub_80DB174(u16 species, u32 otId, u32 personality, u32 index)
|
|||
LoadCompressedPalette(GetFrontSpritePalFromSpeciesAndPersonality(species, otId, personality), 0x120, 0x20);
|
||||
SetMultiuseSpriteTemplateToPokemon(species, 0);
|
||||
|
||||
spriteId = CreateSprite(&gMultiuseSpriteTemplate, 0x70, sub_80A600C(2, species, 0), 30);
|
||||
spriteId = CreateSprite(&gMultiuseSpriteTemplate, 0x70, GetBattlerSpriteFinal_Y(2, species, FALSE), 30);
|
||||
gSprites[spriteId].oam.paletteNum = 2;
|
||||
gSprites[spriteId].oam.priority = 2;
|
||||
gSprites[spriteId].subpriority = sub_80A82E4(2);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
const struct MonCoords gUnknown_083021D8[] =
|
||||
const struct MonCoords gMonBackPicCoords[] =
|
||||
{
|
||||
{0x88, 0x00}, // SPECIES_NONE
|
||||
{0x64, 0x10}, // SPECIES_BULBASAUR
|
||||
|
|
|
@ -19,10 +19,10 @@ struct CompressedTilesPal
|
|||
const u8 *pal;
|
||||
};
|
||||
|
||||
extern void sub_80D5860(struct Sprite *sprite);
|
||||
extern void sub_80D58F8(struct Sprite *sprite);
|
||||
extern void sub_80D5968(struct Sprite *sprite);
|
||||
extern void sub_80D5A94(struct Sprite *sprite);
|
||||
extern void DoHorizontalLunge(struct Sprite *sprite);
|
||||
extern void DoVerticalDip(struct Sprite *sprite);
|
||||
extern void SlideMonToOriginalPos(struct Sprite *sprite);
|
||||
extern void SlideMonToOffset(struct Sprite *sprite);
|
||||
extern void sub_80D5B48(struct Sprite *sprite);
|
||||
|
||||
// this file's functions
|
||||
|
@ -422,7 +422,7 @@ const struct SpriteTemplate gHorizontalLungeSpriteTemplate =
|
|||
.anims = gDummySpriteAnimTable,
|
||||
.images = NULL,
|
||||
.affineAnims = gDummySpriteAffineAnimTable,
|
||||
.callback = sub_80D5860,
|
||||
.callback = DoHorizontalLunge,
|
||||
};
|
||||
|
||||
const struct SpriteTemplate gVerticalDipSpriteTemplate =
|
||||
|
@ -433,7 +433,7 @@ const struct SpriteTemplate gVerticalDipSpriteTemplate =
|
|||
.anims = gDummySpriteAnimTable,
|
||||
.images = NULL,
|
||||
.affineAnims = gDummySpriteAffineAnimTable,
|
||||
.callback = sub_80D58F8,
|
||||
.callback = DoVerticalDip,
|
||||
};
|
||||
|
||||
const struct SpriteTemplate gSlideMonToOriginalPosSpriteTemplate =
|
||||
|
@ -444,7 +444,7 @@ const struct SpriteTemplate gSlideMonToOriginalPosSpriteTemplate =
|
|||
.anims = gDummySpriteAnimTable,
|
||||
.images = NULL,
|
||||
.affineAnims = gDummySpriteAffineAnimTable,
|
||||
.callback = sub_80D5968,
|
||||
.callback = SlideMonToOriginalPos,
|
||||
};
|
||||
|
||||
const struct SpriteTemplate gSlideMonToOffsetSpriteTemplate =
|
||||
|
@ -455,7 +455,7 @@ const struct SpriteTemplate gSlideMonToOffsetSpriteTemplate =
|
|||
.anims = gDummySpriteAnimTable,
|
||||
.images = NULL,
|
||||
.affineAnims = gDummySpriteAffineAnimTable,
|
||||
.callback = sub_80D5A94,
|
||||
.callback = SlideMonToOffset,
|
||||
};
|
||||
|
||||
const struct SpriteTemplate gUnknown_0857FE88 =
|
||||
|
|
|
@ -378,8 +378,8 @@ static void Task_DoPokeballSendOutAnim(u8 taskId)
|
|||
gSprites[ballSpriteId].callback = SpriteCB_PlayerMonSendOut_1;
|
||||
break;
|
||||
case POKEBALL_OPPONENT_SENDOUT:
|
||||
gSprites[ballSpriteId].pos1.x = GetBattlerSpriteCoord(battlerId, BANK_X_POS);
|
||||
gSprites[ballSpriteId].pos1.y = GetBattlerSpriteCoord(battlerId, BANK_Y_POS) + 24;
|
||||
gSprites[ballSpriteId].pos1.x = GetBattlerSpriteCoord(battlerId, BATTLER_COORD_X);
|
||||
gSprites[ballSpriteId].pos1.y = GetBattlerSpriteCoord(battlerId, BATTLER_COORD_Y) + 24;
|
||||
gBattlerTarget = battlerId;
|
||||
gSprites[ballSpriteId].data[0] = 0;
|
||||
gSprites[ballSpriteId].callback = SpriteCB_OpponentMonSendOut;
|
||||
|
@ -399,8 +399,8 @@ static void Task_DoPokeballSendOutAnim(u8 taskId)
|
|||
|
||||
// this will perform an unused ball throw animation
|
||||
gSprites[ballSpriteId].data[0] = 0x22;
|
||||
gSprites[ballSpriteId].data[2] = GetBattlerSpriteCoord(gBattlerTarget, BANK_X_POS);
|
||||
gSprites[ballSpriteId].data[4] = GetBattlerSpriteCoord(gBattlerTarget, BANK_Y_POS) - 16;
|
||||
gSprites[ballSpriteId].data[2] = GetBattlerSpriteCoord(gBattlerTarget, BATTLER_COORD_X);
|
||||
gSprites[ballSpriteId].data[4] = GetBattlerSpriteCoord(gBattlerTarget, BATTLER_COORD_Y) - 16;
|
||||
gSprites[ballSpriteId].data[5] = -40;
|
||||
sub_80A68D4(&gSprites[ballSpriteId]);
|
||||
gSprites[ballSpriteId].oam.affineParam = taskId;
|
||||
|
@ -411,7 +411,7 @@ static void Task_DoPokeballSendOutAnim(u8 taskId)
|
|||
|
||||
static void SpriteCB_TestBallThrow(struct Sprite *sprite)
|
||||
{
|
||||
if (AnimateBallThrow(sprite))
|
||||
if (TranslateAnimArc(sprite))
|
||||
{
|
||||
u16 ballId;
|
||||
u8 taskId = sprite->oam.affineParam;
|
||||
|
@ -922,7 +922,7 @@ static void SpriteCB_PlayerMonSendOut_2(struct Sprite *sprite)
|
|||
StartSpriteAffineAnim(sprite, 4);
|
||||
}
|
||||
r4 = sprite->data[0];
|
||||
sub_80A6F3C(sprite);
|
||||
TranslateAnimLinear(sprite);
|
||||
sprite->data[7] += sprite->sBattler / 3;
|
||||
sprite->pos2.y += Sin(HIBYTE(sprite->data[7]), sprite->data[5]);
|
||||
sprite->oam.affineParam += 0x100;
|
||||
|
@ -940,7 +940,7 @@ static void SpriteCB_PlayerMonSendOut_2(struct Sprite *sprite)
|
|||
}
|
||||
else
|
||||
{
|
||||
if (AnimateBallThrow(sprite))
|
||||
if (TranslateAnimArc(sprite))
|
||||
{
|
||||
sprite->pos1.x += sprite->pos2.x;
|
||||
sprite->pos1.y += sprite->pos2.y;
|
||||
|
|
|
@ -248,12 +248,9 @@ gUnknown_020375D6: @ 20375D6
|
|||
.include "src/palette.o"
|
||||
.include "src/sound.o"
|
||||
.include "src/battle_anim.o"
|
||||
|
||||
.align 2
|
||||
|
||||
gUnknown_02038444: @ 2038444
|
||||
.space 0x10
|
||||
|
||||
.include "src/battle_anim_80A5C6C.o"
|
||||
|
||||
.space 0xC
|
||||
gUnknown_02038454: @ 2038454
|
||||
.space 0x200
|
||||
|
||||
|
|
Loading…
Reference in a new issue