Thread Tools Display Modes
04-23-09, 08:39 AM   #1
Bluspacecow
Giver of walls of text :)
 
Bluspacecow's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2006
Posts: 770
Script commands for every sound (updated for Wrath 3.1)

http://www.wowinterface.com/download...o.php?id=13194

Basically it's a zip file got a collection of text files in it. 2 of those 2 text files contain /script commands to play most any sound in game. If it was in the MPQ files then there should be a /script command to play it in game !

To use just use a decent text editor to do a Find on either "3_1_sounds.txt" or "wow_sounds_includingwrath_FINAL.txt"

For some reason it doesn't work if you open it in NotePad. Please use something else like Word or Wordpad. If I could figure out a way to save it on my mac so it is in a form you can open in NotePad I would. I'ld also need to upload it from work , as that's the only accessible PC I can get too.

So questions ? Comments ? Advice ?
__________________
tuba_man on Apple test labs : "I imagine a brushed-aluminum room with a floor made of keyboards, each one plugged into a different test box somewhere. Someone is tasked with tossing a box full of cats (all wearing turtlenecks) into this room. If none of the systems catch fire within 30 minutes, testing is complete. Someone else must remove the cats. All have iPods." (http://community.livejournal.com/tec...t/2018070.html)
  Reply With Quote
04-24-09, 11:58 AM   #2
Verissi
Premium Member
 
Verissi's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2006
Posts: 99
Macs (and *NIX) save raw ASCII text files with line endings that consist of only line feeds. Windows adds a "carriage return" as well, so if a Windows user opens up a text file in Notepad that just has line feeds, it will display the whole thing as one line. The line feeds are still there, but Windows doesn't see them as sufficient for a line ending (silly, I know).

You can add the carriage returns to your file in a number of ways. My old TiBook isn't running now, but the command I use on my Linux machines to do this is pretty simple:

Code:
sed -e 's/$/\r/' inputfilename > outputfilename
You should be able to open up a terminal window and do the same, or you could probably set up a folder action to do it as well for any files that you drop into that folder.

If you anticipate doing this a lot, you would probably want to make the above into a simple script:

Code:
#!/bin/sh
sed -e 's/$/\r/' $1 > $2
Then call it from the command line like (I named the script addcr):
addcr inputfilename outputfilename
Hope this helps
  Reply With Quote
04-24-09, 01:29 PM   #3
Seerah
Fishing Trainer
 
Seerah's Avatar
WoWInterface Super Mod
Featured
Join Date: Oct 2006
Posts: 10,860
Off-topic, but... I always have problems viewing lua files in regular Notepad. WordPad works perfectly, however.
__________________
"You'd be surprised how many people violate this simple principle every day of their lives and try to fit square pegs into round holes, ignoring the clear reality that Things Are As They Are." -Benjamin Hoff, The Tao of Pooh

  Reply With Quote
04-25-09, 11:51 PM   #4
Bluspacecow
Giver of walls of text :)
 
Bluspacecow's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2006
Posts: 770
Originally Posted by Verissi View Post
Code:
#!/bin/sh
sed -e 's/$/\r/' $1 > $2
Then call it from the command line like (I named the script addcr):
addcr inputfilename outputfilename
Hope this helps
Doesn't work

I pasted the code into a new script and chmod'd the file.

I execute and it truncates each line with a "r" character ????
__________________
tuba_man on Apple test labs : "I imagine a brushed-aluminum room with a floor made of keyboards, each one plugged into a different test box somewhere. Someone is tasked with tossing a box full of cats (all wearing turtlenecks) into this room. If none of the systems catch fire within 30 minutes, testing is complete. Someone else must remove the cats. All have iPods." (http://community.livejournal.com/tec...t/2018070.html)

Last edited by Bluspacecow : 04-26-09 at 12:39 AM.
  Reply With Quote
04-26-09, 03:33 AM   #5
Verissi
Premium Member
 
Verissi's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2006
Posts: 99
Originally Posted by honem View Post
Doesn't work

I pasted the code into a new script and chmod'd the file.

I execute and it truncates each line with a "r" character ????
Hmm, the shell may be using the slashes and escaping the backslash portion of the carriage return. Try changing the sed command to this and see if it works:
Code:
sed -e 's:$:\r:' $1 > $2
If it still has issues, you can try adding an extra backslash to the above in front of \r (e.g. \\r). Some shells handle things a bit differently and I can't remember which incarnation of "/bin/sh" is used by Macs these days.
  Reply With Quote
04-26-09, 06:08 AM   #6
Bluspacecow
Giver of walls of text :)
 
