Questions tagged [audio-source]

This tag will use to ask about the questions related to audio source component of unity3d game engine. Audio source is one of the basic component of unity for enabling sounds in game. Its allow sounds playback in 3D environment.

An AudioSource is attached to a GameObject for playing back sounds in a 3D environment. In order to play 3D sounds you also need to have an AudioListener. The AudioListener is normally attached to the camera you want to use. Whether sounds are played in 3D or 2D is determined by AudioImporter settings [More].


Related tags

52 questions
0
votes
2 answers

Unity2d AudioClip leaves a lasting echo

I have a mono .wav file that I'm trying to play as a PlayOneShot() AudioClip in my game using an AudioSource. The sound plays perfectly in the Unity editor but for some reason echos and leaves a lasting reverb in the game that never goes away. …
dulongj
  • 307
  • 2
  • 17
0
votes
1 answer

Why are some audio files not working when trying to play them in Unity?

I am making a 2D game in which I wanted to attach an audio file to a button. I was able to do this successfully. But later I felt like changing that sound. So I simply replaced it with another audio file. Then it stopped working! When I again…
Aravind
  • 31
  • 2
  • 11
0
votes
1 answer

Dictionary.Add() occur error because initialized directly

all.I'm a beginner of c# and unity.I want to make an audio manager with the dictionary.But it occurs an error"NullReferenceException" with blew code. public Dictionary AudioDictionary = new Dictionary() ; …
-1
votes
1 answer

Pause sounds and background music in Unity

I am making a Pause menu in Unity that appears when you press escape. But whenever I press escape, the background music still plays. I am getting an error in lines 32 and 46. The error log is Assets\PauseMenu.cs(32,32): error CS0029: Cannot…
-1
votes
1 answer

How to allow the user to upload new music to an audio source which is tied to a button?

I'm trying to build an app where a user can play music and mix multiple audio. I not getting an idea on how to allow the user to upload his/her own music file to the audio source which is tied to a toggle button. How i have planned to make this work…
-2
votes
1 answer

Audio null in unity

I am getting this weird error in unity when I am trying to run my (sad excuse for a) game. Here's the code using System.Collections; using System.Collections.Generic; using UnityEngine; public class ARsound : MonoBehaviour { public static…
GraniteSOS
  • 49
  • 2
  • 10
1 2 3
4