Isle
Loading...
Searching...
No Matches
legoextraactor.cpp
Go to the documentation of this file.
1#include "legoextraactor.h"
2
3#include "anim/legoanim.h"
6#include "legosoundmanager.h"
7#include "legoworld.h"
8#include "misc.h"
9#include "mxmisc.h"
10#include "mxtimer.h"
11
13
14// GLOBAL: LEGO1 0x100f31d0
16
17// GLOBAL: LEGO1 0x100f31d4
19
20// GLOBAL: LEGO1 0x100f31d8
22
23// GLOBAL: LEGO1 0x100f31dc
25
26// GLOBAL: LEGO1 0x10104c18
28
29// FUNCTION: LEGO1 0x1002a500
30// FUNCTION: BETA10 0x10080908
32{
33 m_unk0x70 = 0.0f;
34 m_scheduledTime = 0;
35 m_unk0x0c = 0;
36 m_unk0x0e = 0;
37 m_whichAnim = 0;
38 m_assAnim = NULL;
39 m_disAnim = NULL;
40 m_unk0x15 = 0;
41}
42
43// FUNCTION: LEGO1 0x1002a6b0
45{
46 delete m_assAnim;
47 delete m_disAnim;
48}
49
50// FUNCTION: LEGO1 0x1002a720
51MxU32 LegoExtraActor::VTable0x90(float p_time, Matrix4& p_transform)
52{
53 switch (m_actorState & c_maxState) {
54 case c_initial:
55 case c_one:
56 return TRUE;
57 case c_two:
58 m_scheduledTime = p_time + 2000.0f;
60 m_actorTime += (p_time - m_lastTime) * m_worldSpeed;
61 m_lastTime = p_time;
62 return FALSE;
63 case c_three: {
64 Vector3 positionRef(p_transform[3]);
65 p_transform = m_roi->GetLocal2World();
66
67 if (p_time < m_scheduledTime) {
68 Mx3DPointFloat position;
69 position = positionRef;
70 positionRef.Clear();
71
72 switch (m_axis) {
73 case e_posz: {
74 p_transform.RotateZ(0.7f);
75 break;
76 }
77 case e_negz: {
78 p_transform.RotateZ(-0.7f);
79 break;
80 }
81 case e_posx: {
82 p_transform.RotateX(0.7f);
83 break;
84 }
85 case e_negx: {
86 p_transform.RotateX(-0.7f);
87 break;
88 }
89 }
90
91 positionRef = position;
92 m_actorTime += (p_time - m_lastTime) * m_worldSpeed;
93 m_lastTime = p_time;
94 VTable0x74(p_transform);
95 return FALSE;
96 }
97 else {
99 m_scheduledTime = 0.0f;
100 positionRef -= g_unk0x10104c18;
101 m_roi->FUN_100a58f0(p_transform);
102 return TRUE;
103 }
104 }
105
106 default:
107 return FALSE;
108 }
109}
110
111// FUNCTION: LEGO1 0x1002aa90
113{
114 switch (m_unk0x0c) {
115 case 1:
116 p_und1 = TRUE;
117 p_und2 = 1;
118 break;
119 case 2:
120 p_und1 = FALSE;
121 p_und2 = 1;
122 break;
123 default:
124 p_und1 = TRUE;
125 p_und2 = rand() % p_und2 + 1;
126 break;
127 }
128}
129
130// FUNCTION: LEGO1 0x1002aae0
132{
133 LegoPathBoundary* oldEdge = m_boundary;
134 Vector3 rightRef(m_unk0xec[0]);
135 Vector3 upRef(m_unk0xec[1]);
136 Vector3 dirRef(m_unk0xec[2]);
137 Vector3 positionRef(m_unk0xec[3]);
138
139 dirRef *= -1.0f;
140 rightRef.EqualsCross(upRef, dirRef);
141
142 if (m_boundary == m_destEdge->m_faceA) {
144 }
145 else {
147 }
148
149 if (!m_boundary) {
150 m_boundary = oldEdge;
151 }
152
154 return SUCCESS;
155}
156
158{
159 LegoWorld* w = CurrentWorld();
160
161 if (g_unk0x100f31d0 != w) {
162 g_unk0x100f31d0 = w;
163 m_assAnimP = (LegoLocomotionAnimPresenter*) w->Find("LegoAnimPresenter", "BNsAss01");
164 m_disAnimP = (LegoLocomotionAnimPresenter*) w->Find("LegoAnimPresenter", "BNsDis01");
165 }
166
167 if (!m_assAnim) {
168 MxS32 index = 0;
169 m_assAnimP->FUN_1006d680(this, -20.0f);
170
171 for (MxS32 i = 0; i < m_animMaps.size(); i++) {
172 if (m_animMaps[i]->GetUnknown0x00() == -20.0f) {
173 m_assAnim = new LegoAnimActorStruct(*m_animMaps[i]);
174 break;
175 }
176 }
177 }
178
179 if (!m_disAnim) {
180 MxS32 index = 0;
181 m_disAnimP->FUN_1006d680(this, -21.0f);
182
183 for (MxS32 i = 0; i < m_animMaps.size(); i++) {
184 if (m_animMaps[i]->GetUnknown0x00() == -21.0f) {
185 m_disAnim = new LegoAnimActorStruct(*m_animMaps[i]);
186 break;
187 }
188 }
189 }
190}
191
192// FUNCTION: LEGO1 0x1002aba0
193// FUNCTION: BETA10 0x1008114a
195{
196 if (p_actor->GetActorState() != c_initial || GetActorState() != c_initial) {
197 return FAILURE;
198 }
199
200 if (p_bool) {
201 if (m_unk0x15 != 0) {
202 return FAILURE;
203 }
204
205 m_unk0x15 = 100;
206 FUN_1002aae0();
207 }
208 else {
209 MxU32 b = FALSE;
210
211 if (++g_unk0x100f31dc % 2 == 0) {
212 MxMatrix matrix(p_actor->GetROI()->GetLocal2World());
213 MxMatrix matrix2(m_roi->GetLocal2World());
214
215 m_unk0x18 = matrix2;
216 Vector3 positionRef(matrix2[3]);
217 Mx3DPointFloat dir(matrix[2]);
218
219 dir *= 2.0f;
220 positionRef += dir;
221
222 for (MxS32 i = 0; i < m_boundary->GetNumEdges(); i++) {
224
225 if (positionRef.Dot(*normal, positionRef) + normal->index_operator(3) < -0.001) {
226 b = TRUE;
227 break;
228 }
229 }
230
231 if (!b) {
232 m_roi->FUN_100a58f0(matrix2);
233 m_roi->VTable0x14();
234 FUN_1002ad8a();
235 assert(m_roi);
236 assert(SoundManager()->GetCacheSoundManager());
238 m_scheduledTime = Timer()->GetTime() + m_disAnim->GetDuration();
239 m_prevWorldSpeed = GetWorldSpeed();
240 VTable0xc4();
241 SetWorldSpeed(0);
242 m_whichAnim = 1;
244 }
245 }
246
247 if (b) {
248 LegoROI* roi = GetROI();
249 assert(roi);
251 VTable0xc4();
253 Mx3DPointFloat dir = p_actor->GetWorldDirection();
254 MxMatrix matrix3 = MxMatrix(roi->GetLocal2World());
255 Vector3 positionRef(matrix3[3]);
256 positionRef += g_unk0x10104c18;
257 roi->FUN_100a58f0(matrix3);
258
259 float dotX = dir.Dot(dir, Mx3DPointFloat(1.0f, 0, 0));
260 float dotZ = dir.Dot(dir, Mx3DPointFloat(0, 0, 1.0f));
261
262 if (fabs(dotZ) < fabs(dotX)) {
263 m_axis = dotX > 0.0 ? e_posz : e_negz;
264 }
265 else {
266 m_axis = dotZ > 0.0 ? e_posx : e_negx;
267 }
268 }
269 }
270
271 return SUCCESS;
272}
273
274// FUNCTION: LEGO1 0x1002b290
276{
277 LegoPathBoundary* oldBoundary = m_boundary;
279
280 if (m_boundary != oldBoundary) {
281 MxU32 b = FALSE;
283
284 for (LegoAnimPresenterSet::iterator it = presenters.begin(); it != presenters.end(); it++) {
285 MxU32 roiMapSize;
286 if ((*it)->GetROIMap(roiMapSize)) {
287 b = TRUE;
288 break;
289 }
290 }
291
292 if (b) {
293 m_unk0x0e = 1;
294 m_prevWorldSpeed = GetWorldSpeed();
295 SetWorldSpeed(0);
296 }
297 }
298
299 return result;
300}
301
302// FUNCTION: LEGO1 0x1002b370
304{
305 if (m_unk0x0e != 0) {
306 MxU32 b = FALSE;
308
309 for (LegoAnimPresenterSet::iterator it = presenters.begin(); it != presenters.end(); it++) {
310 MxU32 roiMapSize;
311 if ((*it)->GetROIMap(roiMapSize)) {
312 b = TRUE;
313 break;
314 }
315 }
316
317 if (!b) {
318 SetWorldSpeed(m_prevWorldSpeed);
319 m_unk0x0e = 0;
320 }
321 }
322}
323
324// FUNCTION: LEGO1 0x1002b440
325void LegoExtraActor::Animate(float p_time)
326{
328
329 switch (m_whichAnim) {
330 case 0:
332 break;
333 case 1:
334 if (m_scheduledTime < p_time) {
335 m_whichAnim = 2;
337 m_scheduledTime = m_assAnim->GetDuration() + p_time;
338 break;
339 }
340 else {
341 laas = m_disAnim;
342 break;
343 }
344 case 2:
345 if (m_scheduledTime < p_time) {
346 m_whichAnim = 0;
348 SetWorldSpeed(m_prevWorldSpeed);
349 m_roi->FUN_100a58f0(m_unk0x18);
350 m_lastTime = p_time;
351 break;
352 }
353 else {
354 laas = m_assAnim;
355 break;
356 }
357 }
358
359 if (laas) {
360 float duration2, duration;
361 duration = laas->GetDuration();
362 duration2 = p_time - (m_scheduledTime - duration);
363
364 if (duration2 < 0) {
365 duration2 = 0;
366 }
367 else if (duration2 > duration) {
368 duration2 = duration;
369 }
370
371 MxMatrix matrix(m_roi->GetLocal2World());
372 LegoTreeNode* root = laas->m_AnimTreePtr->GetRoot();
373 MxS32 count = root->GetNumChildren();
374
375 for (MxS32 i = 0; i < count; i++) {
376 LegoROI::FUN_100a8e80(root->GetChild(i), matrix, duration2, laas->m_roiMap);
377 }
378 }
379}
380
381// FUNCTION: LEGO1 0x1002b5d0
383{
384 if (m_whichAnim == 0) {
385 LegoAnimActor::VTable0x74(p_transform);
386 }
387}
388
389// FUNCTION: LEGO1 0x1002b5f0
391{
392 if (m_curAnim == 0 && p_worldSpeed > 0) {
393 VTable0xc4();
394 }
395
396 LegoAnimActor::SetWorldSpeed(p_worldSpeed);
397}
398
399// FUNCTION: LEGO1 0x1002b630
401{
402 if (m_curAnim != 0) {
403 return;
404 }
405
406 if (m_worldSpeed > -0.001 || m_worldSpeed < 0.001) {
407 MxU16 name = *((MxU16*) m_roi->GetName());
408 MxBool b = name == TWOCC('m', 'a') || name == TWOCC('p', 'a');
409
410 if (b) {
411 float duration = m_animMaps[m_curAnim]->GetDuration();
412 MxMatrix matrix(m_unk0xec);
413 LegoAnimActor::FUN_1001c360(duration, matrix);
414 }
415 }
416}
417
418// FUNCTION: LEGO1 0x1002b6f0
420{
421 return LegoPathActor::VTable0x68(p_point1, p_point2, p_point3);
422}
423
424// FUNCTION: LEGO1 0x1002b980
426 LegoPathBoundary* p_boundary,
427 Vector3& p_v1,
428 Vector3& p_v2,
429 float p_f1,
430 float p_f2,
431 Vector3& p_v3
432)
433{
434 LegoAnimPresenterSet& presenters = p_boundary->GetPresenters();
435
436 for (LegoAnimPresenterSet::iterator itap = presenters.begin(); itap != presenters.end(); itap++) {
437 if ((*itap)->VTable0x94(p_v1, p_v2, p_f1, p_f2, p_v3)) {
438 return 1;
439 }
440 }
441
442 LegoPathActorSet& plpas = p_boundary->GetActors();
443 LegoPathActorSet lpas(plpas);
444
445 for (LegoPathActorSet::iterator itpa = lpas.begin(); itpa != lpas.end(); itpa++) {
446 if (plpas.find(*itpa) != plpas.end()) {
447 LegoPathActor* actor = *itpa;
448
449 if (this != actor && !(actor->GetActorState() & LegoPathActor::c_noCollide)) {
450 LegoROI* roi = actor->GetROI();
451
452 if ((roi != NULL && roi->GetVisibility()) || actor->GetCameraFlag()) {
453 if (actor->GetUserNavFlag()) {
454 MxMatrix local2world = roi->GetLocal2World();
455 Vector3 local60(local2world[3]);
456 Mx3DPointFloat local54(p_v1);
457
458 local54 -= local60;
459 float local1c = p_v2.Dot(p_v2, p_v2);
460 float local24 = p_v2.Dot(p_v2, local54) * 2.0f;
461 float local20 = local54.Dot(local54, local54);
462
463 if (m_unk0x15 != 0 && local20 < 10.0f) {
464 return 0;
465 }
466
467 local20 -= 1.0f;
468
469 if (local1c >= 0.001 || local1c <= -0.001) {
470 float local40 = (local24 * local24) + (local20 * local1c * -4.0f);
471
472 if (local40 >= -0.001) {
473 local1c *= 2.0f;
474 local24 = -local24;
475
476 if (local40 < 0.0f) {
477 local40 = 0.0f;
478 }
479
480 local40 = sqrt(local40);
481 float local20X = (local24 + local40) / local1c;
482 float local1cX = (local24 - local40) / local1c;
483
484 if (local1cX < local20X) {
485 local40 = local20X;
486 local20X = local1cX;
487 local1cX = local40;
488 }
489
490 if ((local20X >= 0.0f && local20X <= p_f1) || (local1cX >= 0.0f && local1cX <= p_f1) ||
491 (local20X <= -0.01 && p_f1 + 0.01 <= local1cX)) {
492 p_v3 = p_v1;
493
494 if (HitActor(actor, TRUE) < 0) {
495 return 0;
496 }
497
498 actor->HitActor(this, FALSE);
499 return 2;
500 }
501 }
502 }
503 }
504 else {
505 if (roi->FUN_100a9410(p_v1, p_v2, p_f1, p_f2, p_v3, m_collideBox && actor->GetCollideBox())) {
506 if (HitActor(actor, TRUE) < 0) {
507 return 0;
508 }
509
510 actor->HitActor(this, FALSE);
511 return 2;
512 }
513 }
514 }
515 }
516 }
517 }
518
519 if (m_unk0x15 != 0) {
520 m_unk0x15--;
521 }
522
523 return 0;
524}
void SetWorldSpeed(MxFloat p_worldSpeed) override
[AI] Sets the current world speed and chooses which animation (from the animation map list) should be...
vector< LegoAnimActorStruct * > m_animMaps
[AI] List of animation structures, each representing a valid animation for different speed/phase rang...
virtual MxResult FUN_1001c360(float p_und, Matrix4 &p_transform)
[AI] Applies the animation transform for the current animation at the given phase,...
MxS16 m_curAnim
[AI] Index of currently selected animation map (-1 if none active). [AI]
void Animate(float p_time) override
[AI] Performs per-frame update; applies the appropriate animation to mesh ROIs based on speed and sta...
void VTable0x74(Matrix4 &p_transform) override
[AI] Applies the current animation's transforms to the provided matrix, propagates to mesh hierarchie...
LegoCacheSound * Play(const char *p_key, const char *p_name, MxBool p_looping)
[AI] Plays a sound identified by key, with the given playback name and looping flag.
Mx3DPointFloat GetWorldDirection()
[AI] Gets the normalized world-space direction vector, optionally updating from ROI....
Definition: legoentity.cpp:202
LegoROI * GetROI()
[AI] Gets the ROI (Realtime Object Instance) associated with this entity. [AI]
Definition: legoentity.h:161
MxFloat m_worldSpeed
[AI] World-relative speed (can affect animation/movement logic). [AI]
Definition: legoentity.h:212
MxFloat GetWorldSpeed()
[AI] Gets the entity's current world speed state. [AI]
Definition: legoentity.h:158
LegoROI * m_roi
[AI] Pointer to this entity's currently assigned ROI (3D instance in the world). [AI]
Definition: legoentity.h:215
MxBool GetCameraFlag()
[AI] Returns whether this entity is flagged as camera (affects world/camera synchronization)....
Definition: legoentity.h:167
Represents a special actor in the world with additional animation state machines and complex interact...
MxResult HitActor(LegoPathActor *p_actor, MxBool p_bool) override
Processes a collision ("hit") with another actor, updating internal animation state and triggering so...
void VTable0x74(Matrix4 &p_transform) override
Updates object transformation if special animation is not active, otherwise delegates to parent class...
MxS32 VTable0x68(Vector3 &p_point1, Vector3 &p_point2, Vector3 &p_point3) override
(Inherited implementation) Delegates edge update logic to LegoPathActor.
void Animate(float p_time) override
Performs animation updates for the actor, handling alternate animations and transitions after collisi...
void Restart()
Checks whether this actor's previous boundary was "blocked" and re-enables movement if allowed; calle...
void SetWorldSpeed(MxFloat p_worldSpeed) override
Sets the world speed for this actor, factoring in its current animation/interaction state.
MxU32 VTable0x6c(LegoPathBoundary *p_boundary, Vector3 &p_v1, Vector3 &p_v2, float p_f1, float p_f2, Vector3 &p_v3) override
Tests for and handles collision with other path actors during simulation.
void VTable0xc4() override
Handles special cleanup or reset behavior for extra actors, often related to secondary animation stat...
void VTable0xa4(MxBool &p_und1, MxS32 &p_und2) override
Determines secondary state outputs for randomization or specific internal state flags,...
~LegoExtraActor() override
Destructor, cleans up allocated animation structures.
MxResult VTable0x9c() override
Called when crossing path boundaries, manages transitions to special in-between animation states and ...
virtual MxResult FUN_1002aae0()
Handles boundary edge changes and swapping the actor's edge, updating direction and orientation accor...
void FUN_1002ad8a()
Loads or assigns the alternate ("assembly" and "disassembly") animations to this actor as needed.
MxU32 VTable0x90(float p_time, Matrix4 &p_matrix) override
Core animation & state tick: handles scheduled events (e.g., switching state after timed delay post-c...
@ e_negz
-Z axis [AI]
@ e_posz
+Z axis [AI]
@ e_negx
-X axis [AI]
@ e_posx
+X axis [AI]
[AI] Specialized presenter class for handling locomotion animation playback and state in the LEGO Isl...
void FUN_1006d680(LegoAnimActor *p_actor, MxFloat p_value)
[AI] Binds a LegoAnimActor to the internal animation context and ROI mapping.
[AI] An actor that moves along a predefined path, supporting boundary transitions,...
Definition: legopathactor.h:32
MxFloat m_actorTime
[AI] Animation time for current path segment. [AI]
MxBool GetCollideBox()
[AI] Gets the actor's collision box flag (if TRUE, actor uses a precise collision shape).
MxU32 GetActorState()
[AI] Gets the current navigation/animation state of the actor.
LegoUnknown100db7f4 * m_destEdge
[AI] Current or target edge for path traversal. [AI]
virtual MxBool GetUserNavFlag()
[AI] Returns user navigation state (whether actor follows player input).
LegoPathBoundary * m_boundary
[AI] Current boundary the actor is navigating on. [AI]
MxU32 m_actorState
[AI] State and flags bitfield for path following logic. [AI]
@ c_maxState
[AI] Max actor state (reserved for logic). [AI]
Definition: legopathactor.h:42
@ c_initial
[AI] Default state upon creation or reset. [AI]
Definition: legopathactor.h:37
@ c_noCollide
[AI] Disables collision for this actor (e.g. ghosts, debug). [AI]
Definition: legopathactor.h:45
virtual MxResult VTable0x9c()
[AI] Handles exit transition and next-edge search logic; also used for collision reaction and fallbac...
MxMatrix m_unk0xec
[AI] World-to-local transformation matrix for this actor/ROI. [AI]
MxBool m_collideBox
[AI] Use bounding-box for more accurate collision. [AI]
virtual MxS32 VTable0x68(Vector3 &p_v1, Vector3 &p_v2, Vector3 &p_v3)
[AI] Checks for collision/intersection with boundaries, geometry, and other actors along a traced seg...
virtual MxResult HitActor(LegoPathActor *, MxBool)
[AI] Handles logic when this actor hits (collides with) another path actor; can be overridden for cus...
MxFloat m_lastTime
[AI] Time of last update (used for delta calculations). [AI]
void SetActorState(MxU32 p_actorState)
[AI] Sets the navigation/path state of the actor.
[AI] Represents a path segment or boundary in the navigation network for actors (vehicles,...
LegoAnimPresenterSet & GetPresenters()
[AI] Direct access to the animation presenter set for this boundary.
LegoPathActorSet & GetActors()
[AI] Direct access to the actor set for this boundary.
[AI] Represents a Real-time Object Instance enriched with LEGO-specific functionality.
Definition: legoroi.h:43
LegoU32 FUN_100a9410(Vector3 &p_v1, Vector3 &p_v2, float p_f1, float p_f2, Vector3 &p_v3, LegoBool p_collideBox)
[AI] Tests for collision along or within sphere/box, and computes intersection point as needed.
Definition: legoroi.cpp:594
static void FUN_100a8e80(LegoTreeNode *p_node, Matrix4 &p_matrix, LegoTime p_time, LegoROI **p_roiMap)
[AI] [Static] Recursively evaluates animation nodes, updating the transformation matrices and visibil...
Definition: legoroi.cpp:414
const LegoChar * GetName() const
[AI] Gets this ROI's name.
Definition: legoroi.h:287
LegoCacheSoundManager * GetCacheSoundManager()
[AI] Returns the cache sound manager used to cache and reuse sound effects.
[AI] Represents a node within a general, N-ary tree structure.
Definition: legotree.h:44
LegoU32 GetNumChildren()
[AI] Returns the number of direct children of this node. [AI]
Definition: legotree.h:63
LegoTreeNode * GetChild(LegoU32 p_i)
[AI] Gets the child node at the specified index (no bounds checking).
Definition: legotree.h:72
LegoTreeNode * GetRoot()
[AI] Returns a pointer to the root node of the tree. [AI]
Definition: legotree.h:112
LegoU8 GetNumEdges()
[AI] Returns the number of edge elements assigned to this face.
Definition: legoweedge.h:43
Mx4DPointFloat * GetEdgeNormal(int index)
[AI] Returns a pointer to the 4D edge normal at the given sub-edge index.
Definition: legowegedge.h:75
Represents the active 3D world, holding all entity, animation, sound, path, and ROI objects.
Definition: legoworld.h:49
MxCore * Find(const char *p_class, const char *p_name)
Finds an object of a given class and name in the world.
Definition: legoworld.cpp:573
4x4 Matrix class with virtual interface for manipulation and transformation.
Definition: matrix.h:24
void RotateX(const float &p_angle)
Applies a rotation (in radians or degrees, depending on implementation) about the X axis.
void RotateZ(const float &p_angle)
Applies a rotation (in radians or degrees) about the Z axis.
[AI] Represents a 3D point with floating-point precision, inheriting from Vector3.
Definition: mxgeometry3d.h:14
[AI] 4D point class for floating point values.
Definition: mxgeometry4d.h:18
float & index_operator(int idx)
[AI] Explicit indexed access wrapper (alias for operator[]).
Definition: mxgeometry4d.h:73
[AI] Represents a 4x4 transformation matrix, specialized for the LEGO Island engine and derived from ...
Definition: mxmatrix.h:16
MxLong GetTime()
Returns the current timer value in ms, depending on running state.
Definition: mxtimer.h:50
const Matrix4 & GetLocal2World() const
Accessor for the current local-to-world transformation matrix.
virtual void VTable0x14()
[AI] Calls VTable0x1c().
Definition: orientableroi.h:64
void FUN_100a58f0(const Matrix4 &p_transform)
Assigns the given matrix as the local-to-world transformation and enables some internal flags.
unsigned char GetVisibility()
[AI] Returns the visibility flag; true if visible, false if hidden.
Definition: roi.h:228
virtual float Dot(const float *p_a, const float *p_b) const
[AI] Compute the dot product of the two float arrays interpreted as vectors of 2 elements.
[AI] 3D vector class, providing vector and cross-product operations in 3D space.
Definition: vector.h:249
void Clear() override
[AI] Sets every coordinate (x, y, z) to zero.
virtual void EqualsCross(const Vector3 &p_a, const Vector3 &p_b)
[AI] Sets this vector to be the cross product of p_a and p_b.
#define TRUE
Definition: d3drmdef.h:28
#define FALSE
Definition: d3drmdef.h:27
#define DECOMP_SIZE_ASSERT(T, S)
Definition: decomp.h:19
LegoLocomotionAnimPresenter * m_disAnimP
Mx3DPointFloat g_unk0x10104c18
LegoWorld * g_unk0x100f31d0
MxS32 g_unk0x100f31dc
LegoLocomotionAnimPresenter * m_assAnimP
set< LegoAnimPresenter *, LegoAnimPresenterSetCompare > LegoAnimPresenterSet
[AI] Defines a set of LegoAnimPresenter pointers, ordered by pointer value using LegoAnimPresenterSet...
set< LegoPathActor *, LegoPathActorSetCompare > LegoPathActorSet
[AI] Defines a set of LegoPathActor pointers, ordered by pointer value using LegoPathActorSetCompare.
#define NULL
[AI] Null pointer value (C/C++ semantics).
Definition: legotypes.h:26
#define FAILURE
[AI] Used to indicate a failed operation in result codes.
Definition: legotypes.h:34
#define SUCCESS
[AI] Used to indicate a successful operation in result codes.
Definition: legotypes.h:30
LegoSoundManager * SoundManager()
[AI] Accessor for the game's LegoSoundManager subsystem from the global LegoOmni instance....
Definition: misc.cpp:22
LegoWorld * CurrentWorld()
[AI] Accessor for the currently active LegoWorld instance. [AI]
Definition: misc.cpp:93
MxTimer * Timer()
[AI] Returns the global simulation timer.
Definition: mxmisc.cpp:33
MxU8 MxBool
[AI]
Definition: mxtypes.h:124
MxLong MxResult
[AI]
Definition: mxtypes.h:106
#define TWOCC(a, b)
[AI] Macro to compose a 16-bit code from two 8-bit characters (e.g., for type IDs).
Definition: mxtypes.h:151
float MxFloat
[AI]
Definition: mxtypes.h:68
signed int MxS32
[AI]
Definition: mxtypes.h:38
unsigned short MxU16
[AI]
Definition: mxtypes.h:20
unsigned int MxU32
[AI]
Definition: mxtypes.h:32
[AI] Holds per-animation instance data for a LegoAnimActor.
Definition: legoanimactor.h:13
float GetDuration()
[AI] Gets the length, in seconds, of the animation (delegates to anim tree).
LegoAnim * m_AnimTreePtr
[AI] Root of animation tree for this animation [AI]
Definition: legoanimactor.h:39
LegoROI ** m_roiMap
[AI] Mapping of animation nodes to LEGO ROIs (meshes) [AI]
Definition: legoanimactor.h:40
LegoWEEdge * m_faceA
[AI] Pointer to the first face sharing this edge.
Definition: legoedge.h:97
LegoWEEdge * m_faceB
[AI] Pointer to the second face sharing this edge.
Definition: legoedge.h:103