- Home /
DragRigidBody Dynamic Sound Door
I have it playing a sound no problem. What I want to know is where I should start using the default drag script at adding in dynamic sound. Like if it hits the o rotation in the y axis, it'll play a closed sound. I've been doing that with triggers and it's an okay effect, but time consuming with multiple doors. Also as long as the door is moving it should play sound, but when it isn't, it should be silent.
Now that I've explained the kind of dynamic feel I'm wanting, I would just like a spot in the right direction for this. Any help is lovely.
Answer by AlphaGarg8447 · Jan 25, 2016 at 07:49 PM
I believe something like this should work:
if (angularVelocity.y < 1) audiosourcevariable.volume = angularVelocity.y / tweaking;
else audiosourcevariable.volume = 1;
Your answer
Follow this Question
Related Questions
Openable door by keypress with two different sounds 2 Answers
Sound play with the speed of the rotation speed of an object. 1 Answer
When dragging a Door open using RIGIDBODYSCRIPT Plays sound. 1 Answer
Sound on doors 1 Answer
Open Door Once But Sound Plays again when i trigger at the door 3 Answers