Question by
Anass1997 · Jun 19, 2017 at 04:12 PM ·
audiosourceaudioclipmultiple
Playing many AudioSources
Hi everybody, i'm a still a beginner in unity, i have a problem in the audience of my game, i'm building a flappy bird game, and i want to play 2 AudioSource associated to my bird gameobject when he collides with an obstacle, and another one for the wings sound.
Comment
Answer by shadowpuppet · Jun 19, 2017 at 08:55 PM
put one audioSource on the top node of the bird gameObject( where there's probably a triggerCollider so if hits anything tagged "obstacle" ( or whatever" it triggers the collision sound, and you can put another audiosource on a component of the bird for the wing sound. I have some characters like that, my boat gameobject has an audiosource for the motor sound ( top node) and the mesh has one for when it collides with something