You need a Grounds Gold Account to post on the NG BBS! If you don't have one, click here to sign up now! It's fast, free, and easy — and opens up tons of great NG features!

Author Search Results: 'Woadraiders'

We found 561 matches.


<< < > >>

Viewing 91-120 of 561 matches. 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 91419

91.

None

Topic: Phantom problem, no error thrown

Posted: 06/29/09 03:33 PM

Forum: Flash

Yeah, I'd use a for-loop instead.

for(var i:Number = 0;i< collectibleArray.length;i++)
{
    collectibeArray[i].descend();
}

92.

None

Topic: Phantom problem, no error thrown

Posted: 06/29/09 03:21 PM

Forum: Flash

My guess is that they were given a NaN for one of thier coordinates sometime while falling, or SOME field on them is NaN.


93.

None

Topic: A noob question.. xD

Posted: 06/29/09 03:19 PM

Forum: Flash

If testnum is the dynamic text field's instance name, then

gameBox.testnum.text = "3";


94.

None

Topic: flash team

Posted: 06/29/09 03:17 PM

Forum: Flash

What's the money split like?


95.

None

Topic: Need Artist for: Revert to Growth

Posted: 06/29/09 02:22 PM

Forum: Flash

The artist has to pay to work with you?


96.

Shouting

Topic: As3 - Real Map Object Problem...

Posted: 06/29/09 02:16 PM

Forum: Flash

I don't understand what your questions are, could you please be way clearer and speak in flowing english?

The one thing I did understand was that you wanted buildings to go semi-transparent when you walk behind them. You can just change its .alpha property after you know if you're behind it or not. This code will probably be almost identical to your platform hitting code.


97.

None

Topic: Programming question

Posted: 06/29/09 02:08 PM

Forum: Flash

Well, Array.splice takes two parameters, and you didn't get either of them right.
Array.splice(startIndex:Number, length:Number);

What you should do is

var collisiondetection:Collision=new Collision();
var bulletArray:Array = new Array();

var timer:Timer = new Timer(2000);
timer.addEventListener(TimerEvent.TIMER, testShots);
timer.start();

function testShots(e:TimerEvent):void {
	var darkShot:DarkShot = new DarkShot();
	addChild(darkShot);
	bulletArray.push(darkShot);
	darkShot.x = darkTester.x;
	darkShot.y = darkTester.y;
}


function enterFrameFunction(Event) 
{
	for (var i:uint=0; i<bulletArray.length; i++)
	{
		bulletArray[i].y += 3;
		if(bulletArray[i].y >= 400)
		{
			this.removeChild(DisplayObject(bulletArray[i]));
			bulletArray.splice(i,1);
			i--;
			continue;
		}
		if (collisiondetection.isColliding(player, bulletArray[i], 1))
		{
			trace("collision");
		}
	}
}

stage.addEventListener(Event.ENTER_FRAME, enterFrameFunction);

You could take this a step furthur, and create a DarkShot class that has a function called Update():Boolean. So your enterFrameFunction would look something like this:

function enterFrameFunction(e:Event):void
{
	for (var i:uint=0; i<bulletArray.length; i++)
	{
		if(bulletArray[i].Update)
		{
			this.removeChild(DisplayObject(bulletArray[i]));
			bulletArray.splice(i,1);
			i--;
			continue;
		}
		if (collisiondetection.isColliding(player, bulletArray[i], 1))
		{
			trace("collision");
		}
	}
}

.... Inside the DarkShot Code

public function Update():Boolean
{
	this.y += 3;
	if(this.y >= 400)
	{
		return true;
	}
	return false;
}

98.

None

Topic: Requesting Programmer

Posted: 06/29/09 01:53 PM

Forum: Flash

Those look really cool, can't wait to see this game done


99.

None

Topic: movement code help

Posted: 06/29/09 01:40 AM

Forum: Flash


100.

None

Topic: GapTimer not working

Posted: 06/29/09 01:13 AM

Forum: Flash

Lolz0rs. Your nesting was off, you should make use of that auto-formatter built into flash, cause your code was butt ugly.

