An AGS platformer (MariVania)

Started by Calin Leafshade, Wed 04/11/2009 15:26:40

Previous topic - Next topic

Calin Leafshade

I know this has come up before but i just thought I'd share my attempt at a tiny little "Tech Demo"

How does it feel to play? I tried to add in acceleration and stuff like that.. Is it believable?

http://www.thethoughtradar.com/AGS/Platformer7.zip

Arboris

Yes, it is. It feels very good.
 
Concept shooter. Demo version 1.05

Matti

Yep, nice and smooth. Good work.

Snake

Wow, Calin, that's great! It doesn't feel "AGS-ie" at all. Great work! I especially like how you made his hat flip up when falling down or decending from a jump... great job.
Grim: "You're making me want to quit smoking... stop it!;)"
miguel: "I second Grim, stop this nonsense! I love my cigarettes!"

Calin Leafshade

Quote from: Snake on Wed 04/11/2009 17:37:49
I especially like how you made his hat flip up when falling down or decending from a jump... great job.

I stole the idea from somewhere... I wont say where... It's secret

DoorKnobHandle

Bouncy Boxing? :p

Haven't checked this out yet but will asap.

Calin Leafshade

Ramps!

http://www.thethoughtradar.com/AGS/woop.zip

mario assaults draculas castle.

But you'll notice that the ramps dont work.

Im using regions to define platforms.. so Region 1 defines the top of a platform and will not allow the character to fall through it and region 2 defines obstacles that cant be passed through horizontally. Obviously this means that slanted ramps dont work.

Any ideas?


TerranRich

Colin, you magnificent bastard, your platformer works like a charm and feels smooth... except for the multi-jumps. If you hold down "up" you can jump endlessly, which not many platformers actually do. This can be easily fixed, however.

Now I know why you asked about room width limitations. ;)
Status: Trying to come up with some ideas...

Crimson Wizard

That looks realy cool. Did you draw these background graphics?

Arboris

Quote from: Crimson Wizard on Wed 04/11/2009 22:56:16
That looks realy cool. Did you draw these background graphics?

My guess was a tile set from castlevania actually
 
Concept shooter. Demo version 1.05

Calin Leafshade

Quote from: Crimson Wizard on Wed 04/11/2009 22:56:16
That looks realy cool. Did you draw these background graphics?

HAH! I wish kiddo.

Calin Leafshade

So I had a quick try at parallaxing.

I paint the background (the sky) onto the room surface at the viewport but it seems to lag slightly and is especially noticeable if you jump.

Any ideas why that might be?

Code: ags

DrawingSurface *surface = Room.GetDrawingSurfaceForBackground();
surface.Clear();
surface.DrawImage(GetViewportX(),GetViewportY() , 14);


http://www.thethoughtradar.com/AGS/Platformer.zip

Wonkyth

#12
This looks nice.
However, when I tried the second one you uploaded, I sometimes fell through the top of staircases.
Sometimes with disastrous results:


EDIT:
Having a look at the parallax problem, I'm haven't really got any ideas, except that it might just be general lagging.
I did notice that when you move to the left, you get a similar thing, but when you move to the right, it's fine.
You get this when you walk to the left:




My thoughts on the ramp problem are that perhaps if you were within a certain distance of the surface of the ramp(a couple of pixels should be enough), then you could make it so that....Arg! I cant explain!
I'll try pseudo
Code: ags

if (this.Location == StairAreaType.Right)                    //if the thingy is within the special ramp area of a ramp
{                                                                                 //going up to the right

this.HorizontalRightMovement = const_ALittle;          //make it so that pressing the right arrow makes you
                                                                                   //move to the right AND up a little
this.HorizontalLeftMovement = -const_ALittle;           //make it so that pressing the left arrow makes you
                                                                                   //move to the left AND down a little
                                                                                   //it should be set up so that when it's moved it stays 
                                                                                   //within the ramp area
}


I hope I'm making sense, and I hope it works... :P
"But with a ninja on your face, you live longer!"

Scarab

Well if you created a hollow rectangle GUI which makes the screen smaller, then the viewport would be able to load behind it, which would stop the background from showing you its pink bits.

Wonkyth

That would work, except that you'd still get the weird squashing effect whenever you jumped.
"But with a ninja on your face, you live longer!"

Calin Leafshade

#15
I really can't see why this doesnt work.

I paint the background everyframe at the viewport.

The only thing i can think of is that the GetViewPort functions dont return a pixel-perfect result.

EDIT: FIXED!

The following code seems to return the viewport more accurately (if the viewport is following the player)

Code: ags

int BGx = cEgo.x - 160;
if (BGx < 0) BGx = 0;
if (BGx > Room.Width - 320) BGx = Room.Width - 320;
int BGy = cEgo.y - 100;
if (BGy < 0) BGy = 0;
if (BGy > Room.Height - 200) BGy = Room.Height - 200;

Calin Leafshade

So I've done another build to show off the parallaxing a little more but does it hurt your eyes to play?

it seems blurry to me.. is it just my monitor?

http://www.thethoughtradar.com/AGS/Platformer2.zip

Arboris

Hm, it's sharp here.

Try putting the filter on '4x nearest-neighbour' in the game options, and don't allow your monitor to manually stretch it (keep the aspect ratio).   
 
Concept shooter. Demo version 1.05

Denzil Quixode

#18
It doesn't look blurry to me. Looks pretty awesome, in fact :)

My only (minor) gripe about the way Mario moves is that you can't control the height of the jump by tapping the key instead of holding it down. I don't know how difficult that would be to script, though. If you managed that I think you'd get it feeling close to indistinguishable from the original game.

Calin Leafshade

Quote from: Denzil Quixode on Thu 05/11/2009 11:16:42
you can't control the height of the jump by tapping the key instead of holding it down.

Yeah i'm working on this but havent come up with a decent way of implementing it yet.

SMF spam blocked by CleanTalk