OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: GingaWRATH on 07 Jul 2005, 11:00:26
-
I am having problems making a Unit Scream.
My Idea is using Eventhandler killed or Hit run a script with _unit say "scream"
Ive got no error msgs and also No SCREAM! :(
My event handler inside each units INIT field = this addeventhandler ["hit", {_this exec "aier\scream1.sqs"}]
My script =
_unit = _this select 0
_unit say "scream"
exit
Im so confused :(
-
Just incase you was wondering I run my scripts for the scrams from another folder "aier". thats why the script is ran "aier\scream1.sqs"
-
Erm just wondering if you have defined the sound scream in your description.ext?
-
I think so.. :)
-
A dead unit cannot say anything, and you are only activating the say command when the unit is dead.
Could this be the problem?
-
Well ive tryed Hit as my handle but still no response
-
The hit may kill him.
Try playsound instead of say
The direction and volume of the sound will not be correct but it would at least rule out this as a problem
-
Sry actually it could be the D.EXT ive just retryed with out and No error msg sry
-
Maybe you can tell me whats wrong with it. I have 12 different screams named s1 -s12. ( that might be a prob right there lol)
-
Hmm just had a look at your description a bit different to any of mine. Are you having problems with any of your other sounds?
-
The Playsound worx but still no Say
-
do u think i need a .lip file?
I doubt this but i use _unit say "eng1"-"42" all the time and these all have .lipfiles with them. (found in the Sound.pbo file)
-
Ive shot the guy 1 time with the script set to _unit say "eng20" (for the gogogo sound)
and it repeates gogogo 1 time giving me 2 gogogos 1 after eachother hmm. But at leat this worx so im veryconfused as why s1 dont
-
Im almost out of Ideas. I got some Kickass Screaming Here.. :(
Maybe I could try one of your D.ext just for my brains sake.
-
I thought you found the answer. Playsound works - so you have no problem with the sound file or description.ext.
Say does not work with dead units and you want a dead unit to scream - it won't happen.
Try creating a Game Logic at the location of the unit at the point of death and get the game Logic to say the scream.
-
ahhh cleaver guy lol.
So Im gonna make 12 Gamlogics that can be setpos getpos arouns dead units since I have a different Scream for Each group unit.
lemme C..
So now my script would be :
_unit = _this select 0
Gamelogicname setpos getpos _unit
~0.2
Gamelogicname say "scream"
exit
that sound good? or you gotta better way?
-
It was a Great Idea but still no Screaming.. Never mind thanx for the Help Im sure it will be a fine Mission Without this :( lol
-
I can't see why it would not work.
Try
hint format ["%1",_unit]
to see if _unit is defined.
Also: are you close enough to hear the scream when the GL says it?
-
Stood next to the guy and nothing. I added a Hint earlyer and it should all work. All ive done now is Used rus2.3.4.5.8.13 to get a lesser effect.
its koo Guys Thanx for ya efforts.
-
Im not sure if this has been suggested,
you might want to check on your ogg file, u might have an error in it,
your volume might not be assined properly or raised in it
you might have a little space in the declaration of the sound
or could just be what the other guy said, unit dead = no sound.
-
Im not sure if this has been suggested,
you might want to check on your ogg file, u might have an error in it,
your volume might not be assined properly or raised in it
you might have a little space in the declaration of the sound
or could just be what the other guy said, unit dead = no sound.
Yes the OGG file might not work ive had this problem... but I dont think it matters since this topic is over 1 year old ;)