onClipEvent (load)
{
	moveSpeed = 5;
	_root.laser._visible = false;
	laserCounter = 1;
	startgaptimer = false;
	gaptime = 00;
}
onClipEvent (enterFrame) 
{
	if (_name == "laser")
	{
		if (Key.isDown (Key.SPACE) and !startgaptimer)
		{
			laserCounter++;
			_root.laser.duplicateMovieClip ("laser" + laserCounter,laserCounter);
			_root["laser" + laserCounter].startgaptimer = true;
			startgaptimer = true;
		}
		else
		{
			if (startgaptimer)
			{
				gaptime++;
			}
			if (gaptime > 10)
			{
				startgaptimer = false;
				gaptime = 0;
			}
		}
	}
}
onClipEvent (load) 
{
	laserMoveSpeed = 15;
	_x = _root.player._x + 20;
	_y = _root.player._y + 10;
}
onClipEvent (enterFrame)
{
	_x += laserMoveSpeed;
	if (_x > 840)
	{
		this.removeMovieClip ();
	}

	for (i = 1; i < 50; i++)
	{
		if (this.hitTest (_root["enemy" + i]))
		{
			_root["enemy" + i].gotoAndPlay (7);
			this.removeMovieClip ();
		}
	}

}

101.

None

Topic: How Do I Have An Mc Bounce In W/as2

Posted: 06/29/09 12:48 AM

Forum: Flash

So... Not a tweener library? Not even the built in ones?

You're looking for something like,

SomeLibrary.BounceLikeABall(myBall);

?

I'm not trying to be sarcastic or anything, but if its not the tweener libraries then idk, I've never heard of something like that.


102.

None

Topic: How to remove new lines from string

Posted: 06/29/09 12:45 AM

Forum: Flash

'/n' has to be typed in by hand, when you press enter though, the char code of that is 13. Also, your code wouldn't get out spaces, so I used this trick to get those out too, they ended up being 160 and 32. 32 is the character code for a space right after a letter, and 160 is the character code for extra white space. Pretty neat stuff actually. So here's what I've got.

var spacedString:String = test.text;
var noSpace:String = new String();
for (var l:Number=0; l<=spacedString.length; l++) 
{
	if (spacedString.charAt(l).charCodeAt() != 13 && spacedString.charAt(l).charCodeAt() != 160 && spacedString.charAt(l).charCodeAt() != 32) 
	{
		noSpace += spacedString.charAt(l);
	}
}

103.

None

Topic: Preloader/AS3 problem

Posted: 06/29/09 12:31 AM

Forum: Flash

Haha, the smart programmers are ;), but people still submit as2 things all the time, and I'm pretty sure just about every animation out there is in an as2 document anyways.

Gl with your animating.


104.

None

Topic: GapTimer not working

Posted: 06/29/09 12:29 AM

Forum: Flash

I'm pretty sure it doesn't work because you never set startgaptimer to true after you make a laser.
Try this plz.

onClipEvent (load) {
    moveSpeed = 5;
    _root.laser._visible = false;
    laserCounter = 1;
	startgaptimer = false;
	gaptime = 00;
}
onClipEvent (enterFrame) {
if(_name == "laser") {
    if (Key.isDown(Key.SPACE) and !startgaptimer) {
        laserCounter++;
        _root.laser.duplicateMovieClip("laser"+laserCounter, laserCounter);
		_root["laser" + laserCounter].startgaptimer = true;
       startgaptimer = true;
    }
} else {
	if (startgaptimer){
		gaptime++;
	}
	if (gaptime>10){
		startgaptimer = false;
		gaptime = 0;
	}
}
}
onClipEvent (load) {
    laserMoveSpeed = 15;
    _x = _root.player._x + 20;
    _y = _root.player._y + 10;
}
onClipEvent (enterFrame) {
    _x += laserMoveSpeed;
    if (_x > 840) {
        this.removeMovieClip();
    }

	for (i = 1; i < 50; i++)
	{
		if (this.hitTest(_root["enemy" + i])) {
			_root["enemy" + i].gotoAndPlay(7);
			this.removeMovieClip();
		}
	}
	
}

105.

None

Topic: Preloader/AS3 problem

Posted: 06/29/09 12:22 AM

Forum: Flash

If you're just doing an animation, and you already have a working as2 preloader, then why are you bothering with as3 at all?


106.

None

Topic: Need some help...

Posted: 06/28/09 11:43 PM

Forum: Flash

Add me on aim, mibbygames. I'll try to answer your questions.


107.

None

Topic: Outside controll of scroll bar?help

Posted: 06/28/09 10:59 PM

Forum: Flash

In AS3, just figure out what line you need to go to and then do:
textWall.scrollV = targetLine;
myScrollyBar.scrollPosition = targetLine;

How to find the line you need to go to? Idk, find the index of where it occurs in the text, divide that by how many characters can fit on a line, then round down. This will take some adjustment if you have any newline stuff ("/n").

