Login x
User Name:
Password:
Social Links Facebook Twitter YouTube Steam RSS News Feeds
Watch MODSonair

Members Online

»
1 Active | 8 Guests
Online:

LATEST FORUM THREADS

»
water
CoD4 MP Mapping
Rainbow HELP....
CoD4 MP Mapping

Forums

»

Welcome to the MODSonline.com forums. Looking for Frequently Asked Questions? Check out our FAQs section or search it out using the SEARCH link below. If you are new here, you may want to check out our rules and this great user's guide to the forums and the website.
For more mapping and modding information, see our Wiki: MODSonWiki.com

Jump To:
Forum: All Forums : Call of Duty 2
Category: CoD2 Scripting
Scripting and coding with Call of Duty 2.
Moderators: foyleman, Foxhound, Mystic, StrYdeR, batistablr, Welshy, supersword, playername
Latest Posts
Subscribed Posts
Search
Restricted Access Restricted Access subscribe
Author Topic: Making sounds using .csv files
csocsi96
General Member
Since: Aug 9, 2010
Posts: 70
Last: Apr 21, 2013
[view latest posts]
Level 3
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Saturday, Nov. 19, 2011 01:30 pm
Hello,

I want to make custom sounds to some stuff.

I already have the sound files, and the csv file, and it doesn't play the sound... [banghead]

My customsounds.csv looks like this:

sentrygun_fire,,sentrygun/sentrygun_fire.wav,1,1,,,,100,10000,weapon,,,,master,,,,,weapon2


in the script i've added these lines:

level.firesound="sentrygun_fire";
self playsound(level.firesound);

and nothing happens.

Share |
Sevenz
General Member
Since: Apr 24, 2006
Posts: 2390
Last: May 10, 2013
[view latest posts]
Level 8
Category: CoD2 Scripting
Posted: Saturday, Nov. 19, 2011 01:47 pm
the first line in a soundalias csv must be the column list, for cod4 you need this:

Code:
name,sequence,file,vol_min,vol_max,vol_mod,pitch_min,pitch_max,dist_min,dist_max,channel,type,probability,loop,masterslave,loadspec,subtitle,compression,secondaryaliasname,volumefalloffcurve,startdelay,speakermap,reverb,lfe percentage,center percentage,platform,envelop_min,envelop_max,envelop percentage
Share |
csocsi96
General Member
Since: Aug 9, 2010
Posts: 70
Last: Apr 21, 2013
[view latest posts]
Level 3
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Saturday, Nov. 19, 2011 01:57 pm
Category: CoD2 Scripting

so i need it for cod2
Share |
Sevenz
General Member
Since: Apr 24, 2006
Posts: 2390
Last: May 10, 2013
[view latest posts]
Level 8
Category: CoD2 Scripting
Posted: Saturday, Nov. 19, 2011 06:23 pm
i know, but i don't have the cod2 modtool files at hand. you can get the proper line from any of the stock soundalias CSVs. Make sure you not copy the comment lines (lines starting with a comma)
Share |
csocsi96
General Member
Since: Aug 9, 2010
Posts: 70
Last: Apr 21, 2013
[view latest posts]
Level 3
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Sunday, Nov. 20, 2011 01:19 am
Hi,

Here is my csv file:

Code:

name,sequence,file,vol_min,vol_max,vol_mod,pitch_min,pitch_max,dist_min,dist_max,channel,type,probability,loop,masterslave,loadspec,subtitle,compression,secondaryaliasname,volumefalloffcurve,startdelay,speakermap,reverb,lfe percentage


#sentry gun

