Page 1 of 1
AI Speaking
Posted: Sat Jan 25, 2003 6:38 pm
by Guest
Ok, I'm trying to get started on a map... but I would like to know if there is a way that I could make it so that when the player crosses a trigger, the friendly AI says something.
Posted: Sat Jan 25, 2003 6:39 pm
by Sputnik
Darnit that was me!
Posted: Sat Jan 25, 2003 7:20 pm
by Angex
Setup a trigger to go off when walked through, give it a key: setthread and corresponfing value: speech
In you script add a thread, called speech, and add in code like below:
speech:
$friendlyAItargetname say soundalias
end
$friendlyAItargetname - This is the target name you have given to the friendly AI character.
say - This is a script command which will make the targeted character speak.
soundalias - This is an alias from uberdialog, this is what will be spoken.
For example:
speech:
sgt_barnes say dfr_M1L1_104k_1
end
You may also find the following commands useful:
lookat
turnto
waittill saydone
Posted: Sat Jan 25, 2003 9:38 pm
by Sputnik
So, if I wanted my AI named 'friendly1' to say something I would write
// Speech Thread
speech:
$friendly1 say dfr_M1L1_104k_1
end
And thats it??
Also: How do I find the speech sounds?? Which pk3 are they in??
Posted: Sun Jan 26, 2003 3:35 am
by mohaa_rox
Yes, but you need to add:
$friendly1 say dfr_M1L1_104k_1
$friendly1 wattill saydone
The dialogues are in mohaa\main\sound\dialogue, not a pk3, just a folder.
Posted: Mon Jan 27, 2003 2:15 pm
by Sputnik
Thanks, I'll try it. 8)
Posted: Thu Jan 30, 2003 10:21 am
by phalanx
Cool, does this all work in multiplayer?
Posted: Thu Jan 30, 2003 11:29 am
by mohaa_rox
It should work if you do it correctly.
