-
Plaform game trouble
Hello, new to this forum :)
I'm having trouble with a platforming game of mine. I'm using the platform movement object -extension. I took an example from the chaos platform -game which is also using the same extension and also has this same problem.
The problem is, when the character is moving against a wall, or any other object it is colliding with, it starts alternating between the stopped and the walking animation. The situation I mean is, for example if in the level there is a box to pick up, and if the player moves next to the box and still keeps pressing the right or left button while next to it, when colliding with the box the animations just work weird, it looks like the character starts shaking.
My current basic events with it are:
Object is moving - Change animation sequence into Walking
Object is moving (negate) - Change animation sequence into Stopped.
Test for obstacle overlap - Selected object overlaps with an obstacle
Object is overlapping a backdrop
-
Re: Plaform game trouble
Heh, figured out a solution already. I'll just leave this here if someone needs help with similar stuff. :)
Just make another condition for the walking animation event, with GetXVelocity from the platform movement object, and make it so that it has to be more than +1 or less than -1 for the animation to start.
-
Re: Plaform game trouble
Another way you can do it is like this
Object is standing on ground
Negate object is moving
Negate player is holding left
Negate player is holding Right
Change animation sequence to stopped
-
Re: Plaform game trouble
Thanks!
I have another small question and didn't want to make a new thread for it so here goes.
Is there a tutorial for making moving platforms which work properly with the character? He should move with the platform and not go through it or just stand still like it happens now. Thanks in advance for any help. :)
Edit: And I can't for the life of me figure out how to make a working catapult. It was easy with the standard MMF platform movement, but now it just doesn't work no matter what I try. :/
-
Re: Plaform game trouble
In the examples folder there is a file under Platform movement that has moving platforms, however I haven't used moving platforms myself yet.
Not sure what you mean by a catapult but I put something together anyway
View MFA
-
Re: Plaform game trouble
Thanks for that. :)
About the moving platforms, I was previously using the default MMF platform movement (until I realized it's horrible), and thus I made platforms which use the default bouncing ball movement. I somehow need to get the Platform movement object to work correctly with those, as there's no way I'm going to remake all the 6 levels I made already. :(
-
Re: Plaform game trouble
For moving platform I use an active set as a qualifier - say 'bad'
Using PMO - test for overlap + sprite overlap 'bad' = sprite overlaps an obstacle. This way any actives can be used as obstacles.
It might take a bit of time but once you have a standard PMO folder worked for one level - if you are using global objects - it shouldn't be too much of a hassle to slot it in.
-
Re: Plaform game trouble
Hmm, I'm not sure I understand what you mean. I know how to make my character collide with objects, I use the way you described. The problem is when there is a platform that moves from, let's say left to right, when the player is standing on it he should automatically be moving with the platform, that's what I'm trying to do. :)
And currently when there are platforms that move up and down, the player just goes through them or gets stuck for a bit.
-
Re: Plaform game trouble
If it is just synching sprite/platform movement then set the same X add/subtract for both.
If sprite overlaps 'bad' object (and object is moving X+4) set sprite X to X+4.
>> platforms that move up and down
ditto except Y = Y-4
4 is up to you - faster or slower. As long as they are the same.
>> player just goes through them
Not sure if you are using PMO here?
You could try off-setting the pixel difference.
Say platform is moving up 4 pixels then have player move up 5 or 6. It might be a little jerky but keeps the player ahead of the game as it were :)
-
Re: Plaform game trouble
Thanks for the help, but that still isn't a solution, as I said the platforms are using the MMF2 default bouncing ball movement. Changing all of them would be just too much work.
EDIT: Hmm or it might work, I'll try.
-
Re: Plaform game trouble
Hmm, nope, just can't get it to work.
Btw, the setting of x and y coordinates is a bit like arabic to me, which commands should I use for those? And is there actually any possible way to make this work with the bouncing ball/path movement platforms? I'm really stuck with this right now. :(