When Your Homework is Making A Game

Published December 13, 2013
Advertisement
Hi everyone, it's me again. As much as I wanted to do this on a weekly basis, so I'd never run out of content and I'd always leave my readers in a constant state of anticipation, I lost a coin flip to myself (never call tails) and I really wanted to post another entry... a real entry... an entry that talks about more than just myself, that may one day be used to guide the other high schoolers who come looking for answers.

In my first entry I listed off some of the courses that are recommended to get into game development, this time I'm going to talk a bit about it. The one I'm referring to is programming. I'm sure many schools call it different things, but it's most likely going to appear as "Computer Science." I'm aware that not all schools have this as a course, so a lot of what I say won't apply to people who sadly don't have access to this course. For those of you who don't have this course available, there are plenty of books, videos, tutorials and whatnot that you can access. I personally always choose the "For Dummies" series to begin learning something.

The high school programming course changes slightly depending on your local school board, but after research and emailing some friends who live outside of Canada, I was able to find some patterns. For schools that start offering it in your second year of high school (as opposed to 3rd year), you do very simple programming with VisualBasic. I didn't take that course when I had the option to. Instead I took a computer engineering course (hardware, software, circuits). For 3rd year courses, you enter the magnificent world of Java! Java is a lovely programming language, but I'm afraid you won't walk out with enough knowledge to build your own Minecraft. For anyone who hasn't tried learning a programming language, it can be a bit confusing at first. Sure there are simple concepts like "variables" and "if loops," but the hard part is creating a sequence of code that when you run will actually do what you want it to. That sequence is called an algorithm. Making algorithms comes to some people naturally, while others can end up struggling with it. I'd like to apologize in advance to my programming teacher for ripping off one of her lessons.

Despite some of that being "useful information," that wasn't nearly as interesting as I hoped it would be. Let's get on to the good stuff then. This is a message to all teenage boys: be fully prepared to be in a class with no girls. This is a message to all teenage girls: be prepared to be in a class where you're the only girl. I'm sorry if that scared anyone away from programming (don't worry though, there will be girls in your other classes), but sadly the classes tend to be "male dominant." Fortunately my programming class had three attractive girls, two of which I was already friends with, but I spent the entirety of that class befriending the third girl. Relationship advice: don't be afraid to be yourself... but if you pretend she's just "one of the guys" then she may as well be one of the guys. Hey, don't forget, my target audience here are high school students, the whole dating thing had to come up at some point, right? Anyways, throughout the course you will be writing longer codes, some of which you are given a week to complete. A lot of them will be games. Mostly text based games. The computer is thinking of a random number between 1-10, guess what it is and it'll say "congratulations" or something like that. Again, I am very sorry to crush anyone's dreams, but don't worry... there will be girls in your other classes, and that is quite important (to me at least).

Programming is a very important aspect of game development. As dull and boring as the 500 line code you wrote to simulate an ATM machine is, it can be done in a number of ways, and that's one of the main lessons, you can do that one thing 100 possible ways. Now imagine what a team of 10 programmers can do (dominate the world 1000 possible ways). By learning programming, you are now confident that the main character in your 5 act Shakespearean tragedy about a boy with long hair, a huge sword, and a horde of orcs to kill... is moving in the right direction. There's still a lot that needs to be learned before your game is ready, but programming is easily the first step.

Well, I'm going to start wrapping up this one. This entry seemed to be a bit more "school lesson" oriented, not sure how I feel about that considering how under-qualified I am to teach anyone else. Maybe instead we can say I was offering some insight on a subject at least one of the readers knows nothing about. Enclosed with this entry is just a simple code to demonstrate what you learn in your first week of class, if you want to run it to see if/how it works, there's an online compiler you can copy-paste this code into at www.compileonline.com/compile_java_online.php. Thanks for listening, and I'll see you all in a week (or possibly Wednesday and stick to once a week).

[spoiler]public class SimpleProgramming //don't worry about this for now
{

public static void main(String []args) //don't worry about this for now either
{
int num1 = 20; //stores the number 20 in a variable
int num2 = 5; //stores the number 5 in a variable
System.out.println("Addition: "+(num1+num2));//outputs the word Addition and adds the two variables
System.out.println("Subtraction: "+(num1-num2));//outputs the word Subtraction and subtracts the second variable from the first
System.out.println("Multiplication: "+(num1*num2));//outputs the word Multiplication and multiplies the two variables
System.out.println("Division: "+(num1/num2));//outputs the word Division and divides the first variable by the second
}
}[/spoiler]
Previous Entry The First of Many
Next Entry The Nerd Mafia
2 likes 0 comments

Comments

Nobody has left a comment. You can be the first!
You must log in to join the conversation.
Don't have a GameDev.net account? Sign up!
Advertisement
Advertisement