mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-12-26 03:34:15 +01:00
Rename field_map_obj to event_object_movement
This commit is contained in:
parent
300428d540
commit
38a126df66
@ -5,114 +5,6 @@
|
||||
|
||||
.text
|
||||
|
||||
thumb_func_start GetAllGroundEffectFlags_OnSpawn
|
||||
@ void GetAllGroundEffectFlags_OnSpawn(struct npc_state *fieldObject, u32 *flags)
|
||||
GetAllGroundEffectFlags_OnSpawn: @ 8096638
|
||||
push {r4,r5,lr}
|
||||
adds r4, r0, 0
|
||||
adds r5, r1, 0
|
||||
bl FieldObjectUpdateMetatileBehaviors
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_Reflection
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_TallGrassOnSpawn
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_LongGrassOnSpawn
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_SandHeap
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_ShallowFlowingWater
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_ShortGrass
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_HotSprings
|
||||
pop {r4,r5}
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end GetAllGroundEffectFlags_OnSpawn
|
||||
|
||||
thumb_func_start GetAllGroundEffectFlags_OnBeginStep
|
||||
@ void GetAllGroundEffectFlags_OnBeginStep(struct npc_state *fieldObject, u32 *flags)
|
||||
GetAllGroundEffectFlags_OnBeginStep: @ 8096680
|
||||
push {r4,r5,lr}
|
||||
adds r4, r0, 0
|
||||
adds r5, r1, 0
|
||||
bl FieldObjectUpdateMetatileBehaviors
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_Reflection
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_TallGrassOnBeginStep
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_LongGrassOnBeginStep
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_Tracks
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_SandHeap
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_ShallowFlowingWater
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_Puddle
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_ShortGrass
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_HotSprings
|
||||
pop {r4,r5}
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end GetAllGroundEffectFlags_OnBeginStep
|
||||
|
||||
thumb_func_start GetAllGroundEffectFlags_OnFinishStep
|
||||
@ void GetAllGroundEffectFlags_OnFinishStep(struct npc_state *fieldObject, u32 *flags)
|
||||
GetAllGroundEffectFlags_OnFinishStep: @ 80966D8
|
||||
push {r4,r5,lr}
|
||||
adds r4, r0, 0
|
||||
adds r5, r1, 0
|
||||
bl FieldObjectUpdateMetatileBehaviors
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_ShallowFlowingWater
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_SandHeap
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_Puddle
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_Ripple
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_ShortGrass
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_HotSprings
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_Seaweed
|
||||
adds r0, r4, 0
|
||||
adds r1, r5, 0
|
||||
bl GetGroundEffectFlags_JumpLanding
|
||||
pop {r4,r5}
|
||||
pop {r0}
|
||||
bx r0
|
||||
thumb_func_end GetAllGroundEffectFlags_OnFinishStep
|
||||
|
||||
thumb_func_start FieldObjectUpdateMetatileBehaviors
|
||||
@ void FieldObjectUpdateMetatileBehaviors(struct npc_state *fieldObject)
|
||||
FieldObjectUpdateMetatileBehaviors: @ 8096728
|
||||
|
@ -106,7 +106,7 @@ gUnknown_0850E84A:: @ 850E84A
|
||||
gUnknown_0850E850:: @ 850E850
|
||||
.byte 0x01, 0x01, 0x02, 0x00
|
||||
|
||||
// referenced in data/field_map_obj.s
|
||||
// referenced in data/event_object_movement.s
|
||||
.align 2
|
||||
gUnknown_0850E854::
|
||||
.4byte sub_8097E50
|
||||
|
@ -92,9 +92,9 @@ SECTIONS {
|
||||
src/field_camera.o(.text);
|
||||
src/field_door.o(.text);
|
||||
asm/field_player_avatar.o(.text);
|
||||
src/field_map_obj.o(.text);
|
||||
src/event_object_movement.o(.text);
|
||||
asm/field_ground_effect.o(.text);
|
||||
src/field_map_obj_helpers.o(.text);
|
||||
src/event_object_movement_helpers.o(.text);
|
||||
src/field_message_box.o(.text);
|
||||
src/map_obj_lock.o(.text);
|
||||
src/text_window.o(.text);
|
||||
@ -397,7 +397,7 @@ SECTIONS {
|
||||
src/metatile_behavior.o(.rodata);
|
||||
src/field_door.o(.rodata);
|
||||
data/field_player_avatar.o(.rodata);
|
||||
data/field_map_obj.o(.rodata);
|
||||
data/event_object_movement.o(.rodata);
|
||||
data/field_ground_effect.o(.rodata);
|
||||
data/map_obj_8097404.o(.rodata);
|
||||
src/text_window.o(.rodata);
|
||||
|
@ -21,7 +21,7 @@
|
||||
#include "constants/items.h"
|
||||
#include "palette.h"
|
||||
#include "window.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "event_scripts.h"
|
||||
#include "trainer_see.h"
|
||||
#include "field_message_box.h"
|
||||
@ -32,7 +32,7 @@
|
||||
#include "overworld.h"
|
||||
#include "field_weather.h"
|
||||
#include "gym_leader_rematch.h"
|
||||
#include "field_map_obj_helpers.h"
|
||||
#include "event_object_movement_helpers.h"
|
||||
|
||||
enum
|
||||
{
|
||||
|
@ -2,7 +2,7 @@
|
||||
#include "berry_tag_screen.h"
|
||||
#include "berry.h"
|
||||
#include "decompress.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "item_menu.h"
|
||||
#include "constants/items.h"
|
||||
#include "item.h"
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "global.h"
|
||||
#include "bike.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "field_player_avatar.h"
|
||||
#include "fieldmap.h"
|
||||
#include "constants/flags.h"
|
||||
|
@ -17,7 +17,7 @@
|
||||
#include "field_player_avatar.h"
|
||||
#include "field_camera.h"
|
||||
#include "field_screen.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "list_menu.h"
|
||||
#include "menu_helpers.h"
|
||||
#include "menu.h"
|
||||
|
@ -14,7 +14,7 @@
|
||||
#include "rom_818CFC8.h"
|
||||
#include "rom_81BE66C.h"
|
||||
#include "field_ground_effect.h"
|
||||
#include "field_map_obj_helpers.h"
|
||||
#include "event_object_movement_helpers.h"
|
||||
#include "mauville_old_man.h"
|
||||
#include "metatile_behavior.h"
|
||||
#include "field_effect.h"
|
||||
@ -22,7 +22,7 @@
|
||||
#include "field_camera.h"
|
||||
#include "trainer_see.h"
|
||||
#include "decoration.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
|
||||
#define NUM_FIELD_MAP_OBJECT_TEMPLATES 0x51
|
||||
|
||||
@ -175,6 +175,24 @@ extern u8 (*const gUnknown_0850DEE8[5])(u8);
|
||||
extern const s16 gUnknown_0850DFBC[3];
|
||||
extern const s16 gUnknown_0850DFC2[3];
|
||||
|
||||
/*static*/ void FieldObjectUpdateMetatileBehaviors(struct MapObject*);
|
||||
/*static*/ void GetAllGroundEffectFlags_OnBeginStep(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_Reflection(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_TallGrassOnSpawn(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_LongGrassOnSpawn(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_SandHeap(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_ShallowFlowingWater(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_ShortGrass(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_HotSprings(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_TallGrassOnBeginStep(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_LongGrassOnBeginStep(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_Tracks(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_Puddle(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_Ripple(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_Seaweed(struct MapObject*, u32*);
|
||||
/*static*/ void GetGroundEffectFlags_JumpLanding(struct MapObject*, u32*);
|
||||
|
||||
|
||||
// Code
|
||||
|
||||
static void npc_clear_ids_and_state(struct MapObject *mapObject)
|
||||
@ -5117,3 +5135,42 @@ static void npc_update_obj_anim_flag(struct MapObject *mapObject, struct Sprite
|
||||
sprite->invisible = TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
/*static*/ void GetAllGroundEffectFlags_OnSpawn(struct MapObject *eventObj, u32 *flags)
|
||||
{
|
||||
FieldObjectUpdateMetatileBehaviors(eventObj);
|
||||
GetGroundEffectFlags_Reflection(eventObj, flags);
|
||||
GetGroundEffectFlags_TallGrassOnSpawn(eventObj, flags);
|
||||
GetGroundEffectFlags_LongGrassOnSpawn(eventObj, flags);
|
||||
GetGroundEffectFlags_SandHeap(eventObj, flags);
|
||||
GetGroundEffectFlags_ShallowFlowingWater(eventObj, flags);
|
||||
GetGroundEffectFlags_ShortGrass(eventObj, flags);
|
||||
GetGroundEffectFlags_HotSprings(eventObj, flags);
|
||||
}
|
||||
|
||||
/*static*/ void GetAllGroundEffectFlags_OnBeginStep(struct MapObject *eventObj, u32 *flags)
|
||||
{
|
||||
FieldObjectUpdateMetatileBehaviors(eventObj);
|
||||
GetGroundEffectFlags_Reflection(eventObj, flags);
|
||||
GetGroundEffectFlags_TallGrassOnBeginStep(eventObj, flags);
|
||||
GetGroundEffectFlags_LongGrassOnBeginStep(eventObj, flags);
|
||||
GetGroundEffectFlags_Tracks(eventObj, flags);
|
||||
GetGroundEffectFlags_SandHeap(eventObj, flags);
|
||||
GetGroundEffectFlags_ShallowFlowingWater(eventObj, flags);
|
||||
GetGroundEffectFlags_Puddle(eventObj, flags);
|
||||
GetGroundEffectFlags_ShortGrass(eventObj, flags);
|
||||
GetGroundEffectFlags_HotSprings(eventObj, flags);
|
||||
}
|
||||
|
||||
/*static*/ void GetAllGroundEffectFlags_OnFinishStep(struct MapObject *eventObj, u32 *flags)
|
||||
{
|
||||
FieldObjectUpdateMetatileBehaviors(eventObj);
|
||||
GetGroundEffectFlags_ShallowFlowingWater(eventObj, flags);
|
||||
GetGroundEffectFlags_SandHeap(eventObj, flags);
|
||||
GetGroundEffectFlags_Puddle(eventObj, flags);
|
||||
GetGroundEffectFlags_Ripple(eventObj, flags);
|
||||
GetGroundEffectFlags_ShortGrass(eventObj, flags);
|
||||
GetGroundEffectFlags_HotSprings(eventObj, flags);
|
||||
GetGroundEffectFlags_Seaweed(eventObj, flags);
|
||||
GetGroundEffectFlags_JumpLanding(eventObj, flags);
|
||||
}
|
@ -1,8 +1,8 @@
|
||||
#include "global.h"
|
||||
#include "field_ground_effect.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "field_effect.h"
|
||||
#include "field_map_obj_helpers.h"
|
||||
#include "event_object_movement_helpers.h"
|
||||
#include "malloc.h"
|
||||
#include "task.h"
|
||||
#include "util.h"
|
@ -4,7 +4,7 @@
|
||||
#include "field_camera.h"
|
||||
#include "field_player_avatar.h"
|
||||
#include "fieldmap.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "gpu_regs.h"
|
||||
#include "menu.h"
|
||||
#include "overworld.h"
|
||||
|
@ -6,8 +6,8 @@
|
||||
#include "decompress.h"
|
||||
#include "field_camera.h"
|
||||
#include "field_effect_helpers.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "field_map_obj_helpers.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "event_object_movement_helpers.h"
|
||||
#include "field_player_avatar.h"
|
||||
#include "field_screen.h"
|
||||
#include "field_weather.h"
|
||||
|
@ -1,7 +1,7 @@
|
||||
#include "global.h"
|
||||
#include "task.h"
|
||||
#include "sprite.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "constants/songs.h"
|
||||
#include "sound.h"
|
||||
#include "palette.h"
|
||||
|
@ -4,7 +4,7 @@
|
||||
#include "constants/songs.h"
|
||||
#include "event_data.h"
|
||||
#include "field_camera.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "malloc.h"
|
||||
#include "random.h"
|
||||
#include "roulette_util.h"
|
||||
|
@ -4,7 +4,7 @@
|
||||
#include "bg.h"
|
||||
#include "event_data.h"
|
||||
#include "field_camera.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "fieldmap.h"
|
||||
#include "global.fieldmap.h"
|
||||
#include "gpu_regs.h"
|
||||
|
@ -9,7 +9,7 @@
|
||||
#include "constants/songs.h"
|
||||
#include "decompress.h"
|
||||
#include "event_data.h"
|
||||
#include "field_map_obj_helpers.h"
|
||||
#include "event_object_movement_helpers.h"
|
||||
#include "field_player_avatar.h"
|
||||
#include "field_specials.h"
|
||||
#include "graphics.h"
|
||||
|
@ -12,12 +12,12 @@
|
||||
#include "data2.h"
|
||||
#include "event_data.h"
|
||||
#include "fieldmap.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "field_player_avatar.h"
|
||||
#include "field_screen.h"
|
||||
#include "field_weather.h"
|
||||
#include "item.h"
|
||||
#include "field_map_obj_helpers.h"
|
||||
#include "event_object_movement_helpers.h"
|
||||
#include "mail.h"
|
||||
#include "metatile_behavior.h"
|
||||
#include "overworld.h"
|
||||
|
@ -1,7 +1,7 @@
|
||||
#include "global.h"
|
||||
#include "event_data.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "field_map_obj_helpers.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "event_object_movement_helpers.h"
|
||||
#include "field_player_avatar.h"
|
||||
#include "map_obj_lock.h"
|
||||
#include "script_movement.h"
|
||||
|
@ -11,7 +11,7 @@
|
||||
#include "pokemon.h"
|
||||
#include "field_specials.h"
|
||||
#include "field_player_avatar.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "event_data.h"
|
||||
#include "constants/vars.h"
|
||||
#include "constants/songs.h"
|
||||
|
@ -11,8 +11,8 @@
|
||||
#include "field_effect.h"
|
||||
#include "field_fadetransition.h"
|
||||
#include "field_ground_effect.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "field_map_obj_helpers.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "event_object_movement_helpers.h"
|
||||
#include "field_message_box.h"
|
||||
#include "field_player_avatar.h"
|
||||
#include "field_screen_effect.h"
|
||||
|
@ -4,7 +4,7 @@
|
||||
#include "decoration.h"
|
||||
#include "event_scripts.h"
|
||||
#include "field_fadetransition.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "field_screen.h"
|
||||
#include "field_weather.h"
|
||||
#include "international_string_util.h"
|
||||
|
@ -6,7 +6,7 @@
|
||||
#include "event_data.h"
|
||||
#include "event_scripts.h"
|
||||
#include "field_effect.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "field_player_avatar.h"
|
||||
#include "item_use.h"
|
||||
#include "party_menu.h"
|
||||
|
@ -1,7 +1,7 @@
|
||||
#include "global.h"
|
||||
#include "bike.h"
|
||||
#include "event_data.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "constants/maps.h"
|
||||
#include "constants/songs.h"
|
||||
#include "sound.h"
|
||||
|
@ -13,8 +13,8 @@
|
||||
#include "field_door.h"
|
||||
#include "field_effect.h"
|
||||
#include "field_fadetransition.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "field_map_obj_helpers.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "event_object_movement_helpers.h"
|
||||
#include "field_message_box.h"
|
||||
#include "field_player_avatar.h"
|
||||
#include "field_screen_effect.h"
|
||||
|
@ -1,7 +1,7 @@
|
||||
#include "global.h"
|
||||
#include "script_movement.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "field_map_obj_helpers.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "event_object_movement_helpers.h"
|
||||
#include "task.h"
|
||||
#include "util.h"
|
||||
|
||||
|
@ -20,7 +20,7 @@
|
||||
#include "field_player_avatar.h"
|
||||
#include "field_screen.h"
|
||||
#include "field_weather.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "field_effect.h"
|
||||
#include "fldeff_80F9BCC.h"
|
||||
#include "metatile_behavior.h"
|
||||
|
@ -15,7 +15,7 @@
|
||||
#include "battle_frontier_2.h"
|
||||
#include "rom_818CFC8.h"
|
||||
#include "field_specials.h"
|
||||
#include "field_map_obj_helpers.h"
|
||||
#include "event_object_movement_helpers.h"
|
||||
#include "script.h"
|
||||
#include "main.h"
|
||||
#include "sound.h"
|
||||
|
@ -4,9 +4,9 @@
|
||||
#include "pokemon.h"
|
||||
#include "sprite.h"
|
||||
#include "field_effect.h"
|
||||
#include "field_map_obj.h"
|
||||
#include "event_object_movement.h"
|
||||
#include "field_player_avatar.h"
|
||||
#include "field_map_obj_helpers.h"
|
||||
#include "event_object_movement_helpers.h"
|
||||
#include "pokenav.h"
|
||||
#include "task.h"
|
||||
#include "util.h"
|
||||
|
Loading…
Reference in New Issue
Block a user