Bluspacecow's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2006
Posts: 770
Originally Posted by Verissi View Post
Some shells handle things a bit differently and I can't remember which incarnation of "/bin/sh" is used by Macs these days.
If it helps I'm using bash.
__________________
tuba_man on Apple test labs : "I imagine a brushed-aluminum room with a floor made of keyboards, each one plugged into a different test box somewhere. Someone is tasked with tossing a box full of cats (all wearing turtlenecks) into this room. If none of the systems catch fire within 30 minutes, testing is complete. Someone else must remove the cats. All have iPods." (http://community.livejournal.com/tec...t/2018070.html)
  Reply With Quote
04-26-09, 06:49 AM   #7
Verissi
Premium Member
 
Verissi's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2006
Posts: 99
Ah, then the amended sed line should work just beautifully. I just checked it on my Linux machine and it went swimmingly. You probably should change the /bin/sh reference to /bin/bash (or what ever the path is to bash on your machine) to make sure it's calling bash as the script's interpreter as well.

Absolute worst case, I can whip up a perl script to do the same thing and just PM it over
  Reply With Quote
04-27-09, 02:48 AM   #8
Bluspacecow
Giver of walls of text :)
 
Bluspacecow's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2006
Posts: 770
Originally Posted by Verissi View Post
Ah, then the amended sed line should work just beautifully. I just checked it on my Linux machine and it went swimmingly. You probably should change the /bin/sh reference to /bin/bash (or what ever the path is to bash on your machine) to make sure it's calling bash as the script's interpreter as well.

Absolute worst case, I can whip up a perl script to do the same thing and just PM it over
It still seems to just put the r at the end of each line

I've tried something different this time.

Using TextWrangler I've had it save Dos Line breaks

Here's a file sample.

Can someone test this under windows , open in Notepad ?
Attached Files
File Type: txt 3_1_sounds.save3.txt (72.7 KB, 1970 views)
File Type: txt 3_1_sounds.doslinebreaks.txt (73.6 KB, 1501 views)
__________________
tuba_man on Apple test labs : "I imagine a brushed-aluminum room with a floor made of keyboards, each one plugged into a different test box somewhere. Someone is tasked with tossing a box full of cats (all wearing turtlenecks) into this room. If none of the systems catch fire within 30 minutes, testing is complete. Someone else must remove the cats. All have iPods." (http://community.livejournal.com/tec...t/2018070.html)
  Reply With Quote
04-27-09, 05:35 AM   #9
Wimpface
A Molten Giant
 
Wimpface's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2008
Posts: 648
I tried it in windows, and the results were as if the new lines never occured. Here's a visual example of the first few lines.

/script PlaySoundFile("Sound\\CinematicVoices\\DeathKnightNarration.mp3")/script PlaySoundFile("Sound\\Creature\\AlexandrosMograine\\PE_AlexandrosMograine_DeathKnightEvent01.wav")/script PlaySoundFile("Sound\\Creature\\AlexandrosMograine\\PE_AlexandrosMograine_DeathKnightEvent02.wav")
Between every script there was a small square, but this didn't show up in the Quote.
__________________
All I see is strobe lights blinding me in my hindsight.
  Reply With Quote
04-27-09, 09:03 AM   #10
Seerah
Fishing Trainer
 
Seerah's Avatar
WoWInterface Super Mod
Featured
Join Date: Oct 2006
Posts: 10,860
Try in WordPad. As I said, any lua file I open in NotePad doesn't translate the line breaks.


edit: Both files you attached work perfectly in WordPad. In NotePad, only the second has line breaks, not the first. Don't worry about it though.
__________________
"You'd be surprised how many people violate this simple principle every day of their lives and try to fit square pegs into round holes, ignoring the clear reality that Things Are As They Are." -Benjamin Hoff, The Tao of Pooh

  Reply With Quote
04-27-09, 09:30 AM   #11
Bluspacecow
Giver of walls of text :)
 
Bluspacecow's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2006
Posts: 770
Originally Posted by Seerah View Post
edit: Both files you attached work perfectly in WordPad. In NotePad, only the second has line breaks, not the first. Don't worry about it though.
B-b-b-b-b-but its my baby

I want it to be perfect.

I want it so people can just open it up in Notepad.

So the second one had the line breaks you say ?

Many apologies but I'm trying to figure out how i saved that second one.

Here's one saved as DOS linebreaks , with Western (windows latin) encoding.
__________________
tuba_man on Apple test labs : "I imagine a brushed-aluminum room with a floor made of keyboards, each one plugged into a different test box somewhere. Someone is tasked with tossing a box full of cats (all wearing turtlenecks) into this room. If none of the systems catch fire within 30 minutes, testing is complete. Someone else must remove the cats. All have iPods." (http://community.livejournal.com/tec...t/2018070.html)
  Reply With Quote
04-27-09, 09:50 AM   #12
Verissi
Premium Member
 
Verissi's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2006
Posts: 99
Originally Posted by honem View Post
It still seems to just put the r at the end of each line
Skah! Ok, try this script. Perl should behave predictably

Code:
#!/usr/bin/perl -pi
s/\n/\r\n/;
Of course, substitute the path for perl on your system in the first line. Once you make it executable (chmod +x), you should be able to call it like this (I named mine addcr.pl):
addcr.pl inputfile
It will just edit the existing file (no need for an output file name). We'll find a way to get this done if it kills me
  Reply With Quote
04-27-09, 11:42 AM   #13
Wimpface
A Molten Giant
 
Wimpface's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2008
Posts: 648
Originally Posted by honem View Post
B-b-b-b-b-but its my baby

I want it to be perfect.

I want it so people can just open it up in Notepad.

So the second one had the line breaks you say ?

Many apologies but I'm trying to figure out how i saved that second one.

Here's one saved as DOS linebreaks , with Western (windows latin) encoding.
Works a charm.
__________________
All I see is strobe lights blinding me in my hindsight.
  Reply With Quote
04-27-09, 06:33 PM   #14
Bluspacecow
Giver of walls of text :)
 
