- Home /
How to find which script changed AudioSource.volume
Is it possible by debugging with MonoDevelop to find out which script has changed variable in Unity's built-in component?
For example, I have a project that has 10 script that possible change AudioSource.volume variable on a gameobject's component. Of course, I don't want to read every 10 script to find out which line has changed the AudioSource.volume variable. That's why I want to know is there a way debug with MonoDevelop which shows the line of code that changed the variable or call stack every time when the AudioSource.volume variable has changed.
Answer by smoggach · Aug 12, 2014 at 03:46 PM
You can do script debugging if you check the box in build settings before making a build. I'm also pretty sure it works if you just put a breakpoint there.
However your best bet is to use Debug.Log to make each script yell out it's name when it's changing the volume.
$$anonymous$$aybe, I wasn't clear enough in my guestion. It is not possible put a breakpoint on the AudioSource.volume variable and I try to avoid reading the scripts through, so the Debug.Log is not the wanted answer, even thought it can be the only solution.
In a nutshell, I just wanted to know which script/method/line changed the AudioSource.volume variable without reading or debugging line by line every possible script.
Your answer
![](https://koobas.hobune.stream/wayback/20220613160434im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
App crashes when trying to debug on Android 0 Answers
How to get rid of the crash error in MonoDevelop 2 Answers
[Solved] Unity / Monodevelop Debugger Problem 2 Answers
If Expression True in Immediate Window But Code In if Block Never Runs 1 Answer
debugger halt after start(), can only resume in update 0 Answers