Platform Behavior does need improvements.

Discussion and feedback on Construct 2

Post » Sat Apr 14, 2012 6:45 pm

I know there are obviously other things that you want to do first, Ash, and there is a lot on that to-do list, but I do feel the need to point this out.

The platform behavior is neat, but the Classic behavior has some things that the C2 version doesn't:

- Variable jumping height
- Air speed options
- Inverse control
- Bunny hopping option
- Being able to fall through platforms (would be nice to be able to do it with a custom key, too)

But I also think that the behavior has some other limitations that could be addressed that limits what people can do with it. Namely, rotations. Some platformers (Sonic being one of the first examples) allow platforming characters to rotate on slopes, walk/run on walls, that sort of thing.

I've tried to do such things with the custom movement, but I'm pretty sure it's extremely difficult to do, because methods from Classic don't work very well at all. Physics... Just as difficult, if not moreso. And the only other alternative is making your own movement through pure events, and that can get very complex indeed (especially if you're trying to create something momentum-based like Sonic).

I think it might be beneficial to create an "Advanced Platform Behavior" that gives users much more flexibility and options on how they want to make a platform character to move. Do they want rotations on slopes, or not? How about being able to slide or roll down a slope to pick up speed? Stick to walls and ceilings, or fall off if there's not enough speed? That sort of thing.

It would unshackle more than a few of the limitations of the behavior while also giving users the option to start off with the "basic" version, and moving on to the more advanced options if they want them. Slope rotations, believe it or not, would go along way to extending what a platform character can do.

With that in mind, I imagine an "Advanced Platform Behavior" (or just an improved regular behavior) would have these features:

- Slope Rotations
- Slope acceleration/deceleration
- Collisions based on objects/families as well as the Solid/Jump-Thru behaviors
- Toggling collisions with particular 'solid' objects on a per-instance basis (rather than turning off the actual solid itself)
- Some other stuff I can't be arsed to think of right now

Long story short, if you can faithfully recreate Sonic platform physics using such a behavior, I would say that would be the point where you can say 'mission accomplished'. Can't be that hard, surely. :)

I know there's a LOT on your plate, but I guess it really can't hurt to make suggestions.
B
94
S
37
G
11
Posts: 404
Reputation: 11,275

Post » Sun Apr 15, 2012 1:02 am

Thanks for the ideas - the Platform behavior is definitely still missing some important things, and I guess this is a good reminder what's left to do.

However I think a Sonic-like movement is quite a tall order... it would involve significant changes to how the Platform behavior works, and it's already an extremely complicated behavior (try figuring out the algorithms for jump-thrus at arbitrary gravity angles...) Still, I'll have a play at some point and see if I can figure out how a Sonic-type movement works, but it's a pretty clever movement type, I'm not sure I'll be able to figure it out!
Scirra Founder
B
359
S
214
G
72
Posts: 22,952
Reputation: 178,600

Post » Sun Apr 15, 2012 1:20 am

Interesting though. I never thought about how complex Sonic's movement is... it actually might be. Hmm...
B
47
S
10
G
6
Posts: 455
Reputation: 8,326

Post » Sun Apr 15, 2012 2:03 am

Sounds like a good topic for a contest....
Image Image
B
161
S
48
G
90
Posts: 7,356
Reputation: 66,767

Post » Sun Apr 15, 2012 2:17 am

I agree!
B
47
S
10
G
6
Posts: 455
Reputation: 8,326

Post » Sun Apr 15, 2012 2:38 am

I was just wondering how to make my bot graphics rotate to move on angles! Glad I saw this thread. Answered that question.
Check out "Extraordinary!" the Superhero Card Game: www.armchairadventuring.com
B
13
S
2
Posts: 35
Reputation: 1,298

Post » Sun Apr 15, 2012 2:44 am

Classic didn't have variable jump height stuff out of the box, but the same methods used for it in Classic can be used in C2. Basically, on release of the jump button while jumping you can set VectorY to something like JumpStrength / 2 or -100 or whatever to kill the upward momentum. Works pretty swell.
B
58
S
20
G
7
Posts: 305
Reputation: 8,804

Post » Sun Apr 15, 2012 3:25 am

@Ashley
There is a sonic fan site, that goes into detail about all its physics.
Scroll down and you will see the sonic loop slope.

http://info.sonicretro.org/SPG:Solid_Tiles
B
50
S
11
G
7
Posts: 274
Reputation: 8,146

Post » Sun Apr 15, 2012 5:37 am

Believe it or not, Ashley, there's actually an entire guide on how Sonic physics works. The page linked in PixelPalette's post above is just one page in the whole thing!

Sonic Physics Guide

Plus,you can also check out the Classic version of the Sonic engine I'm trying to replicate in C2 (with some difficulty). The physics, to my knowledge, are quite accurate, so it's a good reference as well. Best to look at both, since the event-based engine works a bit differently when it comes to stuff such as rotations, due to the guide being based around methods used in the Genesis/Mega Drive Sonic games.

Really, creating a more advanced Platform Behavior based around Sonic physics may seem hard, but Sonic fans have spent years figuring out how it works. Obsessive, but it does have benefits. :) Build a solid framework based around those physics, and then provide users with options to be as flexible as they want with it, and then you have a behaviour that will let you do more than what is there right now, I think.

Speaking of which, Ash, did you get that PM I sent you about anglelerp() and RotateAngle()?

Edit: Fixed the links. And just to note, even Mario could run on walls at times in Super Mario World. Food for thought.Candescence2012-04-15 13:23:34
B
94
S
37
G
11
Posts: 404
Reputation: 11,275

Post » Sun Apr 15, 2012 1:32 pm

I dunno about all that, but basic slopes, collisions, and moving platform interaction could be improved. You can tidy em up with events but you can only go so far.

Yeah the C2 platform behavior doesn't have everything the CC one did but I'm kind of glad to be honest ^^; there were a lot of useless properties.Tokinsom2012-04-15 13:35:19
Image
B
225
S
27
G
13
Posts: 1,774
Reputation: 18,024

Next

Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 6 guests