DoD Plugins

Go Back   DoD Plugins > General > Modeling and Mapping Chat

Modeling and Mapping Chat We will just do chatting about Mapping and Modeling.

» Navigation
 > FAQ
» Forum Actions
» Programming
 > VERC
» Server Links
For Linking to Us
AvaMods
=|[76AD]|=
GameSpy Rangers
Merrill's Marauders
Reply
 
Thread Tools Display Modes
  #1  
Old 03-09-2012, 03:00 AM
RichNagel's Avatar
RichNagel RichNagel is offline
Member
 
Join Date: Jan 2012
Location: Crystal River, Florida
Posts: 47
Question Triggered VOX spoken announcement using map entities?

(I posted this over in the Steam Counter-Strike and Half-Life forums, but figured I'd post it here as well... as I have a good hunch that the same method (if it's possible) for Day of Defeat would ALSO apply to Counter-Strike)


Here's what I'm trying to do...


I have a map with the following entities:

Code:
{ "model" "*104" "material" "0" "health" "1" "renderamt" "50" "rendermode" "2" "rendercolor" "0 0 0" "explosion" "1" "explodemagnitude" "384" "target" "reactorcorebreached" "classname" "func_breakable" } { "origin" "-1174 177 -264" "targetname" "reactorcorebreached" "message" "Warning! The reactor core chamber has been breached!" "channel" "1" "effect" "0" "holdtime" "5" "fadeout" "4" "fadein" "0.05" "color2" "240 110 0" "color" "100 100 100" "y" "-1" "x" "-1" "spawnflags" "1" "classname" "game_text" }

In the map, model 104 is the glass on the front of a box (a reactor chamber). When model 104 is broken, the text message in the second entitiy is displayed "Warning! The reactor core chamber has been breached!".


I'm trying to ALSO trigger an audible spoken message, using the standard "sentences/VOX" features and sound files included with Half-Life (which, of course, is loaded and accessible when playing Counter-Strike).

I've read things about the class names "sentence" and "scripted_sentence" (as well as using "ambient_generic", but so far have had no luck.


An example from Half-Life's "Sentences.txt" file would be:

Code:
C2A4_1 bizwarn bizwarn. alert. biological containment breach detected

I've found that the game includes the correct sound files to "speak" the message that I want, something like:

Code:
bizwarn bizwarn. warning. the reactor core chamber has been breached.

...as they're included with Half-Life, in the game's GCF; "Valve\Sound\VOX\*.wav".


So... any idea of how to get the game to "talk" and speak the message (and heard by all players), triggered when model 104 is broken?
Reply With Quote
  #2  
Old 03-09-2012, 08:10 AM
RichNagel's Avatar
RichNagel RichNagel is offline
Member
 
Join Date: Jan 2012
Location: Crystal River, Florida
Posts: 47
Smile

Figured it out on my own

Here's what I did:

Code:
{ "model" "*104" "material" "0" "health" "1" "renderamt" "50" "rendermode" "2" "rendercolor" "0 0 0" "explosion" "1" "explodemagnitude" "384" "delay" "0" "target" "reactorcorebreached" "classname" "func_breakable" } { "origin" "0 0 -150" "targetname" "reactorcorebreached" "message" "Warning! The reactor core chamber has been breached!" "channel" "2" "effect" "0" "holdtime" "10" "fadeout" "4" "fadein" "0.05" "color2" "15 142 136" "color" "197 228 222" "y" "-1" "x" "-1" "spawnflags" "1" "classname" "game_text" } { "origin" "0 0 -150" "warning1" 0.000 "warning2" 0.888 "warning3" 1.776 "warning4" 2.664 "warning5" 3.552 "warning6" 4.116 "warning7" 4.475 "warning8" 5.177 "warning9" 5.907 "warning10" 6.624 "warning11" 7.213 "warning12" 7.620 "targetname" "reactorcorebreached" "classname" "multi_manager" } { "origin" "0 0 -150" "health" "10" "targetname" "warning1" "message" "vox/bizwarn.wav" "spawnflags" "57" "classname" "ambient_generic" } { "origin" "0 0 -150" "health" "10" "targetname" "warning2" "message" "vox/bizwarn.wav" "spawnflags" "57" "classname" "ambient_generic" } { "origin" "0 0 -150" "health" "10" "targetname" "warning3" "message" "vox/bizwarn.wav" "spawnflags" "57" "classname" "ambient_generic" } { "origin" "0 0 -150" "health" "10" "targetname" "warning4" "message" "vox/bizwarn.wav" "spawnflags" "57" "classname" "ambient_generic" } { "origin" "0 0 -150" "health" "10" "targetname" "warning5" "message" "vox/warning.wav" "spawnflags" "57" "classname" "ambient_generic" } { "origin" "0 0 -150" "health" "10" "targetname" "warning6" "message" "vox/the.wav" "spawnflags" "57" "classname" "ambient_generic" } { "origin" "0 0 -150" "health" "10" "targetname" "warning7" "message" "vox/reactor.wav" "spawnflags" "57" "classname" "ambient_generic" } { "origin" "0 0 -150" "health" "10" "targetname" "warning8" "message" "vox/core.wav" "spawnflags" "57" "classname" "ambient_generic" } { "origin" "0 0 -150" "health" "10" "targetname" "warning9" "message" "vox/chamber.wav" "spawnflags" "57" "classname" "ambient_generic" } { "origin" "0 0 -150" "health" "10" "targetname" "warning10" "message" "vox/has.wav" "spawnflags" "57" "classname" "ambient_generic" } { "origin" "0 0 -150" "health" "10" "targetname" "warning11" "message" "vox/been.wav" "spawnflags" "57" "classname" "ambient_generic" } { "origin" "0 0 -150" "health" "10" "targetname" "warning12" "message" "vox/breached.wav" "spawnflags" "57" "classname" "ambient_generic" }

