A reimplementation of Mario Kart Wii's physics engine in C++
Loading...
Searching...
No Matches
ObjectCrane.hh
1#pragma once
2
3#include "game/field/obj/ObjectKCL.hh"
4
5namespace Field {
6
10class ObjectCrane final : public ObjectKCL {
11public:
13 ~ObjectCrane() override;
14
15 void calc() override;
16
18 [[nodiscard]] u32 loadFlags() const override {
19 return 1;
20 }
21
23 [[nodiscard]] f32 colRadiusAdditionalLength() const override {
24 return m_xAmplitude;
25 }
26
27private:
35 f32 m_xFreq;
36 f32 m_yFreq;
37};
38
39} // namespace Field
The moving crane platforms after the second turn of Toad's Factory.
u16 m_xPeriod
Framecount of a full oscillation on x-axis.
f32 m_xFreq
2pi / m_xPeriod
u16 m_yPeriod
Framecount of a full oscillation on y-axis.
const EGG::Vector3f m_startPos
Initial starting position.
u16 m_yAmplitude
Max y-position delta from starting position.
u16 m_xAmplitude
Max x-position delta from starting position.
f32 m_yFreq
2pi / m_yPeriod
u16 m_xt
Current time along the x-axis period.
u16 m_yt
Current time along the y-axis period.
Pertains to collision.
A 3D float vector.
Definition Vector.hh:87