Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Merge branch 'master' into master
- Loading branch information
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
|
|
@@ -489,7 +489,7 @@ class cAudioManager |
|
|
void PreloadMissionAudio(const char *name); /// ok |
|
|
void PreTerminateGameSpecificShutdown(); /// ok |
|
|
/// processX - main logic of adding new sounds |
|
|
void ProcessActiveQueues(); // todo |
|
|
void ProcessActiveQueues(); /// ok |
|
|
bool ProcessAirBrakes(cVehicleParams *params); /// ok |
|
|
void ProcessAirportScriptObject(uint8 sound); /// ok |
|
|
bool ProcessBoatEngine(cVehicleParams *params); /// ok |
|
|
@@ -544,7 +544,7 @@ class cAudioManager |
|
|
bool ProcessTrainNoise(cVehicleParams *params); /// ok |
|
|
void ProcessVehicle(CVehicle *vehicle); /// ok |
|
|
bool ProcessVehicleDoors(cVehicleParams *params); /// ok |
|
|
bool ProcessVehicleEngine(cVehicleParams *params); // todo |
|
|
void ProcessVehicleEngine(cVehicleParams *params); /// ok |
|
|
void ProcessVehicleHorn(cVehicleParams *params); /// ok |
|
|
void ProcessVehicleOneShots(void *); // todo |
|
|
bool ProcessVehicleReverseWarning(cVehicleParams *params); /// ok |
|
|
|
|
|
@@ -6,9 +6,6 @@ |
|
|
#include "Curves.h" |
|
|
#include "PathFind.h" |
|
|
|
|
|
#if 0 |
|
|
WRAPPER void CAutoPilot::ModifySpeed(float) { EAXJMP(0x4137B0); } |
|
|
#else |
|
|
void CAutoPilot::ModifySpeed(float speed) |
|
|
{ |
|
|
m_fMaxTrafficSpeed = max(0.01f, speed); |
|
|
@@ -41,7 +38,6 @@ void CAutoPilot::ModifySpeed(float speed) |
|
|
m_nTimeEnteredCurve = CTimer::GetTimeInMilliseconds() - positionBetweenNodes * m_nSpeedScaleFactor; |
|
|
#endif |
|
|
} |
|
|
#endif |
|
|
|
|
|
void CAutoPilot::RemoveOnePathNode() |
|
|
{ |
|
|
|
|
|
@@ -881,9 +881,7 @@ CCarCtrl::SlowCarOnRailsDownForTrafficAndLights(CVehicle* pVehicle) |
|
|
pVehicle->AutoPilot.ModifySpeed(max(maxSpeed, curSpeed - 0.5f * CTimer::GetTimeStep())); |
|
|
} |
|
|
} |
|
|
#if 0 |
|
|
WRAPPER void CCarCtrl::SlowCarDownForPedsSectorList(CPtrList&, CVehicle*, float, float, float, float, float*, float) { EAXJMP(0x419300); } |
|
|
#else |
|
|
|
|
|
void CCarCtrl::SlowCarDownForPedsSectorList(CPtrList& lst, CVehicle* pVehicle, float x_inf, float y_inf, float x_sup, float y_sup, float* pSpeed, float curSpeed) |
|
|
{ |
|
|
float frontOffset = pVehicle->GetModelInfo()->GetColModel()->boundingBox.max.y; |
|
|
@@ -991,7 +989,6 @@ void CCarCtrl::SlowCarDownForPedsSectorList(CPtrList& lst, CVehicle* pVehicle, f |
|
|
} |
|
|
} |
|
|
} |
|
|
#endif |
|
|
|
|
|
void CCarCtrl::SlowCarDownForCarsSectorList(CPtrList& lst, CVehicle* pVehicle, float x_inf, float y_inf, float x_sup, float y_sup, float* pSpeed, float curSpeed) |
|
|
{ |
|
|
@@ -1055,9 +1052,6 @@ void CCarCtrl::SlowCarDownForOtherCar(CEntity* pOtherEntity, CVehicle* pVehicle, |
|
|
} |
|
|
} |
|
|
|
|
|
#if 0 |
|
|
WRAPPER float CCarCtrl::TestCollisionBetween2MovingRects(CVehicle* pVehicleA, CVehicle* pVehicleB, float projectionX, float projectionY, CVector* pForwardA, CVector* pForwardB, uint8 id) { EAXJMP(0x41A020); } |
|
|
#else |
|
|
float CCarCtrl::TestCollisionBetween2MovingRects(CVehicle* pVehicleA, CVehicle* pVehicleB, float projectionX, float projectionY, CVector* pForwardA, CVector* pForwardB, uint8 id) |
|
|
{ |
|
|
CVector2D vecBToA = pVehicleA->GetPosition() - pVehicleB->GetPosition(); |
|
|
@@ -1180,7 +1174,6 @@ float CCarCtrl::TestCollisionBetween2MovingRects(CVehicle* pVehicleA, CVehicle* |
|
|
} |
|
|
return proximity; |
|
|
} |
|
|
#endif |
|
|
|
|
|
float CCarCtrl::FindAngleToWeaveThroughTraffic(CVehicle* pVehicle, CPhysical* pTarget, float angleToTarget, float angleForward) |
|
|
{ |
|
|
|
|
|
@@ -2,9 +2,6 @@ |
|
|
#include "patcher.h" |
|
|
#include "Curves.h" |
|
|
|
|
|
#if 0 |
|
|
WRAPPER float CCurves::CalcSpeedScaleFactor(CVector*, CVector*, float, float, float, float) { EAXJMP(0x420410); } |
|
|
#else |
|
|
float CCurves::CalcSpeedScaleFactor(CVector* pPoint1, CVector* pPoint2, float dir1X, float dir1Y, float dir2X, float dir2Y) |
|
|
{ |
|
|
CVector2D dir1(dir1X, dir1Y); |
|
|
@@ -16,11 +13,7 @@ float CCurves::CalcSpeedScaleFactor(CVector* pPoint1, CVector* pPoint2, float di |
|
|
else |
|
|
return ((1.0f - dp) * 0.2f + 1.0f) * distance; |
|
|
} |
|
|
#endif |
|
|
|
|
|
#if 0 |
|
|
WRAPPER void CCurves::CalcCurvePoint(CVector*, CVector*, CVector*, CVector*, float, int32, CVector*, CVector*) { EAXJMP(0x4204D0); } |
|
|
#else |
|
|
void CCurves::CalcCurvePoint(CVector* pPos1, CVector* pPos2, CVector* pDir1, CVector* pDir2, float between, int32 timeOnCurve, CVector* pOutPos, CVector* pOutDir) |
|
|
{ |
|
|
float actualFactor = CalcSpeedScaleFactor(pPos1, pPos2, pDir1->x, pDir1->y, pDir2->x, pDir2->y); |
|
|
@@ -35,5 +28,4 @@ void CCurves::CalcCurvePoint(CVector* pPos1, CVector* pPos2, CVector* pDir1, CVe |
|
|
(dir1.x * (1.0f - curveCoef) + dir2.x * curveCoef) / (timeOnCurve * 0.001f), |
|
|
(dir1.y * (1.0f - curveCoef) + dir2.y * curveCoef) / (timeOnCurve * 0.001f), |
|
|
0.0f); |
|
|
} |
|
|
#endif
|
|
|
}
|
|
|
@@ -162,9 +162,6 @@ CDarkel::ReadStatus() |
|
|
return Status; |
|
|
} |
|
|
|
|
|
#if 0 |
|
|
WRAPPER void CDarkel::RegisterCarBlownUpByPlayer(CVehicle *vehicle) { EAXJMP(0x421070); } |
|
|
#else |
|
|
void |
|
|
CDarkel::RegisterCarBlownUpByPlayer(CVehicle *vehicle) |
|
|
{ |
|
|
@@ -178,11 +175,7 @@ CDarkel::RegisterCarBlownUpByPlayer(CVehicle *vehicle) |
|
|
RegisteredKills[vehicle->GetModelIndex()]++; |
|
|
CStats::CarsExploded++; |
|
|
} |
|
|
#endif |
|
|
|
|
|
#if 0 |
|
|
WRAPPER void CDarkel::RegisterKillByPlayer(CPed *victim, eWeaponType weapontype, bool headshot) { EAXJMP(0x420F60); } |
|
|
#else |
|
|
void |
|
|
CDarkel::RegisterKillByPlayer(CPed *victim, eWeaponType weapon, bool headshot) |
|
|
{ |
|
|
@@ -207,7 +200,6 @@ CDarkel::RegisterKillByPlayer(CPed *victim, eWeaponType weapon, bool headshot) |
|
|
CStats::HeadsPopped++; |
|
|
CStats::KillsSinceLastCheckpoint++; |
|
|
} |
|
|
#endif |
|
|
|
|
|
void |
|
|
CDarkel::RegisterKillNotByPlayer(CPed* victim, eWeaponType weapontype) |
|
|
@@ -222,9 +214,6 @@ CDarkel::ResetModelsKilledByPlayer() |
|
|
RegisteredKills[i] = 0; |
|
|
} |
|
|
|
|
|
#if 0 |
|
|
WRAPPER void CDarkel::ResetOnPlayerDeath() { EAXJMP(0x420E70); } |
|
|
#else |
|
|
void |
|
|
CDarkel::ResetOnPlayerDeath() |
|
|
{ |
|
|
@@ -253,11 +242,7 @@ CDarkel::ResetOnPlayerDeath() |
|
|
player->MakeChangesForNewWeapon(player->m_currentWeapon); |
|
|
} |
|
|
} |
|
|
#endif |
|
|
|
|
|
#if 0 |
|
|
WRAPPER void CDarkel::StartFrenzy(eWeaponType weaponType, int32 time, uint16 kill, int32 modelId0, wchar *text, int32 modelId2, int32 modelId3, int32 modelId4, bool standardSound, bool needHeadShot) { EAXJMP(0x4210E0); } |
|
|
#else |
|
|
void |
|
|
CDarkel::StartFrenzy(eWeaponType weaponType, int32 time, uint16 kill, int32 modelId0, wchar *text, int32 modelId2, int32 modelId3, int32 modelId4, bool standardSound, bool needHeadShot) |
|
|
{ |
|
|
@@ -306,7 +291,6 @@ CDarkel::StartFrenzy(eWeaponType weaponType, int32 time, uint16 kill, int32 mode |
|
|
if (CDarkel::bStandardSoundAndMessages) |
|
|
DMAudio.PlayFrontEndSound(SOUND_RAMPAGE_START, 0); |
|
|
} |
|
|
#endif |
|
|
|
|
|
void |
|
|
CDarkel::Update() |
|
|
|
Oops, something went wrong.