summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/core/ColStore.cpp1
-rw-r--r--src/core/SurfaceTable.cpp8
-rw-r--r--src/core/SurfaceTable.h1
-rw-r--r--src/entities/Entity.cpp2
-rw-r--r--src/render/Shadows.cpp2
-rw-r--r--src/render/Shadows.h2
-rw-r--r--src/vehicles/Bike.cpp11
7 files changed, 16 insertions, 11 deletions
diff --git a/src/core/ColStore.cpp b/src/core/ColStore.cpp
index 070967e5..bca1e9b7 100644
--- a/src/core/ColStore.cpp
+++ b/src/core/ColStore.cpp
@@ -223,7 +223,6 @@ CColStore::EnsureCollisionIsInMemory(const CVector2D &pos)
}
}
-//--MIAMI: done
bool
CColStore::HasCollisionLoaded(const CVector2D &pos)
{
diff --git a/src/core/SurfaceTable.cpp b/src/core/SurfaceTable.cpp
index 9076a9a6..56cea203 100644
--- a/src/core/SurfaceTable.cpp
+++ b/src/core/SurfaceTable.cpp
@@ -6,6 +6,8 @@
#include "Collision.h"
#include "SurfaceTable.h"
+//--MIAMI: file done
+
float CSurfaceTable::ms_aAdhesiveLimitTable[NUMADHESIVEGROUPS][NUMADHESIVEGROUPS];
void
@@ -148,3 +150,9 @@ CSurfaceTable::GetAdhesiveLimit(CColPoint &colpoint)
{
return ms_aAdhesiveLimitTable[GetAdhesionGroup(colpoint.surfaceB)][GetAdhesionGroup(colpoint.surfaceA)];
}
+
+bool
+CSurfaceTable::IsSoftLanding(uint8 surf)
+{
+ return surf == SURFACE_GRASS || surf == SURFACE_SAND || surf == SURFACE_SAND_BEACH;
+}
diff --git a/src/core/SurfaceTable.h b/src/core/SurfaceTable.h
index 359ebd5c..cd08c843 100644
--- a/src/core/SurfaceTable.h
+++ b/src/core/SurfaceTable.h
@@ -96,4 +96,5 @@ public:
static int GetAdhesionGroup(uint8 surfaceType);
static float GetWetMultiplier(uint8 surfaceType);
static float GetAdhesiveLimit(CColPoint &colpoint);
+ static bool IsSoftLanding(uint8 surf);
};
diff --git a/src/entities/Entity.cpp b/src/entities/Entity.cpp
index b27284bc..cf1dd9e7 100644
--- a/src/entities/Entity.cpp
+++ b/src/entities/Entity.cpp
@@ -33,7 +33,7 @@
#include "WindModifiers.h"
#include "Occlusion.h"
-//--MIAMI: file almost done (see TODO)
+//--MIAMI: file done
int gBuildings;
diff --git a/src/render/Shadows.cpp b/src/render/Shadows.cpp
index 5bb6a734..a964ceb6 100644
--- a/src/render/Shadows.cpp
+++ b/src/render/Shadows.cpp
@@ -715,7 +715,7 @@ CShadows::StoreShadowForVehicle(CVehicle *pCar, VEH_SHD_TYPE type)
}
void
-CShadows::StoreCarLightShadow(CAutomobile *pCar, int32 nID, RwTexture *pTexture, CVector *pPosn,
+CShadows::StoreCarLightShadow(CVehicle *pCar, int32 nID, RwTexture *pTexture, CVector *pPosn,
float fFrontX, float fFrontY, float fSideX, float fSideY, uint8 nRed, uint8 nGreen, uint8 nBlue,
float fMaxViewAngle)
{
diff --git a/src/render/Shadows.h b/src/render/Shadows.h
index 94b2981f..937ff4eb 100644
--- a/src/render/Shadows.h
+++ b/src/render/Shadows.h
@@ -159,7 +159,7 @@ public:
static void StoreShadowToBeRendered ( uint8 ShadowType, CVector *pPosn, float fFrontX, float fFrontY, float fSideX, float fSideY, int16 nIntensity, uint8 nRed, uint8 nGreen, uint8 nBlue);
static void StoreShadowToBeRendered ( uint8 ShadowType, RwTexture *pTexture, CVector *pPosn, float fFrontX, float fFrontY, float fSideX, float fSideY, int16 nIntensity, uint8 nRed, uint8 nGreen, uint8 nBlue, float fZDistance, bool bDrawOnWater, float fScale, CCutsceneShadow *pShadow, bool bDrawOnBuildings);
static void StoreShadowForVehicle (CVehicle *pCar, VEH_SHD_TYPE type);
- static void StoreCarLightShadow (CAutomobile *pCar, int32 nID, RwTexture *pTexture, CVector *pPosn, float fFrontX, float fFrontY, float fSideX, float fSideY, uint8 nRed, uint8 nGreen, uint8 nBlue, float fMaxViewAngle);
+ static void StoreCarLightShadow (CVehicle *pCar, int32 nID, RwTexture *pTexture, CVector *pPosn, float fFrontX, float fFrontY, float fSideX, float fSideY, uint8 nRed, uint8 nGreen, uint8 nBlue, float fMaxViewAngle);
static void StoreShadowForPed (CPed *pPed, float fDisplacementX, float fDisplacementY, float fFrontX, float fFrontY, float fSideX, float fSideY);
static void StoreShadowForPedObject (CEntity *pPedObject, float fDisplacementX, float fDisplacementY, float fFrontX, float fFrontY, float fSideX, float fSideY);
static void StoreShadowForCutscenePedObject(CCutsceneObject *pObject, float fDisplacementX, float fDisplacementY, float fFrontX, float fFrontY, float fSideX, float fSideY);
diff --git a/src/vehicles/Bike.cpp b/src/vehicles/Bike.cpp
index c32e72bc..760a8ec6 100644
--- a/src/vehicles/Bike.cpp
+++ b/src/vehicles/Bike.cpp
@@ -1448,16 +1448,13 @@ CBike::PreRender(void)
fwd.Normalise();
float f = headLightPos.y + 6.0f;
pos += CVector(f*fwd.x, f*fwd.y, 2.0f);
-
-// TODO(MIAMI):
-// CShadows::StoreCarLightShadow(this, (uintptr)this + 22, gpShadowExplosionTex, &pos,
-// 7.0f*fwd.x, 7.0f*fwd.y, 3.5f*fwd.y, -3.5f*fwd.x, 45, 45, 45, 7.0f);
+ CShadows::StoreCarLightShadow(this, (uintptr)this + 22, gpShadowExplosionTex, &pos,
+ 7.0f*fwd.x, 7.0f*fwd.y, 3.5f*fwd.y, -3.5f*fwd.x, 45, 45, 45, 7.0f);
f = (tailLightPos.y - 2.5f) - (headLightPos.y + 6.0f);
pos += CVector(f*fwd.x, f*fwd.y, 0.0f);
-// TODO(MIAMI):
-// CShadows::StoreCarLightShadow(this, (uintptr)this + 25, gpShadowExplosionTex, &pos,
-// 3.0f, 0.0f, 0.0f, -3.0f, 35, 0, 0, 4.0f);
+ CShadows::StoreCarLightShadow(this, (uintptr)this + 25, gpShadowExplosionTex, &pos,
+ 3.0f, 0.0f, 0.0f, -3.0f, 35, 0, 0, 4.0f);
}
if(this == FindPlayerVehicle() && !alarmOff){