Page 1 of 1

Player falling through block platforms and sizeables

Posted: 28 Feb 2017, 2:10
by SmokeyTheBandicoot
SMBX 1.4.4 - Patch 1 (currently latest)

description: The player passes through platform blocks (block like sizeables, bridges, clouds, and in general blocks which are "platforms" or "platforms (up)" ) falling through them as soon as they are moving towards the up direction.

steps to reproduce:
1) Create a new level
2) Create a new layer
3) In that layer put some blocks. I used SMB1 mushrooms, customized to be "Platform (Up)" blocks through custom block properties (works with "Platform" too)
4) through the use of scripts (not tested with events, but should give the same results), move the layers towards the negative verse of the y-axis (Up)
5) Test the level
6) As soon as the player will land on that blocks, it will fall through the platform
7) Same things happens for NPCs
8) Using the property "Block (Solid)" solves the issue for the players, but kills the NPCs which are standing on top of the moving layer

In the image the green mushroom is moving up and down (through scripts, I set the movement of the layer to be sin(v(temp)), where temp is a variable that increments of 0.15 each frame). The green mushroom goes up ad down. When it is going down the player is able to stand on top of it without consequences, as soon as the mushroom starts rising, the player falls through (as you can see in the pic)

Posted: 28 Feb 2017, 21:58
by Mushroom King
I see that bug on a level where I jumped on a platform turning around a block, so I guess it's a problem with every moving block you can pass through like sizeable.

Posted: 1 Mar 2017, 0:50
by SmokeyTheBandicoot
Yes, tested right now, every sizeable block, every platform block. Hope to see this one fixed.

Posted: 1 Mar 2017, 19:40
by Lx Xzit
This problem has been there since SMBX 1.4.1. :/
I think I know why this happens. If the character is stand in a block then the velocity of the block will be the added to the player velocity. I mean, if the block has -5 velocity, then the player will go to -5. What's the problem? there's 1 frame delay and this is what causes unsyncronised movements. I think a viable way to fix is applying the same system for moving NPCs to the blocks: they moves the player based in the X and Y ubicationt, no with the speed.

Posted: 2 Mar 2017, 3:07
by SmokeyTheBandicoot
Yes, I bet this bug happened since the smbx 1.3 days. I though about using NPCs to move the player, but I thought it would have produced the same results. Thanks for the suggestion! Time to rework custom graphic a little bit :biggrin: