SMG-Decomp
A decompilation of Super Mario Galaxy 1
Loading...
Searching...
No Matches
OceanRing.hpp
1#pragma once
2
3#include "Game/LiveActor/LiveActor.hpp"
4#include "Game/Map/WaterInfo.hpp"
5#include "Game/Map/WaterPoint.hpp"
6
9class OceanRingPipe;
11
12namespace {
13 static f32 sEdgePointNum = 2.0f;
14};
15
16class OceanRing : public LiveActor {
17public:
18 OceanRing(const char *);
19
20 virtual ~OceanRing();
21 virtual void init(const JMapInfoIter &);
22 virtual void initAfterPlacement();
23 virtual void movement();
24 virtual void draw() const;
25 virtual void startClipped();
26 virtual void endClipped();
27
28 bool isInWater(const TVec3f &) const;
29 bool calcWaterInfo(const TVec3f &, const TVec3f &, WaterInfo *);
30 f32 calcNearestPos(const TVec3f &, TVec3f *, TVec3f *, TVec3f *) const;
31 f32 calcWaveHeight(const TVec3f &, f32, TVec3f *);
32 void calcStreamVec(const TVec3f &, f32, TVec3f *);
33 void initPoints();
34 void updatePoints();
35 void updatePointsInLine(s32, s32, s32, s32);
36 f32 calcCurrentWidthRate(f32) const;
37 f32 calcCurrentFlowSpeedRate(f32) const;
38 void calcClippingBox();
39 WaterPoint* getPoint(int, int) const;
40
41 s32 mWaterPointNum; // _8C
42 u32 mSegCount; // _90
43 s32 mStride; // _94
44 WaterPoint** mWaterPoints; // _98
45 f32 mWidthMax; // _9C
46 s32 mObjArg1; // _A0
47 f32 mWaveTheta1; // _A4
48 f32 mWaveTheta2; // _A8
49 f32 mWaveHeight1; // _AC
50 f32 mWaveHeight2; // _B0
51 u8 _B4;
52 u8 _B5;
53 u8 _B6;
54 u8 _B7;
55 f32 mNearPosToPlayer; // _B8
56 TVec3f mNearestPos; // _BC
57 TVec3f mNearestDir; // _C8
58 OceanRingDrawer* mRingDrawer; // _D4
59 TBox3f mBox; // _D8
60 TBox3f mClippingBox; // _F0
61 TVec3f _108;
62 TVec3f mNearestToWatchCam; // _114
63 AudSoundObject* mSoundObj1; // _120
64 TVec3f mNerarestToCam; // _124
65 AudSoundObject* mSoundObj2; // _130
66 OceanRingPipe* mOceanRingPipe; // _134
67 OceanRingBloomDrawer* mBloomDrawer; // _138
68};
The basis of a drawable actor that can contain states (see: Nerve)
Definition LiveActor.hpp:24
virtual void draw() const
Draws the object. Does nothing until overridden.
virtual void init(const JMapInfoIter &)
Intializes the NameObj and can set various settings and construct necessary classes.