Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - NateTheGreatt

Pages: 1 2 3 [4] 5
61
help / Re: howdy
« on: Thu, Jul 22, 2010 »
Welcome to the forums.

Check out this thread for pixel-perfect collision:

http://flixel.org/forums/index.php?topic=1380.0

62
help / Re: decent tile map editor
« on: Thu, Jul 22, 2010 »

63
help / [SOLVED] Enemy AI - Jumping up to a platform
« on: Thu, Jul 22, 2010 »
I'm trying to implement some basic enemy AI into my small project. I already have a lot of aggressive AI set up into my enemies so that they chase after the player when the player enters a certain "aggro radius".

Now I'm trying to have my enemies jump up a tileblock if they are chasing the player and they run into one.

Any suggestions? I'm really stumped on this one.

64
help / Re: Player hitbox?
« on: Wed, Jul 21, 2010 »
Thanks a bunch dude  ;D

65
help / Re: Player hitbox?
« on: Wed, Jul 21, 2010 »
Unfortunately that's not doable since the collision function relies on the FlxSprite using the built in velocity vector stuff. This means that whichever sprite you use for movement you must use for collisions.

May I ask why you want to separate your player from your collision hitbox? Usually any issues can be solved by resizing the collision box.

Resizing... the... collision.. box..?

*face palm*

How do I do that? That's exactly what I'm trying to do -_-; I had no idea that that feature was built in.

66
help / Re: Player hitbox?
« on: Wed, Jul 21, 2010 »
No, you can manually add FlxSprites to a FlxSprite without using add()

Basically instead of adding the child sprite to a FlxGroup which renders and updates the sprite for you, you call the child sprites render and update function from the parent sprite like so:
-snip-

Aahh okay that's awesome. I'm still having trouble figuring this out, though. I'll just lay out exactly what I want done and see if you can help me with it:

My original player class has all of the movement and attack movements and all that fun stuff in it (obviously). Is there any way I can retain that code and have my hitbox collide with the tilemap as opposed to my player? So basically having the hitbox handle all collisions and the player handle all movement (that the hitbox corresponds with).

67
help / Re: Player hitbox?
« on: Wed, Jul 21, 2010 »
They way I'm using at the moment is to call a function in the player class that updates the position of the sprites relative to the collidebox directly after calling collide in the playstate.

ie: In the playstate

collide
player.update_sprite_locations
overlap

Do I have to move all of my player's update code and put it into the new FlxGroup player class?

68
help / Re: Player hitbox?
« on: Wed, Jul 21, 2010 »
This thread may be of help http://flixel.org/forums/index.php?topic=2063.0

We're discussing how to have a player that consists of multiple FlxSprites which move relative to a main body sprite at all times.

Yeah, I was just reading through that. I'm just having a bit of trouble figuring out how to make the hitBox sprite collide with the map and have the player stick to it without reworking my entire Player class

69
help / [SOLVED] Player hitbox?
« on: Wed, Jul 21, 2010 »
What would be the best method to use when trying to implement hitboxes? For example on my player: Should I make my player class extend FlxGroup and add a player and  hitbox to the class?

I'm trying to make it as modular as possible

70
help / Re: Rotate camera?
« on: Fri, Jul 16, 2010 »
I don't know if Flixel has anything that could help with rotating the camera :/.

A Vcam might work. I used to use them back when I did animation. Take a look at this and see if there's anything you can do with it:

http://bryanheisey.com/blog/?p=12

Best of luck, and let us know if you come up with anything!

71
Worked like a charm. Thanks!

72
help / Re: Player "Shaking"
« on: Fri, Jul 16, 2010 »
Maybe I just have a bad flashplayer.

I see it, too.

73
help / [SOLVED] Larger Tilemaps than SWF resolution?
« on: Fri, Jul 16, 2010 »
Right now I have a tilemap that is larger than the SWF resolution and my player is not colliding with the tiles outside of the resolution.

