Can we get a PlaySoundAtLocation function?
Calgacus
Member Posts: 273
Instead of needing a pre-placed soundobject or a monsters action queue we need to be able to play sounds from an arbitrary location and time so we can easily script sound effects relative to the location of whatever we want.
I was trying to make a zombie make a puke sound and couldn't see how to get it to work without some preplaced sound object and so thought this function might be useful.
I was trying to make a zombie make a puke sound and couldn't see how to get it to work without some preplaced sound object and so thought this function might be useful.
Post edited by Calgacus on
0
Comments
Where lHere is a predefined location and make_noise_snd is the resref of the sound.
TR
vector v2 = Vector(1.0f, 2.0f, 3.0f);//that's Vector(float x, float y, float z)
But as I say that is just a position in space. It could be in any area. To define a position in a single area you need a location. To define a location you use something along the lines of -
location loc = Location(objArea, vecPosition, fFacing);//Location(object area, vector position, float degrees)
Does that help?
TR
One other thing. If you are on windows or you can read .chm help files and you haven't got it, the downloadable version of the lexicon will tell you much more about the various data types (there's 10 built in ones in total).
For links to a whole lot of links to tutorials follow this link.
TR
TR