Be a Supporter!
Response to: God damn fucking cops, Posted October 4th, 2009 in General

This thread is full of fabs and fails.

Response to: realtime battle Posted October 3rd, 2009 in Game Development

OP here how you do it,
1) Learn actionscript
2) Come back and ask question in a more inteligent and well thought out way if you can't figure it out after learning AS

3) Punch self in face
Response to: Your favorite flash FPS games Posted October 3rd, 2009 in Game Development

At 10/3/09 04:12 AM, simonhason wrote: "Sierra 7"

HALO RIPOFF

Response to: AS3, how to choose the highest var? Posted September 26th, 2009 in Game Development

Oh ok, thanks. I hadn't heard of Math.max before.

AS3, how to choose the highest var? Posted September 26th, 2009 in Game Development

I have a piece of code right now which subtracts two variables. The problem is, one of them is actually the average of two variables being subtracted from one. Let me show you:

var1-(var2+var3)/2;

Now this work's okay, but instead of taking the average of those two variables, I want it to choose the highest one.

This is in a movement code by the way, so if the player is only moving right (var2) and not moving at all up or down (var3) then the amount taken away from var1 is half as much as i would like it to be. It also means diagonal movement will give too much in comparison.

Thanks in advance for any help you can provide, :D

Response to: Were going to die. Posted September 26th, 2009 in General

December 21st, 2012.
End o' Story

Response to: Collision detection problem Posted September 20th, 2009 in Game Development

I was going to do that later, but I'm just adding to it function by function, Il probably do that now or tomarrow though.

Response to: Show NG your desktop! Posted September 20th, 2009 in General

Eat it bitches!

Show NG your desktop!

Response to: Collision detection problem Posted September 20th, 2009 in Game Development

I haven't but i guess that makes sense. I didn't think that would affect it in any way.
Just tested it, and it works perfectly. Thank you very much!

Response to: Sony vs Microsoft Posted September 20th, 2009 in General

Who ever wins, we lose

Response to: Funny thread title pairs. Posted September 20th, 2009 in General

At 9/20/09 10:13 AM, andy70707 wrote: I found this kinda funny:

Oh damnit. Beat me by 3 minutes.....

Response to: Funny thread title pairs. Posted September 20th, 2009 in General

Heres one

Funny thread title pairs.

Response to: Few questions of AS3 Posted September 20th, 2009 in Game Development

At 9/20/09 05:10 AM, GustTheASGuy wrote: You've got everything wrong, so AS3 will only give you pain. Stick to AS1.

<sarcasm>Another shining example of how to be kind and helpful at the same time!</sarcasm>

Response to: levels Posted September 20th, 2009 in Game Development

instead of frame numbers, you could try labeling the frames, so instead of

on(Press){
gotoAndPlay(4);
}

It would be

on(press){
gotoAndPlay("win");
}
Collision detection problem Posted September 20th, 2009 in Game Development

I swear this is my last question for today.
Maybe

Ok, I have a character (just a box), a V-Cam and 4 walls on the main stage. The walls aren't MC's so they don't matter.
My code is just a movement script for the character, with the V-Cam following. The only problem is the walls. The character stops when he hits the walls, but he gets stuck halfway through, and you can slowly wiggle him out. I have accounted for the width of the character already, so thats not the problem. BTW, the width of the character is 30 pixels, and the height is also 30.
Any help would be greatly appreaciated.

TL;DR - Guy gets stuck in walls, already accounted for height and width.

Heres the code:

var up:Boolean = false;
var down:Boolean = false;
var right:Boolean = false;
var left:Boolean = false;
var xspeed:Number = 0;
var xspeedup:Number = 0.5;
var xdecay:Number = 0.95;
var yspeed:Number = 0;
var yspeedup:Number = 0.5;
var ydecay:Number = 0.95;
function keyDowns(event:KeyboardEvent) {
	if (event.keyCode == 87) {
		up = true;
	}
	if (event.keyCode == 83) {
		down = true;
	}
	if (event.keyCode == 68) {
		right = true;
	}
	if (event.keyCode == 65) {
		left = true;
	}
}
function keyUps(event:KeyboardEvent) {
	if (event.keyCode == 87) {
		event.keyCode = 0;
		up = false;
	}
	if (event.keyCode == 83) {
		event.keyCode = 0;
		down = false;
	}
	if (event.keyCode == 68) {
		event.keyCode = 0;
		right = false;
	}
	if (event.keyCode == 65) {
		event.keyCode = 0;
		left = false;
	}
}
function xmove(Event) {
	if (right == true) {
		xspeed+=xspeedup;
	}
	if (left == true) {
		xspeed-=xspeedup;
	}
	if (left == false && right == false) {
		xspeed*=xdecay;
	}
	player.x+=xspeed;
}
function ymove(Event) {
	if (up == true) {
		yspeed-=yspeedup;
	}
	if (down == true) {
		yspeed+=yspeedup;
	}
	if (down == false && up == false) {
		yspeed*=ydecay;
	}
	player.y+=yspeed;
}
function limits(Event) {
	if (xspeed>=15) {
		xspeed = 15;
	}
	if (yspeed>=15) {
		yspeed = 15;
	}
	if (xspeed<=-15) {
		xspeed = -15;
	}
	if (yspeed<=-15) {
		yspeed = -15;
	}
}
function walls(Event) {
	if (player.x>3389.0) {
		player.x=3389.0-1;
	}
	if (player.y>3301.4) {
		player.y=3301.4-1;
	}
	if (player.x<-581) {
		player.x=-581+1;
	}
	if (player.y<-669) {
		player.y=-669+1;
	}
}
function camfollow(Event) {
	vcam.y=player.y;
	vcam.x=player.x;
}
stage.addEventListener(Event.ENTER_FRAME, walls);
stage.addEventListener(KeyboardEvent.KEY_DOWN, keyDowns);
stage.addEventListener(KeyboardEvent.KEY_UP, keyUps);
stage.addEventListener(Event.ENTER_FRAME, xmove);
stage.addEventListener(Event.ENTER_FRAME, ymove);
stage.addEventListener(Event.ENTER_FRAME, limits);
stage.addEventListener(Event.ENTER_FRAME, camfollow);
Response to: Am I gonna die? Posted September 20th, 2009 in General