Is there any way to make large tilemaps or do I need huge SWF resolutions?

74
games / Re: [Finished] Beat Boost
« on: Tue, Jul 13, 2010 »
This game is really, REALLY, cool. Reminds me of Audiosurf (I wouldn't be surprised if you were inspired by it).

You chose some good music :D. I loved all of the tracks.

While this is a fantastic idea for a game and the gameplay is solid so far, it is a little boring. I felt myself amazed at what you did when I first began the game and was very impressed, but by the second song I realized that I was just sitting there listening to music and hitting the up key and the down key here and there.

The 8bit aesthetics for the game are all there. The surf-spray emitter is freaking sweet and the HUD is elegant. If you could implement more gameplay features that the user could interact with I think you would have a home run hit game here.

Again this is a fantastic idea for a game but I think that you need to do something to make it more engaging. It has a ton of potential.

75
help / Re: Pixel-perfect Tilemmap collisions
« on: Tue, Jul 13, 2010 »
Just make that other objects are not part of the tilemap....

Yeah, sorry, I confused myself before on how I want the game to work.

This is perfect, thanks

76
help / Re: Pixel-perfect Tilemmap collisions
« on: Mon, Jul 12, 2010 »
That looks like a good solution, but I have one problem:

Using this, how can I add, say, cloud platforms to my game? Or other elements of the map that require interactivity by other objects of the game?

77
help / Pixel-perfect Tilemmap collisions
« on: Mon, Jul 12, 2010 »
I'm trying to implement a pixel perfect collision system between the player and tilemap of my game. I'm using the FlxHitTest class from the forums, but that only works with FlxSprites.

Any suggestions on how I could go about doing this?

78
help / Re: Rocket launching movement
« on: Tue, Jul 6, 2010 »
Ah okay, that makes sense. Thank you.

For anyone else with a similar problem: don't forget to include a super.update(). I forgot to include that and it had me stumped for awhile xD.

Here is my fully working class code:
Code: [Select]
package Entities
{
import org.flixel.*;

public class Rocket extends FlxSprite
{

[Embed(source = '../Images/Rocket.png')] private var ImgRocket:Class;

[Embed(source = '../Sounds/rocket.mp3')]
private var soundRocket:Class;

private var ignited:Boolean;
private var leftOrRight:Boolean
private var counter:Number = 0;
private var soundPlayed:Boolean = false;

public function Rocket(x:Number, y:Number, type:Boolean):void
{
super(x, y, ImgRocket);

leftOrRight = type;

ignited = false;
}

override public function update():void
{

if (!ignited)
{

velocity.y = 16;

if (leftOrRight) {
velocity.x = 38;
} else {
velocity.x = -38;
}

counter += FlxG.elapsed*2;
if (counter >= 1)
{
ignited = true;
counter = 0;
}

}

if (ignited)
{
acceleration.y = -500;
//velocity.y = -500;
velocity.x = 0;
}

super.update();

}

}

}

79
chat / Re: Aviary Music Creator
« on: Tue, Jul 6, 2010 »

80
help / Rocket launching movement
« on: Tue, Jul 6, 2010 »
I'm fairly new to AS3 and Flixel. I've only been practicing AS3 for a few months, and Flixel for a few short weeks. I've created a simple vertical scrolling space-shooter game.

I'm trying to animate a rocket shoot out from the side of the spaceship down at a short angle, and then launch forward. How could I go about doing this? I tried to figure it out and this is as far as I got (this code is in the update() function of my Rocket class):

Code: [Select]
if (!ignited)
{
velocity.y = 50;

if (leftOrRight) {
velocity.x = 50;
} else {
velocity.x = -50;
}

ignited = true;
}


if (ignited)
{
velocity.y = 500;
velocity.x = 0;
}

I'm still very unfamiliar with the movement controls of Flixel. Any suggestions?

Pages: 1 2 3 [4] 5