I know its been a few months since this was posted but Iâll put my two cents in here.
Iâm actually in the same boat right now I feel. Iâve been studying these courses and, coding in general, for a few months and I feel like this answer will help you: Everyone has their own style.
What I mean is that the instructors in this course all teach in slightly different ways and due to this it can be difficult to apply basic principles to your code. Sometimes an instructor will declare and initialize a variable at the top of the class, but another instructor likes to declare and then initialize in Start( ) or in a later method, both do essentially the same thing, but now your mind has two, three, four different ways of doing the same thing and you start overanalyzing/thinking. Most of the time, we as students know what the instructors are doing because coding is easy at its core and they break it down really well, but when it comes time to do my own code my brain usually starts off like this:
âok, moving object from Point A to Point B. OkâŚdo I need the transform? I do, so let me make a variable of that. Oh wait, I donât need a variable because this transform is on the object⌠So do i need a vector3 variable? Wait is it being moved each frame? If I put a vector3 do I have to make a ânewâ vector3 or do I just declare it and then use it somewhereâŚâ
After about 5 minutes of that it would be enough to make anyone go crazy.
But back on topic, the only thing Iâve found that has helped me make my own stuff work without needing to watch tutorials is to break what iâm trying to do down into its simplest parts and then approach each thing one at a time. Iâm not big on math or anything but Iâm pretty sure the process is called creating an algorithm. So using the example above, I do this approach now:
- Create local variable Vector3, use debug log to make sure its actually getting something.
- If debug.log is good, how do you make things move? Update method, so add some code to move the Vector3 in a direction, doesnât matter how far.
- If its moving, place an ending logic to the movement code so it stops at that point. Use the transform of the ending point.
If any of the code fails above, I take it back to step 1 and start again.
Hope this super long rant was helpful, it helped me out