Now, no matter how careful you are about your code,
debugging is almost certainly going to be a large part of any game development.
The more complex and bigger aim gets the more chances are that
an interaction here and there is going to bring up something unexpected in gameplay.
So, it's important to go about debugging in a smart and efficient manner.
When you come across a bug,
make sure to note it.
Don't promise or remember or say that it's just so obvious that you can't ignore it.
Note the bug, and give it as much detail as you can.
Note that the conditions that it came up,
how you maybe came across it,
and what the bug exactly was.
Maybe what you'd think is a bug someone else thinks as a feature, it happens.
If you have any suspicions about the bug at the time
and can't delve in this code to try and fix it,
also note down those.
They might be vital clues later on to figuring out how to fix the bug.
Now, if you can fix a bug,
do so right away.
Letting a bug linger can introduce more bugs based off of
it or someone might forget it or just not care later on.
Now, schedules may not allow you to go bug hunt it right away,
so, if you can't,
be sure to give yourself as much clues in the future as possible.
Now, one way to do this is to add a to-do list.
Now, this is a little controversial in a way,
some people view the to-do as a very easy way of noting things to do
in code and some see it as a lazy or problematic way.
Let me show you what it is and I'll let you decide.
Now, in this code here,
doesn't actually matter what this code is,
but let's just say that my timer equals spawn timer,
is doing something a little funny or maybe I want to do it in a slightly different way.
I can add in a to-do,
fix this and save this into my code.
Now, later on in Visual Studio,
you can always go to your task list.
The task list keeps track of certain comments such as the to-dos.
Now, in here you're going to see the to-do I just added plus
a few more that were in the code from when we inherited this project.
Now, down here I've got to-do fix this,
which is terribly unhelpful,
do not make comments like this,
but just as an example, this is fine.
We also have the to-do for an anti flicker in the Bloomer components,
and in that same component,
we also have a to-do to the extend the use of
RGBM to the whole chain for mobile platforms.
Now, I have no idea what this to-do actually means without delving into the code.
Chances are it was meant to be fixed before
everything went out but just someone didn't have the time,
which is the strength and the weakness of the to-do.
On one hand they're very easy to put in, you can to-do,
put in the information here and make the information as much as possible,
and hope that someone will come along,
hopefully you, and fix it in the future.
But it's also easy to forget,
which is one of the main complaints.
So, a to-do is not necessarily a must do,
it's a should do sometimes,
and it depends on who you ask.
So, go ahead and decide what a to-do is to you.
Some companies use them extensively and some frown upon them being used.