Kylsboy Posted March 3, 2016 Share Posted March 3, 2016 Hello i wand to change my mta gun sounds but for my server but i doint know how to change it and its nowear on youtube i hope someone will help me Greating Robin Link to comment
Dimos7 Posted March 3, 2016 Share Posted March 3, 2016 you mean by script or just recplace the default sounds? Link to comment
Kylsboy Posted March 3, 2016 Author Share Posted March 3, 2016 Dimos7 said: you mean by script or just recplace the default sounds? Yes i have this Meta: Replace.lua addEventHandler("onClientPlayerWeaponFire", getRootElement(), function ( weapon, ammo, ammoInClip ) local x,y,z = getElementPosition(source) if weapon == 30 then local sound = playSound3D("GENRL/sound_005.mp3", x,y,z) setSoundMaxDistance(sound,75) end end ) Link to comment
Dimos7 Posted March 3, 2016 Share Posted March 3, 2016 try this addEventHandler("onClientPlayerWeaponFire", root, function(weapon, ammo, ammoInClip) local x, y, z = getElementPosition(localPlayer) if weapon == 30 then local sound = playSound3D("GENRL/sound_005.mp3", x, y, z) setSoundMaxDistance(sound, 75) end end) also in meta change it like that <meta> <script src="replace.lua" type="client"/> <file src="GENRL/sound_005.mp3"/> </meta> Link to comment
Kylsboy Posted March 3, 2016 Author Share Posted March 3, 2016 it says in de console couldnt find file GENRL/sound_005.mp3 for resource sounds and than Loading of resource Sounds Failed Link to comment
Dimos7 Posted March 3, 2016 Share Posted March 3, 2016 its in same folder the sound and script Link to comment
Bonus Posted March 3, 2016 Share Posted March 3, 2016 addEventHandler("onClientPlayerWeaponFire", root, function(weapon, _, _, _, _, _, _, x, y, z ) if weapon == 30 then local sound = playSound3D("GENRL/sound_005.mp3", x, y, z) setSoundMaxDistance(sound, 75) end end) Use it that way for better sound. Link to comment
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