Would You Like To Play A Game?
Our last Let’s Program was focused on some pretty serious AI techniques for solving pretty serious math problems. So this time around let’s take it easy and program a nice relaxing game.
Eh, who am I kidding. A well designed game is just as mathematically intense as your average AI. But the end product sure is a lot more fun!
Why A Browser Game?
If you’re anything like me, when you hear the word “videogame” you immediately think of a console or powerful computer running a big game like Skyrim or Final Fantasy. Tiny little browser games may not have even crossed your mind.
But don’t be too fast to look down on web browser games! Modern computer browsers have more power than most of the gaming systems I grew up with and some of the more elaborate browser games rival traditional games in terms of graphics, gameplay and content.
Browser games also benefit from a massive audience. Millions and millions of people may own gaming consoles and gaming PCs but the number of people who own web browsers is in the billions! So if you want to create a game that anyone, anywhere, can play browser games are the way to go. This is a big part of the reason that they are the king of casual games.
Not to say that they don’t have their downsides. Browsers games lack the power and size for many types of games. Skyrim could never have been built as a browser game, and even if it was no-one would want to wait the eight hours it took for that particular page.
But even if your end goal is to build the next Skyrim instead of the next Cookie Clicker you still might want to spend at least a little time playing with browser game programming. It’s a good learning experience and you might be surprised at just how much game you can fit into a small browser download.
So we’ve decided to program a small game that can be inserted directly into a web page. Now how do we do that?
For years Flash was the most reliable way to include a game in a website. Flash is basically a program designed to run other programs and it let people enhance their websites with streaming video, animated menus and even entire games. It was hardly perfect and had definite issues with memory hogging and slowdown but it was very successful at letting people play online games without the normal mess of downloading and installing a separate program. They just visited a web page and Flash automatically loaded the game and started it up in the browser.
Today Flash is still one of, if not the most, popular way to build browser based games. Just visit a free gaming site like kongregate to see what I mean. Flash as far as the eye can see.
So next week we’ll get this Let’s Program started by covering the basics of drawing on the HTML canvas.