This commit is contained in:
Jack Andersen 2016-07-26 20:14:17 -10:00
commit 11fe521bbc
10 changed files with 428 additions and 28 deletions

View File

@ -11,32 +11,32 @@ namespace DNAMP1
struct CTweakGame : ITweakGame
{
DECL_YAML
String<-1> m_worldPrefix;
String<-1> m_ruinsArea; // ????
Value<float> m_fov;
Value<bool> unknown1;
Value<bool> unknown2;
Value<bool> unknown3;
Value<bool> unknown4;
Value<float> unknown5;
Value<float> unknown6;
Value<float> unknown7;
Value<float> unknown8;
Value<float> unknown9;
Value<float> unknown10;
Value<float> unknown11;
Value<float> unknown12;
Value<float> unknown13;
Value<float> unknown14;
Value<float> unknown15;
Value<float> unknown16;
Value<float> unknown17;
Value<float> unknown18;
Value<float> hardmodeDamageMult;
Value<float> hardmodeWeaponMult;
String<-1> x4_worldPrefix;
String<-1> x14_ruinsArea; // ????
Value<float> x24_fov;
Value<bool> x28_unknown1;
Value<bool> x29_unknown2;
Value<bool> x2a_unknown3;
Value<bool> x2b_unknown4;
Value<float> x2c_cunknown5;
Value<float> x30_unknown6;
Value<float> x34_unknown7;
Value<float> x38_unknown8;
Value<float> x3c_unknown9;
Value<float> x40_unknown10;
Value<float> x44_unknown11;
Value<float> x48_unknown12;
Value<float> x4c_unknown13;
Value<float> x50_unknown14;
Value<float> x54_unknown15;
Value<float> x58_unknown16;
Value<float> x5c_unknown17;
Value<float> x60_unknown18;
Value<float> x64_hardmodeDamageMult;
Value<float> x68_hardmodeWeaponMult;
virtual const std::string& GetWorldPrefix() const { return m_worldPrefix; }
CTweakGame(athena::io::IStreamReader& in) { this->read(in); }
virtual const std::string& GetWorldPrefix() const { return x4_worldPrefix; }
CTweakGame(athena::io::IStreamReader& in) { this->read(in); x2b_unknown4 = false; }
};
}
}

View File

@ -377,6 +377,7 @@ void ViewManager::stop()
{
m_videoVoice.reset();
m_projManager.shutdown();
TShader<CThermalColdFilter>::Shutdown();
CElementGen::Shutdown();
CMoviePlayer::Shutdown();
CLineRenderer::Shutdown();

View File

@ -46,6 +46,7 @@ add_library(RuntimeCommon
${PARTICLE_SOURCES}
${WORLD_SOURCES}
#CMemory.hpp CMemory.cpp
ITweak.hpp
CMemoryCardSys.hpp
CSaveWorld.hpp CSaveWorld.cpp
IAllocator.hpp IAllocator.cpp

View File

@ -1,5 +1,5 @@
#include "CLineRendererShaders.hpp"
#include "CLineRenderer.hpp"
#include "Graphics/CLineRenderer.hpp"
#if BOO_HAS_METAL
namespace urde

View File

@ -90,7 +90,7 @@ struct CThermalColdFilterGLDataBindingFactory : TShader<CThermalColdFilter>::IDa
boo::PipelineStage stages[] = {boo::PipelineStage::Vertex};
boo::ITexture* texs[] = {CGraphics::g_SpareTexture, filter.m_shiftTex};
return cctx.newShaderDataBinding(TShader<CThermalColdFilter>::m_pipeline,
ctx.newVertexFormat(3, VtxVmt), filter.m_vbo, nullptr, nullptr,
ctx.newVertexFormat(2, VtxVmt), filter.m_vbo, nullptr, nullptr,
1, bufs, stages, nullptr, nullptr, 2, texs);
}
};

13
Runtime/ITweak.hpp Normal file
View File

@ -0,0 +1,13 @@
#ifndef __URDE_ITWEAK_HPP__
#define __URDE_ITWEAK_HPP__
namespace urde
{
class ITweak
{
public:
virtual ~ITweak() {}
};
}
#endif // __URDE_ITWEAK_HPP__