That's the best I can do for you.


108.

None

Topic: movement code help

Posted: 06/28/09 10:06 PM

Forum: Flash

The code looks fine to me, you have like gotoAndPlay(1) when it reaches the run frames right?

I'm really not sure what you're problem is, could you upload the swf?


109.

None

Topic: I feel extremely dumb. help? D:

Posted: 06/28/09 08:14 PM

Forum: Flash

So you installed it right? I just want to be clear, you say you set it up, but that doesn't mean just downloading it off the site right?


110.

None

Topic: Slope Problem.

Posted: 06/28/09 05:50 PM

Forum: Flash

Haha yeah no kidding, gl dude.


111.

None

Topic: Slope Problem.

Posted: 06/28/09 05:38 PM

Forum: Flash

Oops, I made that picture too fast. I meant worldX = 50, worldY = 0.


112.

None

Topic: Slope Problem.

Posted: 06/28/09 05:37 PM

Forum: Flash

At 6/28/09 05:12 PM, CHINESEMANZOMG wrote: Thanks for replying Woadraiders,

I'm afraid I got lost in your code. Basically what you do is that you get the current position of the object, then every time it moves you get that movement...then you tell the player to....what?

Sorry if I seem like a noob.

No, you don't sound like any noob I've ever ran into on these forums.

So, let's go through a short scenario.

1. When the game starts, nothing has been scrolled, worldX and worldY are 0 and 0.

2. The player moves right 5 pixels a frame, so 5 is added to worldX every frame.

3. An object gets added to the game, maybe a coin. We want this coin to be placed where the player is. So it's modernX and modernY is the current worldX + player.x and worldY + player.y.

We add worldX and worldY to offset however much has already been scrolled. Check out this picture, maybe it will help to visualize?

Slope Problem.


113.

None

Topic: Slope Problem.

Posted: 06/28/09 05:06 PM

Forum: Flash

If you have uneven terrain, but not a ramp (I would use exact math for that), then you should be using the optional flag in your hittest.

while(_root.ground.hitTest(_root.player.
_x, _root.player._y, true))

or

while(ground.hitTestObject(player.x, player.y, true))

It won't push you up until you get to the top of its bounding box if you use this.. About scrolling, I use two variables, worldX and worldY. When you create something, it sets its own fields called modernX and modernY.

public function Object(startX:Number, startY:Number, master:Gamescreen)
{
this.modernX = master.worldX + startX;
this.modernY = master.worldY + startY;
UpdatePosition(master);
}
public function UpdatePosition(master:Gamescreen):void
{
this.x = this.modernX - master.worldX;
this.y = this.modernY - master.worldY;
}
public function Update(master:Gamescreen):void
{
UpdatePosition(master);
//Do any AI here.
}

And when the player moves:

.....
master.worldX += this.xvel;
master.worldY += this.yvel;
.....

It's just an option, i do it this way because everytime I try using a Vcam it makes my HUD jitter =(.


114.

None

Topic: me need a programmer!!

Posted: 06/28/09 04:26 PM

Forum: Flash

Doesn't look 3d to me.


115.

None

Topic: As2: Sim Game. Help!!!

Posted: 06/28/09 04:06 PM

Forum: Flash

I think a simple setInterval, clearInterval would be cleaner.


116.

None

Topic: Player Move Using Wasd Controls?

Posted: 06/28/09 04:05 PM

Forum: Flash

Yeah they should.


117.

Elated

Topic: My graphics + your code = <3

Posted: 06/28/09 04:03 PM

Forum: Flash

I made a sweet game called Starbound with a dude named "HeliosStar".
Here's a link to the game, http://www.newgrounds.com/portal/view/41 6573.

Do you think I could script the ninja game? I added you to my aim and msn, I'm using a different hotmail account now.

Cya Taylor.


118.

None

Topic: :.Sponsorship.:

Posted: 06/28/09 03:31 PM

Forum: Flash


119.

None

Topic: Problems With Oop In As3

Posted: 06/28/09 03:30 PM

Forum: Flash

Since mass is a static field, you need to say DocClass.mass, there is only one instance of this mass variable, and you can only access it directly from the DocClass, not from any instances of the DocClass.


120.

None

Topic: How to create a button in AS3??

Posted: 06/28/09 05:44 AM

Forum: Flash


All times are Eastern Standard Time (GMT -5) | Current Time: 03:44 AM

<< < > >>

Viewing 91-120 of 561 matches. 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 91419