mirror of
https://github.com/ACreTeam/ac-decomp
synced 2026-05-23 06:34:18 -04:00
Implement & link m_player_lib
This commit is contained in:
@@ -256,6 +256,11 @@ m_player_call.c:
|
||||
.text: [0x803D8AEC, 0x803D8CEC]
|
||||
.data: [0x8065B9A0, 0x8065B9C8]
|
||||
.bss: [0x8129CC98, 0x8129CCA8]
|
||||
m_player_lib.c:
|
||||
.text: [0x803D8CEC, 0x803DE8A0]
|
||||
.rodata: [0x80642A10, 0x806431C8]
|
||||
.data: [0x8065B9C8, 0x8065BE98]
|
||||
.bss: [0x8129CCA8, 0x8129CD40]
|
||||
m_police_box.c:
|
||||
.text: [0x803DE8A0, 0x803DEE38]
|
||||
.rodata: [0x806431C8, 0x806431D8]
|
||||
|
||||
@@ -8,6 +8,19 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
enum {
|
||||
aUKI_STATUS_0,
|
||||
aUKI_STATUS_CARRY,
|
||||
aUKI_STATUS_READY,
|
||||
aUKI_STATUS_CAST,
|
||||
aUKI_STATUS_FLOAT,
|
||||
aUKI_STATUS_VIB,
|
||||
aUKI_STATUS_COMEBACK,
|
||||
aUKI_STATUS_7,
|
||||
|
||||
aUKI_STATUS_NUM
|
||||
};
|
||||
|
||||
typedef void (*aUKI_SET_VALUE_PROC)(ACTOR* actorx, xyz_t pos, xyz_t pos_speed, int param_4, int command);
|
||||
typedef mActor_name_t (*aUKI_GET_FISH_TYPE)(ACTOR* actorx);
|
||||
|
||||
|
||||
+18
-20
@@ -11,32 +11,32 @@ extern "C" {
|
||||
extern int aWeather_ChangingWeather();
|
||||
extern void aWeather_RequestChangeWeatherToIsland();
|
||||
extern void aWeather_RequestChangeWeatherFromIsland();
|
||||
|
||||
|
||||
extern ACTOR_PROFILE Weather_Profile;
|
||||
|
||||
typedef struct ac_weather_priv_s{
|
||||
typedef struct ac_weather_priv_s {
|
||||
xyz_t pos;
|
||||
xyz_t speed;
|
||||
f32 currentY;
|
||||
f32 unk1C;
|
||||
s16 timer;
|
||||
s16 work[5];
|
||||
s16 work[5];
|
||||
u8 use;
|
||||
u8 id;
|
||||
u8 status;
|
||||
}aWeather_Priv;
|
||||
} aWeather_Priv;
|
||||
|
||||
typedef struct weather_actor_s WEATHER_ACTOR;
|
||||
|
||||
typedef void (*CHANGE_WEATHER_PROC)(ACTOR* weather, s16 status, s16 level);
|
||||
typedef int (*GET_WEATHER_PRV_NUM)(ACTOR* weather);
|
||||
typedef void (*REMOVE_WEATHER_PRV)(ACTOR* weather, int id);
|
||||
typedef void (*CHANGE_WEATHER_PROC)(ACTOR* actorx, s16 status, s16 level);
|
||||
typedef int (*GET_WEATHER_PRV_NUM)(ACTOR* actorx);
|
||||
typedef void (*REMOVE_WEATHER_PRV)(ACTOR* actorx, int id);
|
||||
typedef aWeather_Priv* (*GET_WEATHER_PRV)(u8 status, s16 timer, xyz_t* pos, xyz_t* speed, ACTOR* weather, int id);
|
||||
typedef int (*WEATHER_SOUND_EFFECT)();
|
||||
typedef void (*CHANGE_WEATER_INSTANCE_PROC)(WEATHER_ACTOR* weather, s16 status, s16 level);
|
||||
typedef void (*CHANGE_WEATER_INSTANCE_PROC)(ACTOR* actorx, s16 status, s16 level);
|
||||
|
||||
typedef struct ac_weather_clip_s{
|
||||
WEATHER_ACTOR* actor;
|
||||
typedef struct ac_weather_clip_s {
|
||||
ACTOR* actor;
|
||||
CHANGE_WEATHER_PROC change_weather;
|
||||
GET_WEATHER_PRV_NUM get_priv_num;
|
||||
REMOVE_WEATHER_PRV remove_priv;
|
||||
@@ -44,25 +44,24 @@ typedef struct ac_weather_clip_s{
|
||||
WEATHER_SOUND_EFFECT stop_sound;
|
||||
WEATHER_SOUND_EFFECT start_sound;
|
||||
CHANGE_WEATER_INSTANCE_PROC change_weather_instance;
|
||||
}aWeather_Clip_c;
|
||||
} aWeather_Clip_c;
|
||||
|
||||
|
||||
typedef void (*MK_WEATHER_PROC)(ACTOR*,GAME*);
|
||||
typedef void (*MK_WEATHER_PROC)(ACTOR*, GAME*);
|
||||
typedef void (*CT_WEATHER_PROC)(aWeather_Priv*, GAME*);
|
||||
typedef void (*MV_WEATHER_PROC)(aWeather_Priv*, GAME*);
|
||||
typedef void (*MT_WEATHER_PROC)(aWeather_Priv*, GAME*);
|
||||
typedef void (*ST_WEATHER_PROC)(GAME*);
|
||||
typedef void (*DW_WEATHER_PROC)(aWeather_Priv*, GAME*);
|
||||
|
||||
typedef struct ac_weather_profile_s{
|
||||
typedef struct ac_weather_profile_s {
|
||||
MK_WEATHER_PROC make;
|
||||
CT_WEATHER_PROC constructor;
|
||||
MV_WEATHER_PROC move;
|
||||
ST_WEATHER_PROC set;
|
||||
DW_WEATHER_PROC draw;
|
||||
}aWeather_Profile_c;
|
||||
} aWeather_Profile_c;
|
||||
|
||||
struct weather_actor_s{
|
||||
struct weather_actor_s {
|
||||
/* 0x000 */ ACTOR actor_class;
|
||||
/* 0x174 */ aWeather_Profile_c* current_profile;
|
||||
/* 0x178 */ s16 current_status;
|
||||
@@ -74,10 +73,10 @@ struct weather_actor_s{
|
||||
/* 0x184 */ u8* ptr;
|
||||
/* 0x188 */ xyz_t pos;
|
||||
/* 0x194 */ aWeather_Priv* priv;
|
||||
/* 0x198 */ void* t;
|
||||
/* 0x198 */ void* t;
|
||||
/* 0x19C */ u8 request_change;
|
||||
/* 0x19E */ s16 unk19E;
|
||||
/* 0x1A0 */ aWeather_Clip_c clip;
|
||||
/* 0x1A0 */ aWeather_Clip_c clip;
|
||||
/* 0x1C0 */ s16 timer;
|
||||
/* 0x1C2 */ s16 timer2;
|
||||
/* 0x1C4 */ xyz_t wind_info;
|
||||
@@ -90,11 +89,10 @@ struct weather_actor_s{
|
||||
/* 0x1DC */ s16 start_sound_effect;
|
||||
/* 0x1DE */ s16 stop_sound_effect;
|
||||
/* 0x1E0 */ s16 basement_event;
|
||||
};
|
||||
};
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
+10
-10
@@ -9,16 +9,16 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
typedef struct actor_dlftbl_s {
|
||||
u32 rom_start; // unused in AC
|
||||
u32 rom_end; // unused in AC
|
||||
u8* ram_start; // used only with a check, but never set in AC
|
||||
u8* ram_end; // unused in AC
|
||||
u8* alloc_buf; // used in AC but only on free check and data is never allocated
|
||||
ACTOR_PROFILE* profile; // profile for the actor
|
||||
int unk; // unused in AC
|
||||
u16 flags; // related to memory pinning but functionally useless in AC since alloc_buf is never allocated
|
||||
s8 num_actors; // number of this type of actor that currently exist
|
||||
s8 unk2; // unused in AC
|
||||
/* 0x00 */ u32 rom_start; // unused in AC
|
||||
/* 0x04 */ u32 rom_end; // unused in AC
|
||||
/* 0x08 */ u8* ram_start; // used only with a check, but never set in AC
|
||||
/* 0x0C */ u8* ram_end; // unused in AC
|
||||
/* 0x10 */ u8* alloc_buf; // used in AC but only on free check and data is never allocated
|
||||
/* 0x14 */ ACTOR_PROFILE* profile; // profile for the actor
|
||||
/* 0x18 */ int unk; // unused in AC
|
||||
/* 0x1C */ u16 flags; // related to memory pinning but functionally useless in AC since alloc_buf is never allocated
|
||||
/* 0x1E */ s8 num_actors; // number of this type of actor that currently exist
|
||||
/* 0x1F */ s8 unk2; // unused in AC
|
||||
} ACTOR_DLFTBL;
|
||||
|
||||
extern int actor_dlftbls_num;
|
||||
|
||||
@@ -345,6 +345,15 @@ extern f32 mCoBG_Wpos2BgUtCenterHeight_AddColumn(xyz_t pos);
|
||||
extern f32 mCoBG_UtNum2UtCenterY_Keep(int ut_x, int ut_z);
|
||||
extern int mCoBG_RegistDecalCircle(const xyz_t* pos_p, f32 radius_start, f32 radius_end, s16 timer);
|
||||
|
||||
typedef int (*mCoBG_LINECHECK_PROC)(mActor_name_t);
|
||||
|
||||
#define mCoBG_LINECHECK_CAT_WALL (1 << 0)
|
||||
#define mCoBG_LINECHECK_CAT_GROUND (1 << 1)
|
||||
#define mCoBG_LINECHECK_CAT_WATER (1 << 2)
|
||||
|
||||
extern int mCoBG_LineCheck_RemoveFg(xyz_t* rev_pos, xyz_t start_pos, xyz_t end_pos, mCoBG_LINECHECK_PROC check_proc,
|
||||
int category);
|
||||
|
||||
extern void mCoBG_InitMoveBgData();
|
||||
extern void mCoBG_InitBlockBgCheckMode();
|
||||
extern void mCoBG_InitDecalCircle();
|
||||
|
||||
@@ -241,7 +241,8 @@ typedef struct common_data_s {
|
||||
/* 0x028592 */ s16 demo_profiles[2]; /* demo_profiles[0] is for demo_clip, demo_profiles[1] is for demo_clip2 */
|
||||
/* 0x028596 */ u16 copy_protect_code;
|
||||
/* 0x028598 */ int event_keep_flags[4];
|
||||
/* 0x0285A8 */ u8 _285A8[0x0285BE - 0x0285A8];
|
||||
/* 0x0285A8 */ u8 _285A8[0x0285BD - 0x0285A8];
|
||||
/* 0x0285BD */ s8 player_warp_request;
|
||||
/* 0x0285BE */ s8 player_actor_exists;
|
||||
/* 0x0285BF */ s8 complete_payment_type;
|
||||
/* 0x0285C0 */ s8 player_decoy_flag;
|
||||
@@ -258,8 +259,8 @@ typedef struct common_data_s {
|
||||
/* 0x028839 */ s8 player_bee_chase_flag;
|
||||
/* 0x02883A */ s8 goki_shocked_flag;
|
||||
/* 0x02883B */ u8 time_changed_flag;
|
||||
/* 0x02883C */ u8 unable_to_wade_flag;
|
||||
/* 0x02883D */ u8 fail_emu_flag;
|
||||
/* 0x02883C */ s8 unable_wade;
|
||||
/* 0x02883D */ s8 fail_emu_flag;
|
||||
/* 0x02883E */ u8 train_coming_flag; /* state tracker for when train is going to spawn/has spawned */
|
||||
/* 0x02883F */ u8 train_exists_flag; /* state tracker for when train exists */
|
||||
/* 0x028840 */ u8 train_control_state; /* current train state */
|
||||
|
||||
@@ -350,6 +350,13 @@ enum {
|
||||
mEv_SPECIAL_STATE_NUM
|
||||
};
|
||||
|
||||
enum {
|
||||
mEv_EVENT_MAIL_VT_DAY, /* Valentine's day */
|
||||
mEv_EVENT_MAIL_WT_DAY, /* White day */
|
||||
|
||||
mEv_EVENT_MAIL_NUM
|
||||
};
|
||||
|
||||
#define mEv_STATUS_ACTIVE (1 << 0) /* event is active */
|
||||
#define mEv_STATUS_STOP (1 << 1) /* event is stopped */
|
||||
#define mEv_STATUS_SHOW (1 << 2) /* event is shown */
|
||||
|
||||
@@ -308,7 +308,7 @@ extern int mFI_UnregistMoveActorList(mActor_name_t actor_name, int bx, int bz);
|
||||
extern int mFI_AddMoveActorList(mActor_name_t actor_name, int bx, int bz, int ut_x, int ut_z, s16 arg);
|
||||
extern mFM_move_actor_c* mFI_MoveActorListDma(int bx, int bz);
|
||||
extern void mFI_InitMoveActorBitData();
|
||||
extern void mFI_SetPlayerWade(GAME_PLAY* play);
|
||||
extern void mFI_SetPlayerWade(GAME* game);
|
||||
extern int mFI_CheckPlayerWade(int wade);
|
||||
extern int mFI_GetPlayerWade();
|
||||
extern int mFI_GetNextBlockNum(int* bx, int* bz);
|
||||
|
||||
@@ -497,6 +497,7 @@ extern int mNT_check_unknown(mActor_name_t item_no);
|
||||
(item) >= GOLD_TREE_STUMP001 && (item) <= GOLD_TREE_STUMP004 \
|
||||
)
|
||||
|
||||
#define IS_ITEM_HITTABLE_TREE(item) (IS_ITEM_SMALL_TREE(item) || IS_ITEM_MED_TREE(item) || IS_ITEM_LARGE_TREE(item) || IS_ITEM_FULL_TREE(item))
|
||||
#define IS_ITEM_SHAKEABLE_TREE(item) (IS_ITEM_MED_TREE(item) || IS_ITEM_LARGE_TREE(item) || IS_ITEM_FULL_TREE(item))
|
||||
|
||||
#define IS_ITEM_BEE_TREE(item) ((item) == TREE_BEES || (item) == CEDAR_TREE_BEES || (item) == GOLD_TREE_BEES)
|
||||
|
||||
+164
-155
@@ -23,7 +23,7 @@ extern "C" {
|
||||
#define mNpc_GET_TYPE(npc_id) ((npc_id) & 0xF000)
|
||||
#define mNpc_IS_SPECIAL(npc_id) (mNpc_GET_TYPE(npc_id) == 0xD000)
|
||||
|
||||
#define ANIMAL_NUM_MIN 5
|
||||
#define ANIMAL_NUM_MIN 5
|
||||
#define ANIMAL_NUM_MAX 15 /* Maximum number of villagers possible in town */
|
||||
#define ANIMAL_MEMORY_NUM 7
|
||||
#define ANIMAL_CATCHPHRASE_LEN 10
|
||||
@@ -38,188 +38,194 @@ extern "C" {
|
||||
#define mNpc_ISLANDER_NO ANIMAL_NUM_MAX
|
||||
|
||||
enum {
|
||||
mNpc_MOOD_0,
|
||||
mNpc_MOOD_1,
|
||||
mNpc_MOOD_2,
|
||||
mNpc_MOOD_3,
|
||||
mNpc_MOOD_4,
|
||||
mNpc_MOOD_5,
|
||||
mNpc_MOOD_6,
|
||||
mNpc_MOOD_7,
|
||||
mNpc_MOOD_8,
|
||||
mNpc_MOOD_0,
|
||||
mNpc_MOOD_1,
|
||||
mNpc_MOOD_2,
|
||||
mNpc_MOOD_3,
|
||||
mNpc_MOOD_4,
|
||||
mNpc_MOOD_5,
|
||||
mNpc_MOOD_6,
|
||||
mNpc_MOOD_7,
|
||||
mNpc_MOOD_8,
|
||||
|
||||
mNpc_MOOD_NUM
|
||||
mNpc_MOOD_NUM
|
||||
};
|
||||
|
||||
enum {
|
||||
mNpc_LETTER_RANK_BAD,
|
||||
mNpc_LETTER_RANK_OK,
|
||||
mNpc_LETTER_RANK_BAD,
|
||||
mNpc_LETTER_RANK_OK,
|
||||
|
||||
mNpc_LETTER_RANK_NUM
|
||||
mNpc_LETTER_RANK_NUM
|
||||
};
|
||||
|
||||
enum {
|
||||
mNpc_EVENT_MAIL_VT_DAY, /* valentine's day */
|
||||
mNpc_EVENT_MAIL_WT_DAY, /* white day (JP only) */
|
||||
mNpc_EVENT_MAIL_VT_DAY, /* valentine's day */
|
||||
mNpc_EVENT_MAIL_WT_DAY, /* white day (JP only) */
|
||||
|
||||
mNpc_EVENT_MAIL_NUM
|
||||
mNpc_EVENT_MAIL_NUM
|
||||
};
|
||||
|
||||
enum {
|
||||
mNpc_EVENT_MAIL_BEST_FRIEND,
|
||||
mNpc_EVENT_MAIL_OK_FRIEND,
|
||||
mNpc_EVENT_MAIL_NOT_FRIEND,
|
||||
mNpc_EVENT_MAIL_BEST_FRIEND,
|
||||
mNpc_EVENT_MAIL_OK_FRIEND,
|
||||
mNpc_EVENT_MAIL_NOT_FRIEND,
|
||||
|
||||
mNpc_EVENT_MAIL_FRIEND_NUM
|
||||
mNpc_EVENT_MAIL_FRIEND_NUM
|
||||
};
|
||||
|
||||
enum {
|
||||
mNpc_GROW_STARTER,
|
||||
mNpc_GROW_MOVE_IN,
|
||||
mNpc_GROW_ISLANDER,
|
||||
mNpc_GROW_STARTER,
|
||||
mNpc_GROW_MOVE_IN,
|
||||
mNpc_GROW_ISLANDER,
|
||||
|
||||
mNpc_GROW_NUM
|
||||
mNpc_GROW_NUM
|
||||
};
|
||||
|
||||
enum {
|
||||
mNpc_NAME_TYPE_SPNPC,
|
||||
mNpc_NAME_TYPE_NPC,
|
||||
mNpc_NAME_TYPE_SPNPC,
|
||||
mNpc_NAME_TYPE_NPC,
|
||||
|
||||
mNpc_NAME_TYPE_NUM
|
||||
mNpc_NAME_TYPE_NUM
|
||||
};
|
||||
|
||||
enum {
|
||||
mNpc_FEEL_NORMAL,
|
||||
mNpc_FEEL_HAPPY,
|
||||
mNpc_FEEL_ANGRY,
|
||||
mNpc_FEEL_SAD,
|
||||
mNpc_FEEL_SLEEPY,
|
||||
mNpc_FEEL_PITFALL,
|
||||
mNpc_FEEL_NORMAL,
|
||||
mNpc_FEEL_HAPPY,
|
||||
mNpc_FEEL_ANGRY,
|
||||
mNpc_FEEL_SAD,
|
||||
mNpc_FEEL_SLEEPY,
|
||||
mNpc_FEEL_PITFALL,
|
||||
|
||||
mNpc_FEEL_NUM,
|
||||
mNpc_FEEL_NUM,
|
||||
|
||||
mNpc_FEEL_6 = mNpc_FEEL_NUM,
|
||||
mNpc_FEEL_UZAI_0,
|
||||
mNpc_FEEL_UZAI_1,
|
||||
mNpc_FEEL_6 = mNpc_FEEL_NUM,
|
||||
mNpc_FEEL_UZAI_0,
|
||||
mNpc_FEEL_UZAI_1,
|
||||
|
||||
mNpc_FEEL_ALL_NUM
|
||||
mNpc_FEEL_ALL_NUM
|
||||
};
|
||||
|
||||
enum {
|
||||
mNpc_PATIENCE_MILDLY_ANNOYED,
|
||||
mNpc_PATIENCE_ANNOYED,
|
||||
mNpc_PATIENCE_NORMAL,
|
||||
mNpc_PATIENCE_MILDLY_ANNOYED,
|
||||
mNpc_PATIENCE_ANNOYED,
|
||||
mNpc_PATIENCE_NORMAL,
|
||||
|
||||
mNpc_PATIENCE_NUM
|
||||
mNpc_PATIENCE_NUM
|
||||
};
|
||||
|
||||
/* sizeof(Anmremail_c) == 0x16 */
|
||||
typedef struct animal_remail_s {
|
||||
lbRTC_ymd_c date; /* date sent */
|
||||
u8 name[ANIMAL_NAME_LEN]; /* villager name */
|
||||
u8 land_name[LAND_NAME_SIZE]; /* town name */
|
||||
struct {
|
||||
u8 cond:1; /* was letter good or not */
|
||||
u8 looks:7; /* personality */
|
||||
} flags;
|
||||
lbRTC_ymd_c date; /* date sent */
|
||||
u8 name[ANIMAL_NAME_LEN]; /* villager name */
|
||||
u8 land_name[LAND_NAME_SIZE]; /* town name */
|
||||
struct {
|
||||
u8 cond : 1; /* was letter good or not */
|
||||
u8 looks : 7; /* personality */
|
||||
} flags;
|
||||
} Anmremail_c;
|
||||
|
||||
/* sizeof(Anmplmail_c) == 0x104 */
|
||||
typedef struct animal_player_maiL_s {
|
||||
/* 0x000 */ u8 font; /* 'font' to use for letter info */
|
||||
/* 0x001 */ u8 paper_type;
|
||||
/* 0x002 */ mActor_name_t present;
|
||||
/* 0x004 */ u8 header_back_start; /* position for name insertion in header */
|
||||
/* 0x005 */ u8 header[MAIL_HEADER_LEN];
|
||||
/* 0x01D */ u8 body[MAIL_BODY_LEN];
|
||||
/* 0x0DD */ u8 footer[MAIL_FOOTER_LEN];
|
||||
/* 0x0FD */ u8 pad0; /* likely pad */
|
||||
/* 0x0FE */ lbRTC_ymd_c date; /* sent date */
|
||||
/* 0x000 */ u8 font; /* 'font' to use for letter info */
|
||||
/* 0x001 */ u8 paper_type;
|
||||
/* 0x002 */ mActor_name_t present;
|
||||
/* 0x004 */ u8 header_back_start; /* position for name insertion in header */
|
||||
/* 0x005 */ u8 header[MAIL_HEADER_LEN];
|
||||
/* 0x01D */ u8 body[MAIL_BODY_LEN];
|
||||
/* 0x0DD */ u8 footer[MAIL_FOOTER_LEN];
|
||||
/* 0x0FD */ u8 pad0; /* likely pad */
|
||||
/* 0x0FE */ lbRTC_ymd_c date; /* sent date */
|
||||
} Anmplmail_c;
|
||||
|
||||
/* sizeof(Anmhome_c) == 5 */
|
||||
typedef struct animal_home_s {
|
||||
/* 0x00 */ u8 type_unused; /* Likely the house type, but seems to be unused outside of SChk_Anmhome_c_sub */
|
||||
/* 0x01 */ u8 block_x; /* acre x position */
|
||||
/* 0x02 */ u8 block_z; /* acre y position */
|
||||
/* 0x03 */ u8 ut_x; /* unit x position */
|
||||
/* 0x04 */ u8 ut_z; /* unit z position */
|
||||
/* 0x00 */ u8 type_unused; /* Likely the house type, but seems to be unused outside of SChk_Anmhome_c_sub */
|
||||
/* 0x01 */ u8 block_x; /* acre x position */
|
||||
/* 0x02 */ u8 block_z; /* acre y position */
|
||||
/* 0x03 */ u8 ut_x; /* unit x position */
|
||||
/* 0x04 */ u8 ut_z; /* unit z position */
|
||||
} Anmhome_c;
|
||||
|
||||
/* sizeof(Anmlet_c) == 1 */
|
||||
typedef struct animal_letter_info_s {
|
||||
u8 exists:1; /* letter received by villager and exists */
|
||||
u8 cond:1; /* mNpc_LETTER_RANK_* */
|
||||
u8 send_reply:1; /* set when the villager should reply */
|
||||
u8 has_present_cloth:1; /* set when the villager's held present shirt is from this letter */
|
||||
u8 wearing_present_cloth:1; /* set when a villager is wearing the shirt sent with the saved letter */
|
||||
u8 bit5_7:3; /* seemingly unused */
|
||||
u8 exists : 1; /* letter received by villager and exists */
|
||||
u8 cond : 1; /* mNpc_LETTER_RANK_* */
|
||||
u8 send_reply : 1; /* set when the villager should reply */
|
||||
u8 has_present_cloth : 1; /* set when the villager's held present shirt is from this letter */
|
||||
u8 wearing_present_cloth : 1; /* set when a villager is wearing the shirt sent with the saved letter */
|
||||
u8 bit5_7 : 3; /* seemingly unused */
|
||||
} Anmlet_c;
|
||||
|
||||
/* sizeof(Anmlnd_c) == 0xA */
|
||||
typedef struct animal_land_mem_s {
|
||||
/* 0x00 */ u8 name[LAND_NAME_SIZE];
|
||||
/* 0x08 */ u16 id;
|
||||
/* 0x00 */ u8 name[LAND_NAME_SIZE];
|
||||
/* 0x08 */ u16 id;
|
||||
} Anmlnd_c;
|
||||
|
||||
typedef struct island_animal_best_ftr_s {
|
||||
u32 check;
|
||||
u16 have_bitfield;
|
||||
u32 check;
|
||||
u16 have_bitfield;
|
||||
} Anm_bestFtr_c;
|
||||
|
||||
/* sizeof(memuni_u) == 0xC */
|
||||
typedef union {
|
||||
Anmlnd_c land; /* size = 0xA */
|
||||
Anm_bestFtr_c island; /* size = 6 */
|
||||
Anmlnd_c land; /* size = 0xA */
|
||||
Anm_bestFtr_c island; /* size = 6 */
|
||||
} memuni_u;
|
||||
|
||||
/* sizeof(Anmmem_c) == 0x138 */
|
||||
typedef struct animal_memory_s {
|
||||
/* 0x000 */ PersonalID_c memory_player_id; /* personal id of the player memory belongs to */
|
||||
/* 0x014 */ lbRTC_time_c last_speak_time; /* time the player last spoke to this villager */
|
||||
/* 0x01C */ memuni_u memuni; /* union between town NPC land memory & islander player action memory */
|
||||
/* 0x028 */ u64 saved_town_tune; /* memory origin town tune */
|
||||
/* 0x030 */ s8 friendship; /* friendship with the player */
|
||||
/* 0x031 */ Anmlet_c letter_info; /* saved letter flags */
|
||||
/* 0x032 */ Anmplmail_c letter; /* saved letter */
|
||||
/* 0x000 */ PersonalID_c memory_player_id; /* personal id of the player memory belongs to */
|
||||
/* 0x014 */ lbRTC_time_c last_speak_time; /* time the player last spoke to this villager */
|
||||
/* 0x01C */ memuni_u memuni; /* union between town NPC land memory & islander player action memory */
|
||||
/* 0x028 */ u64 saved_town_tune; /* memory origin town tune */
|
||||
/* 0x030 */ s8 friendship; /* friendship with the player */
|
||||
/* 0x031 */ Anmlet_c letter_info; /* saved letter flags */
|
||||
/* 0x032 */ Anmplmail_c letter; /* saved letter */
|
||||
} Anmmem_c;
|
||||
|
||||
/* sizeof(anmuni) == 8 */
|
||||
typedef union {
|
||||
u8 previous_land_name[LAND_NAME_SIZE];
|
||||
mActor_name_t island_ftr[mNpc_ISLAND_FTR_SAVE_NUM];
|
||||
u8 previous_land_name[LAND_NAME_SIZE];
|
||||
mActor_name_t island_ftr[mNpc_ISLAND_FTR_SAVE_NUM];
|
||||
} anmuni_u;
|
||||
|
||||
/* sizeof(AnmHPMail_c) == 0x1C */
|
||||
typedef struct animal_password_mail_s {
|
||||
/* 0x00 */ lbRTC_time_c receive_time;
|
||||
/* 0x08 */ u8 password[20]; /* TODO: this should not be a hardcoded length */
|
||||
/* 0x00 */ lbRTC_time_c receive_time;
|
||||
/* 0x08 */ u8 password[20]; /* TODO: this should not be a hardcoded length */
|
||||
} AnmHPMail_c;
|
||||
|
||||
/* sizeof(Animal_c) == 0x988 */
|
||||
typedef struct animal_s {
|
||||
/* 0x000 */ AnmPersonalID_c id; /* this villager's ID */
|
||||
/* 0x010 */ Anmmem_c memories[ANIMAL_MEMORY_NUM]; /* memories of players who've spoken to this villager */
|
||||
/* 0x898 */ Anmhome_c home_info; /* home position info */
|
||||
/* 0x89D */ u8 catchphrase[ANIMAL_CATCHPHRASE_LEN]; /* may be called 'word_ending' */
|
||||
/* 0x8A8 */ mQst_contest_c contest_quest; /* current contest quest information */
|
||||
/* 0x8D0 */ u8 parent_name[PLAYER_NAME_LEN]; /* name of the player who 'spawned' the villager in, unsure why this is tracked */
|
||||
/* 0x8D8 */ anmuni_u anmuni; /* name of the last town the villager lived in or saved island ftr */
|
||||
/* 0x8E0 */ u16 previous_land_id; /* id of the previous town the villager lived in */
|
||||
/* 0x8E2 */ u8 mood; /* probably called 'feel' based on code */
|
||||
/* 0x8E3 */ u8 mood_time; /* probably called 'feel_tim' based on code */
|
||||
/* 0x8E4 */ mActor_name_t cloth; /* shirt the villager is wearing */
|
||||
/* 0x8E6 */ u16 remove_info; /* info about villager moving between towns? kinda stubbed */
|
||||
/* 0x8E8 */ u8 is_home; /* TRUE when the villager is home, otherwise FALSE */
|
||||
/* 0x8E9 */ u8 moved_in; /* TRUE when the villager moved in after town creation, FALSE if they started out in town */
|
||||
/* 0x8EA */ u8 removing; /* TRUE when the villager is leaving town, FALSE otherwise */
|
||||
/* 0x8EB */ u8 cloth_original_id; /* 0xFF when not wearing an Able Sister's pattern, otherwise 0-3 indicating which pattern */
|
||||
/* 0x8EC */ s8 umbrella_id; /* 0xFF when no umbrella, 0-31 when a standard umbrella, 32-35 when using an Able Sister's pattern */
|
||||
/* 0x8ED */ u8 unk_8ED; /* Exists according to mISL_gc_to_agb_animal, but seems unused in practice */
|
||||
/* 0x8EE */ mActor_name_t present_cloth; /* The most recently received shirt from a letter which the villager may change into */
|
||||
/* 0x8F0 */ u8 animal_relations[ANIMAL_NUM_MAX]; /* relationships between all villagers in town, starts at 128 which is neutral */
|
||||
/* 0x900 */ AnmHPMail_c hp_mail[ANIMAL_HP_MAIL_NUM]; /* mail password info storage */
|
||||
/* 0x000 */ u8 unused[24]; /* unknown usage/unused */
|
||||
/* 0x000 */ AnmPersonalID_c id; /* this villager's ID */
|
||||
/* 0x010 */ Anmmem_c memories[ANIMAL_MEMORY_NUM]; /* memories of players who've spoken to this villager */
|
||||
/* 0x898 */ Anmhome_c home_info; /* home position info */
|
||||
/* 0x89D */ u8 catchphrase[ANIMAL_CATCHPHRASE_LEN]; /* may be called 'word_ending' */
|
||||
/* 0x8A8 */ mQst_contest_c contest_quest; /* current contest quest information */
|
||||
/* 0x8D0 */ u8
|
||||
parent_name[PLAYER_NAME_LEN]; /* name of the player who 'spawned' the villager in, unsure why this is tracked */
|
||||
/* 0x8D8 */ anmuni_u anmuni; /* name of the last town the villager lived in or saved island ftr */
|
||||
/* 0x8E0 */ u16 previous_land_id; /* id of the previous town the villager lived in */
|
||||
/* 0x8E2 */ u8 mood; /* probably called 'feel' based on code */
|
||||
/* 0x8E3 */ u8 mood_time; /* probably called 'feel_tim' based on code */
|
||||
/* 0x8E4 */ mActor_name_t cloth; /* shirt the villager is wearing */
|
||||
/* 0x8E6 */ u16 remove_info; /* info about villager moving between towns? kinda stubbed */
|
||||
/* 0x8E8 */ u8 is_home; /* TRUE when the villager is home, otherwise FALSE */
|
||||
/* 0x8E9 */ u8
|
||||
moved_in; /* TRUE when the villager moved in after town creation, FALSE if they started out in town */
|
||||
/* 0x8EA */ u8 removing; /* TRUE when the villager is leaving town, FALSE otherwise */
|
||||
/* 0x8EB */ u8
|
||||
cloth_original_id; /* 0xFF when not wearing an Able Sister's pattern, otherwise 0-3 indicating which pattern */
|
||||
/* 0x8EC */ s8 umbrella_id; /* 0xFF when no umbrella, 0-31 when a standard umbrella, 32-35 when using an Able
|
||||
Sister's pattern */
|
||||
/* 0x8ED */ u8 unk_8ED; /* Exists according to mISL_gc_to_agb_animal, but seems unused in practice */
|
||||
/* 0x8EE */ mActor_name_t
|
||||
present_cloth; /* The most recently received shirt from a letter which the villager may change into */
|
||||
/* 0x8F0 */ u8 animal_relations[ANIMAL_NUM_MAX]; /* relationships between all villagers in town, starts at 128 which
|
||||
is neutral */
|
||||
/* 0x900 */ AnmHPMail_c hp_mail[ANIMAL_HP_MAIL_NUM]; /* mail password info storage */
|
||||
/* 0x000 */ u8 unused[24]; /* unknown usage/unused */
|
||||
} Animal_c;
|
||||
|
||||
/*
|
||||
@@ -230,69 +236,69 @@ typedef struct animal_s {
|
||||
|
||||
/* sizeof(Anmret_c) == 0xC */
|
||||
typedef struct animal_return_s {
|
||||
/* 0x00 */ mActor_name_t npc_id; /* id of the villager who left */
|
||||
/* 0x02 */ u8 talk_bit; /* which players have already interacted with this villager */
|
||||
/* 0x03 */ u8 exist; /* if the villager exists */
|
||||
/* 0x04 */ lbRTC_time_c renew_time; /* time that this struct was updated */
|
||||
/* 0x00 */ mActor_name_t npc_id; /* id of the villager who left */
|
||||
/* 0x02 */ u8 talk_bit; /* which players have already interacted with this villager */
|
||||
/* 0x03 */ u8 exist; /* if the villager exists */
|
||||
/* 0x04 */ lbRTC_time_c renew_time; /* time that this struct was updated */
|
||||
} Anmret_c;
|
||||
|
||||
typedef struct demo_npc_s {
|
||||
mActor_name_t npc_name; /* villager id, E0XX */
|
||||
u32 block_x, block_z; /* spawn acre */
|
||||
u32 ut_x, ut_z; /* spawn unit in acre */
|
||||
mActor_name_t npc_name; /* villager id, E0XX */
|
||||
u32 block_x, block_z; /* spawn acre */
|
||||
u32 ut_x, ut_z; /* spawn unit in acre */
|
||||
} mNpc_demo_npc_c;
|
||||
|
||||
typedef struct {
|
||||
u8 type;
|
||||
u8 palette;
|
||||
u8 wall_id;
|
||||
u8 floor_id;
|
||||
mActor_name_t main_layer_id;
|
||||
mActor_name_t secondary_layer_id;
|
||||
u8 type;
|
||||
u8 palette;
|
||||
u8 wall_id;
|
||||
u8 floor_id;
|
||||
mActor_name_t main_layer_id;
|
||||
mActor_name_t secondary_layer_id;
|
||||
} mNpc_NpcHouseData_c;
|
||||
|
||||
typedef struct npc_conversation_s {
|
||||
u8 beesting:1; // talk to player about their beesting
|
||||
u8 fish_complete:1; // talk to the player about catching all fish
|
||||
u8 insect_complete:1; // talk to the player about catching all insects
|
||||
u8 unk:5;
|
||||
u8 beesting : 1; // talk to player about their beesting
|
||||
u8 fish_complete : 1; // talk to the player about catching all fish
|
||||
u8 insect_complete : 1; // talk to the player about catching all insects
|
||||
u8 unk : 5;
|
||||
} mNpc_NpcConversation_c;
|
||||
|
||||
typedef struct npc_list_s {
|
||||
mActor_name_t name;
|
||||
mActor_name_t field_name;
|
||||
xyz_t house_position;
|
||||
xyz_t position;
|
||||
u8 appear_flag;
|
||||
mNpc_NpcConversation_c conversation_flags;
|
||||
mQst_base_c quest_info;
|
||||
mNpc_NpcHouseData_c house_data;
|
||||
mActor_name_t reward_furniture;
|
||||
mActor_name_t name;
|
||||
mActor_name_t field_name;
|
||||
xyz_t house_position;
|
||||
xyz_t position;
|
||||
u8 appear_flag;
|
||||
mNpc_NpcConversation_c conversation_flags;
|
||||
mQst_base_c quest_info;
|
||||
mNpc_NpcHouseData_c house_data;
|
||||
mActor_name_t reward_furniture;
|
||||
} mNpc_NpcList_c;
|
||||
|
||||
typedef struct event_npc_s {
|
||||
mActor_name_t event_id; /* event NPC id */
|
||||
mActor_name_t texture_id; /* real NPC id which is used for texture data */
|
||||
mActor_name_t npc_id; /* non-texture NPC id used for other NPC data */
|
||||
mActor_name_t cloth_id; /* cloth texture id */
|
||||
u8 exists; /* has the actor been spawned yet? */
|
||||
u8 in_use; /* is this event npc structure being used? */
|
||||
u16 _A; /* exists based on size of structure, seems unused */
|
||||
mActor_name_t event_id; /* event NPC id */
|
||||
mActor_name_t texture_id; /* real NPC id which is used for texture data */
|
||||
mActor_name_t npc_id; /* non-texture NPC id used for other NPC data */
|
||||
mActor_name_t cloth_id; /* cloth texture id */
|
||||
u8 exists; /* has the actor been spawned yet? */
|
||||
u8 in_use; /* is this event npc structure being used? */
|
||||
u16 _A; /* exists based on size of structure, seems unused */
|
||||
} mNpc_EventNpc_c;
|
||||
|
||||
typedef struct mask_npc_s {
|
||||
mActor_name_t mask_id; /* 'mask' actor id */
|
||||
mActor_name_t npc_id; /* NPC actor id whose data will be used */
|
||||
mActor_name_t cloth_id; /* cloth actor id */
|
||||
u8 exists; /* has the actor been spawned yet? */
|
||||
u8 in_use; /* is this mask npc structure being used? */
|
||||
Animal_c animal_data; /* animal data is copied if the mask npc is a standard villager NPC */
|
||||
mActor_name_t mask_id; /* 'mask' actor id */
|
||||
mActor_name_t npc_id; /* NPC actor id whose data will be used */
|
||||
mActor_name_t cloth_id; /* cloth actor id */
|
||||
u8 exists; /* has the actor been spawned yet? */
|
||||
u8 in_use; /* is this mask npc structure being used? */
|
||||
Animal_c animal_data; /* animal data is copied if the mask npc is a standard villager NPC */
|
||||
} mNpc_MaskNpc_c;
|
||||
|
||||
typedef struct npc_default_data_s {
|
||||
mActor_name_t cloth;
|
||||
u16 catchphrase_str_idx;
|
||||
s8 umbrella;
|
||||
mActor_name_t cloth;
|
||||
u16 catchphrase_str_idx;
|
||||
s8 umbrella;
|
||||
} mNpc_Default_Data_c;
|
||||
|
||||
extern void mNpc_AddNowNpcMax(u8* npc_max);
|
||||
@@ -340,7 +346,8 @@ extern void mNpc_CopyAnimalInfo(Animal_c* dst, Animal_c* src);
|
||||
extern int mNpc_SearchAnimalinfo(Animal_c* animal, mActor_name_t npc_id, int count);
|
||||
extern Animal_c* mNpc_GetAnimalInfoP(mActor_name_t npc_id);
|
||||
extern int mNpc_SearchAnimalPersonalID(AnmPersonalID_c* anm_pid);
|
||||
extern AnmPersonalID_c* mNpc_GetOtherAnimalPersonalIDOtherBlock(AnmPersonalID_c* exclude_pids, int count, int bx, int bz, int check_flag);
|
||||
extern AnmPersonalID_c* mNpc_GetOtherAnimalPersonalIDOtherBlock(AnmPersonalID_c* exclude_pids, int count, int bx,
|
||||
int bz, int check_flag);
|
||||
extern AnmPersonalID_c* mNpc_GetOtherAnimalPersonalID(AnmPersonalID_c* pids, int count);
|
||||
extern void mNpc_SetAnimalThisLand(Animal_c* animal, int count);
|
||||
extern int mNpc_GetSameLooksNum(u8 looks);
|
||||
@@ -354,7 +361,7 @@ extern int mNpc_SendMailtoNpc(Mail_c* mail);
|
||||
extern void mNpc_ClearRemail(Anmremail_c* remail);
|
||||
extern void mNpc_Remail();
|
||||
extern u8 mNpc_GetPaperType();
|
||||
extern int mNpc_SendVtdayMail();
|
||||
extern int mNpc_SendVtdayMail(int type);
|
||||
extern int mNpc_CheckFriendship(PersonalID_c* pid, Animal_c* animal);
|
||||
extern int mNpc_SendEventBirthdayCard(PersonalID_c* pid);
|
||||
extern int mNpc_SendEventBirthdayCard2(PersonalID_c* pid, int player_no);
|
||||
@@ -366,7 +373,8 @@ extern void mNpc_ChangePresentCloth();
|
||||
extern u8* mNpc_GetWordEnding(ACTOR* actor);
|
||||
extern void mNpc_ResetWordEnding(ACTOR* actor);
|
||||
extern int mNpc_GetFreeEventNpcIdx();
|
||||
extern int mNpc_RegistEventNpc(mActor_name_t event_id, mActor_name_t texture_id, mActor_name_t npc_id, mActor_name_t cloth_id);
|
||||
extern int mNpc_RegistEventNpc(mActor_name_t event_id, mActor_name_t texture_id, mActor_name_t npc_id,
|
||||
mActor_name_t cloth_id);
|
||||
extern void mNpc_UnRegistEventNpc(mNpc_EventNpc_c* npc);
|
||||
extern void mNpc_ClearEventNpc();
|
||||
extern mNpc_EventNpc_c* mNpc_GetSameEventNpc(mActor_name_t event_id);
|
||||
@@ -383,7 +391,8 @@ extern void mNpc_SetAnimalTitleDemo(mNpc_demo_npc_c* demo_npc, Animal_c* animal,
|
||||
extern int mNpc_GetReservedUtNum(int* ut_x, int* ut_z, mActor_name_t* item);
|
||||
extern int mNpc_BlockNum2ReservedUtNum(int* ut_x, int* ut_z, int bx, int bz);
|
||||
extern void mNpc_MakeReservedListBeforeFieldct(Anmhome_c* reserved, int reserved_num, u8* reserved_count);
|
||||
extern void mNpc_MakeReservedListAfterFieldct(Anmhome_c* reserved, int reserved_num, u8* reserved_count, u8 bx_max, u8 bz_max);
|
||||
extern void mNpc_MakeReservedListAfterFieldct(Anmhome_c* reserved, int reserved_num, u8* reserved_count, u8 bx_max,
|
||||
u8 bz_max);
|
||||
extern mNpc_InitNpcData();
|
||||
extern void mNpc_InitNpcList(mNpc_NpcList_c* npclist, int count);
|
||||
extern void mNpc_SetNpcList(mNpc_NpcList_c* npclist, Animal_c* animal, int count, int malloc_flag);
|
||||
|
||||
+40
-9
@@ -775,6 +775,37 @@ enum {
|
||||
mPlayer_GOLDEN_ITEM_TYPE_NUM
|
||||
};
|
||||
|
||||
enum {
|
||||
mPlayer_USE_FACE_ROM_TYPE_TEX,
|
||||
mPlayer_USE_FACE_ROM_TYPE_PAL,
|
||||
|
||||
mPlayer_USE_FACE_ROM_TYPE_NUM
|
||||
};
|
||||
|
||||
enum {
|
||||
mPlayer_EYE_TEX0,
|
||||
mPlayer_EYE_TEX1,
|
||||
mPlayer_EYE_TEX2,
|
||||
mPlayer_EYE_TEX3,
|
||||
mPlayer_EYE_TEX4,
|
||||
mPlayer_EYE_TEX5,
|
||||
mPlayer_EYE_TEX6,
|
||||
mPlayer_EYE_TEX7,
|
||||
|
||||
mPlayer_EYE_TEX_NUM
|
||||
};
|
||||
|
||||
enum {
|
||||
mPlayer_MOUTH_TEX0,
|
||||
mPlayer_MOUTH_TEX1,
|
||||
mPlayer_MOUTH_TEX2,
|
||||
mPlayer_MOUTH_TEX3,
|
||||
mPlayer_MOUTH_TEX4,
|
||||
mPlayer_MOUTH_TEX5,
|
||||
|
||||
mPlayer_MOUTH_TEX_NUM
|
||||
};
|
||||
|
||||
#define mPlayer_SETUP_TEXTURE_ANIMATION_NONE (0 << 0)
|
||||
/* Where is (1 << 0)? */
|
||||
#define mPlayer_SETUP_TEXTURE_ANIMATION_EYE (1 << 1)
|
||||
@@ -1987,10 +2018,10 @@ typedef struct {
|
||||
|
||||
typedef struct controller_data_s {
|
||||
MCON mcon;
|
||||
s8 on;
|
||||
s8 now;
|
||||
s8 unk3A;
|
||||
s8 unk3B;
|
||||
s8 trigger_btn_a;
|
||||
s8 btn_a;
|
||||
s8 trigger_btn_b;
|
||||
s8 btn_b;
|
||||
mActor_name_t equiped_item;
|
||||
} mPlayer_Controller_Data_c;
|
||||
|
||||
@@ -2174,10 +2205,10 @@ struct player_actor_s {
|
||||
/* 0x12D0 */ int (*request_main_demo_standing_train_all_proc)(GAME*, int);
|
||||
/* 0x12D4 */ int (*request_main_stung_bee_all_proc)(GAME*, int);
|
||||
/* 0x12D8 */ int (*request_main_shock_all_proc)(GAME*, f32, s16, s8, int, int);
|
||||
/* 0x12DC */ int (*request_main_change_cloth_forNPC_proc)(GAME*, mActor_name_t, int);
|
||||
/* 0x12DC */ int (*request_main_change_cloth_forNPC_proc)(GAME*, mActor_name_t, u16, int);
|
||||
/* 0x12E0 */ int (*request_main_push_snowball_all_proc)(GAME*, void*, int, int);
|
||||
/* 0x12E4 */ int (*request_main_stung_mosquito_all_proc)(GAME*, int, int);
|
||||
/* 0x12E8 */ int (*request_main_switch_on_lighthouse_all_proc)(GAME*, const xyz_t*, int, int);
|
||||
/* 0x12E4 */ int (*request_main_stung_mosquito_all_proc)(GAME*, void*, int);
|
||||
/* 0x12E8 */ int (*request_main_switch_on_lighthouse_all_proc)(GAME*, const xyz_t*, s16, int);
|
||||
/* 0x12EC */ int (*request_main_demo_geton_boat_all_proc)(GAME*, const xyz_t*, s16, int);
|
||||
/* 0x12F0 */ int (*request_main_demo_getoff_boat_standup_all_proc)(GAME*, const xyz_t*, s16, int);
|
||||
/* 0x12F4 */ int (*request_main_demo_get_golden_item2_all_proc)(GAME*, int, int);
|
||||
@@ -2194,7 +2225,7 @@ struct player_actor_s {
|
||||
/* 0x1320 */ int (*SetParam_for_push_snowball_proc)(GAME*, const xyz_t*, s16, f32);
|
||||
/* 0x1324 */ int (*able_submenu_request_main_index_proc)(GAME*);
|
||||
/* 0x1328 */ int (*check_able_change_camera_normal_index_proc)(ACTOR*);
|
||||
/* 0x132C */ int (*Check_able_force_speak_label_proc)(GAME*, ACTOR*);
|
||||
/* 0x132C */ int (*Check_able_force_speak_label_proc)(GAME*, void*);
|
||||
/* 0x1330 */ int (*check_cancel_request_change_proc_index_proc)(int);
|
||||
/* 0x1334 */ u32 (*Get_item_net_catch_label_proc)(ACTOR*);
|
||||
/* 0x1338 */ int (*Change_item_net_catch_label_proc)(ACTOR*, u32, s8);
|
||||
@@ -2217,7 +2248,7 @@ struct player_actor_s {
|
||||
/* 0x137C */ mActor_name_t (*Get_itemNo_forWindow_proc)(ACTOR*);
|
||||
/* 0x1380 */ int (*check_cancel_event_without_priority_proc)(GAME*);
|
||||
/* 0x1384 */ int (*CheckScene_AbleSubmenu_proc)();
|
||||
/* 0x1388 */ int (*Check_stung_mosquito_proc)(GAME*, ACTOR*);
|
||||
/* 0x1388 */ int (*Check_stung_mosquito_proc)(GAME*, void*);
|
||||
/* 0x138C */ int a_btn_pressed;
|
||||
/* 0x1390 */ int a_btn_triggers_submenu;
|
||||
/* 0x1394 */ mActor_name_t item_in_front; /* item directly in front of the player */
|
||||
|
||||
+163
-104
@@ -10,123 +10,182 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern void mPlib_Object_Exchange_keep_Player_dt(GAME_PLAY*);
|
||||
extern PLAYER_ACTOR* get_player_actor_withoutCheck(GAME_PLAY* play);
|
||||
extern mPlayer_Controller_Data_c* mPlib_Get_controller_data_for_title_demo_p();
|
||||
extern void mPlib_SetData1_controller_data_for_title_demo(int btn_a, int btn_b, f32 stick_x, f32 stick_y);
|
||||
extern void mPlib_SetData2_controller_data_for_title_demo(mActor_name_t tool);
|
||||
extern void mPlib_Clear_controller_data_for_title_demo(void);
|
||||
extern void mPlib_request_main_invade_type1(GAME_PLAY* play);
|
||||
extern mActor_name_t mPlib_Get_itemNo_forWindow();
|
||||
extern int mPlib_check_able_change_camera_normal_index(void);
|
||||
extern void mPlib_request_main_refuse_type1(GAME* game);
|
||||
extern void mPlib_request_main_wait_type3(GAME* game);
|
||||
extern void mPlib_Set_able_force_speak_label(ACTOR* actor);
|
||||
extern void mPlib_Reset_able_force_speak_label(void);
|
||||
extern int mPlib_request_main_demo_walk_type1(GAME* game, f32 goal_x, f32 goal_z, f32 speed, int flag);
|
||||
extern void mPlib_Set_goal_player_demo_walk(f32 goal_x, f32 goal_z, f32 speed);
|
||||
extern void mPlib_Set_able_hand_all_item_in_demo(s8 enable);
|
||||
extern void mPlib_change_player_cloth_info_lv2(Private_c* priv, mActor_name_t cloth_name);
|
||||
extern int mPlib_Get_address_able_display(void);
|
||||
extern int mPlib_get_player_actor_main_index(GAME* game);
|
||||
extern int mPlib_check_player_actor_main_index_AllWade(GAME_PLAY* play);
|
||||
extern int mPlib_request_main_demo_wait_type1(GAME* game, int param_2, void* param_3);
|
||||
extern int mPlib_request_main_talk_type1(GAME_PLAY* play, ACTOR* other_actor, int turn, int flag);
|
||||
extern int mPlib_request_main_talk_end_type1(GAME_PLAY* play, int return_demo_wait, int return_get_golden_axe_demo);
|
||||
extern int mPlib_request_main_door_type1(GAME* game, const xyz_t* pos, s16 angle_y, int door_type, void* door_label);
|
||||
extern int mPlib_request_main_door_type2(GAME* game, const xyz_t* pos, s16 angle_y, int door_type, void* door_label);
|
||||
extern int mPlib_strength_request_main_door_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_wade_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_demo_wade_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_demo_geton_boat_wade_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_door_type1_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_door_type2_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_outdoor_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_talk_type1_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_speak_type1_priority(GAME* game);
|
||||
extern int mPlib_Check_able_force_speak_label(GAME* game, ACTOR* label);
|
||||
extern int mPlib_able_submenu_type1(GAME* game);
|
||||
extern void mPlib_request_main_demo_wait_from_submenu(ACTOR* force_speak_label);
|
||||
extern void mPlib_Load_PlayerTexAndPallet(void* tex_p, void* pal_p, int idx);
|
||||
extern void mPlib_request_main_give_from_submenu(mActor_name_t disp_item, int submenu_ovl, int present_flag,
|
||||
int counter_flag);
|
||||
extern int mPlib_Check_tree_shaken_big(const xyz_t* pos);
|
||||
extern int mPlib_Check_tree_shaken_little(const xyz_t* pos);
|
||||
extern int mPlib_request_main_recieve_wait_type1(GAME* game, mActor_name_t item, int counter_flag);
|
||||
extern int mPlib_able_player_warp_forEvent(void);
|
||||
extern int mPlib_Get_unable_wade(void);
|
||||
extern s8 mPlib_Get_ItemNoToItemKind(mActor_name_t);
|
||||
extern void mPlib_Set_boat_angleZ(s16 angleZ);
|
||||
extern int mPlib_Get_end_player_demo_walk(void);
|
||||
extern int mPlib_request_main_demo_geton_boat_type1(f32 goal_x, f32 goal_z, s16 angleY);
|
||||
extern int mPlib_request_main_demo_getoff_boat_standup_type1(const xyz_t* pos, s16 angleY);
|
||||
extern int mPlib_check_player_actor_main_index_RecieveMove(GAME* game);
|
||||
extern int mPlib_check_label_player_demo_wait(GAME* game, void* label);
|
||||
extern int mPlib_check_player_outdoor_start(GAME* game);
|
||||
extern void mPlib_Set_change_color_request(void);
|
||||
extern int mPlib_check_player_open_umbrella(GAME_PLAY* play);
|
||||
extern int mPlib_Check_UKI_COMEBACK_STATUS(void);
|
||||
extern int mPlib_check_player_actor_main_index_OutDoorMove(GAME* game);
|
||||
extern int mPlib_request_main_close_furniture_type1(GAME* game);
|
||||
extern int mPlib_request_main_shock_type1(GAME* game, f32 time, s16 angle_y, int axe_swing);
|
||||
extern int mPlib_request_main_hold_type1(GAME* game, int ftr_no, int player_direct, const xyz_t* player_pos);
|
||||
extern int mPlib_check_player_warp_forEvent(void);
|
||||
extern int mPlib_check_player_actor_main_index_Furniture_Move(GAME* game);
|
||||
extern int mPlib_request_main_sitdown_type1(GAME* game, int direct, const xyz_t* pos, int ftr_no);
|
||||
extern int mPlib_request_main_lie_bed_type1(GAME* game, int direct, const xyz_t* pos, int head_direct, int ftr_no);
|
||||
extern void mPlib_change_player_cloth(GAME* game, int idx);
|
||||
extern u32 mPlib_Get_item_net_catch_label(void);
|
||||
extern int mPlib_Check_stung_mosquito(ACTOR* actorx);
|
||||
extern int mPlib_request_main_stung_mosquito_type1(ACTOR* actorx);
|
||||
extern int mPlib_Check_HitAxe(xyz_t* axe_pos);
|
||||
extern int mPlib_Check_StopNet(xyz_t* net_pos);
|
||||
extern int mPlib_Check_DigScoop(xyz_t* scoop_pos);
|
||||
extern int mPlib_Check_tree_shaken(const xyz_t* pos);
|
||||
extern int mPlib_Check_VibUnit_OneFrame(const xyz_t* pos);
|
||||
extern int mPlib_Get_BasicItemShapeIndex_fromItemKind(int item_kind);
|
||||
extern u8 mPlib_Get_Item_DataPointerType(int idx);
|
||||
extern void* mPlib_Get_Item_DataPointer(int idx);
|
||||
extern int mPlib_Get_BasicPlayerAnimeIndex_fromItemKind(int item_kind);
|
||||
extern cKF_Animation_R_c* mPlib_Get_Pointer_Animation(int anim_idx);
|
||||
extern int mPlib_Get_BasicPlayerAnimeIndex_fromItemKind(int item_kind);
|
||||
extern int mPlib_Get_BasicPartTableIndex_fromAnimeIndex(int anim_idx);
|
||||
extern void* mPlib_Get_Item_DataPointer(int data_kind);
|
||||
extern int mPlib_Get_BasicItemShapeIndex_fromItemKind(int item_kind);
|
||||
extern int mPlib_Get_BasicItemAnimeIndex_fromItemKind(int item_kind);
|
||||
extern void mPlib_DMA_player_Part_Table(s8* part_table_p, int idx);
|
||||
extern u8 mPlib_Get_Item_DataPointerType(int data_idx);
|
||||
extern void mPlib_Object_Exchange_keep_new_PlayerMdl(GAME_PLAY* play);
|
||||
extern u32 mPlib_Get_PlayerTexRom_p(int idx);
|
||||
extern void mPlib_Object_Exchange_keep_new_PlayerTex(GAME_PLAY* play, int bank_idx, int bank);
|
||||
extern u32 mPlib_Get_PlayerPalletRom_p(int idx);
|
||||
extern void mPlib_Object_Exchange_keep_new_PlayerPallet(GAME_PLAY* play, int bank_idx, int bank);
|
||||
extern int mPlib_Check_PlayerClothInAram(int idx);
|
||||
extern void mPlib_Object_Exchange_keep_new_PlayerFaceTex(GAME_PLAY* play);
|
||||
extern void mPlib_Object_Exchange_keep_new_PlayerFacePallet(GAME_PLAY* play, int bank, int bank_idx);
|
||||
extern void mPlib_Object_Exchange_keep_Player_dt(GAME_PLAY* play);
|
||||
extern u8* mPlib_get_player_tex_p(GAME* game);
|
||||
extern u16* mPlib_get_player_pallet_p(GAME* game);
|
||||
extern u8* mPlib_get_player_face_p(GAME* game);
|
||||
extern u16* mPlib_get_player_face_pallet_p(GAME* game);
|
||||
extern void mPlib_change_player_cloth(GAME* game, u16 cloth_idx);
|
||||
extern void mPlib_change_player_face_pallet(GAME* game);
|
||||
extern void mPlib_change_player_face(GAME* game);
|
||||
extern PLAYER_ACTOR* get_player_actor_withoutCheck(GAME_PLAY* play);
|
||||
extern int mPlib_get_player_actor_main_index(GAME* game);
|
||||
extern int mPlib_get_player_actor_request_main_index(GAME* game);
|
||||
extern cKF_Skeleton_R_c* mPlib_get_player_mdl_p(void);
|
||||
extern s16 mPlib_get_player_Object_Bank(void);
|
||||
extern void mPlib_DMA_player_Part_Table(s8* part_table_p, int idx);
|
||||
extern void mPlib_change_player_cloth_info(mPr_cloth_c* cloth_p, mActor_name_t item);
|
||||
extern void mPlib_change_player_cloth_info_lv2(Private_c* priv, mActor_name_t item);
|
||||
extern void mPlib_Load_PlayerTexAndPallet(void* tex_p, void* pal_p, int idx);
|
||||
extern mPlayer_change_data_from_submenu_c* mPlib_Get_change_data_from_submenu_p(void);
|
||||
extern void mPlib_Clear_change_data_from_submenu(void);
|
||||
extern void mPlib_request_main_give_from_submenu(mActor_name_t item, int after_mode, int present_flag,
|
||||
int surface_flag);
|
||||
extern void mPlib_request_main_putin_scoop_from_submenu(const xyz_t* pos_p, mActor_name_t item, int gold_scoop_flag);
|
||||
extern void mPlib_request_main_release_creature_gyoei_from_submenu(s16 angle_y, s16 item, int gold_scoop_flag);
|
||||
extern void mPlib_request_main_release_creature_insect_from_submenu(int insect_type, int gold_scoop_flag);
|
||||
extern s8 mPlib_Get_ItemNoToItemKind(mActor_name_t itemNo);
|
||||
extern int mPlib_Get_ItemKindTOBalloonShapeType(int item_kind);
|
||||
extern void mPlib_request_main_release_creature_balloon_from_submenu(mActor_name_t itemNo, int gold_scoop_flag);
|
||||
extern void mPlib_request_main_wait_from_submenu(void);
|
||||
extern void mPlib_request_main_demo_get_golden_item_from_submenu(void);
|
||||
extern void mPlib_request_main_mail_land_from_submenu(void);
|
||||
extern void mPlib_request_main_demo_wait_from_submenu(ACTOR* speak_actor_p);
|
||||
extern void mPlib_Set_unable_wade(int v);
|
||||
extern int mPlib_Get_unable_wade(void);
|
||||
extern int mPlib_Check_able_force_speak_label(GAME* game, ACTOR* label);
|
||||
extern void mPlib_Set_able_force_speak_label(ACTOR* label);
|
||||
extern void mPlib_Reset_able_force_speak_label(void);
|
||||
extern u8* mPlib_Get_PlayerEyeTexAnimation_p(int anim_idx);
|
||||
extern u8* mPlib_Get_PlayerMouthTexAnimation_p(int anim_idx);
|
||||
extern u8* mPlib_Get_eye_tex_p(int idx);
|
||||
extern u8* mPlib_Get_mouth_tex_p(int idx);
|
||||
extern u8* mPlib_get_player_tex_p(GAME* game);
|
||||
extern u16* mPlib_get_player_pallet_p(GAME* game);
|
||||
extern u16* mPlib_get_player_face_pallet_p(GAME* game);
|
||||
extern int mPlib_Check_scoop_after(GAME* game, xyz_t* pos, mActor_name_t* item, ACTOR** hit_actor, int gold_shovel);
|
||||
extern int mPlib_request_main_demo_standing_train_type1(GAME* game);
|
||||
extern void mPlib_Set_unable_wade(int unable);
|
||||
extern int mPlib_request_main_invade_type1(GAME* game);
|
||||
extern int mPlib_request_main_refuse_type1(GAME* game);
|
||||
extern int mPlib_request_main_wait_type3(GAME* game);
|
||||
extern int mPlib_request_main_demo_get_golden_item2_type1(GAME* game, int golden_item_type);
|
||||
extern int mPlib_request_main_talk_end_type1(GAME* game, int wait_demo, int demo_get_golden_axe);
|
||||
extern int mPlib_request_main_talk_type1(GAME* game, ACTOR* talk_actor_p, int turn_flag, int umbrella_flag);
|
||||
extern int mPlib_request_main_hold_type1(GAME* game, int ftr_no, int player_direct, const xyz_t* player_pos_p);
|
||||
extern int mPlib_request_main_recieve_wait_type1(GAME* game, mActor_name_t item, int counter_flag);
|
||||
extern int mPlib_request_main_give_type1(GAME* game, mActor_name_t item, int mode, int present, int on_surface);
|
||||
extern int mPlib_request_main_sitdown_type1(GAME* game, int direct, const xyz_t* pos_p, int ftr_no);
|
||||
extern int mPlib_request_main_close_furniture_type1(GAME* game);
|
||||
extern int mPlib_request_main_lie_bed_type1(GAME* game, int direct, const xyz_t* pos_p, int head_direct, int ftr_no);
|
||||
extern int mPlib_request_main_hide_type1(GAME* game);
|
||||
extern int mPlib_request_main_groundhog_type1(GAME* game);
|
||||
extern int mPlib_request_main_door_type1(GAME* game, const xyz_t* pos_p, s16 angle_y, int door_type, void* door_label);
|
||||
extern int mPlib_request_main_door_type2(GAME* game, const xyz_t* pos_p, s16 angle_y, int door_type, void* door_label);
|
||||
extern int mPlib_request_main_outdoor_type1(GAME* game, int is_start_demo, int door_type);
|
||||
extern int mPlib_request_main_wash_car_type1(GAME* game, const xyz_t* car_pos_p, const xyz_t* ret_pos_p,
|
||||
s16 ret_angle_y, ACTOR* ctrl_actor_p);
|
||||
extern int mPlib_request_main_rotate_octagon_type1(GAME* game, const xyz_t* pos_p, s16 angle_y);
|
||||
extern int mPlib_request_main_throw_money_type1(GAME* game, const xyz_t* pos_p, s16 angle_y);
|
||||
extern int mPlib_request_main_pray_type1(GAME* game, const xyz_t* pos_p, s16 angle_y);
|
||||
extern int mPlib_request_main_mail_jump_type1(GAME* game, const xyz_t* pos_p, s16 angle_y);
|
||||
extern int mPlib_request_main_stung_bee_type1(GAME* game);
|
||||
extern int mPlib_request_main_stung_mosquito_type1(void* label);
|
||||
extern int mPlib_request_main_switch_on_lighthouse_type1(GAME* game, const xyz_t* pos_p, s16 angle_y);
|
||||
extern int mPlib_request_main_demo_geton_boat_type1(f32 goal_x, f32 goal_z, s16 angleY);
|
||||
extern int mPlib_request_main_demo_getoff_boat_standup_type1(const xyz_t* pos_p, s16 angleY);
|
||||
extern int mPlib_request_main_shock_type1(GAME* game, f32 time, s16 angle_y, int axe_swing);
|
||||
extern int mPlib_request_main_change_cloth_forNPC_type1(GAME* game, mActor_name_t cloth_item, u16 cloth_idx,
|
||||
int try_on_flag);
|
||||
extern int mPlib_request_main_push_snowball_type1(GAME* game, void* label);
|
||||
extern int mPlib_request_main_push_snowball_end_type1(GAME* game);
|
||||
extern int mPlib_request_main_demo_wait_type1(GAME* game, int umbrella_flag, void* label);
|
||||
extern int mPlib_request_main_demo_walk_type1(GAME* game, f32 goal_x, f32 goal_z, f32 speed, int wait_flag);
|
||||
extern int mPlib_request_main_demo_geton_train_type1(GAME* game, const xyz_t* pos_p);
|
||||
extern int mPlib_request_main_demo_getoff_train_type1(GAME* game);
|
||||
extern int mPlib_check_player_actor_main_index_OutDoorMove2(GAME* game);
|
||||
extern int mPlib_Check_SetOrderSubmenu(void);
|
||||
extern void mPlib_Clear_change_data_from_submenu(void);
|
||||
extern int mPlib_request_main_demo_standing_train_type1(GAME* game);
|
||||
extern int mPlib_check_request_main_talk_type1_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_speak_type1_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_door_type1_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_door_type2_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_wade_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_demo_wade_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_demo_geton_boat_wade_priority(GAME* game);
|
||||
extern int mPlib_strength_request_main_wade_priority(GAME* game);
|
||||
extern int mPlib_strength_request_main_demo_wade_priority(GAME* game);
|
||||
extern int mPlib_strength_request_main_demo_geton_boat_wade_priority(GAME* game);
|
||||
extern int mPlib_strength_request_main_wade_snowball_priority(GAME* game);
|
||||
extern void mPlib_change_player_face(GAME* game);
|
||||
extern void mPlib_change_player_cloth_info(mPr_cloth_c* cloth_p, mActor_name_t cloth_item);
|
||||
extern int mPlib_Get_status_for_bee(void);
|
||||
extern int mPlib_request_main_demo_get_golden_item2_type1(GAME* game, int golden_item_type);
|
||||
extern void mPlib_Get_goal_player_demo_walk(f32* goal_pos_x, f32* goal_pos_z, f32* speed);
|
||||
extern int mPlib_strength_request_main_demo_geton_boat_wade_priority(GAME* game);
|
||||
extern int mPlib_strength_request_main_door_priority(GAME* game);
|
||||
extern int mPlib_check_request_main_outdoor_priority(GAME* game);
|
||||
extern int mPlib_Check_SetOrderSubmenu(void);
|
||||
extern int mPlib_able_submenu_type1(GAME* game);
|
||||
extern int mPlib_check_player_open_umbrella(GAME* game);
|
||||
extern int mPlib_check_player_outdoor_start(GAME* game);
|
||||
extern int mPlib_check_label_player_demo_wait(GAME* game, void* label);
|
||||
extern void mPlib_Set_goal_player_demo_walk(f32 pos_x, f32 pos_z, f32 speed);
|
||||
extern void mPlib_Get_goal_player_demo_walk(f32* pos_x_p, f32* pos_z_p, f32* speed_p);
|
||||
extern void mPlib_Set_continue_player_after_demo_walk(int value);
|
||||
extern int mPlib_Get_continue_player_after_demo_walk(void);
|
||||
extern void mPlib_Set_continue_player_after_demo_walk(int wait_flag);
|
||||
extern void mPlib_Set_end_player_demo_walk(int end_flag);
|
||||
|
||||
extern mPlayer_change_data_from_submenu_c* mPlib_Get_change_data_from_submenu_p(void);
|
||||
|
||||
extern void mPlib_Object_Exchange_keep_new_PlayerMdl(GAME_PLAY* play);
|
||||
extern void mPlib_Object_Exchange_keep_new_PlayerTex(GAME_PLAY* play, int bank_id, int base_idx);
|
||||
extern void mPlib_Object_Exchange_keep_new_PlayerFaceTex(GAME_PLAY* play);
|
||||
extern void mPlib_Object_Exchange_keep_new_PlayerFacePallet(GAME_PLAY* play, int bank_id, int base_idx);
|
||||
extern void mPlib_Object_Exchange_keep_new_PlayerPallet(GAME_PLAY* play, int bank_id, int base_idx);
|
||||
extern void mPlib_request_main_give_type1(GAME* game, mActor_name_t item, int mode, int present, int on_surface);
|
||||
extern void mPlib_Set_end_player_demo_walk(int value);
|
||||
extern int mPlib_Get_end_player_demo_walk(void);
|
||||
extern int mPlib_Get_space_putin_item(void);
|
||||
extern int mPlib_Get_space_putin_item_forTICKET(mActor_name_t* item_p);
|
||||
extern int mPlib_Get_space_putin_item_forHITODAMA(mActor_name_t* item_p);
|
||||
extern int mPlib_able_player_warp_forEvent(void);
|
||||
extern int mPlib_request_player_warp_forEvent(void);
|
||||
extern int mPlib_cancel_player_warp_forEvent(void);
|
||||
extern int mPlib_check_player_warp_forEvent(void);
|
||||
extern int mPlib_Check_HitAxe(xyz_t* pos_p);
|
||||
extern int mPlib_Check_VibUnit_OneFrame(const xyz_t* pos_p);
|
||||
extern int mPlib_Check_StopNet(xyz_t* pos_p);
|
||||
extern u32 mPlib_Get_item_net_catch_label(void);
|
||||
extern int mPlib_Change_item_net_catch_label(u32 label, s8 type);
|
||||
extern int mPlib_Check_HitScoop(xyz_t* pos_p);
|
||||
extern int mPlib_Check_DigScoop(xyz_t* pos_p);
|
||||
extern int mPlib_Get_address_able_display(void);
|
||||
extern int mPlib_Check_scoop_after(GAME* game, xyz_t* pos_p, mActor_name_t* item_p, ACTOR** reflect_actor_pp,
|
||||
int gold_scoop);
|
||||
extern int mPlib_Check_scene_able_change_camera_pos(void);
|
||||
extern int mPlib_Check_RotateOctagon(void);
|
||||
extern int mPlib_Set_EndWashCar(void);
|
||||
extern int mPlib_Set_AnimeSpeedWashCar(f32 anime_speed);
|
||||
extern int mPlib_Check_now_handin_item_kind(void);
|
||||
extern int mPlib_Check_now_handin_item(void);
|
||||
extern void mPlib_Set_able_hand_all_item_in_demo(s8 v);
|
||||
extern int mPlib_Get_status_for_bee(void);
|
||||
extern int mPlib_Check_end_stung_bee(void);
|
||||
extern int mPlib_Check_Label_main_push_snowball(void* label);
|
||||
extern int mPlib_Check_Label_main_wade_snowball(void* label);
|
||||
extern int mPlib_Set_ScrollDemo_forWade_snowball(int dir, const xyz_t* snowball_dist_p);
|
||||
extern int mPlib_GetSnowballPos_forWadeSnowball(xyz_t* pos_p);
|
||||
extern int mPlib_CheckCondition_forWadeSnowball(const xyz_t* pos_p, s16 angle_y);
|
||||
extern int mPlib_SetParam_for_push_snowball(const xyz_t* pos_p, s16 angle_y, f32 anim_speed);
|
||||
extern void mPlib_Set_crash_snowball_for_wade(int v);
|
||||
extern mPlayer_Controller_Data_c* mPlib_Get_controller_data_for_title_demo_p(void);
|
||||
extern void mPlib_Clear_controller_data_for_title_demo(void);
|
||||
extern void mPlib_SetData1_controller_data_for_title_demo(int btn_a, int btn_b, f32 stick_x, f32 stick_y);
|
||||
extern void mPlib_SetData2_controller_data_for_title_demo(mActor_name_t item);
|
||||
extern int mPlib_Check_CorrectPlayerPos_forEvent(void);
|
||||
extern int mPlib_Check_UKI_COMEBACK_STATUS(void);
|
||||
extern int mPlib_Check_tree_shaken(const xyz_t* pos_p);
|
||||
extern int mPlib_Check_tree_shaken_little(const xyz_t* pos_p);
|
||||
extern int mPlib_Check_tree_shaken_big(const xyz_t* pos_p);
|
||||
extern mActor_name_t mPlib_Get_itemNo_forWindow(void);
|
||||
extern int mPlib_able_birth_bee(void);
|
||||
extern int mPlib_check_able_change_camera_normal_index(void);
|
||||
extern int mPlib_check_player_actor_main_index_Furniture_Move(GAME* game);
|
||||
extern int mPlib_check_player_actor_main_index_RecieveMove(GAME* game);
|
||||
extern int mPlib_check_player_actor_main_index_Pitfall(GAME* game);
|
||||
extern int mPlib_check_player_actor_main_index_OutDoorMove(GAME* game);
|
||||
extern int mPlib_check_player_actor_main_index_OutDoorMove2(GAME* game);
|
||||
extern int mPlib_check_player_actor_main_index_AllWade(GAME* game);
|
||||
extern int mPlib_check_player_actor_main_index_catch_insect(GAME* game);
|
||||
extern int mPlib_check_player_actor_main_index_catch_fish(GAME* game);
|
||||
extern int mPlib_check_player_actor_start_switch_on_lighthouse(GAME* game);
|
||||
extern int mPlib_Check_stung_mosquito(void* label);
|
||||
extern void mPlib_Set_boat_angleZ(s16 angle_z);
|
||||
extern int mPlib_CheckButtonOnly_forDush(void);
|
||||
extern int mPlib_Check_golden_item_get_demo_end(int gold_item_type);
|
||||
extern void mPlib_Set_change_color_request(void);
|
||||
|
||||
#define GET_PLAYER_ACTOR(play) get_player_actor_withoutCheck(play)
|
||||
#define GET_PLAYER_ACTOR_NOW() get_player_actor_withoutCheck((GAME_PLAY*)gamePT)
|
||||
|
||||
@@ -87,6 +87,8 @@ enum {
|
||||
#define mPr_ORIGINAL_DESIGN_COUNT 8
|
||||
#define mPr_RADIOCARD_MAX_DAYS 13
|
||||
|
||||
#define mPr_ORIGINAL_DESIGN_IDX_VALID(idx) ((idx) >= 0 && (idx) < mPr_ORIGINAL_DESIGN_COUNT)
|
||||
|
||||
#define mPr_GET_ITEM_COND(all_cond, slot_no) (((all_cond) >> (((u32)(slot_no)) << 1)) & mPr_ITEM_COND_NUM)
|
||||
#define mPr_SET_ITEM_COND(all_cond, slot_no, cond) \
|
||||
(((all_cond) & ~((u32)mPr_ITEM_COND_NUM << ((u32)(slot_no) << 1))) | ((u32)(cond) << ((u32)(slot_no) << 1)))
|
||||
|
||||
@@ -17,7 +17,7 @@ static void aNRTC_think_title(NPC_ACTOR* actor, GAME_PLAY* play) {
|
||||
|
||||
play->fb_wipe_type = 3;
|
||||
play->fb_fade_type = 4;
|
||||
mPlib_request_main_invade_type1(play);
|
||||
mPlib_request_main_invade_type1((GAME*)play);
|
||||
Actor_info_save_actor(play);
|
||||
rtc->think_idx = aNRTC_THINK_WAIT;
|
||||
}
|
||||
|
||||
+13
-11
@@ -19,17 +19,19 @@ static void aTUMB_actor_ct(ACTOR* actor, GAME* game);
|
||||
static void aTUMB_actor_move(ACTOR* actor, GAME* game);
|
||||
static void aTUMB_actor_draw(ACTOR* actor, GAME* game);
|
||||
|
||||
ACTOR_PROFILE T_Umbrella_Profile = { mAc_PROFILE_T_UMBRELLA,
|
||||
ACTOR_PART_BG,
|
||||
ACTOR_STATE_NO_DRAW_WHILE_CULLED | ACTOR_STATE_NO_MOVE_WHILE_CULLED,
|
||||
EMPTY_NO,
|
||||
ACTOR_OBJ_BANK_UMBRELLA,
|
||||
sizeof(UMBRELLA_ACTOR),
|
||||
&aTUMB_actor_ct,
|
||||
NONE_ACTOR_PROC,
|
||||
&aTUMB_actor_move,
|
||||
&aTUMB_actor_draw,
|
||||
NULL };
|
||||
ACTOR_PROFILE T_Umbrella_Profile = {
|
||||
mAc_PROFILE_T_UMBRELLA,
|
||||
ACTOR_PART_BG,
|
||||
ACTOR_STATE_NO_DRAW_WHILE_CULLED | ACTOR_STATE_NO_MOVE_WHILE_CULLED,
|
||||
EMPTY_NO,
|
||||
ACTOR_OBJ_BANK_UMBRELLA,
|
||||
sizeof(UMBRELLA_ACTOR),
|
||||
&aTUMB_actor_ct,
|
||||
NONE_ACTOR_PROC,
|
||||
&aTUMB_actor_move,
|
||||
&aTUMB_actor_draw,
|
||||
NULL,
|
||||
};
|
||||
|
||||
extern Gfx e_umb01_model[];
|
||||
extern Gfx kasa_umb01_model[];
|
||||
|
||||
+73
-61
@@ -19,8 +19,8 @@ static void Weather_Actor_dt(ACTOR* actor, GAME* game);
|
||||
static void Weather_Actor_move(ACTOR* actor, GAME* game);
|
||||
static void Weather_Actor_draw(ACTOR* actor, GAME* game);
|
||||
|
||||
static void aWeather_SetNowProfile(WEATHER_ACTOR* weather, s16 id);
|
||||
static int aWeather_CountWeatherPrivate(WEATHER_ACTOR* weather);
|
||||
static void aWeather_SetNowProfile(ACTOR* actorx, s16 id);
|
||||
static int aWeather_CountWeatherPrivate(ACTOR* actorx);
|
||||
|
||||
static aWeather_Profile_c* profile_tbl[] = {
|
||||
&iam_weather_fine, &iam_weather_rain, &iam_weather_snow, &iam_weather_sakura, &iam_weather_leaf,
|
||||
@@ -58,12 +58,14 @@ static void aWeather_SysLevCall_MoveEnd(WEATHER_ACTOR* weather) {
|
||||
}
|
||||
|
||||
static void aWeather_SysLevStart(u8 flag) {
|
||||
Common_Get(clip.weather_clip)->actor->start_sound_effect = flag;
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
|
||||
weather->start_sound_effect = flag;
|
||||
}
|
||||
|
||||
static void aWeather_SysLevStop(u8 flag) {
|
||||
int stopFlag = flag;
|
||||
WEATHER_ACTOR* weather = Common_Get(clip.weather_clip)->actor;
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
|
||||
if (weather->start_sound_effect == stopFlag) {
|
||||
weather->start_sound_effect = 0;
|
||||
@@ -97,13 +99,12 @@ static void aWeather_RequestChangeWeather(ACTOR* actor, s16 status, s16 level) {
|
||||
}
|
||||
|
||||
extern void aWeather_RequestChangeWeatherToIsland() {
|
||||
aWeather_RequestChangeWeather(&Common_Get(clip.weather_clip)->actor->actor_class, Common_Get(island_weather),
|
||||
aWeather_RequestChangeWeather(Common_Get(clip.weather_clip)->actor, Common_Get(island_weather),
|
||||
Common_Get(island_weather_intensity));
|
||||
}
|
||||
|
||||
extern void aWeather_RequestChangeWeatherFromIsland() {
|
||||
aWeather_RequestChangeWeather(&Common_Get(clip.weather_clip)->actor->actor_class,
|
||||
mEnv_SAVE_GET_WEATHER_TYPE(Save_Get(weather)),
|
||||
aWeather_RequestChangeWeather(Common_Get(clip.weather_clip)->actor, mEnv_SAVE_GET_WEATHER_TYPE(Save_Get(weather)),
|
||||
mEnv_SAVE_GET_WEATHER_INTENSITY(Save_Get(weather)));
|
||||
}
|
||||
|
||||
@@ -158,8 +159,7 @@ static aWeather_Priv* aWeather_GetWeatherPrv(u8 status, s16 timer, xyz_t* pos, x
|
||||
}
|
||||
|
||||
static int aWeather_StopSysLevSE() {
|
||||
WEATHER_ACTOR* weather = Common_Get(clip.weather_clip)->actor;
|
||||
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
u8 current = weather->current_sound_effect;
|
||||
|
||||
if (weather->sound_flag == 0) {
|
||||
@@ -174,8 +174,7 @@ static int aWeather_StopSysLevSE() {
|
||||
}
|
||||
|
||||
static int aWeather_StartSysLevSE() {
|
||||
WEATHER_ACTOR* weather = Common_Get(clip.weather_clip)->actor;
|
||||
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
u8 current = weather->current_sound_effect;
|
||||
|
||||
if (weather->sound_flag == 1) {
|
||||
@@ -202,7 +201,8 @@ static int aWeather_StartSysLevSE() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void aWeather_ChangeWeatherInstance(WEATHER_ACTOR* weather, s16 status, s16 level) {
|
||||
static void aWeather_ChangeWeatherInstance(ACTOR* actorx, s16 status, s16 level) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
|
||||
weather->next_status = status;
|
||||
weather->next_level = level;
|
||||
@@ -210,9 +210,9 @@ static void aWeather_ChangeWeatherInstance(WEATHER_ACTOR* weather, s16 status, s
|
||||
weather->current_level = 0;
|
||||
weather->request_change = TRUE;
|
||||
|
||||
if (!aWeather_CountWeatherPrivate(weather)) {
|
||||
if (!aWeather_CountWeatherPrivate(actorx)) {
|
||||
weather->current_status = weather->next_status;
|
||||
aWeather_SetNowProfile(weather, weather->current_status);
|
||||
aWeather_SetNowProfile(actorx, weather->current_status);
|
||||
aWeather_weatherinfo_CommonSet(weather->current_status, weather->next_level);
|
||||
weather->current_level = level;
|
||||
weather->current_aim_level = weather->next_level;
|
||||
@@ -229,7 +229,8 @@ static int aWeather_IsLand_Event_Check() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int aWeather_Basement_Event_Check(WEATHER_ACTOR* weather) {
|
||||
static int aWeather_Basement_Event_Check(ACTOR* actorx) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
|
||||
if ((weather->basement_event == 1) || (weather->basement_event == 2)) {
|
||||
return 1;
|
||||
@@ -237,7 +238,8 @@ static int aWeather_Basement_Event_Check(WEATHER_ACTOR* weather) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void aWeather_ChangeEnvSE(WEATHER_ACTOR* weather, GAME_PLAY* play, s16 status, s16 level) {
|
||||
static void aWeather_ChangeEnvSE(ACTOR* actorx, GAME* game, s16 status, s16 level) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
u8 current = weather->current_sound_effect;
|
||||
|
||||
if (weather->sound_flag == 1 || weather->sound_flag == 2)
|
||||
@@ -256,7 +258,7 @@ static void aWeather_ChangeEnvSE(WEATHER_ACTOR* weather, GAME_PLAY* play, s16 st
|
||||
if ((status == 1) && (weather->current_sound_effect == -1000)) {
|
||||
switch (level) {
|
||||
case 1:
|
||||
if (mPlib_check_player_open_umbrella(play) != 0) {
|
||||
if (mPlib_check_player_open_umbrella(game) != 0) {
|
||||
aWeather_SysLevStart(0x12);
|
||||
weather->current_sound_effect = 0x12;
|
||||
return;
|
||||
@@ -265,7 +267,7 @@ static void aWeather_ChangeEnvSE(WEATHER_ACTOR* weather, GAME_PLAY* play, s16 st
|
||||
weather->current_sound_effect = 7;
|
||||
break;
|
||||
case 2:
|
||||
if (mPlib_check_player_open_umbrella(play) != 0) {
|
||||
if (mPlib_check_player_open_umbrella(game) != 0) {
|
||||
aWeather_SysLevStart(0x13);
|
||||
weather->current_sound_effect = 0x13;
|
||||
return;
|
||||
@@ -274,7 +276,7 @@ static void aWeather_ChangeEnvSE(WEATHER_ACTOR* weather, GAME_PLAY* play, s16 st
|
||||
weather->current_sound_effect = 8;
|
||||
break;
|
||||
case 3:
|
||||
if (mPlib_check_player_open_umbrella(play) != 0) {
|
||||
if (mPlib_check_player_open_umbrella(game) != 0) {
|
||||
aWeather_SysLevStart(0x14);
|
||||
weather->current_sound_effect = 0x14;
|
||||
return;
|
||||
@@ -293,7 +295,7 @@ static void aWeather_EndEnvSE(ACTOR* actor) {
|
||||
|
||||
if ((sAdo_GameframeEnd_Check() == 1) ||
|
||||
((sAdo_GameframeEnd_Check() == 2) &&
|
||||
((aWeather_IsLand_Event_Check() != 0) || (aWeather_Basement_Event_Check(weather) != 0)))) {
|
||||
((aWeather_IsLand_Event_Check() != 0) || (aWeather_Basement_Event_Check(actor) != 0)))) {
|
||||
if (((u8)(current - 7) <= 2) || ((u8)(current - 0x12) <= 1) || (u8)(current == 0x14)) {
|
||||
aWeather_SysLevStop(current);
|
||||
weather->current_sound_effect = -1000;
|
||||
@@ -305,7 +307,8 @@ static void aWeather_EndEnvSE(ACTOR* actor) {
|
||||
aWeather_SysLevCall_MoveEnd(weather);
|
||||
}
|
||||
|
||||
static void aWeather_SetNowProfile(WEATHER_ACTOR* weather, s16 id) {
|
||||
static void aWeather_SetNowProfile(ACTOR* actorx, s16 id) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
|
||||
if (!mFI_GET_TYPE(mFI_GetFieldId())) {
|
||||
weather->current_profile = profile_tbl[id];
|
||||
@@ -314,11 +317,11 @@ static void aWeather_SetNowProfile(WEATHER_ACTOR* weather, s16 id) {
|
||||
}
|
||||
}
|
||||
|
||||
static void aWeather_SecureWeatherPrivateWork(WEATHER_ACTOR* weather) {
|
||||
static void aWeather_SecureWeatherPrivateWork(ACTOR* actorx) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
int i;
|
||||
|
||||
weather->priv = zelda_malloc(sizeof(aWeather_Priv) * 100);
|
||||
|
||||
if (weather->priv != NULL) {
|
||||
for (i = 0; i < 100; i++) {
|
||||
bzero(&weather->priv[i], sizeof(aWeather_Priv));
|
||||
@@ -326,14 +329,16 @@ static void aWeather_SecureWeatherPrivateWork(WEATHER_ACTOR* weather) {
|
||||
}
|
||||
}
|
||||
|
||||
static void aWeather_SetClip(WEATHER_ACTOR* weather, int flag) {
|
||||
static void aWeather_SetClip(ACTOR* actorx, int flag) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
aWeather_Clip_c* clip;
|
||||
|
||||
if (flag != 0) {
|
||||
Common_Set(clip.weather_clip, NULL);
|
||||
} else {
|
||||
clip = &weather->clip;
|
||||
|
||||
clip->actor = weather;
|
||||
clip->actor = actorx;
|
||||
clip->change_weather = aWeather_RequestChangeWeather;
|
||||
clip->get_priv_num = aWeather_GetWeatherPrvNum;
|
||||
clip->remove_priv = aWeather_AbolishPrivate;
|
||||
@@ -346,7 +351,8 @@ static void aWeather_SetClip(WEATHER_ACTOR* weather, int flag) {
|
||||
}
|
||||
}
|
||||
|
||||
static void aWeather_RenewWindInfo(WEATHER_ACTOR* weather) {
|
||||
static void aWeather_RenewWindInfo(ACTOR* actorx) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
s_xyz pos = Common_Get(wind); // multiply by 1 means inline ?
|
||||
f32 speed = Common_Get(wind_speed) * 0.01f;
|
||||
f32 factor = 1.0f;
|
||||
@@ -356,12 +362,12 @@ static void aWeather_RenewWindInfo(WEATHER_ACTOR* weather) {
|
||||
weather->wind_info.z = pos.z * speed * factor;
|
||||
}
|
||||
|
||||
static void aWeather_SnowInAdvance(WEATHER_ACTOR* weather, GAME_PLAY* play, int moves) {
|
||||
|
||||
static void aWeather_SnowInAdvance(ACTOR* actorx, GAME* game, int moves) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
int i;
|
||||
|
||||
for (i = 0; i < moves; i++) {
|
||||
Weather_Actor_move(&weather->actor_class, &play->game);
|
||||
Weather_Actor_move(actorx, game);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -375,7 +381,7 @@ static void Weather_Actor_ct(ACTOR* actor, GAME* game) {
|
||||
int cur;
|
||||
xyz_t* pos = Camera2_getCenterPos_p();
|
||||
|
||||
aWeather_SetClip(weather, 0);
|
||||
aWeather_SetClip(actor, 0);
|
||||
|
||||
if (mEv_CheckTitleDemo() > 0) {
|
||||
cur = mEv_CheckTitleDemo() - 1;
|
||||
@@ -408,17 +414,17 @@ static void Weather_Actor_ct(ACTOR* actor, GAME* game) {
|
||||
weather->lightning_timer2 = 30;
|
||||
|
||||
weather->sound_flag = 0;
|
||||
aWeather_RenewWindInfo(weather);
|
||||
aWeather_RenewWindInfo(actor);
|
||||
|
||||
if (!mFI_GET_TYPE(mFI_GetFieldId())) {
|
||||
aWeather_SecureWeatherPrivateWork(weather);
|
||||
aWeather_SecureWeatherPrivateWork(actor);
|
||||
}
|
||||
|
||||
aWeather_SetNowProfile(weather, weather->current_status);
|
||||
aWeather_SetNowProfile(actor, weather->current_status);
|
||||
|
||||
if ((weather->current_status == 2) || (weather->current_status == 3)) {
|
||||
weather->pos.y -= 50.0f;
|
||||
aWeather_SnowInAdvance(weather, play, 0x28);
|
||||
aWeather_SnowInAdvance(actor, game, 0x28);
|
||||
weather->pos.y += 50.0f;
|
||||
}
|
||||
|
||||
@@ -437,11 +443,11 @@ static void Weather_Actor_ct(ACTOR* actor, GAME* game) {
|
||||
weather->basement_event = 0;
|
||||
}
|
||||
if ((play->fb_wipe_type == 6) && (aWeather_IsLand_Event_Check() == 0) &&
|
||||
(aWeather_Basement_Event_Check(weather) == 0)) {
|
||||
(aWeather_Basement_Event_Check(actor) == 0)) {
|
||||
weather->current_sound_effect = Common_Get(current_sound_effect);
|
||||
} else {
|
||||
weather->current_sound_effect = -1000;
|
||||
aWeather_ChangeEnvSE(weather, play, weather->current_status, weather->current_level);
|
||||
aWeather_ChangeEnvSE(actor, game, weather->current_status, weather->current_level);
|
||||
aWeather_SysLevCall_MoveEnd(weather);
|
||||
}
|
||||
}
|
||||
@@ -453,7 +459,7 @@ static void Weather_Actor_dt(ACTOR* actor, GAME* game) {
|
||||
zelda_free(weather->priv);
|
||||
}
|
||||
|
||||
aWeather_SetClip(weather, 1);
|
||||
aWeather_SetClip(actor, 1);
|
||||
}
|
||||
|
||||
static void aWeather_DrawWeatherPrv(ACTOR* actor, GAME* game) {
|
||||
@@ -495,7 +501,8 @@ static void aWeather_MakeWeatherPrv(ACTOR* actor, GAME* game) {
|
||||
}
|
||||
}
|
||||
|
||||
static void aWeather_MoveWeatherPrv(WEATHER_ACTOR* weather, GAME* game) {
|
||||
static void aWeather_MoveWeatherPrv(ACTOR* actorx, GAME* game) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
aWeather_Priv* priv;
|
||||
int i;
|
||||
|
||||
@@ -509,7 +516,7 @@ static void aWeather_MoveWeatherPrv(WEATHER_ACTOR* weather, GAME* game) {
|
||||
if (priv->timer != -100) {
|
||||
priv->timer--;
|
||||
if (priv->timer <= 0) {
|
||||
aWeather_AbolishPrivate(&weather->actor_class, i);
|
||||
aWeather_AbolishPrivate(actorx, i);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -517,7 +524,8 @@ static void aWeather_MoveWeatherPrv(WEATHER_ACTOR* weather, GAME* game) {
|
||||
}
|
||||
}
|
||||
|
||||
static int aWeather_CountWeatherPrivate(WEATHER_ACTOR* weather) {
|
||||
static int aWeather_CountWeatherPrivate(ACTOR* actorx) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
int i;
|
||||
int count;
|
||||
aWeather_Priv* priv = weather->priv;
|
||||
@@ -534,7 +542,8 @@ static int aWeather_CountWeatherPrivate(WEATHER_ACTOR* weather) {
|
||||
return count;
|
||||
}
|
||||
|
||||
static void aWeather_ChangeWeather(WEATHER_ACTOR* weather, GAME_PLAY* play) {
|
||||
static void aWeather_ChangeWeather(ACTOR* actorx, GAME* game) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
|
||||
if ((weather->request_change == TRUE) && (weather->current_level == 0)) {
|
||||
if (mFI_GET_TYPE(mFI_GetFieldId())) {
|
||||
@@ -542,27 +551,28 @@ static void aWeather_ChangeWeather(WEATHER_ACTOR* weather, GAME_PLAY* play) {
|
||||
aWeather_weatherinfo_CommonSet(weather->current_status, weather->next_level);
|
||||
weather->current_level = 1;
|
||||
weather->current_aim_level = weather->next_level;
|
||||
aWeather_ChangeEnvSE(weather, play, weather->current_status, weather->current_level);
|
||||
aWeather_ChangeEnvSE(actorx, game, weather->current_status, weather->current_level);
|
||||
weather->request_change = FALSE;
|
||||
} else if (aWeather_CountWeatherPrivate(weather) == 0) {
|
||||
} else if (aWeather_CountWeatherPrivate(actorx) == 0) {
|
||||
weather->current_status = weather->next_status;
|
||||
aWeather_SetNowProfile(weather, weather->current_status);
|
||||
aWeather_SetNowProfile(actorx, weather->current_status);
|
||||
aWeather_weatherinfo_CommonSet(weather->current_status, weather->next_level);
|
||||
weather->current_level = 1;
|
||||
weather->current_aim_level = weather->next_level;
|
||||
aWeather_ChangeEnvSE(weather, play, weather->current_status, weather->current_level);
|
||||
aWeather_ChangeEnvSE(actorx, game, weather->current_status, weather->current_level);
|
||||
weather->request_change = FALSE;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void aWeather_CheckWeatherTimer() {
|
||||
static void aWeather_CheckWeatherTimer(ACTOR* actorx) {
|
||||
s_xyz dir;
|
||||
|
||||
mEnv_DecideWindDirect(&dir, 0x3000, 0x3000);
|
||||
}
|
||||
|
||||
static void aWeather_RenewWeatherLevel(WEATHER_ACTOR* weather, GAME_PLAY* play) {
|
||||
static void aWeather_RenewWeatherLevel(ACTOR* actorx, GAME* game) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
s16 level;
|
||||
|
||||
if (weather->current_level != weather->current_aim_level) {
|
||||
@@ -574,12 +584,13 @@ static void aWeather_RenewWeatherLevel(WEATHER_ACTOR* weather, GAME_PLAY* play)
|
||||
weather->current_level--;
|
||||
else
|
||||
weather->current_level++;
|
||||
aWeather_ChangeEnvSE(weather, play, weather->current_status, weather->current_level);
|
||||
aWeather_ChangeEnvSE(actorx, game, weather->current_status, weather->current_level);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void aWeather_ChangeWeatherTime0(WEATHER_ACTOR* weather) {
|
||||
static void aWeather_ChangeWeatherTime0(ACTOR* actorx) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
s16 rndWeather, rndIntensity;
|
||||
s16 evWeather, evIntensity;
|
||||
s16 save_weather;
|
||||
@@ -611,14 +622,15 @@ static void aWeather_ChangeWeatherTime0(WEATHER_ACTOR* weather) {
|
||||
Save_Set(weather, rndIntensity | (rndWeather * 16));
|
||||
|
||||
if (((mEv_CheckTitleDemo() != -9) || (weather->sound_flag != 1)) && (mFI_CheckInIsland() == 0)) {
|
||||
aWeather_RequestChangeWeather(&weather->actor_class, rndWeather, rndIntensity);
|
||||
aWeather_RequestChangeWeather(actorx, rndWeather, rndIntensity);
|
||||
}
|
||||
Common_Set(weather_time, Common_Get(time.rtc_time));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void aWeather_MakeKaminari(WEATHER_ACTOR* weather) {
|
||||
static void aWeather_MakeKaminari(ACTOR* actorx) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actorx;
|
||||
lbRTC_time_c time = Common_Get(time.rtc_time);
|
||||
u8 month = time.month;
|
||||
s16 timer;
|
||||
@@ -660,21 +672,21 @@ static void Weather_Actor_move(ACTOR* actor, GAME* game) {
|
||||
camera = &play->camera;
|
||||
|
||||
angle = search_position_angleY(&camera->lookat.center, &camera->lookat.eye);
|
||||
aWeather_MakeKaminari(weather);
|
||||
aWeather_CheckWeatherTimer(weather);
|
||||
aWeather_MakeKaminari(actor);
|
||||
aWeather_CheckWeatherTimer(actor);
|
||||
aWeather_MakeWeatherPrv(actor, game);
|
||||
aWeather_RenewWeatherLevel(weather, play);
|
||||
aWeather_MoveWeatherPrv(weather, game);
|
||||
aWeather_ChangeWeather(weather, play);
|
||||
aWeather_RenewWeatherLevel(actor, game);
|
||||
aWeather_MoveWeatherPrv(actor, game);
|
||||
aWeather_ChangeWeather(actor, game);
|
||||
|
||||
weather->pos = *pos;
|
||||
|
||||
aWeather_ChangeWeatherTime0(weather);
|
||||
aWeather_ChangeWeatherTime0(actor);
|
||||
|
||||
if (Common_Get(weather) == 1) {
|
||||
umbrella = mPlib_check_player_open_umbrella(play);
|
||||
umbrella = mPlib_check_player_open_umbrella(game);
|
||||
if (umbrella != weather->umbrella_flag) {
|
||||
aWeather_ChangeEnvSE(weather, play, weather->current_status, weather->current_level);
|
||||
aWeather_ChangeEnvSE(actor, game, weather->current_status, weather->current_level);
|
||||
}
|
||||
|
||||
weather->umbrella_flag = umbrella;
|
||||
@@ -689,10 +701,10 @@ static void Weather_Actor_move(ACTOR* actor, GAME* game) {
|
||||
}
|
||||
|
||||
extern int aWeather_ChangingWeather() {
|
||||
|
||||
if (Common_Get(clip.weather_clip) != NULL) {
|
||||
if (Common_Get(clip.weather_clip->actor) != NULL) {
|
||||
return Common_Get(clip.weather_clip->actor)->request_change == TRUE;
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip).weather_clip->actor;
|
||||
return weather->request_change == TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+60
-67
@@ -27,50 +27,46 @@ Gfx* ef_otiba_model_tbl[] = {
|
||||
};
|
||||
|
||||
aWeather_Profile_c iam_weather_leaf = {
|
||||
aWeatherLeaf_make,
|
||||
aWeatherLeaf_ct,
|
||||
aWeatherLeaf_move,
|
||||
aWeatherLeaf_set,
|
||||
aWeatherLeaf_draw,
|
||||
aWeatherLeaf_make, aWeatherLeaf_ct, aWeatherLeaf_move, aWeatherLeaf_set, aWeatherLeaf_draw,
|
||||
};
|
||||
|
||||
static int aWeatherLeaf_DecideMakeLeafCount(ACTOR* actor, GAME* game){
|
||||
static int aWeatherLeaf_DecideMakeLeafCount(ACTOR* actor, GAME* game) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actor;
|
||||
|
||||
if(weather->current_level == 1){
|
||||
if (weather->current_level == 1) {
|
||||
return (game->frame_counter & 15) == 0;
|
||||
}
|
||||
return (game->frame_counter & 7) == 0;
|
||||
return (game->frame_counter & 7) == 0;
|
||||
}
|
||||
|
||||
static void aWeatherLeaf_make(ACTOR* actor, GAME* game){
|
||||
|
||||
static void aWeatherLeaf_make(ACTOR* actor, GAME* game) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actor;
|
||||
GAME_PLAY* play = (GAME_PLAY*)game;
|
||||
|
||||
aWeather_Priv* priv;
|
||||
f32 x,z;
|
||||
aWeather_Priv* priv;
|
||||
f32 x, z;
|
||||
xyz_t pos = weather->pos;
|
||||
f32 y = 230.0f + pos.y;
|
||||
int count = Common_Get(clip.weather_clip)->get_priv_num(actor);
|
||||
xyz_t base = {0.0f, 0.0f, 0.0f};
|
||||
int count = Common_Get(clip.weather_clip)->get_priv_num(actor);
|
||||
xyz_t base = { 0.0f, 0.0f, 0.0f };
|
||||
xyz_t mod_pos;
|
||||
|
||||
if(aWeatherLeaf_DecideMakeLeafCount(actor, game) != 0){
|
||||
if (aWeatherLeaf_DecideMakeLeafCount(actor, game) != 0) {
|
||||
base.y = -0.8f + (RANDOM_F(-0.0999999642372f));
|
||||
if(count != -1){
|
||||
if (count != -1) {
|
||||
x = -100.0f + (RANDOM_F(200.0f));
|
||||
z = -200.0f + (RANDOM_F(380.0f));
|
||||
|
||||
|
||||
mod_pos = pos;
|
||||
|
||||
mod_pos.x += x;
|
||||
mod_pos.z += z;
|
||||
mod_pos.y = y;
|
||||
|
||||
|
||||
priv = Common_Get(clip.weather_clip)->get_priv(4, 280, &mod_pos, &base, actor, count);
|
||||
if(priv != NULL){
|
||||
if (priv != NULL) {
|
||||
aWeatherLeaf_ct(priv, game);
|
||||
priv->work[3]= 0;
|
||||
priv->work[3] = 0;
|
||||
priv->work[4] = 156.5f + (RANDOM_F(260.5));
|
||||
priv->currentY = y;
|
||||
}
|
||||
@@ -78,36 +74,34 @@ static void aWeatherLeaf_make(ACTOR* actor, GAME* game){
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void aWeatherLeaf_ct(aWeather_Priv* priv, GAME*){
|
||||
static void aWeatherLeaf_ct(aWeather_Priv* priv, GAME*) {
|
||||
priv->work[0] = RANDOM_F(3.0f);
|
||||
priv->work[1] = RANDOM_F(65535.0f);
|
||||
priv->work[2] = RANDOM_F(65535.0f);
|
||||
}
|
||||
|
||||
|
||||
static int aWeatherLeaf_CheckLeafBorder(aWeather_Priv* priv){
|
||||
WEATHER_ACTOR* weather = Common_Get(clip.weather_clip)->actor;
|
||||
static int aWeatherLeaf_CheckLeafBorder(aWeather_Priv* priv) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
int ret = 0;
|
||||
f32 leafTemp;
|
||||
xyz_t pos;
|
||||
|
||||
if(weather != NULL){
|
||||
pos = weather->pos;
|
||||
leafTemp =priv->pos.x;
|
||||
|
||||
if(leafTemp < (-100.0f + pos.x)){
|
||||
if (weather != NULL) {
|
||||
pos = weather->pos;
|
||||
leafTemp = priv->pos.x;
|
||||
|
||||
if (leafTemp < (-100.0f + pos.x)) {
|
||||
ret |= 2;
|
||||
}
|
||||
if(leafTemp > (100.0f + pos.x)){
|
||||
if (leafTemp > (100.0f + pos.x)) {
|
||||
ret |= 8;
|
||||
}
|
||||
leafTemp =priv->pos.z;
|
||||
leafTemp = priv->pos.z;
|
||||
|
||||
if(leafTemp > (180.0f + pos.z)){
|
||||
if (leafTemp > (180.0f + pos.z)) {
|
||||
ret |= 4;
|
||||
}
|
||||
if(leafTemp < (-200.0f + pos.z)){
|
||||
if (leafTemp < (-200.0f + pos.z)) {
|
||||
ret |= 1;
|
||||
}
|
||||
}
|
||||
@@ -115,58 +109,58 @@ static int aWeatherLeaf_CheckLeafBorder(aWeather_Priv* priv){
|
||||
return ret;
|
||||
}
|
||||
|
||||
static void aWeatherLeaf_CheckLeafScroll(aWeather_Priv* priv){
|
||||
static void aWeatherLeaf_CheckLeafScroll(aWeather_Priv* priv) {
|
||||
int border = aWeatherLeaf_CheckLeafBorder(priv);
|
||||
|
||||
if(border != 0){
|
||||
if((border >> 1) & 1){
|
||||
if (border != 0) {
|
||||
if ((border >> 1) & 1) {
|
||||
priv->pos.x += 200.0f;
|
||||
}
|
||||
if((border >> 3) & 1){
|
||||
if ((border >> 3) & 1) {
|
||||
priv->pos.x -= 200.0f;
|
||||
}
|
||||
if((border >> 2) & 1){
|
||||
if ((border >> 2) & 1) {
|
||||
priv->pos.z -= 380.0f;
|
||||
}
|
||||
if(border & 1){
|
||||
if (border & 1) {
|
||||
priv->pos.z += 380.0f;
|
||||
}
|
||||
}
|
||||
|
||||
if(Common_Get(clip.weather_clip) != NULL){
|
||||
if (Common_Get(clip.weather_clip) != NULL) {
|
||||
f32 y;
|
||||
WEATHER_ACTOR* weather = Common_Get(clip.weather_clip)->actor;
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
|
||||
if(weather != NULL){
|
||||
if (weather != NULL) {
|
||||
y = 230.0f + weather->pos.y;
|
||||
if(priv->pos.y < + weather->pos.y){
|
||||
if (priv->pos.y < +weather->pos.y) {
|
||||
priv->pos.y = (y + (priv->pos.y - priv->currentY));
|
||||
priv->currentY = y;
|
||||
priv->currentY = y;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void aWeatherLeaf_SetWind2Leaf(aWeather_Priv* priv){
|
||||
static void aWeatherLeaf_SetWind2Leaf(aWeather_Priv* priv) {
|
||||
|
||||
priv->pos.x += 0.45f;
|
||||
}
|
||||
|
||||
static void aWeatherLeaf_move(aWeather_Priv* priv, GAME* game){
|
||||
GAME_PLAY* play = (GAME_PLAY*) game;
|
||||
static void aWeatherLeaf_move(aWeather_Priv* priv, GAME* game) {
|
||||
GAME_PLAY* play = (GAME_PLAY*)game;
|
||||
|
||||
priv->pos.x += priv->speed.x;
|
||||
priv->pos.y += priv->speed.y;
|
||||
priv->pos.z += priv->speed.z;
|
||||
|
||||
|
||||
priv->work[3] += priv->work[4];
|
||||
aWeatherLeaf_SetWind2Leaf(priv);
|
||||
aWeatherLeaf_CheckLeafScroll(priv);
|
||||
priv->work[1] += 0x8DC;
|
||||
priv->work[2] += 0x474;
|
||||
priv->work[2] += 0x474;
|
||||
}
|
||||
|
||||
static void aWeatherLeaf_set(GAME* game){
|
||||
static void aWeatherLeaf_set(GAME* game) {
|
||||
|
||||
_texture_z_light_fog_prim_xlu(game->graph);
|
||||
|
||||
@@ -174,39 +168,38 @@ static void aWeatherLeaf_set(GAME* game){
|
||||
|
||||
gSPDisplayList(NEXT_POLY_XLU_DISP, ef_otiba01_setmode);
|
||||
|
||||
|
||||
CLOSE_DISP(game->graph);
|
||||
}
|
||||
|
||||
void aWeatherLeaf_draw(aWeather_Priv* priv, GAME* game){
|
||||
GAME_PLAY* play = (GAME_PLAY*) game;
|
||||
|
||||
void aWeatherLeaf_draw(aWeather_Priv* priv, GAME* game) {
|
||||
GAME_PLAY* play = (GAME_PLAY*)game;
|
||||
|
||||
Mtx* work;
|
||||
f32 scale;
|
||||
f32 min;
|
||||
xyz_t pos;
|
||||
xyz_t screen_pos;
|
||||
|
||||
xyz_t screen_pos;
|
||||
|
||||
pos.x = priv->pos.x + (6.0f * sin_s(priv->work[3]));
|
||||
|
||||
pos.z = priv->pos.z + (6.0f * cos_s(priv->work[3]));
|
||||
pos.y = priv->pos.y;
|
||||
pos.y = priv->pos.y;
|
||||
Game_play_Projection_Trans(play, &pos, &screen_pos);
|
||||
|
||||
if(( screen_pos.x >= 0.0f) && (screen_pos.x < SCREEN_WIDTH_F) && ( screen_pos.y >= 0.0f) && (screen_pos.y < SCREEN_HEIGHT_F)){
|
||||
|
||||
if ((screen_pos.x >= 0.0f) && (screen_pos.x < SCREEN_WIDTH_F) && (screen_pos.y >= 0.0f) &&
|
||||
(screen_pos.y < SCREEN_HEIGHT_F)) {
|
||||
|
||||
work = GRAPH_ALLOC_TYPE(game->graph, Mtx, 1);
|
||||
|
||||
OPEN_DISP(game->graph);
|
||||
|
||||
suMtxMakeSRT(work, 0.00499999988824f, 0.00499999988824f, 0.00499999988824f, priv->work[2], priv->work[1], priv->work[2], pos.x, pos.y, pos.z);
|
||||
OPEN_DISP(game->graph);
|
||||
|
||||
suMtxMakeSRT(work, 0.00499999988824f, 0.00499999988824f, 0.00499999988824f, priv->work[2], priv->work[1],
|
||||
priv->work[2], pos.x, pos.y, pos.z);
|
||||
|
||||
gSPMatrix(NEXT_POLY_XLU_DISP, work, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
gSPDisplayList(NEXT_POLY_XLU_DISP, ef_otiba_model_tbl[priv->work[0]]);
|
||||
|
||||
CLOSE_DISP( game->graph);
|
||||
|
||||
gSPDisplayList(NEXT_POLY_XLU_DISP, ef_otiba_model_tbl[priv->work[0]]);
|
||||
|
||||
CLOSE_DISP(game->graph);
|
||||
}
|
||||
}
|
||||
|
||||
+63
-69
@@ -29,24 +29,20 @@ static void aWeatherRain_set(GAME*);
|
||||
static void aWeatherRain_draw(aWeather_Priv*, GAME*);
|
||||
|
||||
aWeather_Profile_c iam_weather_rain = {
|
||||
aWeatherRain_make,
|
||||
aWeatherRain_ct,
|
||||
aWeatherRain_move,
|
||||
aWeatherRain_set,
|
||||
aWeatherRain_draw,
|
||||
aWeatherRain_make, aWeatherRain_ct, aWeatherRain_move, aWeatherRain_set, aWeatherRain_draw,
|
||||
};
|
||||
|
||||
static int aWeatherRain_DecideMakeRainCount(ACTOR* actor){
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actor;
|
||||
static int aWeatherRain_DecideMakeRainCount(ACTOR* actor) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actor;
|
||||
|
||||
if(weather->current_level == 1){
|
||||
if (weather->current_level == 1) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
return( weather->current_level -2 ? 0 : -1) + 3;
|
||||
return (weather->current_level - 2 ? 0 : -1) + 3;
|
||||
}
|
||||
|
||||
static void aWeatherRain_make(ACTOR* actor, GAME* game){
|
||||
static void aWeatherRain_make(ACTOR* actor, GAME* game) {
|
||||
aWeather_Priv* priv;
|
||||
xyz_t pos;
|
||||
xyz_t pos_mod;
|
||||
@@ -57,84 +53,79 @@ static void aWeatherRain_make(ACTOR* actor, GAME* game){
|
||||
GAME_PLAY* play = (GAME_PLAY*)game;
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actor;
|
||||
|
||||
f32 x,y,z;
|
||||
|
||||
f32 x, y, z;
|
||||
|
||||
count = aWeatherRain_DecideMakeRainCount(actor);
|
||||
pos = weather->pos;
|
||||
|
||||
for(i = 0; i < count; i++){
|
||||
for (i = 0; i < count; i++) {
|
||||
|
||||
priv_num = Common_Get(clip.weather_clip)->get_priv_num(&weather->actor_class);
|
||||
if (priv_num != -1){
|
||||
if (priv_num != -1) {
|
||||
x = -130.0f + (RANDOM_F(260.0f));
|
||||
z = -200.0f + (RANDOM_F(360.0f));
|
||||
|
||||
|
||||
pos_mod = pos;
|
||||
speed = ZeroVec;
|
||||
|
||||
speed.y = -9.5f + (RANDOM_F(-2.5f));
|
||||
|
||||
speed.y = -9.5f + (RANDOM_F(-2.5f));
|
||||
speed.y += -2.0f;
|
||||
|
||||
|
||||
pos_mod.x += x;
|
||||
pos_mod.z += z;
|
||||
|
||||
if(mEv_CheckTitleDemo() == -9){
|
||||
if (mEv_CheckTitleDemo() == -9) {
|
||||
PLAYER_ACTOR* player = get_player_actor_withoutCheck(play);
|
||||
|
||||
pos_mod.y = 70.0f + (120.0f + player->actor_class.world.position.y);
|
||||
}
|
||||
else{
|
||||
} else {
|
||||
pos_mod.y = 70.0f + (120.0f + mCoBG_GetBgY_OnlyCenter_FromWpos(pos_mod, 0.0f));
|
||||
}
|
||||
|
||||
|
||||
priv = Common_Get(clip.weather_clip)->get_priv(1, 1000, &pos_mod, &speed, actor, priv_num);
|
||||
if(priv != NULL){
|
||||
aWeatherRain_ct(priv,game);
|
||||
if (priv != NULL) {
|
||||
aWeatherRain_ct(priv, game);
|
||||
priv->work[0] = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void aWeatherRain_ct(aWeather_Priv*, GAME*){
|
||||
|
||||
static void aWeatherRain_ct(aWeather_Priv*, GAME*) {
|
||||
}
|
||||
|
||||
static void aWeatherRain_MoveRain(aWeather_Priv* priv) {
|
||||
|
||||
static void aWeatherRain_MoveRain(aWeather_Priv* priv){
|
||||
|
||||
priv->pos.x += priv->speed.x;
|
||||
priv->pos.y += priv->speed.y;
|
||||
priv->pos.z += priv->speed.z;
|
||||
priv->pos.x += priv->speed.x;
|
||||
priv->pos.y += priv->speed.y;
|
||||
priv->pos.z += priv->speed.z;
|
||||
}
|
||||
|
||||
|
||||
static void aWeatherRain_MakePicha(ACTOR* actor, GAME* game, xyz_t pos){
|
||||
static void aWeatherRain_MakePicha(ACTOR* actor, GAME* game, xyz_t pos) {
|
||||
int priv_num = Common_Get(clip.weather_clip)->get_priv_num(actor);
|
||||
GAME_PLAY* play = (GAME_PLAY*)game;
|
||||
aWeather_Priv* priv;
|
||||
f32 y;
|
||||
|
||||
if(priv_num != -1){
|
||||
if(mEv_CheckTitleDemo() == -9){
|
||||
|
||||
if (priv_num != -1) {
|
||||
if (mEv_CheckTitleDemo() == -9) {
|
||||
PLAYER_ACTOR* player = get_player_actor_withoutCheck(play);
|
||||
|
||||
|
||||
y = player->actor_class.world.position.y;
|
||||
pos.y = y;
|
||||
}
|
||||
else{
|
||||
} else {
|
||||
y = mCoBG_GetBgY_OnlyCenter_FromWpos(pos, 0.0f);
|
||||
pos.y = y;
|
||||
}
|
||||
priv = Common_Get(clip.weather_clip)->get_priv(1, 8, &pos, NULL, actor, priv_num);
|
||||
if(priv != NULL){
|
||||
aWeatherRain_ct(priv,game);
|
||||
if (priv != NULL) {
|
||||
aWeatherRain_ct(priv, game);
|
||||
priv->work[0] = 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void aWeatherRain_set(GAME* game){
|
||||
static void aWeatherRain_set(GAME* game) {
|
||||
|
||||
_texture_z_light_fog_prim_xlu(game->graph);
|
||||
|
||||
@@ -142,75 +133,78 @@ static void aWeatherRain_set(GAME* game){
|
||||
|
||||
gSPDisplayList(NEXT_POLY_XLU_DISP, ef_ame02_setmode);
|
||||
|
||||
|
||||
CLOSE_DISP(game->graph);
|
||||
}
|
||||
|
||||
|
||||
static void aWeatherRain_move(aWeather_Priv* priv, GAME* game){
|
||||
static void aWeatherRain_move(aWeather_Priv* priv, GAME* game) {
|
||||
WEATHER_ACTOR* weather;
|
||||
s16 timer = (1000 - priv->timer);
|
||||
|
||||
if(priv->work[0] == 0){
|
||||
if (priv->work[0] == 0) {
|
||||
aWeatherRain_MoveRain(priv);
|
||||
if((timer >= 10) && (Common_Get(clip.weather_clip) != NULL)){
|
||||
weather = Common_Get(clip.weather_clip)->actor;
|
||||
if(weather != NULL){
|
||||
(Common_Get(clip.weather_clip)->remove_priv(&weather->actor_class, priv->id));
|
||||
if ((timer >= 10) && (Common_Get(clip.weather_clip) != NULL)) {
|
||||
weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
if (weather != NULL) {
|
||||
(Common_Get(clip.weather_clip)->remove_priv(&weather->actor_class, priv->id));
|
||||
aWeatherRain_MakePicha(&weather->actor_class, game, priv->pos);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void aWeatherRain_draw(aWeather_Priv* priv, GAME* game){
|
||||
void aWeatherRain_draw(aWeather_Priv* priv, GAME* game) {
|
||||
static f32 rain_scale[] = {
|
||||
0.000299999985145f, 0.035f, 0.01f,
|
||||
0.000299999985145f,
|
||||
0.035f,
|
||||
0.01f,
|
||||
};
|
||||
static f32 picha_scale[] = {
|
||||
0.0033f,0.0033f,0.0033f,
|
||||
0.0033f,
|
||||
0.0033f,
|
||||
0.0033f,
|
||||
};
|
||||
|
||||
GAME_PLAY* play = (GAME_PLAY*)game;
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
|
||||
s16 disp;
|
||||
s16 disp;
|
||||
xyz_t pos;
|
||||
s16 angle;
|
||||
GRAPH* graph;
|
||||
Mtx* work;
|
||||
|
||||
angle = Common_Get(clip.weather_clip)->actor->current_yAngle;
|
||||
disp = 8 - priv->timer;
|
||||
angle = weather->current_yAngle;
|
||||
disp = 8 - priv->timer;
|
||||
pos = priv->pos;
|
||||
|
||||
if(priv->work[0] == 1){
|
||||
if (priv->work[0] == 1) {
|
||||
graph = play->game.graph;
|
||||
|
||||
disp = disp >> 1;
|
||||
|
||||
Matrix_translate(pos.x,pos.y,pos.z, FALSE);
|
||||
Matrix_translate(pos.x, pos.y, pos.z, FALSE);
|
||||
Matrix_mult(&play->billboard_matrix, 1);
|
||||
Matrix_scale(picha_scale[0], picha_scale[1], picha_scale[2], TRUE);
|
||||
|
||||
OPEN_DISP(graph);
|
||||
OPEN_DISP(graph);
|
||||
|
||||
gSPMatrix(NEXT_POLY_XLU_DISP, _Matrix_to_Mtx_new(play->game.graph), G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
gSPMatrix(NEXT_POLY_XLU_DISP, _Matrix_to_Mtx_new(play->game.graph),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
gSPDisplayList(NEXT_POLY_XLU_DISP, aWeather_rain_picha_disp[(disp)]);
|
||||
|
||||
|
||||
CLOSE_DISP(graph);
|
||||
}
|
||||
else if(priv->work[0] == 0){
|
||||
} else if (priv->work[0] == 0) {
|
||||
work = GRAPH_ALLOC_TYPE(game->graph, Mtx, 1);
|
||||
|
||||
OPEN_DISP( play->game.graph);
|
||||
|
||||
suMtxMakeSRT(work, rain_scale[0], rain_scale[1], rain_scale[2], 0, angle, 0, pos.x, pos.y, pos.z);
|
||||
|
||||
OPEN_DISP(play->game.graph);
|
||||
|
||||
suMtxMakeSRT(work, rain_scale[0], rain_scale[1], rain_scale[2], 0, angle, 0, pos.x, pos.y, pos.z);
|
||||
|
||||
gSPMatrix(NEXT_POLY_XLU_DISP, work, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
gSPDisplayList(NEXT_POLY_XLU_DISP, ef_ame02_04_modelT);
|
||||
|
||||
CLOSE_DISP( play->game.graph);
|
||||
|
||||
CLOSE_DISP(play->game.graph);
|
||||
}
|
||||
}
|
||||
|
||||
+59
-67
@@ -20,50 +20,46 @@ static void aWeatherSakura_set(GAME*);
|
||||
static void aWeatherSakura_draw(aWeather_Priv*, GAME*);
|
||||
|
||||
aWeather_Profile_c iam_weather_sakura = {
|
||||
aWeatherSakura_make,
|
||||
aWeatherSakura_ct,
|
||||
aWeatherSakura_move,
|
||||
aWeatherSakura_set,
|
||||
aWeatherSakura_draw,
|
||||
aWeatherSakura_make, aWeatherSakura_ct, aWeatherSakura_move, aWeatherSakura_set, aWeatherSakura_draw,
|
||||
};
|
||||
|
||||
static int aWeatherSakura_DecideMakeSakuraCount(ACTOR* actor, GAME* game){
|
||||
static int aWeatherSakura_DecideMakeSakuraCount(ACTOR* actor, GAME* game) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actor;
|
||||
|
||||
if(weather->current_level == 1){
|
||||
if (weather->current_level == 1) {
|
||||
return (game->frame_counter & 7) == 0;
|
||||
}
|
||||
return (game->frame_counter & 3) == 0;
|
||||
return (game->frame_counter & 3) == 0;
|
||||
}
|
||||
|
||||
static void aWeatherSakura_make(ACTOR* actor, GAME* game){
|
||||
|
||||
static void aWeatherSakura_make(ACTOR* actor, GAME* game) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)actor;
|
||||
GAME_PLAY* play = (GAME_PLAY*)game;
|
||||
|
||||
aWeather_Priv* priv;
|
||||
f32 x,z;
|
||||
aWeather_Priv* priv;
|
||||
f32 x, z;
|
||||
xyz_t pos = weather->pos;
|
||||
f32 y = 230.0f + pos.y;
|
||||
int count = Common_Get(clip.weather_clip)->get_priv_num(actor);
|
||||
xyz_t base = {0.0f, 0.0f, 0.0f};
|
||||
int count = Common_Get(clip.weather_clip)->get_priv_num(actor);
|
||||
xyz_t base = { 0.0f, 0.0f, 0.0f };
|
||||
xyz_t mod_pos;
|
||||
|
||||
if(aWeatherSakura_DecideMakeSakuraCount(actor, game) != 0){
|
||||
if (aWeatherSakura_DecideMakeSakuraCount(actor, game) != 0) {
|
||||
base.y = -0.8f + (RANDOM_F(-0.0999999642372f));
|
||||
if(count != -1){
|
||||
if (count != -1) {
|
||||
x = -100.0f + (RANDOM_F(200.0f));
|
||||
z = -200.0f + (RANDOM_F(380.0f));
|
||||
|
||||
|
||||
mod_pos = pos;
|
||||
|
||||
mod_pos.x += x;
|
||||
mod_pos.z += z;
|
||||
mod_pos.y = y;
|
||||
|
||||
|
||||
priv = Common_Get(clip.weather_clip)->get_priv(3, 280, &mod_pos, &base, actor, count);
|
||||
if(priv != NULL){
|
||||
if (priv != NULL) {
|
||||
aWeatherSakura_ct(priv, game);
|
||||
priv->work[3]= 0;
|
||||
priv->work[3] = 0;
|
||||
priv->work[4] = 156.5f + (RANDOM_F(260.5));
|
||||
priv->currentY = y;
|
||||
}
|
||||
@@ -71,36 +67,34 @@ static void aWeatherSakura_make(ACTOR* actor, GAME* game){
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void aWeatherSakura_ct(aWeather_Priv* priv, GAME*){
|
||||
static void aWeatherSakura_ct(aWeather_Priv* priv, GAME*) {
|
||||
priv->work[0] = RANDOM_F(65535.0f);
|
||||
priv->work[1] = RANDOM_F(65535.0f);
|
||||
priv->work[2] = RANDOM_F(65535.0f);
|
||||
}
|
||||
|
||||
|
||||
static int aWeatherSakura_CheckSakuraBorder(aWeather_Priv* priv){
|
||||
WEATHER_ACTOR* weather = Common_Get(clip.weather_clip)->actor;
|
||||
static int aWeatherSakura_CheckSakuraBorder(aWeather_Priv* priv) {
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
int ret = 0;
|
||||
f32 sakuraTemp;
|
||||
xyz_t pos;
|
||||
|
||||
if(weather != NULL){
|
||||
pos = weather->pos;
|
||||
sakuraTemp =priv->pos.x;
|
||||
|
||||
if(sakuraTemp < (-100.0f + pos.x)){
|
||||
if (weather != NULL) {
|
||||
pos = weather->pos;
|
||||
sakuraTemp = priv->pos.x;
|
||||
|
||||
if (sakuraTemp < (-100.0f + pos.x)) {
|
||||
ret |= 2;
|
||||
}
|
||||
if(sakuraTemp > (100.0f + pos.x)){
|
||||
if (sakuraTemp > (100.0f + pos.x)) {
|
||||
ret |= 8;
|
||||
}
|
||||
sakuraTemp =priv->pos.z;
|
||||
sakuraTemp = priv->pos.z;
|
||||
|
||||
if(sakuraTemp > (180.0f + pos.z)){
|
||||
if (sakuraTemp > (180.0f + pos.z)) {
|
||||
ret |= 4;
|
||||
}
|
||||
if(sakuraTemp < (-200.0f + pos.z)){
|
||||
if (sakuraTemp < (-200.0f + pos.z)) {
|
||||
ret |= 1;
|
||||
}
|
||||
}
|
||||
@@ -108,59 +102,59 @@ static int aWeatherSakura_CheckSakuraBorder(aWeather_Priv* priv){
|
||||
return ret;
|
||||
}
|
||||
|
||||
static void aWeatherSakura_CheckSakuraScroll(aWeather_Priv* priv){
|
||||
static void aWeatherSakura_CheckSakuraScroll(aWeather_Priv* priv) {
|
||||
int border = aWeatherSakura_CheckSakuraBorder(priv);
|
||||
|
||||
if(border != 0){
|
||||
if((border >> 1) & 1){
|
||||
if (border != 0) {
|
||||
if ((border >> 1) & 1) {
|
||||
priv->pos.x += 200.0f;
|
||||
}
|
||||
if((border >> 3) & 1){
|
||||
if ((border >> 3) & 1) {
|
||||
priv->pos.x -= 200.0f;
|
||||
}
|
||||
if((border >> 2) & 1){
|
||||
if ((border >> 2) & 1) {
|
||||
priv->pos.z -= 380.0f;
|
||||
}
|
||||
if(border & 1){
|
||||
if (border & 1) {
|
||||
priv->pos.z += 380.0f;
|
||||
}
|
||||
}
|
||||
|
||||
if(Common_Get(clip.weather_clip) != NULL){
|
||||
if (Common_Get(clip.weather_clip) != NULL) {
|
||||
f32 y;
|
||||
WEATHER_ACTOR* weather = Common_Get(clip.weather_clip)->actor;
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
|
||||
if(weather != NULL){
|
||||
if (weather != NULL) {
|
||||
y = 230.0f + weather->pos.y;
|
||||
if(priv->pos.y < + weather->pos.y){
|
||||
if (priv->pos.y < +weather->pos.y) {
|
||||
priv->pos.y = (y + (priv->pos.y - priv->currentY));
|
||||
priv->currentY = y;
|
||||
priv->currentY = y;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void aWeatherSakura_SetWind2Sakura(aWeather_Priv* priv){
|
||||
static void aWeatherSakura_SetWind2Sakura(aWeather_Priv* priv) {
|
||||
|
||||
priv->pos.x += 0.45f;
|
||||
}
|
||||
|
||||
static void aWeatherSakura_move(aWeather_Priv* priv, GAME* game){
|
||||
GAME_PLAY* play = (GAME_PLAY*) game;
|
||||
static void aWeatherSakura_move(aWeather_Priv* priv, GAME* game) {
|
||||
GAME_PLAY* play = (GAME_PLAY*)game;
|
||||
|
||||
priv->pos.x += priv->speed.x;
|
||||
priv->pos.y += priv->speed.y;
|
||||
priv->pos.z += priv->speed.z;
|
||||
|
||||
|
||||
priv->work[3] += priv->work[4];
|
||||
aWeatherSakura_SetWind2Sakura(priv);
|
||||
aWeatherSakura_CheckSakuraScroll(priv);
|
||||
priv->work[0] += 0x200;
|
||||
priv->work[1] += 0x8DC;
|
||||
priv->work[2] += 0x474;
|
||||
priv->work[2] += 0x474;
|
||||
}
|
||||
|
||||
static void aWeatherSakura_set(GAME* game){
|
||||
static void aWeatherSakura_set(GAME* game) {
|
||||
|
||||
_texture_z_light_fog_prim_xlu(game->graph);
|
||||
|
||||
@@ -168,41 +162,39 @@ static void aWeatherSakura_set(GAME* game){
|
||||
|
||||
gSPDisplayList(NEXT_POLY_XLU_DISP, ef_hanabira01_00_setmode);
|
||||
|
||||
|
||||
CLOSE_DISP(game->graph);
|
||||
}
|
||||
|
||||
void aWeatherSakura_draw(aWeather_Priv* priv, GAME* game){
|
||||
GAME_PLAY* play = (GAME_PLAY*) game;
|
||||
void aWeatherSakura_draw(aWeather_Priv* priv, GAME* game) {
|
||||
GAME_PLAY* play = (GAME_PLAY*)game;
|
||||
|
||||
xyz_t base = { 0.05f, 0.05f, 0.05f };
|
||||
|
||||
xyz_t base = {0.05f, 0.05f, 0.05f};
|
||||
|
||||
Mtx* work;
|
||||
f32 scale;
|
||||
f32 min;
|
||||
xyz_t pos;
|
||||
xyz_t screen_pos;
|
||||
|
||||
xyz_t screen_pos;
|
||||
|
||||
pos.x = priv->pos.x + (6.0f * sin_s(priv->work[3]));
|
||||
|
||||
pos.z = priv->pos.z + (6.0f * cos_s(priv->work[3]));
|
||||
pos.y = priv->pos.y;
|
||||
pos.y = priv->pos.y;
|
||||
Game_play_Projection_Trans(play, &pos, &screen_pos);
|
||||
|
||||
if(( screen_pos.x >= 0.0f) && (screen_pos.x < SCREEN_WIDTH_F) && ( screen_pos.y >= 0.0f) && (screen_pos.y < SCREEN_HEIGHT_F)){
|
||||
|
||||
if ((screen_pos.x >= 0.0f) && (screen_pos.x < SCREEN_WIDTH_F) && (screen_pos.y >= 0.0f) &&
|
||||
(screen_pos.y < SCREEN_HEIGHT_F)) {
|
||||
|
||||
work = GRAPH_ALLOC_TYPE(game->graph, Mtx, 1);
|
||||
|
||||
OPEN_DISP(game->graph);
|
||||
|
||||
OPEN_DISP(game->graph);
|
||||
|
||||
suMtxMakeSRT(work, base.x, base.y, base.z, priv->work[2], priv->work[1], priv->work[2], pos.x, pos.y, pos.z);
|
||||
|
||||
gSPMatrix(NEXT_POLY_XLU_DISP, work, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
gSPDisplayList(NEXT_POLY_XLU_DISP, ef_hanabira01_00_modelT);
|
||||
|
||||
CLOSE_DISP( game->graph);
|
||||
|
||||
gSPDisplayList(NEXT_POLY_XLU_DISP, ef_hanabira01_00_modelT);
|
||||
|
||||
CLOSE_DISP(game->graph);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -72,7 +72,7 @@ static void aWeatherSnow_ct(aWeather_Priv*, GAME*) {
|
||||
}
|
||||
|
||||
static int aWeatherSnow_CheckSnowBorder(aWeather_Priv* priv, GAME_PLAY* play) {
|
||||
WEATHER_ACTOR* weather = Common_Get(clip.weather_clip)->actor;
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
int ret = 0;
|
||||
f32 wtemp, ptemp;
|
||||
if (weather != NULL) {
|
||||
@@ -120,7 +120,7 @@ static void aWeatherSnow_CheckSnowScroll(aWeather_Priv* priv, GAME_PLAY* play) {
|
||||
|
||||
if (Common_Get(clip.weather_clip) != NULL) {
|
||||
f32 y;
|
||||
WEATHER_ACTOR* weather = Common_Get(clip.weather_clip)->actor;
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
|
||||
if (weather != NULL) {
|
||||
y = 230.0f + weather->pos.y;
|
||||
@@ -135,7 +135,7 @@ static void aWeatherSnow_CheckSnowScroll(aWeather_Priv* priv, GAME_PLAY* play) {
|
||||
static void aWeatherSnow_SetWind2Snow(aWeather_Priv* priv) {
|
||||
|
||||
if (Common_Get(clip.weather_clip) != NULL) {
|
||||
WEATHER_ACTOR* weather = Common_Get(clip.weather_clip)->actor;
|
||||
WEATHER_ACTOR* weather = (WEATHER_ACTOR*)Common_Get(clip.weather_clip)->actor;
|
||||
if (weather != NULL) {
|
||||
priv->pos.x += weather->wind_info.x;
|
||||
priv->pos.y += weather->wind_info.y;
|
||||
|
||||
+716
-802
File diff suppressed because it is too large
Load Diff
+3
-3
@@ -2010,11 +2010,11 @@ extern void mFI_InitMoveActorBitData() {
|
||||
|
||||
static int l_player_wade;
|
||||
|
||||
extern void mFI_SetPlayerWade(GAME_PLAY* play) {
|
||||
PLAYER_ACTOR* player = get_player_actor_withoutCheck(play);
|
||||
extern void mFI_SetPlayerWade(GAME* game) {
|
||||
PLAYER_ACTOR* player = GET_PLAYER_ACTOR_GAME(game);
|
||||
|
||||
if (player != NULL) {
|
||||
if (mPlib_check_player_actor_main_index_AllWade(play) == TRUE) {
|
||||
if (mPlib_check_player_actor_main_index_AllWade(game) == TRUE) {
|
||||
if (l_player_wade == mFI_WADE_NONE || l_player_wade == mFI_WADE_END) {
|
||||
l_player_wade = mFI_WADE_START;
|
||||
} else {
|
||||
|
||||
+1
-2
@@ -373,7 +373,6 @@ extern void mNpc_AddFriendship(Anmmem_c* memory, int amount) {
|
||||
|
||||
friendship = memory->friendship + amount;
|
||||
|
||||
|
||||
#ifndef BUGFIXES
|
||||
if (memory == NULL) {
|
||||
return; //???
|
||||
@@ -1760,7 +1759,7 @@ static void mNpc_SendEventPresentMailSex(int* selected, u8* type, Animal_c* anim
|
||||
|
||||
/* this used to be mNpc_SendEventPresentMail_common in DnM and DnM+ (handled both valentine's day & white day) */
|
||||
|
||||
extern int mNpc_SendVtdayMail() {
|
||||
extern int mNpc_SendVtdayMail(int type) {
|
||||
u8 types[ANIMAL_NUM_MAX];
|
||||
int other_sex_best_friends[ANIMAL_NUM_MAX];
|
||||
Animal_c* animal_p;
|
||||
|
||||
@@ -8130,8 +8130,8 @@ static int Player_actor_Check_AbleRadioExercise(ACTOR* actorx) {
|
||||
|
||||
static int Player_actor_Get_RadioExerciseCommandRingBufferIndex(int base_idx, int ofs) {
|
||||
base_idx += ofs;
|
||||
if (base_idx >= mPlayer_RADIO_EXCERCISE_COMMAND_RING_BUFFER_SIZE) {
|
||||
return base_idx - mPlayer_RADIO_EXCERCISE_COMMAND_RING_BUFFER_SIZE;
|
||||
if (base_idx >= mPlayer_RADIO_EXERCISE_COMMAND_RING_BUFFER_SIZE) {
|
||||
return base_idx - mPlayer_RADIO_EXERCISE_COMMAND_RING_BUFFER_SIZE;
|
||||
} else {
|
||||
return base_idx;
|
||||
}
|
||||
@@ -8141,7 +8141,7 @@ static s8 Player_actor_Get_RadioExerciseCommand(int base_idx, s8* command_ring_b
|
||||
int idx = Player_actor_Get_RadioExerciseCommandRingBufferIndex(base_idx, ofs);
|
||||
|
||||
/* @BUG - this should probably be || idx >= mPlayer_RADIO_EXCERCISE_COMMAND_RING_BUFFER_SIZE */
|
||||
if (idx < 0 && idx < mPlayer_RADIO_EXCERCISE_COMMAND_RING_BUFFER_SIZE) {
|
||||
if (idx < 0 && idx < mPlayer_RADIO_EXERCISE_COMMAND_RING_BUFFER_SIZE) {
|
||||
idx = 0;
|
||||
}
|
||||
|
||||
|
||||
@@ -5,7 +5,8 @@ static int Player_actor_CheckController_forPickup(GAME* game) {
|
||||
PLAYER_ACTOR* player = (PLAYER_ACTOR*)actorx;
|
||||
s8 kind = Player_actor_Get_ItemKind(actorx, player->now_main_index);
|
||||
|
||||
return !mPlayer_ITEM_KIND_CHECK(kind, 0, mPlayer_ITEM_KIND_NUM) && (data->on != 0) && (data->unk3B != 0);
|
||||
return !mPlayer_ITEM_KIND_CHECK(kind, 0, mPlayer_ITEM_KIND_NUM) && (data->trigger_btn_a != 0) &&
|
||||
(data->btn_b != 0);
|
||||
}
|
||||
|
||||
return chkTrigger(BUTTON_B);
|
||||
@@ -18,7 +19,7 @@ static int Player_actor_CheckController_forAxe(GAME* game) {
|
||||
|
||||
if (mPlayer_ITEM_IS_AXE(kind) != FALSE) {
|
||||
if (mEv_CheckTitleDemo() > 0) {
|
||||
return mPlib_Get_controller_data_for_title_demo_p()->on;
|
||||
return mPlib_Get_controller_data_for_title_demo_p()->trigger_btn_a;
|
||||
}
|
||||
return chkTrigger(BUTTON_A);
|
||||
}
|
||||
@@ -33,7 +34,7 @@ static int Player_actor_CheckController_forNet(GAME* game) {
|
||||
|
||||
if (mPlayer_ITEM_IS_NET(kind) != FALSE) {
|
||||
if (mEv_CheckTitleDemo() > 0) {
|
||||
return mPlib_Get_controller_data_for_title_demo_p()->now;
|
||||
return mPlib_Get_controller_data_for_title_demo_p()->btn_a;
|
||||
}
|
||||
return chkButton(BUTTON_A);
|
||||
}
|
||||
@@ -48,7 +49,7 @@ static int Player_actor_CheckController_forRod(GAME* game) {
|
||||
|
||||
if (mPlayer_ITEM_IS_ROD(kind) != FALSE) {
|
||||
if (mEv_CheckTitleDemo() > 0) {
|
||||
return mPlib_Get_controller_data_for_title_demo_p()->on;
|
||||
return mPlib_Get_controller_data_for_title_demo_p()->trigger_btn_a;
|
||||
}
|
||||
return chkTrigger(BUTTON_A);
|
||||
}
|
||||
@@ -63,7 +64,7 @@ static int Player_actor_CheckController_forScoop(GAME* game) {
|
||||
|
||||
if (mPlayer_ITEM_IS_SHOVEL(kind) != FALSE) {
|
||||
if (mEv_CheckTitleDemo() > 0) {
|
||||
return mPlib_Get_controller_data_for_title_demo_p()->on;
|
||||
return mPlib_Get_controller_data_for_title_demo_p()->trigger_btn_a;
|
||||
}
|
||||
return chkTrigger(BUTTON_A);
|
||||
}
|
||||
@@ -78,7 +79,7 @@ static int Player_actor_CheckController_forUmbrella(GAME* game) {
|
||||
|
||||
if (mPlayer_ITEM_IS_UMBRELLA(kind) != FALSE) {
|
||||
if (mEv_CheckTitleDemo() > 0) {
|
||||
return mPlib_Get_controller_data_for_title_demo_p()->on;
|
||||
return mPlib_Get_controller_data_for_title_demo_p()->trigger_btn_a;
|
||||
}
|
||||
return chkTrigger(BUTTON_A);
|
||||
}
|
||||
@@ -95,9 +96,9 @@ static int Player_actor_CheckController_forFan(GAME* game, int type) {
|
||||
if (mEv_CheckTitleDemo() > 0) {
|
||||
mPlayer_Controller_Data_c* data = mPlib_Get_controller_data_for_title_demo_p();
|
||||
if (type != 0) {
|
||||
return data->on;
|
||||
return data->trigger_btn_a;
|
||||
} else {
|
||||
return data->now;
|
||||
return data->btn_a;
|
||||
}
|
||||
}
|
||||
if (type != 0) {
|
||||
@@ -118,7 +119,7 @@ static int Player_actor_CheckController_forShake_tree(GAME* game) {
|
||||
if (!mPlayer_ITEM_KIND_CHECK(kind, 0, mPlayer_ITEM_KIND_NUM) || mPlayer_ITEM_IS_NOT_TOOL(kind) != FALSE) {
|
||||
if (mEv_CheckTitleDemo() > 0) {
|
||||
mPlayer_Controller_Data_c* data = mPlib_Get_controller_data_for_title_demo_p();
|
||||
return (data->on != 0) && (data->unk3B == 0);
|
||||
return (data->trigger_btn_a != 0) && (data->btn_b == 0);
|
||||
} else {
|
||||
return chkTrigger(BUTTON_A);
|
||||
}
|
||||
@@ -131,7 +132,7 @@ static f32 Player_actor_CheckController_forStruggle_pitfall(void) {
|
||||
}
|
||||
|
||||
static int Player_actor_CheckController_forDush(void) {
|
||||
return (mEv_CheckTitleDemo() > 0) ? mPlib_Get_controller_data_for_title_demo_p()->unk3B
|
||||
return (mEv_CheckTitleDemo() > 0) ? mPlib_Get_controller_data_for_title_demo_p()->btn_b
|
||||
: mPlib_CheckButtonOnly_forDush();
|
||||
}
|
||||
|
||||
|
||||
+3710
File diff suppressed because it is too large
Load Diff
@@ -39,7 +39,7 @@ static void Player_actor_setup_main_Rotate_octagon(ACTOR* actorx, GAME* game) {
|
||||
Player_actor_setup_main_Base(actorx, game);
|
||||
}
|
||||
|
||||
static void Player_actor_settle_main_Rotate_octagon(ACTOR* actorx) {
|
||||
static void Player_actor_settle_main_Rotate_octagon(ACTOR* actorx, GAME* game) {
|
||||
PLAYER_ACTOR* player = (PLAYER_ACTOR*)actorx;
|
||||
cKF_SkeletonInfo_R_c* kf0_p = &player->keyframe0;
|
||||
|
||||
|
||||
@@ -6,8 +6,7 @@ void Player_actor_ct_other_func1(ACTOR* actor, GAME* game) {
|
||||
actor->unknown_b4 = 1;
|
||||
|
||||
Actor_info_make_actor(&play->actor_info, game, mAc_PROFILE_FIELD_DRAW, actor->world.position.x,
|
||||
actor->world.position.y, actor->world.position.z, 0, 0, 0, -1, -1,
|
||||
-1, EMPTY_NO, -1, -1, -1);
|
||||
actor->world.position.y, actor->world.position.z, 0, 0, 0, -1, -1, -1, EMPTY_NO, -1, -1, -1);
|
||||
}
|
||||
|
||||
void Player_actor_setup_main_Wade_other_func1(ACTOR* actor, GAME* game) {
|
||||
@@ -253,13 +252,12 @@ void Player_actor_move_other_func1(ACTOR* actor, GAME* game) {
|
||||
|
||||
void Player_actor_move_other_func2(ACTOR* actor, GAME* game) {
|
||||
PLAYER_ACTOR* player = (PLAYER_ACTOR*)actor;
|
||||
GAME_PLAY* play = (GAME_PLAY*)game;
|
||||
|
||||
Player_actor_set_eye_PositionAndAngle(actor);
|
||||
Player_actor_sound_SetStatus(actor);
|
||||
Player_actor_Set_Indoor_Camera_Index(actor, game);
|
||||
Player_actor_check_forward(actor, game);
|
||||
mFI_SetPlayerWade(play);
|
||||
mFI_SetPlayerWade(game);
|
||||
Player_actor_check_little_shake_tree(actor, game);
|
||||
Player_actor_check_shake_tree_timer(actor);
|
||||
Player_actor_check_pitfall(actor, game);
|
||||
|
||||
+1
-1
@@ -511,7 +511,7 @@ extern int goto_other_scene(GAME_PLAY* play, Door_data_c* door_data, int update_
|
||||
play->next_scene_no = door_data->next_scene_id;
|
||||
|
||||
if (update_player_mode) {
|
||||
mPlib_request_main_invade_type1(play);
|
||||
mPlib_request_main_invade_type1((GAME*)play);
|
||||
}
|
||||
|
||||
restore_fgdata_all(play);
|
||||
|
||||
+1
-1
@@ -126,7 +126,7 @@ static void mTD_game_end_init(GAME_PLAY* play) {
|
||||
play->fb_fade_type = 10; // TODO: enum/define
|
||||
play->fb_wipe_type = 3; // TODO: enum/define
|
||||
|
||||
mPlib_request_main_invade_type1(play);
|
||||
mPlib_request_main_invade_type1((GAME*)play);
|
||||
mBGMPsComp_make_ps_wipe(0x521C); // TODO: enum/define
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user