Twilight Princess
Decompilation of The Legend of Zelda: Twilight Princess
Loading...
Searching...
No Matches
d_a_npc_ashB.h
Go to the documentation of this file.
1#ifndef D_A_NPC_ASHB_H
2#define D_A_NPC_ASHB_H
3
4#include "d/actor/d_a_npc.h"
5
14class daNpcAshB_c : public daNpcF_c {
15public:
18
19 enum Animation {
20 /* 0x00 */ ANM_NONE,
21 /* 0x01 */ ANM_F_TALK_A,
22 /* 0x02 */ ANM_F_TALK_B,
23 /* 0x03 */ ANM_F_SILENT,
24 /* 0x04 */ ANM_F_COOL,
25 /* 0x05 */ ANM_F_ASK,
26 /* 0x06 */ ANM_F_EXPLAIN_A,
27 /* 0x07 */ ANM_F_EXPLAIN_B,
28 /* 0x08 */ ANM_WAIT_A,
29 /* 0x09 */ ANM_WAIT_B,
30 /* 0x0A */ ANM_WAIT_C,
31 /* 0x0B */ ANM_STEP,
32 /* 0x0C */ ANM_COOL,
33 /* 0x0D */ ANM_ASK,
34 /* 0x0E */ ANM_EXPLAIN_A,
35 /* 0x0F */ ANM_EXPLAIN_B,
36 /* 0x10 */ ANM_BOWWAIT,
37 /* 0x11 */ ANM_BOWRUN,
38 };
39
41 /* 0x0 */ EXPR_TALK_A,
42 /* 0x1 */ EXPR_TALK_B,
43 /* 0x2 */ EXPR_SILENT,
44 /* 0x3 */ EXPR_COOL,
45 /* 0x4 */ EXPR_ASK,
46 /* 0x5 */ EXPR_EXPLAIN_A,
47 /* 0x6 */ EXPR_EXPLAIN_B,
48 /* 0x7 */ EXPR_NONE,
49 };
50
51 enum Motion {
52 /* 0x0 */ MOT_WAIT_A,
53 /* 0x1 */ MOT_WAIT_B,
54 /* 0x2 */ MOT_WAIT_C,
55 /* 0x3 */ MOT_COOL,
56 /* 0x4 */ MOT_ASK,
57 /* 0x5 */ MOT_EXPLAIN_A,
58 /* 0x6 */ MOT_EXPLAIN_B,
59 /* 0x7 */ MOT_BOWWAIT,
60 /* 0x8 */ MOT_BOWRUN,
61 /* 0x9 */ MOT_STEP,
62 };
63
64 enum LookMode {
65 /* 0 */ LOOK_NONE,
66 /* 1 */ LOOK_RESET,
67 /* 2 */ LOOK_PLAYER,
69 /* 4 */ LOOK_ACTOR,
70 /* 5 */ LOOK_ATTN,
71 };
72
73public:
74 /* 8095DE4C */ daNpcAshB_c();
75 /* 8095E060 */ ~daNpcAshB_c();
76 /* 8095E224 */ cPhs__Step Create();
77 /* 8095E4A0 */ BOOL CreateHeap();
78 /* 8095E914 */ int Delete();
79 /* 8095E948 */ int Execute();
80 /* 8095E96C */ int Draw();
81 /* 8095E9C8 */ bool ctrlJoint(J3DJoint*, J3DModel*);
82 /* 8095EB94 */ static BOOL createHeapCallBack(fopAc_ac_c*);
83 /* 8095EBB4 */ static BOOL ctrlJointCallBack(J3DJoint*, int);
84 /* 8095EC00 */ bool setExpressionAnm(int, bool);
85 /* 8095EE00 */ bool setExpressionBtp(int);
86 /* 8095EEE0 */ bool setMotionAnm(int, f32);
87 /* 8095F0A4 */ void reset();
88 /* 8095F21C */ inline bool setAction(ActionFn i_actionFn);
89 /* 8095F2C4 */ bool wait(void*);
90 /* 8095FC70 */ void setMotion(int, f32, int);
91 /* 8095FD34 */ void setExpression(int, f32);
92 /* 8095FD9C */ bool talk(void*);
93 /* 809602E0 */ bool demo(void*);
94 /* 809604C8 */ BOOL EvCut_Appear(int);
95 /* 80960A60 */ void setParam();
96 /* 80960AE8 */ BOOL main();
97 /* 80960D64 */ void playMotion();
98 /* 80961188 */ BOOL ctrlBtk();
99 /* 80961264 */ void setAttnPos();
100 /* 80961574 */ void lookat();
101 /* 80961770 */ void drawOtherMdls();
102 /* 809617F8 */ BOOL drawDbgInfo();
103
104 static EventFn mEvtSeqList[2];
105
106 s16 getMessageNo() { return (fopAcM_GetParam(this) >> 8) & 0xFFFF;}
107 inline void setExpressionTalkAfter() { setExpression(6, -1.0f); }
108 inline void setLookMode(int i_lookMode);
109 inline BOOL chkFindPlayer();
110 inline bool step(s16, int, f32);
111 inline void playExpression();
112
113private:
116 /* 0xBDC */ J3DModel* mpModel;
120 /* 0xC88 */ dCcD_Cyl mCyl;
121 /* 0xDC4 */ ActionFn mpActionFn;
123 /* 0xDD8 */ s32 mItemPartnerId;
124 /* 0xDDC */ u32 field_0xddc;
125 /* 0xDE0 */ u32 field_0xde0;
126 /* 0xDE4 */ s16 mFlowID;
127 /* 0xDE6 */ s16 mLookMode;
128 /* 0xDE8 */ u16 mMode;
129 /* 0xDEA */ s16 field_0xdea;
130 /* 0xDEC */ u8 field_0xdec;
131 /* 0xDED */ u8 field_0xded;
132 /* 0xDEE */ u8 field_0xdee;
133
134};
135
136STATIC_ASSERT(sizeof(daNpcAshB_c) == 0xdf0);
137
139public:
140 /* 80962078 */ virtual ~daNpcAshB_Param_c();
141
142 struct param {
143 /* 0x00 */ f32 mAttnOffsetY;
144 /* 0x04 */ f32 mGravity;
145 /* 0x08 */ f32 mScale;
146 /* 0x0C */ f32 mShadowDepth;
147 /* 0x10 */ f32 mCcWeight;
148 /* 0x14 */ f32 mCylH;
149 /* 0x18 */ f32 mWallH;
150 /* 0x1C */ f32 mWallR;
151 /* 0x20 */ f32 mBodyUpAngle;
152 /* 0x24 */ f32 mBodyDownAngle;
153 /* 0x28 */ f32 mBodyLeftAngle;
155 /* 0x30 */ f32 mHeadUpAngle;
156 /* 0x34 */ f32 mHeadDownAngle;
157 /* 0x38 */ f32 mHeadLeftAngle;
159 /* 0x40 */ f32 mNeckAngleScl;
160 /* 0x44 */ f32 mMorfFrames;
161 /* 0x48 */ s16 mSpeakDistIdx;
162 /* 0x4A */ s16 mSpeakAngleIdx;
163 /* 0x4C */ s16 mTalkDistIdx;
164 /* 0x4E */ s16 mTalkAngleIdx;
165 /* 0x50 */ f32 mAttnFovY;
166 /* 0x54 */ f32 mAttnRadius;
167 /* 0x58 */ f32 mAttnUpperY;
168 /* 0x5C */ f32 mAttnLowerY;
169 /* 0x60 */ s16 field_0x60;
170 /* 0x62 */ s16 mDamageTimer;
172 /* 0x66 */ s16 mTestMotion;
173 /* 0x68 */ s16 mTestLookMode;
174 /* 0x6A */ bool mTest;
175 /* 0x6C */ f32 field_0x6c;
176 };
177
178 static param const m;
179};
180
181#endif /* D_A_NPC_ASHB_H */
T cLib_calcTimer(T *value)
Definition c_lib.h:74
cPhs__Step
Definition c_phase.h:8
Definition d_a_npc_ashB.h:138
static param const m
Definition d_a_npc_ashB.h:318
virtual ~daNpcAshB_Param_c()
Ashei (Yeti Garb)
Definition d_a_npc_ashB.h:14
u8 field_0xdee
Definition d_a_npc_ashB.h:132
BOOL main()
Definition d_a_npc_ashB.cpp:1203
u32 field_0xddc
Definition d_a_npc_ashB.h:124
void setAttnPos()
Definition d_a_npc_ashB.cpp:1295
u16 mMode
Definition d_a_npc_ashB.h:128
void playMotion()
Definition d_a_npc_ashB.cpp:1219
dCcD_Cyl mCyl
Definition d_a_npc_ashB.h:120
bool setAction(ActionFn i_actionFn)
Definition d_a_npc_ashB.cpp:773
static EventFn mEvtSeqList[2]
Definition d_a_npc_ashB.h:295
void playExpression()
Definition d_a_npc_ashB.cpp:543
void reset()
Definition d_a_npc_ashB.cpp:736
BOOL chkFindPlayer()
Definition d_a_npc_ashB.cpp:523
u8 field_0xdec
Definition d_a_npc_ashB.h:130
static BOOL createHeapCallBack(fopAc_ac_c *)
Definition d_a_npc_ashB.cpp:500
bool ctrlJoint(J3DJoint *, J3DModel *)
Definition d_a_npc_ashB.cpp:464
daNpcF_Lookat_c mLookat
Definition d_a_npc_ashB.h:117
bool wait(void *)
Definition d_a_npc_ashB.cpp:788
int Execute()
Definition d_a_npc_ashB.cpp:450
BOOL CreateHeap()
Definition d_a_npc_ashB.cpp:407
int Delete()
Definition d_a_npc_ashB.cpp:444
Z2Creature mCreatureSound
Definition d_a_npc_ashB.h:114
fopAc_ac_c * mpTalkPartner
Definition d_a_npc_ashB.h:119
static BOOL ctrlJointCallBack(J3DJoint *, int)
Definition d_a_npc_ashB.cpp:506
BOOL EvCut_Appear(int)
Definition d_a_npc_ashB.cpp:1075
s16 field_0xdea
Definition d_a_npc_ashB.h:129
Expression
Definition d_a_npc_ashB.h:40
@ EXPR_COOL
Definition d_a_npc_ashB.h:44
@ EXPR_ASK
Definition d_a_npc_ashB.h:45
@ EXPR_EXPLAIN_A
Definition d_a_npc_ashB.h:46
@ EXPR_NONE
Definition d_a_npc_ashB.h:48
@ EXPR_TALK_B
Definition d_a_npc_ashB.h:42
@ EXPR_TALK_A
Definition d_a_npc_ashB.h:41
@ EXPR_SILENT
Definition d_a_npc_ashB.h:43
@ EXPR_EXPLAIN_B
Definition d_a_npc_ashB.h:47
J3DModel * mpModel
Definition d_a_npc_ashB.h:116
daNpcAshB_c()
Definition d_a_npc_ashB.cpp:301
void setExpressionTalkAfter()
Definition d_a_npc_ashB.h:107
void setParam()
Definition d_a_npc_ashB.cpp:1195
void drawOtherMdls()
Definition d_a_npc_ashB.cpp:1399
ActionFn mpActionFn
Definition d_a_npc_ashB.h:121
bool talk(void *)
Definition d_a_npc_ashB.cpp:961
~daNpcAshB_c()
Definition d_a_npc_ashB.cpp:306
bool setExpressionAnm(int, bool)
Definition d_a_npc_ashB.cpp:609
Motion
Definition d_a_npc_ashB.h:51
@ MOT_BOWWAIT
Definition d_a_npc_ashB.h:59
@ MOT_EXPLAIN_B
Definition d_a_npc_ashB.h:58
@ MOT_STEP
Definition d_a_npc_ashB.h:61
@ MOT_ASK
Definition d_a_npc_ashB.h:56
@ MOT_EXPLAIN_A
Definition d_a_npc_ashB.h:57
@ MOT_WAIT_B
Definition d_a_npc_ashB.h:53
@ MOT_WAIT_A
Definition d_a_npc_ashB.h:52
@ MOT_COOL
Definition d_a_npc_ashB.h:55
@ MOT_BOWRUN
Definition d_a_npc_ashB.h:60
@ MOT_WAIT_C
Definition d_a_npc_ashB.h:54
s16 getMessageNo()
Definition d_a_npc_ashB.h:106
cPhs__Step Create()
Definition d_a_npc_ashB.cpp:355
Animation
Definition d_a_npc_ashB.h:19
@ ANM_F_ASK
Definition d_a_npc_ashB.h:25
@ ANM_EXPLAIN_B
Definition d_a_npc_ashB.h:35
@ ANM_COOL
Definition d_a_npc_ashB.h:32
@ ANM_WAIT_B
Definition d_a_npc_ashB.h:29
@ ANM_F_EXPLAIN_B
Definition d_a_npc_ashB.h:27
@ ANM_EXPLAIN_A
Definition d_a_npc_ashB.h:34
@ ANM_BOWRUN
Definition d_a_npc_ashB.h:37
@ ANM_WAIT_C
Definition d_a_npc_ashB.h:30
@ ANM_F_COOL
Definition d_a_npc_ashB.h:24
@ ANM_F_EXPLAIN_A
Definition d_a_npc_ashB.h:26
@ ANM_F_SILENT
Definition d_a_npc_ashB.h:23
@ ANM_STEP
Definition d_a_npc_ashB.h:31
@ ANM_WAIT_A
Definition d_a_npc_ashB.h:28
@ ANM_NONE
Definition d_a_npc_ashB.h:20
@ ANM_F_TALK_A
Definition d_a_npc_ashB.h:21
@ ANM_BOWWAIT
Definition d_a_npc_ashB.h:36
@ ANM_ASK
Definition d_a_npc_ashB.h:33
@ ANM_F_TALK_B
Definition d_a_npc_ashB.h:22
u32 field_0xde0
Definition d_a_npc_ashB.h:125
bool setMotionAnm(int, f32)
Definition d_a_npc_ashB.cpp:691
BOOL(daNpcAshB_c::* EventFn)(int)
Definition d_a_npc_ashB.h:17
void setLookMode(int i_lookMode)
Definition d_a_npc_ashB.cpp:517
bool step(s16, int, f32)
Definition d_a_npc_ashB.cpp:573
daNpcF_ActorMngr_c mActorMngr[1]
Definition d_a_npc_ashB.h:118
void lookat()
Definition d_a_npc_ashB.cpp:1341
u8 field_0xded
Definition d_a_npc_ashB.h:131
daNpcF_MatAnm_c * mpMatAnm
Definition d_a_npc_ashB.h:115
s16 mFlowID
Definition d_a_npc_ashB.h:126
int Draw()
Definition d_a_npc_ashB.cpp:456
s32 mItemPartnerId
Definition d_a_npc_ashB.h:123
LookMode
Definition d_a_npc_ashB.h:64
@ LOOK_RESET
Definition d_a_npc_ashB.h:66
@ LOOK_NONE
Definition d_a_npc_ashB.h:65
@ LOOK_ATTN
Definition d_a_npc_ashB.h:70
@ LOOK_ACTOR
Definition d_a_npc_ashB.h:69
@ LOOK_PLAYER
Definition d_a_npc_ashB.h:67
@ LOOK_PLAYER_TALK
Definition d_a_npc_ashB.h:68
bool demo(void *)
Definition d_a_npc_ashB.cpp:1034
BOOL ctrlBtk()
Definition d_a_npc_ashB.cpp:1278
s16 mLookMode
Definition d_a_npc_ashB.h:127
void setExpression(int, f32)
Definition d_a_npc_ashB.cpp:940
void setMotion(int, f32, int)
Definition d_a_npc_ashB.cpp:906
bool(daNpcAshB_c::* ActionFn)(void *)
Definition d_a_npc_ashB.h:16
request_of_phase_process_class mPhase[1]
Definition d_a_npc_ashB.h:122
bool setExpressionBtp(int)
Definition d_a_npc_ashB.cpp:671
BOOL drawDbgInfo()
Definition d_a_npc_ashB.cpp:1411
Definition d_a_npc.h:756
Definition d_a_npc.h:1099
Definition d_a_npc.h:1017
Definition d_a_npc.h:772
STATIC_ASSERT(sizeof(daNpcAshB_c)==0xdf0)
u32 fopAcM_GetParam(const void *pActor)
Definition f_op_actor_mng.h:224
Definition d_a_hozelda.cpp:239
Definition d_a_ep.cpp:155
Definition d_a_hozelda.cpp:163
Definition d_a_npc_fguard.cpp:86
Definition d_a_npc_ashB.h:142
f32 mAttnFovY
Definition d_a_npc_ashB.h:165
s16 mTalkDistIdx
Definition d_a_npc_ashB.h:163
f32 mWallH
Definition d_a_npc_ashB.h:149
s16 mTestLookMode
Definition d_a_npc_ashB.h:173
f32 mMorfFrames
Definition d_a_npc_ashB.h:160
f32 mAttnRadius
Definition d_a_npc_ashB.h:166
s16 mTestExpression
Definition d_a_npc_ashB.h:171
f32 mHeadLeftAngle
Definition d_a_npc_ashB.h:157
s16 field_0x60
Definition d_a_npc_ashB.h:169
s16 mSpeakDistIdx
Definition d_a_npc_ashB.h:161
f32 field_0x6c
Definition d_a_npc_ashB.h:175
f32 mBodyDownAngle
Definition d_a_npc_ashB.h:152
f32 mAttnUpperY
Definition d_a_npc_ashB.h:167
f32 mHeadDownAngle
Definition d_a_npc_ashB.h:156
s16 mSpeakAngleIdx
Definition d_a_npc_ashB.h:162
f32 mHeadRightAngle
Definition d_a_npc_ashB.h:158
f32 mNeckAngleScl
Definition d_a_npc_ashB.h:159
f32 mShadowDepth
Definition d_a_npc_ashB.h:146
f32 mBodyUpAngle
Definition d_a_npc_ashB.h:151
s16 mTestMotion
Definition d_a_npc_ashB.h:172
f32 mCcWeight
Definition d_a_npc_ashB.h:147
f32 mScale
Definition d_a_npc_ashB.h:145
f32 mBodyRightAngle
Definition d_a_npc_ashB.h:154
f32 mBodyLeftAngle
Definition d_a_npc_ashB.h:153
f32 mHeadUpAngle
Definition d_a_npc_ashB.h:155
bool mTest
Definition d_a_npc_ashB.h:174
f32 mGravity
Definition d_a_npc_ashB.h:144
f32 mWallR
Definition d_a_npc_ashB.h:150
f32 mAttnOffsetY
Definition d_a_npc_ashB.h:143
f32 mAttnLowerY
Definition d_a_npc_ashB.h:168
s16 mDamageTimer
Definition d_a_npc_ashB.h:170
f32 mCylH
Definition d_a_npc_ashB.h:148
s16 mTalkAngleIdx
Definition d_a_npc_ashB.h:164
Definition d_a_ep.cpp:19
Definition d_a_hozelda.cpp:14
int BOOL
Definition types.h:27
unsigned long u32
Definition types.h:10
float f32
Definition types.h:22
signed short s16
Definition types.h:5
unsigned short u16
Definition types.h:9
signed long s32
Definition types.h:6
unsigned char u8
Definition types.h:8