View File

@ -2,6 +2,7 @@ include_directories(. ..)
set(MP1_SOURCES
CTweaks.hpp CTweaks.cpp
CInGameTweakManager.hpp CInGameTweakManager.cpp
Tweaks/CTweakPlayer.hpp Tweaks/CTweakPlayer.cpp
CMainFlow.hpp CMainFlow.cpp
CMFGame.hpp CMFGame.cpp
CPlayMovie.hpp CPlayMovie.cpp

View File

@ -0,0 +1,182 @@
#include "CTweakPlayer.hpp"
#include "zeus/Math.hpp"
namespace urde
{
namespace MP1
{
CTweakPlayer::CTweakPlayer(urde::CInputStream& in)
{
for (u32 i = 0 ; i<8 ; ++i)
x4_[i] = in.readFloatBig();
for (u32 i = 0 ; i<8 ; ++i)
x24_[i] = in.readFloatBig();
for (u32 i = 0 ; i<8 ; ++i)
x44_[i] = in.readFloatBig();
for (u32 i = 0 ; i<8 ; ++i)
x64_[i] = in.readFloatBig();
for (u32 i = 0 ; i<8 ; ++i)
x84_[i] = in.readFloatBig();
for (u32 i = 0 ; i<8 ; ++i)
xa4_[i] = in.readFloatBig();
xc4_ = in.readFloatBig();
xc8_ = in.readFloatBig();
xcc_ = in.readFloatBig();
xd0_ = in.readFloatBig();
xd4_ = in.readFloatBig();
xd8_ = in.readFloatBig();
xdc_ = in.readFloatBig();
xe0_ = in.readFloatBig();
xe4_ = in.readFloatBig();
xe8_ = in.readFloatBig();
xec_ = in.readFloatBig();
xf0_ = in.readFloatBig();
xf4_ = in.readFloatBig();
xf8_ = in.readFloatBig();
xfc_ = in.readFloatBig();
x100_ = in.readFloatBig();
x104_ = in.readFloatBig();
x108_ = in.readFloatBig();
x10c_ = in.readFloatBig();
x11c_ = in.readFloatBig();
x120_ = in.readFloatBig();
x124_ = in.readFloatBig();
x128_ = in.readFloatBig();
x12c_ = in.readFloatBig();
x130_ = zeus::degToRad(in.readFloatBig());
x134_ = zeus::degToRad(in.readFloatBig());
x138_ = zeus::degToRad(in.readFloatBig());
x13c_ = zeus::degToRad(in.readFloatBig());
x140_ = zeus::degToRad(in.readFloatBig());
x144_ = zeus::degToRad(in.readFloatBig());
x148_ = in.readFloatBig();
x14c_ = in.readFloatBig();
x150_ = in.readFloatBig();
x228_24_ = in.readBool();
x228_25_ = in.readBool();
x228_26_ = in.readBool();
x228_27_ = in.readBool();
x228_28_ = in.readBool();
x228_29_ = in.readBool();
x228_30_ = in.readBool();
x228_31_ = in.readBool();
x229_24_ = in.readBool();
x229_25_ = in.readBool();
x229_26_ = in.readBool();
x229_27_ = in.readBool();
x229_28_ = in.readBool();
x229_29_ = in.readBool();
x229_30_ = in.readBool();
x229_31_ = in.readBool();
x22a_24_ = in.readBool();
x22a_25_ = in.readBool();
x22a_26_ = in.readBool();
x22a_27_ = in.readBool();
x22a_28_ = in.readBool();
x22c_ = in.readFloatBig();
x230_ = in.readFloatBig();
x234_ = in.readFloatBig();
x238_ = zeus::degToRad(in.readFloatBig());
x23c_ = zeus::degToRad(in.readFloatBig());
x240_ = zeus::degToRad(in.readFloatBig());
x244_ = zeus::degToRad(in.readFloatBig());
x248_ = zeus::degToRad(in.readFloatBig());
x24c_ = in.readFloatBig();
x250_ = zeus::degToRad(in.readFloatBig());
x254_ = in.readFloatBig();
x258_ = in.readFloatBig();
x25c_ = in.readFloatBig();
x260_ = in.readFloatBig();
x264_ = zeus::degToRad(in.readFloatBig());
for (u32 i = 0 ; i<3 ; ++i)
{
x158_[i] = in.readFloatBig();
x164_[i] = in.readFloatBig();
x170_[i] = in.readFloatBig();
}
x17c_ = zeus::degToRad(in.readFloatBig());
x180_ = in.readFloatBig();
x184_ = zeus::degToRad(in.readFloatBig());
x188_ = zeus::degToRad(in.readFloatBig());
x18c_ = zeus::degToRad(in.readFloatBig());
x190_ = zeus::degToRad(in.readFloatBig());
x194_ = zeus::degToRad(in.readFloatBig());
x198_ = zeus::degToRad(in.readFloatBig());
x19c_ = in.readFloatBig();
x1a0_ = in.readFloatBig();
x1a4_ = in.readFloatBig();
for (u32 i = 0 ; i<2 ; ++i)
{
x1a8_[i] = in.readUint32Big();
x1b0_[i] = in.readUint32Big();
x1b8_[i] = in.readUint32Big();
x1c0_[i] = in.readUint32Big();
x1c8_[i] = in.readUint32Big();
}
x1d8_ = in.readFloatBig();
x1dc_ = in.readFloatBig();
x1e0_ = in.readFloatBig();
x1e4_ = in.readFloatBig();
x1e8_ = in.readFloatBig();
x1ec_ = in.readFloatBig();
x1f0_ = zeus::degToRad(in.readFloatBig());
x1f4_ = zeus::degToRad(in.readFloatBig());
x1f8_ = in.readFloatBig();
x1fc_ = in.readFloatBig();
x200_24_ = in.readBool();
x200_25_ = in.readBool();
x204_ = in.readFloatBig();
x208_ = in.readFloatBig();
x20c_ = in.readFloatBig();
x210_ = in.readFloatBig();
x214_ = in.readFloatBig();
x218_ = in.readFloatBig();
x21c_24_ = in.readBool();
x21c_25_ = in.readBool();
x220_ = in.readFloatBig();
x224_ = in.readFloatBig();
x2a0_ = in.readFloatBig();
x2a4_ = in.readFloatBig();
x2a8_ = in.readFloatBig();
x2ac_ = in.readFloatBig();
x2b0_ = zeus::degToRad(in.readFloatBig());
x2b4_ = in.readFloatBig();
x2b8_ = in.readFloatBig();
x2bc_ = in.readFloatBig();
x2c0_ = zeus::degToRad(in.readFloatBig());
x2c4_ = in.readFloatBig();
x2c8_ = in.readFloatBig();
x2cc_ = in.readFloatBig();
x2d0_ = in.readUint32Big();
x2d4_ = in.readBool();
x2d5_ = in.readBool();
x2d8_ = in.readFloatBig();
x2dc_ = in.readFloatBig();
x2e0_ = in.readFloatBig();
x2e4_ = in.readFloatBig();
x26c_ = in.readFloatBig();
x270_ = in.readFloatBig();
x274_ = in.readFloatBig();
x278_ = in.readFloatBig();
x27c_ = in.readFloatBig();
x280_ = zeus::degToRad(in.readFloatBig());
x284_ = zeus::degToRad(in.readFloatBig());
x288_ = in.readFloatBig();
x28c_ = in.readFloatBig();
x290_ = zeus::degToRad(in.readFloatBig());
x294_ = in.readFloatBig();
x298_ = in.readFloatBig();
x29c_ = zeus::degToRad(in.readFloatBig());
x2e8_ = in.readFloatBig();
x2ec_ = in.readFloatBig();
x2f0_ = in.readFloatBig();
x2f4_ = in.readBool();
x2f8_ = in.readFloatBig();
x2fc_ = in.readFloatBig();
x300_ = in.readFloatBig();
x304_ = in.readFloatBig();
x308_ = in.readFloatBig();
}
}
}

View File

@ -0,0 +1,202 @@
#ifndef __URDE_MP1_CTWEAKPLAYER_HPP__
#define __URDE_MP1_CTWEAKPLAYER_HPP__
#include "RetroTypes.hpp"
#include "ITweak.hpp"
namespace urde
{
namespace MP1
{
class CTweakPlayer : public ITweak
{
float x4_[8];
float x24_[8];
float x44_[8];
float x64_[8];
float x84_[8];
float xa4_[8];
float xc4_;
float xc8_;
float xcc_;
float xd0_;
float xd4_;
float xd8_;
float xdc_;
float xe0_;
float xe4_;
float xe8_;
float xec_;
float xf0_;
float xf4_;
float xf8_;
float xfc_;
float x100_;
float x104_;
float x108_;
float x10c_;
float x110_;
float x114_;
float x118_;
float x11c_;
float x120_;
float x124_;
float x128_;
float x12c_;
float x130_;
float x134_;
float x138_;
float x13c_;
float x140_;
float x144_;
float x148_;
float x14c_;
float x150_;
float x154_;
float x158_[3];
float x164_[3];
float x170_[3];
float x17c_;
float x180_;
float x184_;
float x188_;
float x18c_;
float x190_;
float x194_;
float x198_;
float x19c_;
float x1a0_;
float x1a4_;
u32 x1a8_[2];
u32 x1b0_[2];
u32 x1b8_[2];
u32 x1c0_[2];
u32 x1c8_[2];
u32 x1d0_[2];
float x1d8_;
float x1dc_;
float x1e0_;
float x1e4_;
float x1e8_;
float x1ec_;
float x1f0_;
float x1f4_;
float x1f8_;
float x1fc_;
union
{
struct
{
bool x200_24_ : 1;
bool x200_25_ : 1;
};
u8 _dummy1 = 0;
};
float x204_;
float x208_;
float x20c_;
float x210_;
float x214_;
float x218_;
union
{
struct
{
bool x21c_24_ : 1;
bool x21c_25_ : 1;
};
u8 _dummy2 = 0;
};
float x220_;
float x224_;
union
{
struct
{
bool x228_24_ : 1;
bool x228_25_ : 1;
bool x228_26_ : 1;
bool x228_27_ : 1;
bool x228_28_ : 1;
bool x228_29_ : 1;
bool x228_30_ : 1;
bool x228_31_ : 1;
bool x229_24_ : 1;
bool x229_25_ : 1;
bool x229_26_ : 1;
bool x229_27_ : 1;
bool x229_28_ : 1;
bool x229_29_ : 1;
bool x229_30_ : 1;
bool x229_31_ : 1;
bool x22a_24_ : 1;
bool x22a_25_ : 1;
bool x22a_26_ : 1;
bool x22a_27_ : 1;
bool x22a_28_ : 1;
};
u32 _dummy3 = 0;
};
float x22c_;
float x230_;
float x234_;
float x238_;
float x23c_;
float x240_;
float x244_;
float x248_;
float x24c_;
float x250_;
float x254_;
float x258_;
float x25c_;
float x260_;
float x264_;
float x268_;
float x26c_;
float x270_;
float x274_;
float x278_;
float x27c_;
float x280_;
float x284_;
float x288_;
float x28c_;
float x290_;
float x294_;
float x298_;
float x29c_;
float x2a0_;
float x2a4_;
float x2a8_;
float x2ac_;
float x2b0_;
float x2b4_;
float x2b8_;
float x2bc_;
float x2c0_;
float x2c4_;
float x2c8_;
float x2cc_;
u32 x2d0_;
bool x2d4_;
bool x2d5_;
float x2d8_;
float x2dc_;
float x2e0_;
float x2e4_;
float x2e8_;
float x2ec_;
float x2f0_;
bool x2f4_;
float x2f8_;
u32 x2fc_;
float x300_;
float x304_;
float x308_;
public:
CTweakPlayer(CInputStream&);
virtual ~CTweakPlayer() {}
};
}
}
#endif // __URDE_MP1_CTWEAKPLAYER_HPP__

2
hecl

@ -1 +1 @@
Subproject commit ba0684b9153beb9d098a87b048ec642f289b0ed5
Subproject commit 3e5c8a7992c4ada055034194687f6f7b7c6b5d72