mirror of
https://github.com/pret/pmd-sky.git
synced 2026-09-27 04:38:15 -05:00
Decomped ov29_02338350
This commit is contained in:
@@ -9,6 +9,5 @@
|
||||
.public IqSkillIsEnabled
|
||||
.public MemAlloc
|
||||
.public MemFree
|
||||
.public MemZero
|
||||
.public ov29_022FAFD4
|
||||
.public RandInt
|
||||
.public ov29_022FAFD4
|
||||
|
||||
3
asm/include/overlay_29_0233836C.inc
Normal file
3
asm/include/overlay_29_0233836C.inc
Normal file
@@ -0,0 +1,3 @@
|
||||
#pragma once
|
||||
.public DUNGEON_PTR
|
||||
.public MemZero
|
||||
@@ -364,32 +364,3 @@ _0233833C:
|
||||
.align 2, 0
|
||||
_0233834C: .word DIRECTIONS_XY
|
||||
arm_func_end ov29_023382A8
|
||||
|
||||
arm_func_start ov29_02338350
|
||||
ov29_02338350: ; 0x02338350
|
||||
stmdb sp!, {r3, lr}
|
||||
bl ov29_023382A8
|
||||
cmp r0, #0
|
||||
movne r0, #1
|
||||
moveq r0, #0
|
||||
and r0, r0, #0xff
|
||||
ldmia sp!, {r3, pc}
|
||||
arm_func_end ov29_02338350
|
||||
|
||||
arm_func_start ResetGravity
|
||||
ResetGravity: ; 0x0233836C
|
||||
ldr r0, _02338388 ; =DUNGEON_PTR
|
||||
ldr ip, _0233838C ; =MemZero
|
||||
ldr r0, [r0]
|
||||
mov r1, #2
|
||||
#ifdef JAPAN
|
||||
add r0, r0, #0x258
|
||||
#else
|
||||
add r0, r0, #0x2fc
|
||||
#endif
|
||||
add r0, r0, #0x12800
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_02338388: .word DUNGEON_PTR
|
||||
_0233838C: .word MemZero
|
||||
arm_func_end ResetGravity
|
||||
|
||||
22
asm/overlay_29_0233836C.s
Normal file
22
asm/overlay_29_0233836C.s
Normal file
@@ -0,0 +1,22 @@
|
||||
.include "asm/macros.inc"
|
||||
.include "overlay_29_0233836C.inc"
|
||||
|
||||
.text
|
||||
|
||||
arm_func_start ResetGravity
|
||||
ResetGravity: ; 0x0233836C
|
||||
ldr r0, _02338388 ; =DUNGEON_PTR
|
||||
ldr ip, _0233838C ; =MemZero
|
||||
ldr r0, [r0]
|
||||
mov r1, #2
|
||||
#ifdef JAPAN
|
||||
add r0, r0, #0x258
|
||||
#else
|
||||
add r0, r0, #0x2fc
|
||||
#endif
|
||||
add r0, r0, #0x12800
|
||||
bx ip
|
||||
.align 2, 0
|
||||
_02338388: .word DUNGEON_PTR
|
||||
_0233838C: .word MemZero
|
||||
arm_func_end ResetGravity
|
||||
8
include/overlay_29_02338350.h
Normal file
8
include/overlay_29_02338350.h
Normal file
@@ -0,0 +1,8 @@
|
||||
#ifndef PMDSKY_OVERLAY_29_02338350_H
|
||||
#define PMDSKY_OVERLAY_29_02338350_H
|
||||
|
||||
#include "dungeon_mode.h"
|
||||
|
||||
bool8 ov29_02338350(struct entity *monster);
|
||||
|
||||
#endif //PMDSKY_OVERLAY_29_02338350_H
|
||||
2
main.lsf
2
main.lsf
@@ -591,6 +591,8 @@ Overlay OVY_29
|
||||
Object asm/overlay_29_02337CCC.o
|
||||
Object src/dungeon_map_access_1.o
|
||||
Object asm/overlay_29_02337EC0.o
|
||||
Object src/overlay_29_02338350.o
|
||||
Object asm/overlay_29_0233836C.o
|
||||
Object src/overlay_29_02338390.o
|
||||
Object asm/overlay_29_023383A8.o
|
||||
Object src/overlay_29_02338548.o
|
||||
|
||||
@@ -18,10 +18,10 @@
|
||||
#include "dungeon_util_static.h"
|
||||
#include "fixed_room_data.h"
|
||||
#include "moves_1.h"
|
||||
#include "overlay_29_02338350.h"
|
||||
|
||||
#define REGULAR_ATTACK_INDEX 4
|
||||
|
||||
extern bool8 ov29_02338350(struct entity *monster);
|
||||
extern bool8 TargetRegularAttack(struct entity *pokemon, u32 *target_dir, bool8 skip_petrified);
|
||||
extern void SetActionRegularAttack(struct action_data *monster_action, u8 direction);
|
||||
extern void SetActionStruggle(struct action_data *monster_action, u8 direction);
|
||||
@@ -46,7 +46,7 @@ void ChooseAiMove(struct entity *monster)
|
||||
(pokemon_info->cringe_class_status.cringe == STATUS_CRINGE_CONFUSED && DungeonRandOutcome__022EAB20(AI_CONFUSED_NO_ATTACK_CHANCE)))
|
||||
return;
|
||||
|
||||
int i;
|
||||
s32 i;
|
||||
if (pokemon_info->bide_class_status.bide != STATUS_TWO_TURN_NONE)
|
||||
{
|
||||
for (i = 0; i < MAX_MON_MOVES; i++)
|
||||
|
||||
10
src/overlay_29_02338350.c
Normal file
10
src/overlay_29_02338350.c
Normal file
@@ -0,0 +1,10 @@
|
||||
#include "overlay_29_02338350.h"
|
||||
|
||||
extern bool8 ov29_023382A8(struct entity *monster);
|
||||
|
||||
bool8 ov29_02338350(struct entity *monster)
|
||||
{
|
||||
if (ov29_023382A8(monster))
|
||||
return TRUE;
|
||||
return FALSE;
|
||||
}
|
||||
Reference in New Issue
Block a user