Warning: Declaration of thesis_comment::start_lvl(&$output, $depth, $args) should be compatible with Walker::start_lvl(&$output, $depth = 0, $args = Array) in /nfs/c03/h08/mnt/50298/domains/gamedev.michaeljameswilliams.com/html/wp-content/themes/thesis_18/lib/classes/comments.php on line 0

Warning: Declaration of thesis_comment::end_lvl(&$output, $depth, $args) should be compatible with Walker::end_lvl(&$output, $depth = 0, $args = Array) in /nfs/c03/h08/mnt/50298/domains/gamedev.michaeljameswilliams.com/html/wp-content/themes/thesis_18/lib/classes/comments.php on line 0

Warning: Declaration of thesis_comment::start_el(&$output, $comment, $depth, $args) should be compatible with Walker::start_el(&$output, $object, $depth = 0, $args = Array, $current_object_id = 0) in /nfs/c03/h08/mnt/50298/domains/gamedev.michaeljameswilliams.com/html/wp-content/themes/thesis_18/lib/classes/comments.php on line 0

Warning: Declaration of thesis_comment::end_el(&$output, $comment, $depth, $args) should be compatible with Walker::end_el(&$output, $object, $depth = 0, $args = Array) in /nfs/c03/h08/mnt/50298/domains/gamedev.michaeljameswilliams.com/html/wp-content/themes/thesis_18/lib/classes/comments.php on line 0

Warning: Cannot modify header information - headers already sent by (output started at /nfs/c03/h08/mnt/50298/domains/gamedev.michaeljameswilliams.com/html/wp-content/themes/thesis_18/lib/classes/comments.php:0) in /nfs/c03/h08/mnt/50298/domains/gamedev.michaeljameswilliams.com/html/wp-includes/feed-rss2-comments.php on line 8
Comments for Michael James Williams http://gamedev.michaeljameswilliams.com I help people make Flash games Mon, 12 Jun 2017 15:43:41 +0000 hourly 1 https://wordpress.org/?v=5.5.7 Comment on About by gameloon http://gamedev.michaeljameswilliams.com/about/comment-page-1/#comment-27068 Mon, 09 Sep 2013 19:49:41 +0000 http://gamedev.michaeljameswilliams.com/?page_id=2#comment-27068 buddy. i am a game developer. when i make a game for anyone what are the necessary steps to be sure that the world knows my company/I developed that game. I guess one is to have a preloader of my company, put my company logos in the game. What else can i do. Is it always best to sell games from FGL. what about selling it privately.

Comment on Learn ActionScript 3 by Following this Simple Avoider Game Tutorial by Maxwell http://gamedev.michaeljameswilliams.com/2008/09/17/avoider-game-tutorial-1/comment-page-8/#comment-26873 Mon, 26 Aug 2013 11:36:42 +0000 http://gamedev.michaeljameswilliams.com/?p=47#comment-26873 I have a problem, im using cs6, and i’ve done everything up until where i try to link the AS file with the symbol for the enemy, the name is correct, but it keeps saying that a defenition for the class could not be found in the classpath… Im not sure what i’ve done wrong here

Comment on Keep Updated by Erin http://gamedev.michaeljameswilliams.com/what-is-rss/comment-page-1/#comment-26785 Tue, 20 Aug 2013 03:30:11 +0000 http://gamedev.michaeljameswilliams.com/?page_id=17#comment-26785 Hi Michael,
I know this page is old, but I’m in dire need of your help for one of the tutorials, part 3, in particular. No matter what I do, I can’t get my PlayScreen to show up! It’s still a gray background! I changed the base class to AvoiderGame and the class shows as PlayScreen and the background is aligned correctly but it doesn’t show up everytime I test it! Could I email you the files to see what I am doing wrong?

Comment on AS3 Avoider Game Tutorial, Part 5: A Score and a Clock by Kohrak http://gamedev.michaeljameswilliams.com/2009/02/03/avoider-game-tutorial-5/comment-page-7/#comment-26717 Wed, 14 Aug 2013 04:26:27 +0000 http://gamedev.michaeljameswilliams.com/?p=231#comment-26717 there is a problem with dinamic clasic text in flash cs6, to solve it just use tlf text and it will solve your problem

Comment on Learn ActionScript 3 by Following this Simple Avoider Game Tutorial by Erin http://gamedev.michaeljameswilliams.com/2008/09/17/avoider-game-tutorial-1/comment-page-8/#comment-26715 Wed, 14 Aug 2013 01:56:41 +0000 http://gamedev.michaeljameswilliams.com/?p=47#comment-26715 GREAT tutorial but I keep running into an issue – I’ve even downloaded your code to look at it and I can’t find any difference. Maybe you could help…it says that I have a “Warning 1106: Empty statement found where block of code expected” on line 34 but I can’t seem to find any issue?
Here’s the code I have:

public function onTick( timerEvent:TimerEvent ):void
            avatar.x = mouseX;
            avatar.y = mouseY;

        if ( avatar.hitTestObject( enemy ) )


