The Daily Click ::. Forums ::. Klik Coding Help ::. Advanced sound effects
 

Post Reply  Post Oekaki 
 

Posted By Message

Holy Elf



Registered
  18/12/2002
Points
  105
7th March, 2004 at 02:28:18 -

I'm working on a horror game and I'm thinking, it's not very scary without good sound effects, right? So, I'm wondring if I can do the following in MMF:
- Changing sound volume according to distance
- EAX
- 3D sound (whether with 2 or 4 speakers)

Thank you.

 
n/a

X_Sheep

I had a custom rating before it was cool

Registered
  01/03/2004
Points
  1313

VIP MemberPicture Me This -Round 23- Winner!Dos Rules!
7th March, 2004 at 02:39:04 -

Changing sound volume according to distance should be easy if you make an expression that calculates the distance:
For example: *inhale*
Root(((Root(X of player - X of ghost)²)²)+((Root(Y of player - Y of ghost)²)²))

I think you need the Advanced Math object to calculate the root.
Err... At least I hope not because that object already has a 'calculate distance' function

 
a/n

AsparagusTrevor

Mine's a pint of the black stuff

Registered
  20/08/2002
Points
  2364

Game of the Week WinnerHas Donated, Thank You!VIP MemberEvil kliker
7th March, 2004 at 11:25:08 -

You can't change the volume of sound effects though unless you use DMC2 or something to play the sound, or have different sound effects at different volumes for varying degrees of distance. As far as I know, EAX and 3D Sound isn't possible.

 
Image

ChrisB

Crazy?

Registered
  16/08/2002
Points
  5457
7th March, 2004 at 11:40:18 -

X_Sheep, that is the dumbest expression I ever saw. A root squared gives you the number you had before...

 
n/a

Kirby Smith

Resident Slacker

Registered
  18/05/2003
Points
  479

VIP Member360 OwnerWii OwnerThe Cake is a Lie
7th March, 2004 at 12:42:46 -

Well... EAX is echos and stuff right?

Theoretically, with a combination of fastloop and DMC you could achieve this. "Sound objects" could shoot out little detectors that move at insane speeds and bounce off walls using trig... then, when they intercect a detector object (like a sphere) that's around the player, they'd create the sound effect again, but at a lower volume. Basically, you'd have to have the volume that the sound effect is played at based on an alterable value in the "sound particle/detector" that starts off at the base volume and then gradually drops to zero, where the object is destroyed. It'd take a crap-load of code and work, but I think it's achieveable.

 
XBL Gamertag: Rampant Mjolnir

Muz



Registered
  14/02/2002
Points
  6499

VIP MemberI'm on a BoatI am an April FoolHonored Admin Alumnus
7th March, 2004 at 19:18:41 -

I think what X_Sheep is trying to say is to use that Pythagoras theorem thing (however you spell it). I'm sure someone your age would know it by now. As I've learned from school, it's better to tell people how to do things than to give them the exact formula.

And I think MMF comes with an in-built root calculation thing.



 
Disclaimer: Any sarcasm in my posts will not be mentioned as that would ruin the purpose. It is assumed that the reader is intelligent enough to tell the difference between what is sarcasm and what is not.

Image

X_Sheep

I had a custom rating before it was cool

Registered
  01/03/2004
Points
  1313

VIP MemberPicture Me This -Round 23- Winner!Dos Rules!
12th March, 2004 at 14:15:13 -

The Square-root thing is to remove the (-) from the number, it could mess up the entire formula

Oops, I think I switched them It should be first square, then root

Image Edited by the Author.

 
a/n
   

Post Reply



 



Advertisement

Worth A Click