DCDecomp
A decompilation of Dark Cloud for the PlayStation 2
Loading...
Searching...
No Matches
actionseq.hpp
1#pragma once
2
3#include "common.h"
4
5// clang-format off
9enum ACT_SEQ_OPERATION {
10 ACT_SEQ_UNUSED = 0,
11 ACT_SEQ_SET_POSITION = 1,
12 ACT_SEQ_MOVE = 2,
13 ACT_SEQ_ROTATE_REFERENCE = 4,
14 ACT_SEQ_ROTATE_MOVEMENT = 5,
15 ACT_SEQ_ROTATE_ANGLE = 6,
16 ACT_SEQ_CLEAR_ROTATION = 7,
17 ACT_SEQ_WAIT_ROTATION = 8,
18 ACT_SEQ_SET_ROTATION = 10,
19 ACT_SEQ_DELAY_ROTATION = 11,
20 ACT_SEQ_MOTION = 12,
21 ACT_SEQ_TRIGGER_MOTION = 14,
22 ACT_SEQ_ANIMATION = 15,
23 ACT_SEQ_TRIGGER_ANIMATION = 18
24};
25
26// clang-format on
27
31struct ACT_SEQ {
32 ACT_SEQ_OPERATION operation;
34 int unk_08;
37 union {
38 float vector[4];
40 struct {
41 int id;
42 int mode;
44 union {
45 float speed;
49 int flags;
52};
53
54STATIC_ASSERT(sizeof(ACT_SEQ) == 0x20);
55class CCharacter;
56
61public:
64 u8 unk_08[8];
65 float position[4];
66 float start_position[4];
67 float queued_position[4];
77 u8 unk_64[12];
78 float rotation_target[4];
81 u8 unk_88[8];
82 float rotation[4];
83 float start_rotation[4];
100 void Initialize(ACT_SEQ *records, int count);
101
109 CActionSeq();
110
118 void ClearSeq();
119
128
136 void SyncChara(CCharacter *target);
137
146
155
164
172 void MoveSeq(float *destination, int frames);
173
181 void MoveSeq(float *destination, float speed);
182
190 void MoveSeq(int frames);
191
199 void SetPos(float *destination);
200
208 void RotRefSeq(float *reference, float speed);
209
217 void RotAngleSeq(float angle, float speed);
218
226 void RotMoveSeq(float speed);
227
235 void ClearRotSeq();
236
244 void WaitRotSeq();
245
253 void SetRot(float *angles);
254
262 void SetDelayRot(int delay);
263
271 void MotionTrg(int delay);
272
280 void AnimeTrg(int delay);
281
289 void MotionSeq(int motion, int mode, float speed, int flags);
290
298 void AnimeSeq(int animation, int enabled, int frames, int disable_after);
299
307 int CheckEnd();
308
316 void Play();
317};
318
319STATIC_ASSERT(sizeof(CActionSeq) == 0xD0);
int rotation_delay
Definition actionseq.hpp:72
ACT_SEQ * GetNextSeq()
Definition actionseq.cpp:41
int anime_trigger
Definition actionseq.hpp:75
float rotation[4]
Definition actionseq.hpp:82
int rotation_complete
Definition actionseq.hpp:71
void SetDelayRot(int delay)
void ClearSeq()
Definition actionseq.cpp:19
void MotionSeq(int motion, int mode, float speed, int flags)
ACT_SEQ * anime_tail
Definition actionseq.hpp:88
float position[4]
Definition actionseq.hpp:65
float start_position[4]
Definition actionseq.hpp:66
void Initialize(ACT_SEQ *records, int count)
Definition actionseq.cpp:9
ACT_SEQ * NextAnimeSeq()
ACT_SEQ * pool
Definition actionseq.hpp:90
void SyncChara(CCharacter *target)
Definition actionseq.cpp:55
void AnimeTrg(int delay)
int motion_trigger
Definition actionseq.hpp:73
float rotation_target[4]
Definition actionseq.hpp:78
int rotation_mode
Definition actionseq.hpp:70
void RotAngleSeq(float angle, float speed)
ACT_SEQ * motion_tail
Definition actionseq.hpp:86
int CheckEnd()
void SetPos(float *destination)
ACT_SEQ * NextMoveSeq()
Definition actionseq.cpp:68
ACT_SEQ * NextMotionSeq()
Definition actionseq.cpp:89
ACT_SEQ * rotation_head
Definition actionseq.hpp:79
int anime_frame
Definition actionseq.hpp:69
float start_rotation[4]
Definition actionseq.hpp:83
int motion_delay
Definition actionseq.hpp:74
ACT_SEQ * move_tail
Definition actionseq.hpp:63
void SetRot(float *angles)
CCharacter * character
Definition actionseq.hpp:91
ACT_SEQ * rotation_tail
Definition actionseq.hpp:80
ACT_SEQ * move_head
Definition actionseq.hpp:62
void AnimeSeq(int animation, int enabled, int frames, int disable_after)
int rotation_frame
Definition actionseq.hpp:84
ACT_SEQ * motion_head
Definition actionseq.hpp:85
void MoveSeq(float *destination, int frames)
void RotMoveSeq(float speed)
void MotionTrg(int delay)
float queued_position[4]
Definition actionseq.hpp:67
void ClearRotSeq()
ACT_SEQ * anime_head
Definition actionseq.hpp:87
void RotRefSeq(float *reference, float speed)
void Play()
void WaitRotSeq()
int anime_delay
Definition actionseq.hpp:76
int duration
Definition actionseq.hpp:33
float speed
Definition actionseq.hpp:45
ACT_SEQ_OPERATION operation
Definition actionseq.hpp:32
struct ACT_SEQ::@2::@3 animation
int flags
Definition actionseq.hpp:49
union ACT_SEQ::@2::@3::@4 playback
float vector[4]
Definition actionseq.hpp:38
union ACT_SEQ::@2 arguments
int disable_after
Definition actionseq.hpp:46
ACT_SEQ * next
Definition actionseq.hpp:35