Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
    1. Welcome to GTAForums!

    1. GTANet.com

    1. GTA Online

      1. The Contract
      2. Updates
      3. Find Lobbies & Players
      4. Guides & Strategies
      5. Vehicles
      6. Content Creator
      7. Help & Support
    2. Red Dead Online

      1. Blood Money
      2. Frontier Pursuits
      3. Find Lobbies & Outlaws
      4. Help & Support
    3. Crews

    1. Grand Theft Auto Series

      1. Bugs*
      2. St. Andrews Cathedral
    2. GTA VI

    3. GTA V

      1. Guides & Strategies
      2. Help & Support
    4. GTA IV

      1. The Lost and Damned
      2. The Ballad of Gay Tony
      3. Guides & Strategies
      4. Help & Support
    5. GTA San Andreas

      1. Classic GTA SA
      2. Guides & Strategies
      3. Help & Support
    6. GTA Vice City

      1. Classic GTA VC
      2. Guides & Strategies
      3. Help & Support
    7. GTA III

      1. Classic GTA III
      2. Guides & Strategies
      3. Help & Support
    8. Portable Games

      1. GTA Chinatown Wars
      2. GTA Vice City Stories
      3. GTA Liberty City Stories
    9. Top-Down Games

      1. GTA Advance
      2. GTA 2
      3. GTA
    1. Red Dead Redemption 2

      1. PC
      2. Help & Support
    2. Red Dead Redemption

    1. GTA Mods

      1. GTA V
      2. GTA IV
      3. GTA III, VC & SA
      4. Tutorials
    2. Red Dead Mods

      1. Documentation
    3. Mod Showroom

      1. Scripts & Plugins
      2. Maps
      3. Total Conversions
      4. Vehicles
      5. Textures
      6. Characters
      7. Tools
      8. Other
      9. Workshop
    4. Featured Mods

      1. Design Your Own Mission
      2. OpenIV
      3. GTA: Underground
      4. GTA: Liberty City
      5. GTA: State of Liberty
    1. Rockstar Games

    2. Rockstar Collectors

    1. Off-Topic

      1. General Chat
      2. Gaming
      3. Technology
      4. Movies & TV
      5. Music
      6. Sports
      7. Vehicles
    2. Expression

      1. Graphics / Visual Arts
      2. GFX Requests & Tutorials
      3. Writers' Discussion
      4. Debates & Discussion
    1. Announcements

    2. Support

    3. Suggestions

Vice City Car Alarm


spaceeinstein
 Share

Recommended Posts

spaceeinstein

Introduction

In GTA III, car alarms have a distinct alarm sound but in GTA: Vice City car alarms are simply repeated horns of the car. This mod recreates GTA III's car alarms in Vice City. See the Settings section below if you want to customize the pitch of the alarm of any cars. In addition, when thunder is occurring, there is a chance that it will set off all car alarms for three seconds. The louder the thunder, the higher the chance. Debug mode can be toggled by typing "THUNDER". When enabled, the screen displays text with four values that are used to determine the trigger to set off car alarms during a thunderstorm. The values are the game time when thunder occurs, the lightning type, random number generator, and random number limit for the lightning type. This mod utilizes CLEO Library for Vice City.

 

Thanks to Victor_Knight for suggesting thunder-triggered alarms and Mr. Jago for suggesting using GTA 2's car alarm sound.

 

Installation

  • Download the mod at GTAGarage.
  • Download LithJoe's Audio Editor at http://www.gtagaming.com/downloads/gta-vice-city/tools/573.
  • In your Audio folder, make sure to remove the read-only option on sfx.SDT and sfx.RAW.
  • Run the editor and open sfx.SDT. Find sfx00052 and replace it with the audio supplied in the download.
  • 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 SEAlarm.cs and SEAlarm.dat into Vice City's folder.
This mod has been tested only on VC v.1.00 US. Please post any troubles you have with installation. This is my first mod release that involves editing the audio file.

 

Settings

