ragingdemonz
Member
Hey there guys. I'm sure that it's been asked like a billion times. But i'm trying to pull-through jump through platforms and slopes. While the Zack bell action platformer aint bad per say it has alot of negatives and downfalls, it's free now so I can't complain to much. But the way that he approaches jump-through platforms is kinda a mess. The issue being that you can't have a jumpthrough platform directly near the Player. Meaning if you're jumping upwards and your player touches another jumpthrough platform or even directly touching a jumpthrough platform it'll return false in his "onGround script" which makes sense as how the code is made and formulated.
But that's the thing though virtually ALL platformer games will have jumpthrough platforms where the mask of the player will be touching another Jumpthrough. Another Pitfall is Jumpthrough Ramps.
so. this is what i did to make sure the normal jumpthrough platforms work is change up the code structure in his "PlatformCheck".
i added a new variable called "TwoWayTarg" which will be used later to make do collision checks with the current jumpthrough
Here's how it looks like now
This makes the jumpthrough Platform work now and even though the player is touching another TwoWay he won't fall through and you're able to still jump. However this breaks ANY hope for JumpThrough Slopes as now when landing on top of the slope it'll snap him back to the top of the Boundary box. I also don't use a sprite for slopes rotate them in GM's room editor and check the "Rectangle with rotation"
does anyone have an idea i can use to make this work?
GML:
return place_meeting(x, y + 1, oParSolid) || (place_meeting(x, y + 1, oParJumpThru ) && !place_meeting(x, y, oParJumpThru));
so. this is what i did to make sure the normal jumpthrough platforms work is change up the code structure in his "PlatformCheck".
i added a new variable called "TwoWayTarg" which will be used later to make do collision checks with the current jumpthrough
Here's how it looks like now
Code:
(OnGround Script)
return place_meeting(x, y + 1, oParSolid) || (place_meeting(x, y + 1, TwoWayTarg ) && !place_meeting(x, y, TwoWayTarg));
(PlatformCheck Script)
if (vsp>0)
{
with (TwoWay)
{
if (place_meeting(x,y-other.vsp,other) && !place_meeting(x,y,other))
{
other.y+= (bbox_top-1) - other.bbox_bottom;
other.twoWayTarg=id;
return true;
}
}
}
This makes the jumpthrough Platform work now and even though the player is touching another TwoWay he won't fall through and you're able to still jump. However this breaks ANY hope for JumpThrough Slopes as now when landing on top of the slope it'll snap him back to the top of the Boundary box. I also don't use a sprite for slopes rotate them in GM's room editor and check the "Rectangle with rotation"
does anyone have an idea i can use to make this work?