Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/src/core/Cam.cpp b/src/core/Cam.cpp
- index 72e8ad93..84abffc6 100644
- --- a/src/core/Cam.cpp
- +++ b/src/core/Cam.cpp
- @@ -944,7 +944,7 @@ CCam::Using3rdPersonMouseCam(void)
- #ifdef FIRST_PERSON
- return CCamera::m_bUseMouse3rdPerson && (Mode == MODE_FOLLOWPED || Mode == MODE_REAL_1ST_PERSON);
- #else
- - return CCamera::m_bUseMouse3rdPerson && Mode == MODE_FOLLOWPED);
- + return CCamera::m_bUseMouse3rdPerson && Mode == MODE_FOLLOWPED;
- #endif
- }
- diff --git a/src/core/FileLoader.cpp b/src/core/FileLoader.cpp
- index d8d328d9..7c9fa15d 100644
- --- a/src/core/FileLoader.cpp
- +++ b/src/core/FileLoader.cpp
- @@ -587,7 +587,7 @@ CFileLoader::AddTexDictionaries(RwTexDictionary *dst, RwTexDictionary *src)
- #define isLine3(l, a, b, c) ((l[0] == a) && (l[1] == b) && (l[2] == c))
- #define isLine4(l, a, b, c, d) ((l[0] == a) && (l[1] == b) && (l[2] == c) && (l[3] == d))
- -
- +#define isLine6(l, a, b, c, d, e, f) ((l[0] == a) && (l[1] == b) && (l[2] == c) && (l[3] == d) && (l[4] == e) && (l[5] == f))
- void
- CFileLoader::LoadObjectTypes(const char *filename)
- {
- @@ -1151,7 +1151,7 @@ CFileLoader::LoadScene(const char *filename)
- else if(isLine4(line, 'p','a','t','h')) section = PATH;
- else if(isLine4(line, 'o','c','c','l')) section = OCCL;
- #ifdef WANTED_PATHS
- - else if (isLine4(line, 'w', 'a', 'n', 't', 'e', 'd')) section = WANTED;
- + else if (isLine6(line, 'w', 'a', 'n', 't', 'e', 'd')) section = WANTED;
- #endif
- }else if(isLine3(line, 'e','n','d')){
- section = NONE;
- diff --git a/src/core/Wanted.cpp b/src/core/Wanted.cpp
- index 0da632bb..7094dcf0 100644
- --- a/src/core/Wanted.cpp
- +++ b/src/core/Wanted.cpp
- @@ -471,19 +471,21 @@ CWanted::WorkOutPolicePresence(CVector posn, float radius)
- CEntity* hitEntity;
- if (FindPlayerPed()->bIsDucking) {
- - CWorld::ProcessLineOfSight(copHeadPos, playerHeadPos, CColPoint{}, hitEntity, true, true, false, false, false, true, true, true);
- + CColPoint ccolpoint{};
- + CWorld::ProcessLineOfSight(copHeadPos, playerHeadPos, ccolpoint, hitEntity, true, true, false, false, false, true, true, true);
- } else {
- bool bCheckVehicles = false;
- if (!FindPlayerVehicle()) {
- CEntity* hitEntity2;
- - if (CWorld::ProcessLineOfSight(copHeadPos, playerHeadPos, CColPoint{}, hitEntity2, true, true, false, false, false, true, true, true)) {
- + CColPoint ccolpoint{};
- + if (CWorld::ProcessLineOfSight(copHeadPos, playerHeadPos, ccolpoint, hitEntity2, true, true, false, false, false, true, true, true)) {
- CVehicle* hitVehicle = (CVehicle*)hitEntity2;
- if (hitVehicle && hitVehicle->IsHighVehicle())
- bCheckVehicles = true;
- }
- }
- -
- - CWorld::ProcessLineOfSight(copHeadPos, playerHeadPos, CColPoint{}, hitEntity, true, bCheckVehicles, false, false, false, true, true, true);
- + CColPoint ccolpoint{};
- + CWorld::ProcessLineOfSight(copHeadPos, playerHeadPos, ccolpoint, hitEntity, true, bCheckVehicles, false, false, false, true, true, true);
- }
- bool isCopSeesPlayer = angleOfSight < -0.25f && !hitEntity;
- @@ -544,19 +546,21 @@ CWanted::WorkOutPolicePresence(CVector posn, float radius)
- CEntity* hitEntity;
- if (FindPlayerPed()->bIsDucking) {
- - CWorld::ProcessLineOfSight(vehicle->GetPosition() + CVector(0.0f, 0.0f, 0.75f), playerHeadPos, CColPoint{}, hitEntity, true, true, false, false, false, true, true, true);
- + CColPoint ccolpoint{};
- + CWorld::ProcessLineOfSight(vehicle->GetPosition() + CVector(0.0f, 0.0f, 0.75f), playerHeadPos, ccolpoint, hitEntity, true, true, false, false, false, true, true, true);
- } else {
- bool bCheckVehicles = false;
- if (!FindPlayerVehicle()) {
- CEntity* hitEntity2;
- - if (CWorld::ProcessLineOfSight(vehicle->GetPosition() + CVector(0.0f, 0.0f, 0.75f), playerHeadPos, CColPoint{}, hitEntity2, true, true, false, false, false, true, true, true)) {
- + CColPoint ccolpoint{};
- + if (CWorld::ProcessLineOfSight(vehicle->GetPosition() + CVector(0.0f, 0.0f, 0.75f), playerHeadPos, ccolpoint, hitEntity2, true, true, false, false, false, true, true, true)) {
- CVehicle* hitVehicle = (CVehicle*)hitEntity2;
- if (hitVehicle && hitVehicle->IsHighVehicle())
- bCheckVehicles = true;
- }
- }
- -
- - CWorld::ProcessLineOfSight(vehicle->GetPosition() + CVector(0.0f, 0.0f, 0.75f), playerHeadPos, CColPoint{}, hitEntity, true, bCheckVehicles, false, false, false, true, true, true);
- + CColPoint ccolpoint{};
- + CWorld::ProcessLineOfSight(vehicle->GetPosition() + CVector(0.0f, 0.0f, 0.75f), playerHeadPos, ccolpoint, hitEntity, true, bCheckVehicles, false, false, false, true, true, true);
- }
- #ifdef DEBUG
- if (!hitEntity && !wanted->IsPlayerHides())
- diff --git a/src/core/config.h b/src/core/config.h
- index 758728ba..d1bd8fe3 100644
- --- a/src/core/config.h
- +++ b/src/core/config.h
- @@ -391,9 +391,9 @@ enum Config {
- //# define PS2_MENU_USEALLPAGEICONS
- #else
- # define MAP_ENHANCEMENTS // Adding waypoint and better mouse support
- -# if defined(XINPUT) || defined(GTA_HANDHELD)
- +//# if defined(XINPUT) || defined(GTA_HANDHELD)
- # define GAMEPAD_MENU // Add gamepad menu
- -# endif
- +//# endif
- //# define TRIANGLE_BACK_BUTTON
- # define CIRCLE_BACK_BUTTON
- #define LEGACY_MENU_OPTIONS // i.e. frame sync(vsync)
- diff --git a/src/peds/CopPed.cpp b/src/peds/CopPed.cpp
- index c905a56e..bac24700 100644
- --- a/src/peds/CopPed.cpp
- +++ b/src/peds/CopPed.cpp
- @@ -408,7 +408,7 @@ CCopPed::CopAI(void)
- if (m_bThrowingTeargas) {
- eWeaponType weapon = GetWeapon()->m_eWeaponType;
- - CWeaponInfo::GetWeaponInfo(weapon)->m_nWeaponSlot == WEAPONSLOT_PROJECTILE ? SetAttack(nil) : m_bThrowingTeargas = false;
- + if (CWeaponInfo::GetWeaponInfo(weapon)->m_nWeaponSlot == WEAPONSLOT_PROJECTILE) { SetAttack(nil); } else { m_bThrowingTeargas = false; }
- }
- #endif
- diff --git a/src/peds/Ped.cpp b/src/peds/Ped.cpp
- index 130c8f2a..d9e9c55d 100644
- --- a/src/peds/Ped.cpp
- +++ b/src/peds/Ped.cpp
- @@ -2044,25 +2044,25 @@ CPed::ProcessControl(void)
- }
- }
- - CVector ñurrentPedPosition = GetPosition();
- + CVector currentPedPosition = GetPosition();
- CVector distance;
- float speed;
- if (bIsClimbingHighJump || bIsClimbingIdle) {
- speed = highClimbingOffsetSpeed;
- - distance = newClimbingIdlePosition - ñurrentPedPosition;
- + distance = newClimbingIdlePosition - currentPedPosition;
- }
- else if (bIsClimbingPull) {
- speed = 1.3f;
- CVector newPedClimbingPullPosition = correctedClimbingStandPosition + CVector(0.0f, 0.0f, 0.5f);
- - distance = newPedClimbingPullPosition - ñurrentPedPosition;
- + distance = newPedClimbingPullPosition - currentPedPosition;
- }
- else if (bIsClimbingJumpB) {
- speed = 0.75f;
- - distance = newClimbingJumpBPosition - ñurrentPedPosition;
- + distance = newClimbingJumpBPosition - currentPedPosition;
- }
- else if (!bIsClimbingIdle) {
- speed = 1.5f;
- - distance = newClimbingPosition - ñurrentPedPosition;
- + distance = newClimbingPosition - currentPedPosition;
- }
- float distanceMagnitude = distance.Magnitude();
- @@ -2077,7 +2077,7 @@ CPed::ProcessControl(void)
- }
- CVector deltaNormal = distance / distanceMagnitude;
- - SetPosition(ñurrentPedPosition + deltaNormal * deltaSpeed);
- + SetPosition(currentPedPosition + deltaNormal * deltaSpeed);
- }
- else if (bIsClimbingIdle) {
- bUsesCollision = 1;
- @@ -10351,8 +10351,8 @@ bool CPed::CheckObjectFrontPlayer(CColPoint& hitForwardPoint)
- bool CPed::CheckObjectAbovePlayer(CColPoint& hitForwardPoint)
- {
- CEntity* hitEntity;
- -
- - bool isObjectAbovePlayer = CWorld::ProcessLineOfSight(GetPosition(), GetPosition() + CVector(0.0f, 0.0f, 2.75f), CColPoint{}, hitEntity, true, false, false, true, false, false);
- + //CColPoint ccolpoint {};
- + bool isObjectAbovePlayer = CWorld::ProcessLineOfSight(GetPosition(), GetPosition() + CVector(0.0f, 0.0f, 2.75f), hitForwardPoint, hitEntity, true, false, false, true, false, false);
- CEntity* hitObjectAbovePlayer1 = CWorld::TestSphereAgainstWorld(GetPosition() + CVector(0.0f, 0.0f, 1.0f), 0.25f, this, true, true, true, true, false, false);
- CEntity* hitObjectAbovePlayer2 = CWorld::TestSphereAgainstWorld(GetPosition() + CVector(0.0f, 0.0f, 1.25f), 0.25f, this, true, true, true, true, false, false);
- diff --git a/src/peds/PedAI.cpp b/src/peds/PedAI.cpp
- index bf30e99c..5f581254 100644
- --- a/src/peds/PedAI.cpp
- +++ b/src/peds/PedAI.cpp
- @@ -6657,7 +6657,8 @@ CPed::KillCharOnFootArmed(CVector &ourPos, CVector &targetPos, CVector &distWith
- #ifdef IMPROVED_TECH_PART // AI
- CEntity* hitEntity;
- - bool obstacle = CWorld::ProcessLineOfSight(m_pedInObjective->GetPosition(), GetPosition(), CColPoint{}, hitEntity, true, true, false, true, false, true);
- + CColPoint ccolpoint{};
- + bool obstacle = CWorld::ProcessLineOfSight(m_pedInObjective->GetPosition(), GetPosition(), ccolpoint, hitEntity, true, true, false, true, false, true);
- CVehicle* hitVehicle = (CVehicle*)hitEntity;
- bool bShootIsDangerous = hitVehicle && hitVehicle->IsHighVehicle();
- diff --git a/src/peds/PlayerPed.cpp b/src/peds/PlayerPed.cpp
- index bf1ca60c..258cb41e 100644
- --- a/src/peds/PlayerPed.cpp
- +++ b/src/peds/PlayerPed.cpp
- @@ -1795,7 +1795,8 @@ CPlayerPed::ProcessPlayerWeapon(CPad *padUsed)
- // first check
- CWorld::pIgnoreEntity = this;
- CEntity* hitEntityRaycast;
- - if (CWorld::ProcessLineOfSight(TheCamera.GetPosition(), TheCamera.GetPosition() + TheCamera.GetForward() * 20.0f, CColPoint{}, hitEntityRaycast, true, false, true, false, false, true)) {
- + CColPoint ccolpoint{};
- + if (CWorld::ProcessLineOfSight(TheCamera.GetPosition(), TheCamera.GetPosition() + TheCamera.GetForward() * 20.0f, ccolpoint, hitEntityRaycast, true, false, true, false, false, true)) {
- if (hitEntityRaycast->IsPed()) {
- CPed* hitPed = (CPed*)hitEntityRaycast;
- if ((hitPed->CanSeeEntity(this, DEGTORAD(80.0f)) && hitPed->m_nPedType != PEDTYPE_COP) ||
Advertisement
Add Comment
Please, Sign In to add comment