sentrygun_deployed,,sentrygun/sentrygun_deployed.wav,0.93,0.93,,,,,,voice,streamed,,,,all_mp
sentrygun_destroyed,,sentrygun/sentrygun_destroyed.wav,0.93,0.93,,,,,,voice,streamed,,,,all_mp
sentrygun_enemyincoming,,sentrygun/sentrygun_enemyincoming.wav,0.93,0.93,,,,,,voice,streamed,,,,all_mp
sentrygun_gone,,sentrygun/sentrygun_gone.wav,0.93,0.93,,,,,,voice,streamed,,,,all_mp
sentrygun_ontheway,,sentrygun/sentrygun_ontheway.wav,0.93,0.93,,,,,,voice,streamed,,,,all_mp
sentrygun_readyfor,1,sentrygun/sentrygun_readyfordelivery.wav,0.93,0.93,,,,,,voice,streamed,,,,all_mp
sentrygun_readyfor,2,sentrygun/sentrygun_readyfordeployment.wav,0.93,0.93,,,,,,voice,streamed,,,,all_mp
sentrygun_ready,1,sentrygun/sentrygun_ready.wav,0.93,0.93,,,,,,voice,streamed,,,,all_mp
sentrygun_ready,2,sentrygun/sentrygun_activated.wav,0.93,0.93,,,,,,voice,streamed,,,,all_mp
sentrygun_fire,,sentrygun/sentrygun_fire.wav,1,1,,,,100,10000,weapon,,,,master,,,,,weapon2
sentrygun_windup,,sentrygun/sentrygun_windup.wav,1,1,,,,100,350,weapon,,,,master,,,,,weapon2
sentrygun_winddown,,sentrygun/sentrygun_winddown.wav,1,1,,,,100,350,weapon,,,,master,,,,,weapon2
sentrygun_servo_short,1,sentrygun/sentrygun_servo_short1.wav,1,1,,,,100,350,auto
sentrygun_servo_short,2,sentrygun/sentrygun_servo_short2.wav,1,1,,,,100,350,auto
sentrygun_servo_short,3,sentrygun/sentrygun_servo_short3.wav,1,1,,,,100,350,auto
sentrygun_servo_medium,1,sentrygun/sentrygun_servo_med1.wav,1,1,,,,100,350,auto
sentrygun_servo_medium,2,sentrygun/sentrygun_servo_med2.wav,1,1,,,,100,350,auto
sentrygun_servo_medium,3,sentrygun/sentrygun_servo_med3.wav,1,1,,,,100,350,auto
sentrygun_servo_long,1,sentrygun/sentrygun_servo_long1.wav,1,1,,,,100,350,auto
sentrygun_servo_long,2,sentrygun/sentrygun_servo_long2.wav,1,1,,,,100,350,auto
sentrygun_servo_long,3,sentrygun/sentrygun_servo_long3.wav,1,1,,,,100,350,auto


in my script i have these lines:
level.turrfiresound="sentry_fire";

and if it shoots, i have that line:
self playsound(level.turrfiresound);

and nothing happens.
The script is good, because if i change the sentry_fire to weap_mp44_fire_plr it shoots like an mp44, so something wrong is with the csv i think.
What's wrong?

Thanks.
Share |
csocsi96
General Member
Since: Aug 9, 2010
Posts: 70
Last: Apr 21, 2013
[view latest posts]
Level 3
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Sunday, Nov. 20, 2011 01:21 am
sry,
the right script is this:

level.firesound="sentrygun_fire";

self playsound(level.firesound);
Share |
csocsi96
General Member
Since: Aug 9, 2010
Posts: 70
Last: Apr 21, 2013
[view latest posts]
Level 3
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Sunday, Nov. 20, 2011 01:22 am
and it doesn't work
Share |
Sevenz
General Member
Since: Apr 24, 2006
Posts: 2390
Last: May 10, 2013
[view latest posts]
Level 8
Category: CoD2 Scripting
Posted: Monday, Nov. 21, 2011 04:55 am
did you pack the audio files as archive (iwd, zip compressed) in the proper directories (*.iwd\sound\sentrygun\sentry...wav) ?

compare your CSV with stock CSVs, cod2 might require sound/sentrygun/sentry...wav as path
Share |
Restricted Access Restricted Access subscribe
MODSonline.com Forums : Call of Duty 2 : CoD2 Scripting

Latest Syndicated News

»
Why console gaming is dying
Quote:Consider this: Dedicated gaming sales — including living-room consoles...
Devs: Games are being dumb...
Click 'read more' to view the contents of this post.
Loadout
Gun Crafting to the Max. edited on Sep. 25, 2012 06:57 pm by Morp...
Introducing the Source Fil...
Surprised this wasn't made a long time ago. Sounds like a nice little feature.
Introducing the Source Fil...
The Source Filmmaker (SFM) is the movie-making tool built and used by us he...

Partners & Friends

»