The SEAlarm.dat file is a plain text file allowing you to change the pitch of the alarm for any vehicles. The file already contains the default pitch values from GTA III. Each line contains the vehicle's model index, which can be referenced from default.ide, and the pitch of the alarm. Vehicles that do not appear in the file will use the default pitch from the game. Vehicles that have a siren do not have an alarm so the pitch value changes the pitch of the siren instead. The default lines are:

 

 

130 9935131 9935132 10928133 9935134 8941135 11922138 8941139 12220140 9935141 9935143 13400144 9935145 13600148 8000149 9935150 8543151 9935152 9935154 9935158 9935159 10123161 10554162 8000163 9935166 9935167 7500168 9935169 8935170 8935171 17000172 9935173 9935174 9935175 9935178 9935179 9935185 9935186 9935187 9935188 9935189 13400191 9935192 9935193 9935196 9935197 9935198 9935200 7948201 9935204 9935205 9935206 9935207 9935208 9935209 9935210 9935211 9935212 9935213 9935215 9935216 9935219 9935221 9935222 9935224 9935225 9935226 9935228 9935229 9935230 9935232 9935233 9935234 9935235 9935

 

Locations

These are some of the locations of alarmed cars in the original game.

  • Admiral at Diaz's Mansion/Vercetti Estate
  • Banshee behind the Washington Beach Pay n Spray
  • Infernus in North Point Mall
  • Several random cars, four along Ocean Drive
Videos

 

 

 

Source

 

 

{$CLEO .cs}// change alarm05DF: write_memory 0x5F0457 size 1 value 0xB0 virtual_protect 1  // use siren sound instead of horn05DF: write_memory 0x5F046D size 1 value 0xB4 virtual_protect 1  // use siren pitch instead of horn05DF: write_memory 0x5F02F9 size 4 value 0 virtual_protect 1  // remove pause after each play05DF: write_memory 0x98410C size 4 value 4646 virtual_protect 1  // alarm sfx (id 52) sample loop end// alarm sfxconstSFX_INDEX = [email protected]_MEM = [email protected]_VAL = [email protected]_INDEX = 0while SFX_INDEX = #LANDSTAL            #VICECHEE >= PITCH_MEM        then            PITCH_MEM -= #LANDSTAL            PITCH_MEM *= 28            PITCH_MEM += 0x6AD1B4            05DF: write_memory PITCH_MEM size 4 value PITCH_FREQ virtual_protect 0        end    end    0A9B: closefile PITCH_DAT_FILEend

 

Edited by spaceeinstein
Link to comment
Share on other sites

Holy sh*t, a veteran came back into the modding!

Nice to see someone is making mods/scripts for older GTA.

  • Like 2
Link to comment
Share on other sites

Do you think III maybe handled it the same way you did?

 

 