Bluspacecow's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2006
Posts: 770
Originally Posted by Verissi View Post
Of course, substitute the path for perl on your system in the first line. Once you make it executable (chmod +x), you should be able to call it like this (I named mine addcr.pl):
addcr.pl inputfile
It will just edit the existing file (no need for an output file name). We'll find a way to get this done if it kills me
"which perl" comes back with the usaul path.

This appears to work. I've applied it to all the files and when I open it in Text Wrangler it has a little popup menu at the bottom of the window "Windows (CRLF)". To be sure I've gone through at also selected "Western (Windows Lating)" encoding as well.

Here's version 2.1
Attached Files
File Type: zip Wow Script Sounds (updated for 3.1.1) v2.1.zip (105.0 KB, 1275 views)
__________________
tuba_man on Apple test labs : "I imagine a brushed-aluminum room with a floor made of keyboards, each one plugged into a different test box somewhere. Someone is tasked with tossing a box full of cats (all wearing turtlenecks) into this room. If none of the systems catch fire within 30 minutes, testing is complete. Someone else must remove the cats. All have iPods." (http://community.livejournal.com/tec...t/2018070.html)
  Reply With Quote
04-27-09, 09:07 PM   #15
Verissi
Premium Member
 
Verissi's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2006
Posts: 99
Yay! <-- dancing bananas added for emphasis

Glad I could finally find something that worked for ya
  Reply With Quote
04-27-09, 10:11 PM   #16
Bluspacecow
Giver of walls of text :)
 
Bluspacecow's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2006
Posts: 770
Everybody loves a dancing banana



Anywho.

Have submitted an update to 2.1

All files should now open in Notepad.
__________________
tuba_man on Apple test labs : "I imagine a brushed-aluminum room with a floor made of keyboards, each one plugged into a different test box somewhere. Someone is tasked with tossing a box full of cats (all wearing turtlenecks) into this room. If none of the systems catch fire within 30 minutes, testing is complete. Someone else must remove the cats. All have iPods." (http://community.livejournal.com/tec...t/2018070.html)
  Reply With Quote
04-29-09, 07:25 AM   #17
Bluspacecow
Giver of walls of text :)
 
Bluspacecow's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2006
Posts: 770
Looks like I missed an entire MPQ when crusing for new 3.1 sounds.

It also had the vast majority of the new 3.1 sounds in it

About 75% of them (about 485MB/635mb)

Uploaded version 2.2 update to correct this
__________________
tuba_man on Apple test labs : "I imagine a brushed-aluminum room with a floor made of keyboards, each one plugged into a different test box somewhere. Someone is tasked with tossing a box full of cats (all wearing turtlenecks) into this room. If none of the systems catch fire within 30 minutes, testing is complete. Someone else must remove the cats. All have iPods." (http://community.livejournal.com/tec...t/2018070.html)
  Reply With Quote
05-13-09, 03:54 PM   #18
Dohzzer
A Kobold Labourer
Join Date: Aug 2008
Posts: 1
When you play these sound files, will other players in-game here it?
  Reply With Quote
05-13-09, 05:14 PM   #19
Bluspacecow
Giver of walls of text :)
 
Bluspacecow's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2006
Posts: 770
Originally Posted by Dohzzer View Post
When you play these sound files, will other players in-game here it?
No they only play for you .
__________________
tuba_man on Apple test labs : "I imagine a brushed-aluminum room with a floor made of keyboards, each one plugged into a different test box somewhere. Someone is tasked with tossing a box full of cats (all wearing turtlenecks) into this room. If none of the systems catch fire within 30 minutes, testing is complete. Someone else must remove the cats. All have iPods." (http://community.livejournal.com/tec...t/2018070.html)
  Reply With Quote
05-26-09, 07:03 PM   #20
Bluspacecow
Giver of walls of text :)
 
Bluspacecow's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2006
Posts: 770
Complete re-extract and update for 3.1.2

Has baby murloc space marine sounds

This is a preview version as I'm not sure if the carriage returns thingy worked again.

I'll update it to my main page as soon as I know if the carriage returns have worked in Notepad or not....

PS Yes I'll be testing this @ work ....
Attached Files
File Type: zip Wow Script Sounds (updated for 3.1.2) v2.3.zip (103.1 KB, 1302 views)
__________________
tuba_man on Apple test labs : "I imagine a brushed-aluminum room with a floor made of keyboards, each one plugged into a different test box somewhere. Someone is tasked with tossing a box full of cats (all wearing turtlenecks) into this room. If none of the systems catch fire within 30 minutes, testing is complete. Someone else must remove the cats. All have iPods." (http://community.livejournal.com/tec...t/2018070.html)
  Reply With Quote

WoWInterface » Developer Discussions » Dev Tools » Script commands for every sound (updated for Wrath 3.1)

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off