- Everything is case sensitive! From Java's point of view, "volumevalue" is a completely different thing than "volumeValue". It doesn't really matter which one you use, as long as you use it consistently everywhere. I also suggest reading about Java's naming conventions (how to name objects and methods etc). Those are only conventions, but help make your code more readable to other people, and probably yourself too.
- Read about objects and primitives, and what is their difference. In your code, "volumevalue" is declared a primitive (double), but elsewhere, you try to call a method called volumevalue.SetValue(), which does not work, since primitives don't have methods.
- Be careful what goes where in the module's source code. As you can see, when you start a new project in MD, there's already a bunch of code there, and you can only edit some specific spots in the code. Familiarize yourself with the structure of a new blank project, and the stuff that is already there: which methods get called at what times, etc. For example, the code you have placed inside the "GetTooltipText" method, I'm pretty sure it's not supposed to be there... Make sure you read the help text above the GetTooltipText method, it should give you an idea when that method is called. Also make sure you don't have any extra leftover code anywhere where there is not supposed to be any.
- Most of audio processing code will probably be inside the ProcessSample() method
- As I said earlier, using curly brackets with IF is always a good idea Like this:
Code: Select all
if ( test something here ) {
do something here
do something more
still part of the IF block
}
after the IF block