spaceeinstein Posted August 3, 2017 Share Posted August 3, 2017 (edited) Introduction Havana Outfit Fix is a modification for Grand Theft Auto: Vice City utilizing the CLEO Library. It checks for the misplacement of the Havana outfit pickup and repositions it to the correct location. After completing "Two Bit Hit", the Havana outfit pickup is created in a clothing shop in Little Havana. But doing "Cop Land" or "No Escape?" afterwards causes the game to misplace the pickup behind an invisible barrier. This can normally be avoided if those missions are completed before "Two Bit Hit" but with this mod you can complete the missions in whatever order you want without the pickup being misplaced. Installation Download the mod at GTAGarage. If you are unable to open SEHavana.rar, rename the file to SEHavana.zip. Download the mod from my website. Download CLEO for Vice City at http://cleo.li/. From the CLEO download, copy VC.CLEO.asi into Vice City's folder. If CLEO.asi already exists in the folder, you must delete that file. From this mod download, place the CLEO folder containing SEHavana.cs into Vice City's folder. This mod has been tested only on VC v1.00 US. Source Sanny Builder const STRUCT_BEGIN = 0x945D30 STRUCT_SIZE = 0x34 INDEX = 0@ TEMP_VAR = 1@ PICKUP_LOCATION = 2@ STRUCT_ELEMENT = 3@ PICKUP_AMMO = 4@ TEMP_FVAR = 5@ end var INDEX : int PICKUP_LOCATION : int STRUCT_ELEMENT : int PICKUP_AMMO : int end 0000: while true wait 250 if 048C: pickup_at -1024.5 -433.9 10.9 available_or_will_respawn then INDEX = 0 while if INDEX < 335 STRUCT_ELEMENT = INDEX STRUCT_ELEMENT *= STRUCT_SIZE STRUCT_ELEMENT += STRUCT_BEGIN // get pickup location PICKUP_LOCATION = STRUCT_ELEMENT 0A8D: TEMP_FVAR = read_memory PICKUP_LOCATION size 4 virtual_protect 0 if and TEMP_FVAR > -1025.0 TEMP_FVAR < -1024.0 then PICKUP_LOCATION += 4 0A8D: TEMP_FVAR = read_memory PICKUP_LOCATION size 4 virtual_protect 0 if and TEMP_FVAR > -434.0 TEMP_FVAR < -433.0 then PICKUP_LOCATION += 4 0A8D: TEMP_FVAR = read_memory PICKUP_LOCATION size 4 virtual_protect 0 if and TEMP_FVAR > 10.0 TEMP_FVAR < 11.0 then // get pickup ammo PICKUP_AMMO = STRUCT_ELEMENT PICKUP_AMMO += 0x18 0A8D: TEMP_VAR = read_memory PICKUP_AMMO size 4 virtual_protect 0 if TEMP_VAR == 5 then // set location PICKUP_LOCATION = STRUCT_ELEMENT 0A8C: write_memory PICKUP_LOCATION size 4 val -1025.2 virtual_protect 0 PICKUP_LOCATION += 4 0A8C: write_memory PICKUP_LOCATION size 4 val -429.2 virtual_protect 0 PICKUP_LOCATION += 4 0A8C: write_memory PICKUP_LOCATION size 4 val 10.8 virtual_protect 0 end end end end INDEX += 1 end end end GTA3Script LVAR_INT index, temp_var, pickup_location, struct_element, pickup_ammo LVAR_FLOAT temp_fvar NOP havana_loop: WAIT 250 IF IS_ANY_PICKUP_AT_COORDS -1024.5 -433.9 10.9 index = 0 WHILE index < 335 struct_element = index * 0x34 struct_element += 0x945D30 // get pickup location pickup_location = struct_element READ_MEMORY pickup_location 4 0 temp_fvar IF temp_fvar > -1025.0 AND temp_fvar < -1024.0 pickup_location += 4 READ_MEMORY pickup_location 4 0 temp_fvar IF temp_fvar > -434.0 AND temp_fvar < -433.0 pickup_location += 4 READ_MEMORY pickup_location 4 0 temp_fvar IF temp_fvar > 10.0 AND temp_fvar < 11.0 // get pickup ammo pickup_ammo = struct_element + 0x18 READ_MEMORY pickup_ammo 4 0 temp_var IF temp_var = 5 // set location pickup_location = struct_element WRITE_MEMORY pickup_location 4 -1025.2 0 pickup_location += 4 WRITE_MEMORY pickup_location 4 -429.2 0 pickup_location += 4 WRITE_MEMORY pickup_location 4 10.8 0 ENDIF ENDIF ENDIF ENDIF index += 1 ENDWHILE ENDIF GOTO havana_loop Edited June 9, 2018 by spaceeinstein Jinx., Blackbird88, Igor Bogdanoff and 16 others 19 Link to comment Share on other sites More sharing options...
Blackbird88 Posted August 3, 2017 Share Posted August 3, 2017 Wow it actually works on existing save games! I guess you keep forcing the coords or something. Source please? Curious to see what you did. LaDiDa and Agem 2 Link to comment Share on other sites More sharing options...
Crspy Posted August 3, 2017 Share Posted August 3, 2017 (edited) Wow it actually works on existing save games! I guess you keep forcing the coords or something. Source please? Curious to see what you did. I guess it checks if the player passed these two missions then if Pickup was created then Destroy it and create another one in the correct position. ( since it's stored in one global variable after all ) Edited August 3, 2017 by Crspy Agem, Blackbird88 and LaDiDa 3 Link to comment Share on other sites More sharing options...
spaceeinstein Posted August 3, 2017 Author Share Posted August 3, 2017 (edited) That wouldn't work if you failed the missions, which also cause the pickups to be misplaced. Want to make another guess? Blackbird88's guess is closer. Edited August 3, 2017 by spaceeinstein Link to comment Share on other sites More sharing options...
Crspy Posted August 3, 2017 Share Posted August 3, 2017 That wouldn't work if you failed the missions, which also cause the pickups to be misplaced. Want to make another guess? Blackbird88's guess is closer. Okay another guess , Check if the pickup at the wrong position is available or will respawn (048C) , then destroy the pickup and create it in the correct position...... i presume that should work correctly ? Link to comment Share on other sites More sharing options...
Igor Bogdanoff Posted August 3, 2017 Share Posted August 3, 2017 is it done the same way as silent moved save in amdd dogg's house? Link to comment Share on other sites More sharing options...
gts. Posted August 3, 2017 Share Posted August 3, 2017 Source please? Curious to see what you did. Yes. Sanny Builder and GTA3script, please. Link to comment Share on other sites More sharing options...
spaceeinstein Posted August 4, 2017 Author Share Posted August 4, 2017 (edited) I did use 048C to check for the pickup's existence at the location but I didn't delete and recreate the pickup. I went through all the pickups in the game to find the matching pickup and just changed its coordinates. I've updated my post with the source code. Edited August 4, 2017 by spaceeinstein Crspy, -Anti-, Blackbird88 and 4 others 7 Link to comment Share on other sites More sharing options...
Savannahpaige Posted June 3, 2018 Share Posted June 3, 2018 I just went threw over half the game, and did copland first before the others.. And i got the glitch! I was so glad to find a real fix.. Then i realized GTA Garage is still down after over a week.. Is there anywhere else to download this? Link to comment Share on other sites More sharing options...
Savannahpaige Posted June 3, 2018 Share Posted June 3, 2018 (edited) i found another link of this mod.. from a working site! Lolhttps://libertycity.net/files/gta-vice-city/112305-havana-outfit-fixkostjum-gavana-fiks.html Edited June 3, 2018 by Savannahpaige iAbokai 1 Link to comment Share on other sites More sharing options...
spaceeinstein Posted June 5, 2018 Author Share Posted June 5, 2018 (edited) Oh hey, I didn't give them permission to mirror my mod. Here's a link for the mod direct from me: http://spaceeinstein.altervista.org/mods/SEHavana.zip Edited June 5, 2018 by spaceeinstein ZT- 1 Link to comment Share on other sites More sharing options...
spartaque12 Posted June 6, 2018 Share Posted June 6, 2018 8 hours ago, spaceeinstein said: Oh hey, I didn't give them permission to mirror my mod. Here's a link for the mod direct from me: http://spaceeinstein.altervista.org/mods/SEHavana.zip they doesnt care about any permissions , its libertycity Dominik_ 1 Link to comment Share on other sites More sharing options...
NanoBarAr Posted April 20, 2019 Share Posted April 20, 2019 Hey man i just downloaded this and installed it just as it says, but it doesn't seem to be working I checked CLEO's log in the game files and it appears to be detecting it and applying it(?) but the glitch is still there. I'm using the steam version (with silent's patch to make it playable) so that may be the problem, but still, can you help me in anyway? Link to comment Share on other sites More sharing options...
NanoBarAr Posted April 28, 2019 Share Posted April 28, 2019 On 4/20/2019 at 1:36 AM, NanoBarAr said: Hey man i just downloaded this and installed it just as it says, but it doesn't seem to be working I checked CLEO's log in the game files and it appears to be detecting it and applying it(?) but the glitch is still there. I'm using the steam version (with silent's patch to make it playable) so that may be the problem, but still, can you help me in anyway? Nevermind that, i just did this and it worked, you just have to run the testapp.exe instead of the steam executable for the mods to apply Link to comment Share on other sites More sharing options...
EyeballMaster3 Posted December 28, 2021 Share Posted December 28, 2021 This didn't work. I did everything correctly and it said that there was one script but 0 plugins loaded. Link to comment Share on other sites More sharing options...
strejda603 Posted July 23 Share Posted July 23 Thank you @spaceeinstein for the source code! I'm trying to convert this code into universal function for CLEO Redux (which with I could then move any pickup from its original location to somewhere else)... Right now I ended up with this code: /** * @param {obj} oPos * @param {obj} nPos * @returns {Pickup} */ function movePickup(oPos, nPos) { let index = 0; // @0 while (index < 335) { let element = index * 0x34; // STRUCT_ELEMENT @3 element += 0x945d30; // STRUCT_BEGIN CPickupVC let loc = element; // @2 let pickup_ammo = element + 0x18; // @4 // let temp_fval = Memory.Read(loc, 4, false); // @5 let pos = { x: Memory.Read(loc, 4, false), y: Memory.Read(loc + 4, 4, false), z: Memory.Read(loc + 8, 4, false), }; let temp_val = Memory.Read(pickup_ammo, 4, false); // @1 - Where TF you belong?! if ( pos.x < oPos.x + 1.0 && pos.x > oPos.x - 1.0 && pos.y < oPos.y + 1.0 && pos.y > oPos.y - 1.0 && pos.z < oPos.z + 1.0 && pos.z > oPos.z - 1.0 ) { Memory.Write(loc, 4, nPos.x, false); Memory.Write(loc + 4, 4, nPos.y, false); Memory.Write(loc + 8, 4, nPos.z, false); } index++; } } ... but I have no idea, where I should put the "pickup_ammo" variable (or if I even need to use it, if I want to move i.g. save marker location).. Does anyone have some idea? Thank you. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now