By , November 20, 2014 10:32 am

Cranked out some Christmas presents last night. First time throwing in a very long time.

function init(){
	circle = new BlueCircle();
	maze = new Maze();
	star = new Star();
	star.x = 110;
	star.y = 200;
	circle.x = origX;
	circle.y = origY;
	circle.addEventListener(MouseEvent.CLICK, startGame);


Flash Lab is Tuesday this week.

comments Comments Off on Flash Lab is Tuesday this week.
By , September 15, 2014 7:49 pm

Tuesday 8:30PM-10:30PM
Hauke 101

Next week it is back on Monday.

Loading Unity Prefabs

By , July 29, 2014 9:23 am

John Pile and I were brainstorming some efficient ways to load prefabs in Unity. Check out the post on his blog to learn more:

GIV links

By , June 23, 2014 3:19 pm

Class 2:Class2

Platformer 2013

comments Comments Off on Platformer 2013
By , November 12, 2013 1:37 am

Platformer example with 8 samples (download files here):

//sample = new Sample1();//draw tiles
//sample = new Sample2();//add player
//sample = new Sample3();//move player and add ArrowKeyInput class
//sample = new Sample4();//check collision
//sample = new Sample5();//exact fit
//sample = new Sample6();//flash the tile that we hit
//sample = new Sample7();//gravity
sample = new Sample8();//jumping

A few diagrams to help you understand how we are checking collision. Comments in the code will refer to this image in the checkCorners() function:

If you look at the exact fit example, this diagrams shows what happens when you move right into a wall:


You can also check out a similar example here that I did a few years ago.

Check collision with wall

By , September 13, 2013 1:33 am

Quick and easy way to check collision with wall and have the object stop. Click the red dot to start. Use’s Tink HitTest class. Here’s the zip

function checkCollision(){
	//save the previous position of the player
	prevX = player.x;
	prevY = player.y;
	//position the player with easing
	var newX = (player.x-mouseX)/4;
	var newY = (player.y-mouseY)/4;
	//check to see if we hit the wall
	var hit =HitTest.complexHitTestObject(player, wall);
		//if we hit the wall, put the player back to its previous position
		player.x = prevX;
		player.y = prevY;
		//this while loop moves the player right next to the wall
		//before we move to the next frame
		while(!HitTest.complexHitTestObject(player, wall)){
			var newX2 = (player.x-mouseX)/50;
			var newY2 = (player.y-mouseY)/50;

GIV Maze Sample 1

By , June 25, 2013 11:02 am

Here is a link to download the files we worked on in our first class:

Sound Basics

By , March 26, 2013 2:23 am

1. Find a sound, mp3s work best.

2. Import the sound into Flash.

3. Add AS3 Linkage to the sound in the library

4. Instantiate and play the sound with code:

//instantiate an instance of the Drum1Sound sound
var sound:Sound = new Drum1Sound();
//play the sound;

5. Review class files from section 1.

6. Complete assignment 10. (1 week assignment)

Joe’s Graphic Game (working on it)

By , February 19, 2013 10:41 pm

Since all 3 sections of Game Tech I are working on their Graphic API assignment, I decided to create a version of my own. All assets for this assignment need to be created with the graphics API in AS3. I will try to finish it this week.

Controls: Arrow Keys to move target, and Z, X, C to shoot Laser.


Shooting with Timer Delay (updated w/ pause)

By , February 14, 2013 11:17 am

Here’s the source code:
Here’s an example that has lots of good stuff happening that you might be able to apply to your vertical shooter.