From f8d4dabdacb54e1898ca35c033920985c4f2a6a3 Mon Sep 17 00:00:00 2001 From: Silent Date: Sun, 22 Sep 2024 14:18:39 +0200 Subject: [PATCH] VC: Update DrawBackfaces, allow the tear gas to damage anyone (including the player), like on PS2 --- Config/SilentPatchVC.ini | 31 +++++++++++++++++++++++++++++++ SilentPatchVC/SilentPatchVC.cpp | 11 +++++++++++ 2 files changed, 42 insertions(+) diff --git a/Config/SilentPatchVC.ini b/Config/SilentPatchVC.ini index 084c3b3..6569f0a 100644 --- a/Config/SilentPatchVC.ini +++ b/Config/SilentPatchVC.ini @@ -31,12 +31,15 @@ ap_hookerinn1 ap_roadsigns1_02 ap_stairsout04 basketballcourt05 +bb_pooltable1_01 +biker_bar_exterior bikeshop_glass2 BillBd04 BillBd1 BillBd2 BillBd3 bodyarmour +carsontrack car_fucko03 chairsntable chairsntableml @@ -57,9 +60,22 @@ cl_tbl_chait_tmpb cl_yachtmdl cof_bardetail cof_extwindw +concerth06 +concerth07 +concerth08 +concerth10 +concerth12 +concerth27 +concerth29 +concerth56 cop_mainroom deco_polbuild deli_exterior_front +destruct03 +destruct04 +destruct05 +destruct1 +destruct2 doc_crane_cab04 doontoon54 doontoon65 @@ -81,10 +97,21 @@ haiticar10 haiticar12 haiticar13 hav_car_show_out2 +hogans_alley +hogans_alley_b hospital hot_room317 hot_trans1 +instruments kb_chr_tbl_test +kickbannerstart01 +kickbus03 +kickcar06 +kickcar17 +kickcar23 +kickcar28 +kickcar3 +kickcar36 lampost_coast lamppost1 lamppost2 @@ -98,6 +125,8 @@ lh_icecream02 lh_philsint lh_pizzaplace litharoada3 +loopbig +looplop2 lw_lights lw_roombitsb mall_ammu @@ -139,6 +168,8 @@ od_lightbeam od_lightext od_lightint od_wtlegs +plank1 +plankk2 pot_02 pw_priint RoosbrgeStart_r_dt diff --git a/SilentPatchVC/SilentPatchVC.cpp b/SilentPatchVC/SilentPatchVC.cpp index 8d956d3..5a8d73e 100644 --- a/SilentPatchVC/SilentPatchVC.cpp +++ b/SilentPatchVC/SilentPatchVC.cpp @@ -1952,6 +1952,7 @@ void Patch_VC_Common() // Fix the screwdriver not making sounds on impact + try { void** pedAttackJumpTable = *get_pattern("83 F8 05 77 77 FF 24 85", 5 + 3); // Only make changes if the table hasn't been relocated @@ -1961,6 +1962,16 @@ void Patch_VC_Common() pedAttackJumpTable[1] = pedAttackJumpTable[2]; } } + TXN_CATCH(); + + + // Allow the tear gas to damage anyone (including the player), like on PS2 + try + { + auto set_peds_choking = get_pattern("0F 84 ? ? ? ? 8D 4B 34 D9 41 08"); + Nop(set_peds_choking, 6); + } + TXN_CATCH(); } BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)