stop ripping off final destination

Response to: Is As2 Keycode The Same In As3 Posted September 20th, 2009 in Game Development

OK ok...thanks anyways. I've only used AS so far so I wouldn't have known that.

Is As2 Keycode The Same In As3 Posted September 20th, 2009 in Game Development

Just answer the title please.

Response to: AS3 Problem with walls. Posted September 20th, 2009 in Game Development

Heh whoops, I forgot to thank you for helping me...
Thanks!
:D

Response to: AS3 Problem with walls. Posted September 20th, 2009 in Game Development

At 9/20/09 04:03 AM, Diki wrote: When Player.x is greater than or equal to 650 it is sent to x-coordinate 0. Then when Player.x is less than or equal to 0 it is sent to x-coordinate 650. Thus starting a loop.

Yeah I actually figured this part out and went to change it to 649 and so on, but I must have messed up that part because it didn't work.

AS3 Problem with walls. Posted September 20th, 2009 in Game Development

I have simple code that makes it so when the character gets to the edge of one part of the screen, they go to the other side, an effect which you've no doubt seen before. Unfortunatly, my code will only work if one half of it is there. Lemme show you.
This wont work:

function walls(Event) {
if (player.x>=650) {
player.x=0;
}
if (player.y>=500) {
player.y=0;
}
if (player.x<=0) {
player.x=650;
}
if (player.y<=0) {
player.y=500;
}
}

However, both of these codes will work, but only without the other.

function walls1(Event) {
	if (player.x>=650) {
		player.x=0;
	}
	if (player.y>=500) {
		player.y=0;
	}
}
function walls2(Event) {
if (player.x<=0) {
		player.x=650;
	}
	if (player.y<=0) {
		player.y=500;
	}
}

So yeah if anyone could help that would be awesome.

Response to: Rule Reminder: system32 Posted September 20th, 2009 in General

Yessir.

Response to: So I just had a nosebleed... Posted September 20th, 2009 in General

Whoop de fucking do for you.
Same shit happens to me all the time.

Response to: Hello kitty gun Posted September 19th, 2009 in General

Dont resurect an '07 thread about a pic we have all seen before

Response to: New virus. Oh fuck Posted September 19th, 2009 in General

Creepily enough, I just finished watching I am Legend on Sky 3, and at the end they say during christmas 2009 the virus was released.

I really hope they meant last year.

Response to: Pale or tanned? Posted September 19th, 2009 in General

At 9/19/09 06:15 PM, knightsofthecircle wrote: The sun is the reason why they're is so much racism in the world today. I propose we blow out the sun in order to aboloish racism! No one can be racist when we're living in sub-arctic conditions and living like mole men. It's GENIUS!!!

Because having life on this planet is for all the retards not living like idiots underground.

Response to: If Tomfulp... Posted September 19th, 2009 in General

At 9/19/09 01:14 PM, Pokemonpoeguygcn wrote:
At 9/19/09 01:10 PM, yugimt wrote: Were to delete one user one day for no reason, who would it be?
Me!

Why'd you destroy the joke, you sick little fucktard.

Response to: Wierd text loading problem? Posted September 19th, 2009 in Game Development

Pigs just flew and shat bicks on my head.
I can't believe I just saw a mod call himself a "nooby noob" and ask for help.

Response to: If Tomfulp... Posted September 19th, 2009 in General

With no doubt in my mind I can say it would have to be you.

Response to: Why do we love cock jokes? Posted September 19th, 2009 in General

Maybe we need to make jokes about vaginas instead.