summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/control/Darkel.cpp2
-rw-r--r--src/core/Streaming.cpp2
-rw-r--r--src/skel/glfw/glfw.cpp3
-rw-r--r--src/vehicles/Cranes.cpp10
4 files changed, 6 insertions, 11 deletions
diff --git a/src/control/Darkel.cpp b/src/control/Darkel.cpp
index 13c49c99..e44cdda9 100644
--- a/src/control/Darkel.cpp
+++ b/src/control/Darkel.cpp
@@ -391,7 +391,7 @@ CDarkel::DealWithWeaponChangeAtEndOfFrenzy()
CPlayerPed* player = FindPlayerPed();
if (fixedWeapon < WEAPONTYPE_TOTALWEAPONS) {
- player->m_nSelectedWepSlot = InterruptedWeaponType;
+ player->m_nSelectedWepSlot = CWeaponInfo::GetWeaponInfo((eWeaponType)InterruptedWeaponSelected)->m_nWeaponSlot;
player->GiveWeapon((eWeaponType)InterruptedWeaponType, AmmoInterruptedWeapon, true);
}
diff --git a/src/core/Streaming.cpp b/src/core/Streaming.cpp
index ddde4664..40d4acee 100644
--- a/src/core/Streaming.cpp
+++ b/src/core/Streaming.cpp
@@ -903,7 +903,7 @@ CStreaming::RequestSpecialModel(int32 modelId, const char *modelName, int32 flag
int i, n;
mi = CModelInfo::GetModelInfo(modelId);
- if(!CGeneral::faststrcmp("CSPlay", modelName)){
+ if(strncasecmp("CSPlay", modelName, 6) == 0){
char *curname = CModelInfo::GetModelInfo(MI_PLAYER)->GetName();
for(int i = 0; CSnames[i][0]; i++){
if(strcasecmp(curname, IGnames[i]) == 0){
diff --git a/src/skel/glfw/glfw.cpp b/src/skel/glfw/glfw.cpp
index 319b7bb0..a613fff0 100644
--- a/src/skel/glfw/glfw.cpp
+++ b/src/skel/glfw/glfw.cpp
@@ -859,7 +859,8 @@ bool IsThisJoystickBlacklisted(int i)
const char* joyname = glfwGetJoystickName(i);
- if (strncmp(joyname, gSelectedJoystickName, strlen(gSelectedJoystickName)) == 0)
+ if (gSelectedJoystickName[0] != '\0' &&
+ strncmp(joyname, gSelectedJoystickName, strlen(gSelectedJoystickName)) == 0)
return false;
return true;
diff --git a/src/vehicles/Cranes.cpp b/src/vehicles/Cranes.cpp
index 1ab31574..2a571a67 100644
--- a/src/vehicles/Cranes.cpp
+++ b/src/vehicles/Cranes.cpp
@@ -12,6 +12,8 @@
#include "Object.h"
#include "World.h"
+// --MIAMI: file done
+
#define MAX_DISTANCE_TO_FIND_CRANE (10.0f)
#define CRANE_UPDATE_RADIUS (300.0f)
#define CRANE_MOVEMENT_PROCESSING_RADIUS (150.0f)
@@ -259,7 +261,6 @@ void CCrane::Update(void)
m_pVehiclePickedUp->bUsesCollision = false;
if (m_bIsCrusher)
m_pVehiclePickedUp->bCollisionProof = true;
- DMAudio.PlayOneShot(m_nAudioEntity, SOUND_CRANE_PICKUP, 0.0f);
}
}
}
@@ -439,8 +440,6 @@ bool CCrane::DoesCranePickUpThisCarType(uint32 mi)
mi != MI_TRASH &&
#ifdef FIX_BUGS
mi != MI_COACH &&
-#else
- mi != MI_BLISTA &&
#endif
mi != MI_SECURICA &&
mi != MI_BUS &&
@@ -657,11 +656,6 @@ void CCranes::Load(uint8* buf, uint32 size)
if (pCrane->m_pVehiclePickedUp != nil)
pCrane->m_pVehiclePickedUp = CPools::GetVehiclePool()->GetSlot((uintptr)pCrane->m_pVehiclePickedUp - 1);
}
- /*for (int i = 0; i < NUM_CRANES; i++) {
- aCranes[i].m_nAudioEntity = DMAudio.CreateEntity(AUDIOTYPE_CRANE, &aCranes[i]);
- if (aCranes[i].m_nAudioEntity != 0)
- DMAudio.SetEntityStatus(aCranes[i].m_nAudioEntity, 1);
- }*/
VALIDATESAVEBUF(size);
}