Jump to content
    1. Welcome to GTAForums!

    1. GTANet.com

    1. GTA Online

      1. Los Santos Drug Wars
      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

[sa] possible to spam audio?


frankandbeans
 Share

Recommended Posts

frankandbeans

I've added 40mm firing sounds to the ac130 mod but I always crash after pressing it more than twice. Is there a way to spam the sounds? The 40mm LMB press from Ryosuke's ac130 mod:

:AC130_5273Audiostream.PerformAction([email protected], PLAY)068D: get_camera_position_to [email protected] [email protected] [email protected] 068E: get_camera_target_point_to [email protected] [email protected] [email protected] 0063: [email protected] -= [email protected] // (float) 0063: [email protected] -= [email protected] // (float) 0063: [email protected] -= [email protected] // (float) 050A: [email protected] = distance_between_XYZ [email protected] [email protected] [email protected] and_XYZ 0.0 0.0 0.0 [email protected] /= 5.0 0073: [email protected] /= [email protected] // (float) 0073: [email protected] /= [email protected] // (float) 0073: [email protected] /= [email protected] // (float) 005B: [email protected] += [email protected] // (float) 005B: [email protected] += [email protected] // (float) 005B: [email protected] += [email protected] // (float) [email protected] *= 100.0 [email protected] *= 100.0 [email protected] *= 100.0 [email protected]([email protected],5i) = Object.Create(1582, [email protected], [email protected], [email protected])Object.CollisionDetection([email protected]([email protected],5i)) = TrueObject.ToggleInMovingList([email protected]([email protected],5i)) = True04D9: object [email protected]([email protected],5i) set_scripted_collision_check 1 0750: set_object [email protected]([email protected],5i) visibility 0 0906: set_object [email protected]([email protected],5i) mass_to 1.0 // float 0908: set_object [email protected]([email protected],5i) turn_mass_to 99999.9 // float Object.SetImmunities([email protected]([email protected],5i), 1, 1, 1, 1, 1)Object.Throw([email protected]([email protected],5i), [email protected], [email protected], [email protected])

The opcode 'Audiostream.PerformAction(20@, PLAY)' shown above is the only thing I added along with '[email protected] = Audiostream.Load("CLEO\ac130\ac130_40mm_fire_c2.WAV")' upon first entering turret mode on the gunship.

Edited by frankandbeans
Link to comment
Share on other sites

Not sure what "spam audio" means.

The opcode 'Audiostream.PerformAction(20@, PLAY)' shown above is the only thing I added along with '[email protected] = Audiostream.Load("CLEO\ac130\ac130_40mm_fire_c2.WAV")' upon first entering turret mode on the gunship.

 

Maybe there is a problem with [email protected] = Audiostream.Load("CLEO\ac130\ac130_40mm_fire_c2.WAV") and you should check the result of it. Shouldn't the path be "...\\....\\..."? I suggest to write a test only for the Audiostream without the rest of the mod.

Link to comment
Share on other sites

yes, mp3 file path is required

either only with opcodes 0AAC: and 0AAD:, without 3dsupport, means without assignment to actor, vehicle or object

i did it mostly in this way

 

//-scriptgosub @music//-code:MP3_ONEif0AAB:   file_exists "CLEO\sound.mp3"jf @MP3_nomp30AAC: [email protected] = load_mp3 "CLEO\sound.mp3"wait 0if8039:   not   [email protected] ==  -1jf @MP3_return0AAD: set_mp3 [email protected] perform_action 1jump @MP3_return:MP3_nomp300BA: show_text_styled GXT 'fem_off' time 1000 style 4wait 1000:MP3_returnreturn
Or with 0AC1: and 0AAD: and additional the code to assigne to actor, vehicle or object,

then cleo 4 is required because mp3 is attached to actor, so it have the effect that the music have less volume if distance between player and actor is bigger

 

0AC1: [email protected] = load_audiostream_with_3d_support "CLEO\music.mp3"0AAD: set_mp3 [email protected] perform_action 10AC4: link_3d_audiostream [email protected] to_actor [email protected]// - cleo 4 -
but this method have also the side effect that the total volume of the music is more quiet

I mostly did it in this way

 

//-scriptgosub @music//-code:musicif0AAB:   file_exists "CLEO\music.mp3"jf @music_nomp30AC1: [email protected] = load_audiostream_with_3d_support "CLEO\music.mp3"wait 0if8039:   not   [email protected] ==  -1jf @music_return0AAD: set_mp3 [email protected] perform_action 10AC4: link_3d_audiostream [email protected] to_actor [email protected]// - cleo 4 -jump @music_return:music_nomp300BA: show_text_styled GXT 'fem_off' time 1000 style 4wait 1000:music_returnreturn
or in this way, i wrote for cars with mp3

 

:car_audiowait 0if0AC1: [email protected] = load_audiostream_with_3d_support "CLEO\Sound\party1.MP3"// - cleo 4 - //IF and SETjf @car_audio0AAD: set_audiostream [email protected] perform_action 10AC5: link_3d_audiostream [email protected] to_vehicle [email protected]// - cleo 4 -
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.