diff options
| author | hatal175 <hatal175@users.noreply.github.com> | 2024-08-17 08:19:53 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-08-16 22:19:53 -0700 |
| commit | 18f4489dd6e7996152bc385ec89a340dccaafe8a (patch) | |
| tree | 5800d04bb9c99f47ecdf03cf0521df9a3e3772bc /include | |
| parent | edd2d30a337a69c6a0228a172108ce17d3253697 (diff) | |
d_particle almost finished (#2193)
* d_particle almost finished
* Remove dolasm.h include from JKRDvdRipper
Diffstat (limited to 'include')
| -rw-r--r-- | include/JSystem/JGeometry.h | 13 | ||||
| -rw-r--r-- | include/JSystem/JParticle/JPAParticle.h | 1 | ||||
| -rw-r--r-- | include/d/kankyo/d_kankyo.h | 1 | ||||
| -rw-r--r-- | include/d/particle/d_particle.h | 7 | ||||
| -rw-r--r-- | include/dolphin/gx.h | 7 |
5 files changed, 27 insertions, 2 deletions
diff --git a/include/JSystem/JGeometry.h b/include/JSystem/JGeometry.h index bbc4eae903..079fcf8d1b 100644 --- a/include/JSystem/JGeometry.h +++ b/include/JSystem/JGeometry.h @@ -305,6 +305,19 @@ struct TVec3<f32> : public Vec { }; return res; } + + void cubic(const TVec3<f32>& param_1, const TVec3<f32>& param_2, const TVec3<f32>& param_3, + const TVec3<f32>& param_4, f32 param_5) { + f32 fVar5 = param_5 * param_5; + f32 fVar6 = fVar5 * param_5; + f32 fVar8 = 1.0f + (2.0f * fVar6 - 3.0f * fVar5); + f32 fVar9 = -2.0f * fVar6 + 3.0f * fVar5; + f32 fVar7 = param_5 + (fVar6 - 2.0f * fVar5); + f32 fVar4 = fVar6 - fVar5; + x = fVar8 * param_1.x + fVar9 * param_4.x + fVar7 * param_2.x + fVar4 * param_3.x; + y = fVar8 * param_1.y + fVar9 * param_4.y + fVar7 * param_2.y + fVar4 * param_3.y; + z = fVar8 * param_1.z + fVar9 * param_4.z + fVar7 * param_2.z + fVar4 * param_3.z; + } }; template <typename T> diff --git a/include/JSystem/JParticle/JPAParticle.h b/include/JSystem/JParticle/JPAParticle.h index ebedcc6549..5d057476d9 100644 --- a/include/JSystem/JParticle/JPAParticle.h +++ b/include/JSystem/JParticle/JPAParticle.h @@ -43,6 +43,7 @@ public: void setDeleteParticleFlag() { setStatus(2); } void getVelVec(JGeometry::TVec3<f32>& vec) const { vec.set(mVelocity); } void getLocalPosition(JGeometry::TVec3<f32>& vec) const { vec.set(mLocalPosition); } + void getBaseAxis(JGeometry::TVec3<f32>& vec) const { vec.set(mBaseAxis); } public: /* 0x00 */ JGeometry::TVec3<f32> mPosition; diff --git a/include/d/kankyo/d_kankyo.h b/include/d/kankyo/d_kankyo.h index f8a2077508..13f6503598 100644 --- a/include/d/kankyo/d_kankyo.h +++ b/include/d/kankyo/d_kankyo.h @@ -599,6 +599,7 @@ void dKy_ParticleColor_get_bg(cXyz* param_0, dKy_tevstr_c* param_1, _GXColor* pa f32 param_6); _GXColor dKy_light_influence_col(_GXColor* param_0, f32 param_1); static void dKy_WaterIn_Light_set(); +void dKy_SordFlush_set(cXyz param_0, int param_1); #endif /* D_KANKYO_D_KANKYO_H */ diff --git a/include/d/particle/d_particle.h b/include/d/particle/d_particle.h index 8f0152cc8f..75ae38a9ef 100644 --- a/include/d/particle/d_particle.h +++ b/include/d/particle/d_particle.h @@ -46,6 +46,7 @@ class cBgS_PolyInfo; class JPAEmitterManager; class JPADrawInfo; class J3DAnmBase; +class dPa_simpleData_c; class dPa_simpleEcallBack : public JPAEmitterCallBack { public: @@ -67,7 +68,7 @@ public: /* 0x0A */ u8 field_0xa; /* 0x0C */ s16 field_0xc; /* 0x0C */ u16 field_0xe; - /* 0x10 */ void* mData; + /* 0x10 */ dPa_simpleData_c* mData; }; // Size: 0x14 class dPa_followEcallBack : public dPa_levelEcallBack { @@ -256,7 +257,9 @@ public: /* 8004B024 */ ~dPa_simpleData_c(); /* 8004B060 */ dPa_simpleData_c(); - u8 field_0x0[20]; + cXyz field_0x00; + GXColor field_0x0c; + GXColor field_0x10; }; class dPa_control_c { diff --git a/include/dolphin/gx.h b/include/dolphin/gx.h index 875ce03fef..12d80c77cb 100644 --- a/include/dolphin/gx.h +++ b/include/dolphin/gx.h @@ -120,6 +120,13 @@ static inline void GXColor1u32(const u32 c) { GXWGFifo.u32 = c; } +static inline void GXColor4u8(const u8 r, const u8 g, const u8 b, const u8 a) { + GXWGFifo.u8 = r; + GXWGFifo.u8 = g; + GXWGFifo.u8 = b; + GXWGFifo.u8 = a; +} + static inline void GXTexCoord2f32(const f32 s, const f32 t) { GXWGFifo.f32 = s; GXWGFifo.f32 = t; |
