summaryrefslogtreecommitdiff
path: root/include/global.fieldmap.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/global.fieldmap.h')
-rw-r--r--include/global.fieldmap.h46
1 files changed, 29 insertions, 17 deletions
diff --git a/include/global.fieldmap.h b/include/global.fieldmap.h
index 3c4b5f382..1858d3344 100644
--- a/include/global.fieldmap.h
+++ b/include/global.fieldmap.h
@@ -278,14 +278,25 @@ struct ObjectEventGraphicsInfo
/*0x20*/ const union AffineAnimCmd *const *affineAnims;
};
-#define PLAYER_AVATAR_FLAG_ON_FOOT (1 << 0)
-#define PLAYER_AVATAR_FLAG_MACH_BIKE (1 << 1)
-#define PLAYER_AVATAR_FLAG_ACRO_BIKE (1 << 2)
-#define PLAYER_AVATAR_FLAG_SURFING (1 << 3)
-#define PLAYER_AVATAR_FLAG_4 (1 << 4)
-#define PLAYER_AVATAR_FLAG_5 (1 << 5)
-#define PLAYER_AVATAR_FLAG_6 (1 << 6)
-#define PLAYER_AVATAR_FLAG_DASH (1 << 7)
+enum {
+ PLAYER_AVATAR_STATE_NORMAL,
+ PLAYER_AVATAR_STATE_MACH_BIKE,
+ PLAYER_AVATAR_STATE_ACRO_BIKE,
+ PLAYER_AVATAR_STATE_SURFING,
+ PLAYER_AVATAR_STATE_UNDERWATER,
+ PLAYER_AVATAR_STATE_FIELD_MOVE,
+ PLAYER_AVATAR_STATE_FISHING,
+ PLAYER_AVATAR_STATE_WATERING,
+};
+
+#define PLAYER_AVATAR_FLAG_ON_FOOT (1 << PLAYER_AVATAR_STATE_NORMAL)
+#define PLAYER_AVATAR_FLAG_MACH_BIKE (1 << PLAYER_AVATAR_STATE_MACH_BIKE)
+#define PLAYER_AVATAR_FLAG_ACRO_BIKE (1 << PLAYER_AVATAR_STATE_ACRO_BIKE)
+#define PLAYER_AVATAR_FLAG_SURFING (1 << PLAYER_AVATAR_STATE_SURFING)
+#define PLAYER_AVATAR_FLAG_UNDERWATER (1 << PLAYER_AVATAR_STATE_UNDERWATER)
+#define PLAYER_AVATAR_FLAG_FIELD_MOVE (1 << PLAYER_AVATAR_STATE_FIELD_MOVE)
+#define PLAYER_AVATAR_FLAG_FISHING (1 << PLAYER_AVATAR_STATE_FISHING)
+#define PLAYER_AVATAR_FLAG_WATERING (1 << PLAYER_AVATAR_STATE_WATERING)
enum
{
@@ -308,7 +319,7 @@ enum
COLLISION_STOP_SURFING,
COLLISION_LEDGE_JUMP,
COLLISION_PUSHED_BOULDER,
- COLLISION_ROTATING_GATE,
+ COLLISION_UNKNOWN_WARP_6C_6D_6E_6F,
COLLISION_WHEELIE_HOP,
COLLISION_ISOLATED_VERTICAL_RAIL,
COLLISION_ISOLATED_HORIZONTAL_RAIL,
@@ -335,22 +346,23 @@ enum
struct PlayerAvatar /* 0x202E858 */
{
/*0x00*/ u8 flags;
- /*0x01*/ u8 unk1; // used to be bike, but it's not that in Emerald and probably isn't here either. maybe transition flags?
+ /*0x01*/ u8 transitionFlags; // used to be bike, but it's not that in Emerald and probably isn't here either. maybe transition flags?
/*0x02*/ u8 runningState; // this is a static running state. 00 is not moving, 01 is turn direction, 02 is moving.
/*0x03*/ u8 tileTransitionState; // this is a transition running state: 00 is not moving, 01 is transition between tiles, 02 means you are on the frame in which you have centered on a tile but are about to keep moving, even if changing directions. 2 is also used for a ledge hop, since you are transitioning.
/*0x04*/ u8 spriteId;
/*0x05*/ u8 objectEventId;
/*0x06*/ bool8 preventStep;
/*0x07*/ u8 gender;
+ // These are not used in FRLG
u8 acroBikeState;
- u8 unk9;
+ u8 newDirBackup;
u8 bikeFrameCounter;
- u8 unkB;
- u32 unkC;
- u32 unk10;
- u8 unk14[8];
- u8 unk1C[8];
- // TODO: rest of struct
+ u8 bikeSpeed;
+ u32 directionHistory;
+ u32 abStartSelectHistory;
+ u8 dirTimerHistory[8];
+ // For the Rocket mazes
+ u16 lastSpinTile;
};
struct Camera