Also, no love for VC CLEO 1.1.1.7? :(

Link to comment
Share on other sites

spaceeinstein

It's good to be back :)

 

The function that controls III's car alarm is very similar to VC. I think it's named cAudioManager::ProcessVehicleSirenOrAlarm. For III v1.0 it is located at 0x56C420, and for VC v1.0 it is located at 0x5F0240. The main differences for VC from III are the different SFX it chooses to play and a delay each time a SFX is played. There are other differences that I wasn't able to understand but just modifying those two is enough to produce the effect from III. I used 1.1.1.6 because I had always used that version for my CLEO mod releases. Is the newer version recommended over this version?

Link to comment
Share on other sites

Is the newer version recommended over this version?

Well, I fixed a notorious Load Game crash and also made VK keys test work somewhat properly.

Link to comment
Share on other sites

spaceeinstein

I've updated the mod to include CLEO v1.1.1.7.

  • Like 3
Link to comment
Share on other sites

Victor_Knight

If I may put my two cents in, is it possible to make alarm 'screaming' on several randomly choosed vehicles during a thunderstorm?

Edited by Victor_Knight
Link to comment
Share on other sites

spaceeinstein

That's a great idea. But I have no clue how thunder is handled or how alarms can be triggered.

Link to comment
Share on other sites

Blackbird88

Looks like that Alarm sound dates back to GTA1 where it even changed pitch randomly.

Link to comment
Share on other sites

spaceeinstein

I don't much about SA but others are free to use my code. The code for my mod is here.

Link to comment
Share on other sites

  • 1 month later...
  • 3 months later...
spaceeinstein

@inadequate, the mod should work with CLEO v1.1.1.7. Just don't copy the CLEO.asi file.

 

@Victor_Knight, would you like thunder-activated alarms to be released with this mod?

 

When thunder is occurring, there is a ~33% chance that it will set off all car alarms for three seconds.

Link to comment
Share on other sites

Looks awesome but I didn't hear the thunder, the alarm should be triggered by thunder, not lightning.

Link to comment
Share on other sites

@inadequate, the mod should work with CLEO v1.1.1.7. Just don't copy the CLEO.asi file.

 

Nope, doesn't work even only copying the script and the fxt file.

Link to comment
Share on other sites

spaceeinstein

@inadequate, does the mod work for the prior CLEO version? The mod relies a lot on using a specific main.scm. I'll try to get some time to rewrite the mod so that it doesn't rely on that file.

 

@Claude Liberty, thunder in the game is oftentimes faint to hear. My code in the video detects any thunder that occurs; it doesn't detect lightning. I have changed my code by doing away with the 33% chance and instead use the loudness of the thunder to determine the chance of setting off the alarm. The louder the thunder, the higher chance the alarm will set off.

  • Like 2
Link to comment
Share on other sites

Found a little thing that should help: I compared the car alarm sounds from GTA2 and GTA III and found that GTA2's (256 kbps) was higher quality than III's (158 kbps).

 

Here's a download with both of them clearly labeled so you can compare. It's not that big of a boost but it shouldn't be too much trouble to put in the mod and it should import fine. :)

Edited by Mr. Jago
Link to comment
Share on other sites

spaceeinstein

@Mr. Jago, thanks for the suggestion. It will be in the next update.

 

Something I want to ask you all, would you like hurricane weather to be disabled for this mod? Thunderstorms do not occur during hurricane weather, only regular rainy weather. Rainy weather occurs between the unlocking of the mainland and the final mission. Any other time only hurricane weather occurs.

Edited by spaceeinstein
Link to comment
Share on other sites

Not for the main release, as this starts to be too far fetched from the original concept. Though if it'd be separate, maybe...

Link to comment
Share on other sites

  • 2 weeks later...
Victor_Knight

Nice to see some updates, couldn't wait to try it. But don't know why, car is not screaming for some reason after several thunder passes. The longest try was about 8 minutes and nothing happened

Here's the save I used with the nearest position to vehicle with alarm (alarm appears randomly each time). The thunder was called by save editor and by 'catsanddogs' also, but both methods seemed to be equal. Of course I didn't forget to install all the stuff before testing.

 

 

Link to comment
Share on other sites

spaceeinstein

Sorry, there's a mistake in the code that I overlooked. Can you test this out for me? If it works, I will release this update. You can type THUNDER to enable debug mode. The values are the thunder time, lightning type, random number generator, and random number limit for the thunder type. If type > 9 and RNG

Link to comment
Share on other sites

Victor_Knight

 

 

 

Yep, sure. Now it became definitely better - alarm goes wild sometimes but only when "thunder" typed as I noticed.
Link to comment
Share on other sites

spaceeinstein

Does it go off without debug mode? I've made it so the alarm doesn't go off too often so it can take a while to test it.

Link to comment
Share on other sites

Victor_Knight

So today I decided to make a deeper testing of it and found that car really screams without debug mode. It was about 4 or 5 times in half an hour - a good result as it seems to me. Great work!

As a suggestion, if you're interested: it would be nice to see ability to equip any selective vehicle with the alarm and turn it on when leaving or off when getting in. Just like another insane idea. :cool:

Link to comment
Share on other sites

  • 1 year later...

Version 3 update:

  • Any pause between playing the alarm sound has been removed.
  • The pitch of the alarm for all cars now matches GTA III.
  • You can customize the alarm pitch of any cars by editing the SEAlarm.dat file.
  • Like 3
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • 1 User Currently Viewing
    0 members, 0 Anonymous, 1 Guest

×
×
  • Create New...

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.