Comment on Learn ActionScript 3 by Following this Simple Avoider Game Tutorial by Kassie Brown http://gamedev.michaeljameswilliams.com/2008/09/17/avoider-game-tutorial-1/comment-page-8/#comment-26704 Tue, 13 Aug 2013 11:09:49 +0000 http://gamedev.michaeljameswilliams.com/?p=47#comment-26704 Hi, so how would you go about making this 2 player?

Comment on AS3 Avoider Game Tutorial, Part 6: Several Small Improvements by Taylor http://gamedev.michaeljameswilliams.com/2009/02/10/avoider-game-tutorial-6/comment-page-2/#comment-26666 Thu, 08 Aug 2013 07:08:28 +0000 http://gamedev.michaeljameswilliams.com/?p=268#comment-26666 I’ve been able to solve the hit detection well by checking distance between the enemies and the avatar. It looks something like this

for each (var enemy:Enemy in army)
                var distance = Math.sqrt(Math.pow(enemy.x - avatar.x, 2) + Math.pow(enemy.y - avatar.y, 2))
                if(distance <= 32.5)
                    avatarHit = true

This basically uses the distance formula to calculate the distance between the avatar and each enemy, and checks it against the radius of the avatar plus the radius of the enemy (in this case it’s 17.5 + 15 respectively). Obviously this only works for circles, but it’s still quite accurate.

Thanks for the awesome lessons, I really appreciate them.

Comment on Learn to Optimise your AS3 Code for Speed and Performance by Benjamin Guihaire http://gamedev.michaeljameswilliams.com/2010/02/10/optimise-as3-for-speed/comment-page-1/#comment-26651 Tue, 06 Aug 2013 14:01:35 +0000 http://gamedev.michaeljameswilliams.com/?p=1100#comment-26651 I would add, do not work on “blind” optimizations, profile your code , by using Adobe Scout for example to discover which portion of the code needs optimizations.


Comment on Understanding Flash’s Coordinate Systems by moneyisshame http://gamedev.michaeljameswilliams.com/2009/08/07/understanding-flashs-coordinate-systems/comment-page-1/#comment-26529 Thu, 25 Jul 2013 14:28:06 +0000 http://gamedev.michaeljameswilliams.com/?p=897#comment-26529 for the code

newBullet.x = hero.gun.x;
newBullet.y = hero.gun.y;

i would use this

newBullet.x = hero.x + hero.gun.x;
//get outside x, and then get inside x, add them together, become the one you are looking for, same as y
// + hero.gun.width if you want the bullet fire at the end
newBullet.y = hero.y + hero.gun.y;
// + hero.gun.height if you want the bullet fire at the bottom

Comment on Multidimensional Arrays in AS3 by moneyisshame http://gamedev.michaeljameswilliams.com/2010/01/13/multidimensional-arrays-in-as3/comment-page-2/#comment-26528 Thu, 25 Jul 2013 14:19:07 +0000 http://gamedev.michaeljameswilliams.com/?p=963#comment-26528 for 3D is it?:

 //start creating 2D z = 0
var firstRow:Array = [STONE, WATER, WATER, WATER, DIRT]; // y = 0
var secondRow:Array = [STONE, WOOD, WOOD, WOOD, DIRT];// y = 1
var thirdRow:Array = [STONE, STONE, WATER, WATER, DIRT]; //y = 2
var fourthRow:Array = [STONE, WATER, WATER, DIRT, DIRT];//y = 3
//stop creating 2D z = 0  x = 0       x = 1       x=2       x=3    x=4
var z0 = [firstRow, secondRow, thirdRow, fourthRow];

//start creating 2D z = 1
var firstRowZ:Array = [AIR, AIR, AIR, AIR, PLAYER]; // y = 0
var secondRowZ:Array = [STAIR, WOOD, WOOD, WOOD, STAIR];// y = 1
var thirdRowZ:Array = [AIR, CHEST, AIR, AIR, AIR]; //y = 2
var fourthRowZ:Array = [AIR, AIR , AIR, GEM, AIR];//y = 3
//stop creating 2D z = 1 x = 0 x = 1 x=2 x=3 x=4
var z0 = [firstRowZ, secondRowZ, thirdRowZ, fourthRowZ];

//start creating 2D z = 2
var firstRowZ2:Array = [AIR, AIR, AIR, AIR, AIR]; // y = 0
var secondRowZ2:Array = [AIR, AIR, LADYBUG, AIR, AIR];// y = 1
var thirdRowZ2:Array = [AIR, AIR, AIR, AIR, AIR]; //y = 2
var fourthRowZ2:Array = [AIR, AIR, AIR, AIR, AIR];//y = 3
//stop creating 2D z = 2 x = 0 x = 1 x=2 x=3 x=4
var z2 = [firstRowZ2, secondRowZ2, thirdRowZ2, fourthRowZ2];

var myLevel:Array = [z0,z1,z2];