Burn Away Effect Explanation

This explanation doesn’t show any code more of just an overview of how to achieve a simple but cool looking effect.

I’ve seen variations this effect used in different places, one of the more recent examples I can think of is the loading screens from Red Orchestra 2. RO2’s effect definitely uses a different method than mine but it gave me an idea to try something similar. I ended up with a similiar effect using pixel manipulation, and a tiny bit of Cellular Automaton.

Read More

Working on a new JS game

I’ve been furloughed from my job (government contractor) so I’ve had a bit of free time on my hands the last 2 weeks. I decided to start and hopefully in a reasonable amount of time finish a full fledged html5/canvas game.

The name of the game is Grapple Hero, check out a few of the wip screenshots.


grapple herograsstiles

menu progress

If anyone has played my old js1k entry  you’ll recognize the game play immediately. Your character cannot move any way but using his grapple. Once your grapple makes a connection you are shot up into the air where you need to grapple again or you’ll fall (sometimes to your death). I created a website for the game  where you can play the most current demo build, which involves you trying to escape from lava.

I plan on releasing it on Windows, Linux, as a standalone executable, on Android via cacoonjs, on the Google app store, and Desura (hopefully).

Its also been added to IndieDB check it out 🙂

Grapple Hero Windows, Linux, Web, Mobile, Android, MetroTab game

How to get the week in a month for a date with Javascript

Working on my calendar application and I needed to get what week in the current month a day occurs on. Unfortunately I couldn’t find anything like this in the JavaScript Date object so this is the function I came up with

Date.prototype.getMonthWeek = function(){
	var firstDay = new Date(this.getFullYear(), this.getMonth(), 1).getDay();
	return Math.ceil((this.getDate() + firstDay)/7);

Thanks to mutilator for helping out with the actual math to figure it out.

Javascript Sorting by date time

Im currently working on a web based calendar and I needed to sort my event object by date real quick. So the first thing I did was a quick search  on sorting an object by date time. Google becomes such second nature I immediately think of doing that first sometimes before fleshing out a whole solution in my mind. The first result I was brought to was this page on about.com. While the authors solution will work I thought why do even need this complexity? This is what I came up with when I stepped away from Google realizing this was a very trivial task

* Function : sortDate(Date, Date)
* Description : Sorts an object based on date
function sortDate(a,b)
    var a = new Date(a.startDateTime),
        b = new Date(b.startDateTime);
    return (a.getTime() - b.getTime());

My object has a property called startDateTime, but this can easily be modified. All I do is a quick comparison of the UNIX time stamp and its sorted. Mainly just hoping this eventually ranks higher than the result I found on Google.

Canvas Lunar Lander update

Game is still coming along, it now supports zooming, which was actually a little bit tricky to figure out. Only a few more things left to add before its a full fledged game.. or clone of a game that is.

Check out the progress  of JSLander

Now supported in any browser that supports the canvas element.

Lunar Lander Canvas Game

Working on a lot of things lately but noticed I haven’t made a post in quite a while. Heres a quick look at one of the random games I’m making using JavaScript and the Canvas element. Its essentially a clone of Lunar Lander.  As it is right now you can’t actually crash, and if you successfully land on one of the pads, your drops from the top again.  I’m not sure yet if I’m going to add the zoom effect when you get close to the landing pads, I think its pretty cool looking as a full page game. I imagine making a bunch of lander automated and having it set as the background to a gaming page.. of course it will only work in modern browsers at this time.

Check it out here

New Canvas game im working on

A while back I posted a link to a Flash game I was working on, it was going to be multiplayer using Nanoba. Unfortunately I gave up on it pretty quickly, I’m not a big fan of Flash and I wanted to learn something totally different, so I decided to try and remake the game using Canvas.

So far development has been going pretty well, the single player implementation in its current state can be seen here http://www.somethinghitme.com/projects/canvaszom/ (please not the images are not free they are actually 2d renders from 3d models i have purchased, the code is under the MIT license). It already has more implemented than the Flash version had. There are quit a few things however left to be done and I will try to make a post with every major milestone and write up how I accomplished it. So far the only thing that is not using JavaScript is the sound. I am using Sound Manager for that, which uses a swf in order to generate the sounds.

AS of right now I have put a halt on development of this particular single player game recently because I am actually working on a multiplayer version that is nearing completion. The next post I make will most likely be releasing that and then I will get back to making this a full fledged game… and Ill most likely not use the bald shirtless men as enemies (they are supposed to be zombies!).