2018-10-07 03:42:33 +00:00
|
|
|
#pragma once
|
2017-01-26 10:06:18 +00:00
|
|
|
|
|
|
|
#include "../../DNACommon/Tweaks/ITweakBall.hpp"
|
|
|
|
#include "zeus/CVector3f.hpp"
|
|
|
|
|
2017-12-29 08:08:12 +00:00
|
|
|
namespace DataSpec::DNAMP1
|
2017-01-26 10:06:18 +00:00
|
|
|
{
|
2017-08-27 03:02:18 +00:00
|
|
|
struct CTweakBall final : public ITweakBall
|
2017-01-26 10:06:18 +00:00
|
|
|
{
|
2018-02-22 07:24:51 +00:00
|
|
|
AT_DECL_EXPLICIT_DNA_YAML
|
2017-08-06 07:15:42 +00:00
|
|
|
Value<float> x4_maxTranslationAcceleration[8];
|
|
|
|
Value<float> x24_translationFriction[8];
|
|
|
|
Value<float> x44_translationMaxSpeed[8];
|
2017-01-26 10:06:18 +00:00
|
|
|
Value<float> x64_;
|
|
|
|
Value<float> x68_;
|
|
|
|
Value<float> x6c_;
|
|
|
|
Value<float> x70_;
|
2017-10-08 02:58:13 +00:00
|
|
|
Value<float> x74_ballCameraAnglePerSecond;
|
|
|
|
Value<zeus::CVector3f> x78_ballCameraOffset;
|
|
|
|
Value<float> x84_ballCameraMinSpeedDistance;
|
|
|
|
Value<float> x88_ballCameraMaxSpeedDistance;
|
|
|
|
Value<float> x8c_ballCameraBackwardsDistance;
|
2017-01-26 10:06:18 +00:00
|
|
|
Value<float> x90_;
|
2017-10-10 03:50:48 +00:00
|
|
|
Value<float> x94_ballCameraSpringConstant;
|
2017-10-08 02:58:13 +00:00
|
|
|
Value<float> x98_ballCameraSpringMax;
|
2017-10-10 03:50:48 +00:00
|
|
|
Value<float> x9c_ballCameraSpringTardis;
|
|
|
|
Value<float> xa0_ballCameraCentroidSpringConstant;
|
2017-10-08 02:58:13 +00:00
|
|
|
Value<float> xa4_ballCameraCentroidSpringMax;
|
2017-10-10 03:50:48 +00:00
|
|
|
Value<float> xa8_ballCameraCentroidSpringTardis;
|
|
|
|
Value<float> xac_ballCameraCentroidDistanceSpringConstant;
|
2017-10-08 02:58:13 +00:00
|
|
|
Value<float> xb0_ballCameraCentroidDistanceSpringMax;
|
2017-10-10 03:50:48 +00:00
|
|
|
Value<float> xb4_ballCameraCentroidDistanceSpringTardis;
|
|
|
|
Value<float> xb8_ballCameraLookAtSpringConstant;
|
2017-10-08 02:58:13 +00:00
|
|
|
Value<float> xbc_ballCameraLookAtSpringMax;
|
2017-10-10 03:50:48 +00:00
|
|
|
Value<float> xc0_ballCameraLookAtSpringTardis;
|
2017-09-17 03:13:03 +00:00
|
|
|
Value<float> xc4_ballForwardBrakingAcceleration[8];
|
2017-09-12 05:51:17 +00:00
|
|
|
Value<float> xe4_ballGravity;
|
|
|
|
Value<float> xe8_ballWaterGravity;
|
2017-01-26 10:06:18 +00:00
|
|
|
float xec_ = 10000.f;
|
|
|
|
float xf0_ = 1000.f;
|
|
|
|
float xf4_ = 40000.f;
|
|
|
|
float xf8_ = 40000.f;
|
|
|
|
float xfc_ = 40000.f;
|
|
|
|
float x100_ = 40000.f;
|
|
|
|
float x104_ = 40000.f;
|
|
|
|
float x108_ = 40000.f;
|
|
|
|
float x10c_ = 10000.f;
|
|
|
|
float x110_ = 1000.f;
|
|
|
|
float x114_ = 40000.f;
|
|
|
|
float x118_ = 40000.f;
|
|
|
|
float x11c_ = 40000.f;
|
|
|
|
float x120_ = 40000.f;
|
|
|
|
float x124_ = 40000.f;
|
|
|
|
float x128_ = 40000.f;
|
2017-09-30 03:45:57 +00:00
|
|
|
float x12c_ballSlipFactor[8] = { 10000.f, 10000.f, 1000.f, 10000.f, 2000.f, 2000.f, 2000.f, 2000.f };
|
2017-01-26 10:06:18 +00:00
|
|
|
Value<float> x14c_;
|
|
|
|
Value<float> x150_;
|
|
|
|
Value<float> x158_;
|
|
|
|
Value<float> x154_;
|
|
|
|
Value<float> x15c_;
|
|
|
|
Value<float> x160_;
|
|
|
|
Value<float> x164_;
|
|
|
|
Value<float> x168_;
|
|
|
|
Value<float> x16c_;
|
2017-10-16 05:26:50 +00:00
|
|
|
Value<float> x170_conservativeDoorCamDistance;
|
2017-01-26 10:06:18 +00:00
|
|
|
Value<float> x174_;
|
2017-10-08 02:58:13 +00:00
|
|
|
Value<float> x178_ballCameraChaseElevation;
|
|
|
|
Value<float> x17c_ballCameraChaseDampenAngle;
|
|
|
|
Value<float> x180_ballCameraChaseDistance;
|
|
|
|
Value<float> x184_ballCameraChaseYawSpeed;
|
|
|
|
Value<float> x188_ballCameraChaseAnglePerSecond;
|
|
|
|
Value<zeus::CVector3f> x18c_ballCameraChaseLookAtOffset;
|
2017-10-10 03:50:48 +00:00
|
|
|
Value<float> x198_ballCameraChaseSpringConstant;
|
2017-10-08 02:58:13 +00:00
|
|
|
Value<float> x19c_ballCameraChaseSpringMax;
|
2017-10-10 03:50:48 +00:00
|
|
|
Value<float> x1a0_ballCameraChaseSpringTardis;
|
2017-10-08 02:58:13 +00:00
|
|
|
Value<float> x1a4_ballCameraBoostElevation;
|
|
|
|
Value<float> x1a8_ballCameraBoostDampenAngle;
|
|
|
|
Value<float> x1ac_ballCameraBoostDistance;
|
|
|
|
Value<float> x1b0_ballCameraBoostYawSpeed;
|
|
|
|
Value<float> x1b4_ballCameraBoostAnglePerSecond;
|
|
|
|
Value<zeus::CVector3f> x1b8_ballCameraBoostLookAtOffset;
|
2017-10-10 03:50:48 +00:00
|
|
|
Value<float> x1c4_ballCameraBoostSpringConstant;
|
2017-10-08 02:58:13 +00:00
|
|
|
Value<float> x1c8_ballCameraBoostSpringMax;
|
2017-10-10 03:50:48 +00:00
|
|
|
Value<float> x1cc_ballCameraBoostSpringTardis;
|
2017-07-16 06:13:37 +00:00
|
|
|
Value<float> x1d0_ballCameraControlDistance;
|
2017-01-26 10:06:18 +00:00
|
|
|
Value<float> x1d4_;
|
|
|
|
Value<float> x1d8_;
|
2017-09-21 05:10:18 +00:00
|
|
|
Value<float> x1dc_minimumAlignmentSpeed;
|
2017-09-30 03:45:57 +00:00
|
|
|
Value<float> x1e0_tireness;
|
2017-09-17 03:13:03 +00:00
|
|
|
Value<float> x1ec_maxLeanAngle;
|
|
|
|
Value<float> x1f0_tireToMarbleThresholdSpeed;
|
|
|
|
Value<float> x1f4_marbleToTireThresholdSpeed;
|
|
|
|
Value<float> x1f8_forceToLeanGain;
|
|
|
|
Value<float> x1fc_leanTrackingGain;
|
2017-07-16 06:13:37 +00:00
|
|
|
Value<float> x1e4_leftStickDivisor;
|
|
|
|
Value<float> x1e8_rightStickDivisor;
|
2017-01-26 10:06:18 +00:00
|
|
|
Value<float> x200_;
|
2017-09-11 02:18:49 +00:00
|
|
|
Value<float> x204_ballTouchRadius;
|
2017-01-26 10:06:18 +00:00
|
|
|
float x208_;
|
2017-09-17 03:13:03 +00:00
|
|
|
Value<float> x20c_boostBallDrainTime;
|
|
|
|
Value<float> x218_boostBallMinChargeTime;
|
2017-09-12 05:51:17 +00:00
|
|
|
Value<float> x21c_boostBallMinRelativeSpeedForDamage;
|
2017-09-21 05:10:18 +00:00
|
|
|
Value<float> x220_boostBallChargeTime0;
|
|
|
|
Value<float> x224_boostBallChargeTime1;
|
|
|
|
float x228_boostBallChargeTime2;
|
2017-09-17 03:13:03 +00:00
|
|
|
Value<float> x210_boostBallMaxChargeTime;
|
2017-09-21 05:10:18 +00:00
|
|
|
Value<float> x22c_boostBallIncrementalSpeed0;
|
|
|
|
Value<float> x230_boostBallIncrementalSpeed1;
|
|
|
|
Value<float> x234_boostBallIncrementalSpeed2;
|
2017-01-26 10:06:18 +00:00
|
|
|
|
|
|
|
CTweakBall()=default;
|
2017-01-27 02:58:21 +00:00
|
|
|
CTweakBall(athena::io::IStreamReader& r)
|
|
|
|
{
|
|
|
|
this->read(r);
|
2018-06-21 21:04:16 +00:00
|
|
|
x6c_ = -x6c_;
|
|
|
|
x70_ = -x70_;
|
2017-10-08 02:58:13 +00:00
|
|
|
x74_ballCameraAnglePerSecond = zeus::degToRad(x74_ballCameraAnglePerSecond);
|
2017-01-27 02:58:21 +00:00
|
|
|
x90_ = zeus::degToRad(x90_);
|
2018-06-21 21:04:16 +00:00
|
|
|
xe4_ballGravity = -xe4_ballGravity;
|
|
|
|
xe8_ballWaterGravity = -xe8_ballWaterGravity;
|
2017-01-27 02:58:21 +00:00
|
|
|
x15c_ = zeus::degToRad(x15c_);
|
|
|
|
x16c_ = zeus::degToRad(x16c_);
|
|
|
|
x174_ = zeus::degToRad(x174_);
|
2017-10-08 02:58:13 +00:00
|
|
|
x17c_ballCameraChaseDampenAngle = zeus::degToRad(x17c_ballCameraChaseDampenAngle);
|
|
|
|
x184_ballCameraChaseYawSpeed = zeus::degToRad(x184_ballCameraChaseYawSpeed);
|
|
|
|
x188_ballCameraChaseAnglePerSecond = zeus::degToRad(x188_ballCameraChaseAnglePerSecond);
|
|
|
|
x1a8_ballCameraBoostDampenAngle = zeus::degToRad(x1a8_ballCameraBoostDampenAngle);
|
|
|
|
x1b0_ballCameraBoostYawSpeed = zeus::degToRad(x1b0_ballCameraBoostYawSpeed);
|
|
|
|
x1b4_ballCameraBoostAnglePerSecond = zeus::degToRad(x1b4_ballCameraBoostAnglePerSecond);
|
2017-09-17 03:13:03 +00:00
|
|
|
x1ec_maxLeanAngle = zeus::degToRad(x1ec_maxLeanAngle);
|
2017-01-27 02:58:21 +00:00
|
|
|
}
|
2017-07-16 06:13:37 +00:00
|
|
|
|
2017-08-06 07:15:42 +00:00
|
|
|
float GetMaxBallTranslationAcceleration(int s) const { return x4_maxTranslationAcceleration[s]; }
|
|
|
|
float GetBallTranslationFriction(int s) const { return x24_translationFriction[s]; }
|
|
|
|
float GetBallTranslationMaxSpeed(int s) const { return x44_translationMaxSpeed[s]; }
|
2017-10-08 02:58:13 +00:00
|
|
|
float GetBallCameraElevation() const { return 2.736f; }
|
|
|
|
float GetBallCameraAnglePerSecond() const { return x74_ballCameraAnglePerSecond; }
|
|
|
|
const zeus::CVector3f& GetBallCameraOffset() const { return x78_ballCameraOffset; }
|
|
|
|
float GetBallCameraMinSpeedDistance() const { return x84_ballCameraMinSpeedDistance; }
|
|
|
|
float GetBallCameraMaxSpeedDistance() const { return x88_ballCameraMaxSpeedDistance; }
|
|
|
|
float GetBallCameraBackwardsDistance() const { return x8c_ballCameraBackwardsDistance; }
|
2017-10-10 03:50:48 +00:00
|
|
|
float GetBallCameraSpringConstant() const { return x94_ballCameraSpringConstant; }
|
2017-10-08 02:58:13 +00:00
|
|
|
float GetBallCameraSpringMax() const { return x98_ballCameraSpringMax; }
|
2017-10-10 03:50:48 +00:00
|
|
|
float GetBallCameraSpringTardis() const { return x9c_ballCameraSpringTardis; }
|
|
|
|
float GetBallCameraCentroidSpringConstant() const { return xa0_ballCameraCentroidSpringConstant; }
|
2017-10-08 02:58:13 +00:00
|
|
|
float GetBallCameraCentroidSpringMax() const { return xa4_ballCameraCentroidSpringMax; }
|
2017-10-10 03:50:48 +00:00
|
|
|
float GetBallCameraCentroidSpringTardis() const { return xa8_ballCameraCentroidSpringTardis; }
|
|
|
|
float GetBallCameraCentroidDistanceSpringConstant() const { return xac_ballCameraCentroidDistanceSpringConstant; }
|
2017-10-08 02:58:13 +00:00
|
|
|
float GetBallCameraCentroidDistanceSpringMax() const { return xb0_ballCameraCentroidDistanceSpringMax; }
|
2017-10-10 03:50:48 +00:00
|
|
|
float GetBallCameraCentroidDistanceSpringTardis() const { return xb4_ballCameraCentroidDistanceSpringTardis; }
|
|
|
|
float GetBallCameraLookAtSpringConstant() const { return xb8_ballCameraLookAtSpringConstant; }
|
2017-10-08 02:58:13 +00:00
|
|
|
float GetBallCameraLookAtSpringMax() const { return xbc_ballCameraLookAtSpringMax; }
|
2017-10-10 03:50:48 +00:00
|
|
|
float GetBallCameraLookAtSpringTardis() const { return xc0_ballCameraLookAtSpringTardis; }
|
2017-09-17 03:13:03 +00:00
|
|
|
float GetBallForwardBrakingAcceleration(int s) const { return xc4_ballForwardBrakingAcceleration[s]; }
|
2017-09-12 05:51:17 +00:00
|
|
|
float GetBallGravity() const { return xe4_ballGravity; }
|
|
|
|
float GetBallWaterGravity() const { return xe8_ballWaterGravity; }
|
2017-09-30 03:45:57 +00:00
|
|
|
float GetBallSlipFactor(int s) const { return x12c_ballSlipFactor[s]; }
|
2017-10-16 05:26:50 +00:00
|
|
|
float GetConservativeDoorCameraDistance() const { return x170_conservativeDoorCamDistance; }
|
2017-10-08 02:58:13 +00:00
|
|
|
float GetBallCameraChaseElevation() const { return x178_ballCameraChaseElevation; }
|
|
|
|
float GetBallCameraChaseDampenAngle() const { return x17c_ballCameraChaseDampenAngle; }
|
|
|
|
float GetBallCameraChaseDistance() const { return x180_ballCameraChaseDistance; }
|
|
|
|
float GetBallCameraChaseYawSpeed() const { return x184_ballCameraChaseYawSpeed; }
|
|
|
|
float GetBallCameraChaseAnglePerSecond() const { return x188_ballCameraChaseAnglePerSecond; }
|
|
|
|
const zeus::CVector3f& GetBallCameraChaseLookAtOffset() const { return x18c_ballCameraChaseLookAtOffset; }
|
2017-10-10 03:50:48 +00:00
|
|
|
float GetBallCameraChaseSpringConstant() const { return x198_ballCameraChaseSpringConstant; }
|
2017-10-08 02:58:13 +00:00
|
|
|
float GetBallCameraChaseSpringMax() const { return x19c_ballCameraChaseSpringMax; }
|
2017-10-10 03:50:48 +00:00
|
|
|
float GetBallCameraChaseSpringTardis() const { return x1a0_ballCameraChaseSpringTardis; }
|
2017-10-08 02:58:13 +00:00
|
|
|
float GetBallCameraBoostElevation() const { return x1a4_ballCameraBoostElevation; }
|
|
|
|
float GetBallCameraBoostDampenAngle() const { return x1a8_ballCameraBoostDampenAngle; }
|
|
|
|
float GetBallCameraBoostDistance() const { return x1ac_ballCameraBoostDistance; }
|
|
|
|
float GetBallCameraBoostYawSpeed() const { return x1b0_ballCameraBoostYawSpeed; }
|
|
|
|
float GetBallCameraBoostAnglePerSecond() const { return x1b4_ballCameraBoostAnglePerSecond; }
|
|
|
|
const zeus::CVector3f& GetBallCameraBoostLookAtOffset() const { return x1b8_ballCameraBoostLookAtOffset; }
|
2017-10-10 03:50:48 +00:00
|
|
|
float GetBallCameraBoostSpringConstant() const { return x1c4_ballCameraBoostSpringConstant; }
|
2017-10-08 02:58:13 +00:00
|
|
|
float GetBallCameraBoostSpringMax() const { return x1c8_ballCameraBoostSpringMax; }
|
2017-10-10 03:50:48 +00:00
|
|
|
float GetBallCameraBoostSpringTardis() const { return x1cc_ballCameraBoostSpringTardis; }
|
2017-10-08 02:58:13 +00:00
|
|
|
float GetBallCameraControlDistance() const { return x1d0_ballCameraControlDistance; }
|
2017-09-21 05:10:18 +00:00
|
|
|
float GetMinimumAlignmentSpeed() const { return x1dc_minimumAlignmentSpeed; }
|
2017-09-30 03:45:57 +00:00
|
|
|
float GetTireness() const { return x1e0_tireness; }
|
2017-09-17 03:13:03 +00:00
|
|
|
float GetMaxLeanAngle() const { return x1ec_maxLeanAngle; }
|
|
|
|
float GetTireToMarbleThresholdSpeed() const { return x1f0_tireToMarbleThresholdSpeed; }
|
|
|
|
float GetMarbleToTireThresholdSpeed() const { return x1f4_marbleToTireThresholdSpeed; }
|
|
|
|
float GetForceToLeanGain() const { return x1f8_forceToLeanGain; }
|
|
|
|
float GetLeanTrackingGain() const { return x1fc_leanTrackingGain; }
|
2017-07-16 06:13:37 +00:00
|
|
|
float GetLeftStickDivisor() const { return x1e4_leftStickDivisor; }
|
|
|
|
float GetRightStickDivisor() const { return x1e8_rightStickDivisor; }
|
2017-09-11 02:18:49 +00:00
|
|
|
float GetBallTouchRadius() const { return x204_ballTouchRadius; }
|
2017-09-17 03:13:03 +00:00
|
|
|
float GetBoostBallDrainTime() const { return x20c_boostBallDrainTime; }
|
|
|
|
float GetBoostBallMaxChargeTime() const { return x210_boostBallMaxChargeTime; }
|
|
|
|
float GetBoostBallMinChargeTime() const { return x218_boostBallMinChargeTime; }
|
2017-09-12 05:51:17 +00:00
|
|
|
float GetBoostBallMinRelativeSpeedForDamage() const { return x21c_boostBallMinRelativeSpeedForDamage; }
|
2017-09-21 05:10:18 +00:00
|
|
|
float GetBoostBallChargeTimeTable(int i) const
|
|
|
|
{
|
|
|
|
switch (i)
|
|
|
|
{
|
|
|
|
default:
|
|
|
|
case 0:
|
|
|
|
return x220_boostBallChargeTime0;
|
|
|
|
case 1:
|
|
|
|
return x224_boostBallChargeTime1;
|
|
|
|
case 2:
|
|
|
|
return x228_boostBallChargeTime2;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
float GetBoostBallIncrementalSpeedTable(int i) const
|
|
|
|
{
|
|
|
|
switch (i)
|
|
|
|
{
|
|
|
|
default:
|
|
|
|
case 0:
|
|
|
|
return x22c_boostBallIncrementalSpeed0;
|
|
|
|
case 1:
|
|
|
|
return x230_boostBallIncrementalSpeed1;
|
|
|
|
case 2:
|
|
|
|
return x234_boostBallIncrementalSpeed2;
|
|
|
|
}
|
|
|
|
}
|
2017-01-26 10:06:18 +00:00
|
|
|
};
|
|
|
|
}
|