It is impossible to know everything there is to know about programming, and why should you? Before you had to know as much as possible because if you didn't, you had to look inside a book for a long time or call a friend. But now, now we have Google (or your favorite search engine).
What I want you to know, to understand is that all the knowledge is out there. Thousands of people around the web have shared their experiences, their knowledge, all you have to do, is grab it. apply it and move on to the next challenge.
The Problem Solving Method consists of 6 easy steps:
1) Draw how you want things to work
2) Identify the variables
3) Schedule your time
4) Define keywords
5) Develop
5.1) Search for solutions you don't know
5.2) Track your progress
5.3) Have fun
6) Test, retest and test some more to make sure you are taking care of all the scenarios.
Let me just go over an example so that you can visualize what I have in mind:
Problem: Make box move from side to side by pressing the arrow keys
1) First step is to illustrate what I want to do, how I want it to work, sketches are fine here, anyone with more artistic talent can do different things, or maybe if you like videos, make a video moving pieces with your hands. or act it out, choose what ever method works for you.
2)As you can see above, I identified that I need:
- Character Object
- Speed
- Left Key
- Right Key
- Left Limit
- Right Limit
3) Here are time estimates I made for myself for the following tasks. These times vary for everyone, it is good to start doing this so that you can learn more about yourself, learn how to estimate your workload, It is a very handy skill in freelancing.
4) What possible keywords can be used to solve problems?
- Actionscript
- AS3
- Flash
- Keyinput
- Left Arrow KeyCode
- Right Arrow KeyCode
5) Now lets get down to the development!
For demonstration purposes, lets search for key input in flash:
Here is the best example I found:
Now I need to know what is right arrow and left arrow... But instead of using google, let me use the trace method, I will just ask flash to tell me the value of the key I am pressing.

Here is the final code...

Here is the final code...
6) Let's test it out, does it work correctly?
After looking at it, I thought it looked a bit jumpy, so I made some adjustments...

Thank you for your time, I really hope this method works for you, you should know that if you master this method, you can program anything you set your mind to.
Please share any or all of your work with me, I really want to know how you adapt this method to your personality. I will be glad to share work you do here in the blog for other future game devs to see and learn from.







No comments:
Post a Comment