...and it works perfectly

BTW, what this is for is my own humble conversion of Half-Life's "Rapid Core" deathmatch map for use with Counter-Strike and Counter-Strike:Condition Zero. I had converted the map a while back, complete with two bomb sites, additional ambient sound effects, and a proper "overview" map.

I also had created (heavily edited) a Condition Zero bot navigation mesh file for the map (so you could play the map with the CZ bots).

Recently I did some more editing to the NAV meshes (adding location "place names" for the players' and bots' radio chatter), and was REALLY GETTING TIRED of the bots (or my human buddies) breaking the glass in the floor in some of the rooms... in Counter-Strike you and the bots will get trapped in those holes in the floor (unless "sv_gravitiy" is set low).

So, I figured out how to make the glass unbreakable, and then thought, hmmmm... might be kind of cool if you could break the glass housing that spinning thing in what I call the "reactor core chamber".

Then, I managed to get a "game_text" message displayed when the glass was broken, as well as a HUGE explosion to kill off anyone that might be in that room.

Last ideas was the above... that announcement voice stating that the reactor chamber had been breached.

WORKS LIKE A CHAMP NOW!
Reply With Quote
  #3  
Old 03-10-2012, 07:52 AM
Sohood's Avatar
Sohood Sohood is offline
Donator
 
Join Date: Sep 2008
Posts: 92
Niice man!

I could use this in my maps, if you don't mind? Where is your server at, I would like to come and check it out. I sent an invitation under a different alias to your steam friends I'm interested in your ideas and work arounds.

Last edited by Sohood; 03-10-2012 at 07:58 AM.
Reply With Quote
  #4  
Old 03-10-2012, 09:51 AM
RichNagel's Avatar
RichNagel RichNagel is offline
Member
 
Join Date: Jan 2012
Location: Crystal River, Florida
Posts: 47
Smile

Quote: Originally Posted by Sohood View Post
Niice man! I could use this in my maps, if you don't mind?

Feel free to do so, no permissions required


Quote: Originally Posted by Sohood View Post
I sent an invitation under a different alias to your steam friends I'm interested in your ideas and work arounds.

Cool. I justed accepted your friend request, and sent an invitation to you for our meager little DoD/CS/CS:CZ clan, the Swamp Buzzards Clan -> http://steamcommunity.com/groups/SwampBuzzardsClan


Quote: Originally Posted by Sohood View Post
Where is your server at, I would like to come and check it out.

I usually run a listen server (with password). Shoot me an email (or PM) for the IP and PW




P.S. For anyone interested, the updated version of my Half-Life to Counter-Strike and Counter-Strike: Condition Zero "Rapid Core" map conversion:

http://www.17buddies.net/17b2/View/M...rapidcore.html
Reply With Quote
  #5  
Old 03-10-2012, 11:55 PM
meathead's Avatar
meathead meathead is offline
developer
Developer
 
Join Date: Aug 2007
Location: Alabama
Posts: 337
pretty nice work
__________________
Reply With Quote
  #6  
Old 03-12-2012, 11:44 AM
RichNagel's Avatar
RichNagel RichNagel is offline
Member
 
Join Date: Jan 2012
Location: Crystal River, Florida
Posts: 47
Talking

BTW... for anyone interested, a simple and short little YouTube video showing "de_Weeds_RapidCore" in action:

http://www.youtube.com/watch?v=2Y3Qk6wUnpE
Reply With Quote
  #7  
Old 03-15-2012, 03:34 PM
DFHServer's Avatar
DFHServer DFHServer is offline
Junior Member
 
Join Date: Feb 2005
Posts: 11
multimanager #s

Hi Rich,

Good job figuring it out.
Just wondering what the numbers in the multimanager do?
Reply With Quote
  #8  
Old 03-15-2012, 06:01 PM
RichNagel's Avatar
RichNagel RichNagel is offline
Member
 
Join Date: Jan 2012
Location: Crystal River, Florida
Posts: 47
Smile

Quote: Originally Posted by DFHServer View Post
Just wondering what the numbers in the multimanager do?

The numbers are the delay (in seconds) of how long to wait before the next sound file plays. Without the delay, ALL of the WAV files play at the exact same time <grin>.

If the numbers are too high, the spoken words are spaced too far apart. If they are too small, one spoken word will "run into" (overlap) the next one.

The way I determined the best delays was to simply load each sound file into my WAV editor of choice (GoldWave), and check the duration of each file.

Then, I simply added up the durations; one at a time; to come up with those numbers.

The result sounds fairly "natural" (as far as when each word sound effect is heard on the game), although, not QUITE as natural as when using the predefined "Sentences.txt" method.

If you load the map within the game; press the little button to the right of the sliding door at the CT's spawn area. THAT one uses the predefined "Sentences.txt" method... while the reactor-core-breached message sound uses my "rig" above.

You can hear the difference between the two methods by listening to the above (note that the button trigger thing isn't shown/heard in my little video... only the reactor breached message).
Reply With Quote
Reply

Bookmarks

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

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

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
changing max entities.. is this real??? diamond-optic Chat 9 04-24-2007 11:21 AM
Display object entities in mini-map orbit Requests for DoD Plugins 1 01-05-2007 12:38 AM

» Donations
If you like this website, and would like to give something in return, you can make a donation. Your donation will be used to pay for hosting service, domain, & maintenance costs only!

$

Select your donation amount and then press the Donate button.




» Log in
User Name:

Password:

Not a member yet?
Register Now!
Powered by vBadvanced CMPS v3.2.3

All times are GMT -3. The time now is 12:06 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.
dodplugins.net