Operating system or device - Godot version:
Linux Ubuntu 64bit commit 36548a3fa58f00a3ef301f169f237b5641bdf635
Issue description:
in OneWay collisions you can't set how far you can go inside the CollisionShape2D, and for moving platforms going upward, you always go throught the platform and fall, when the moving platform is moving downward or horizontally, you dont fall
Steps to reproduce:
set a KinematickBody2D with a CollisionShape2D and set the OneWay Collision checkbox on the shape make the shape move upward with set_transform and see your character fall through
uh.. man this will be seriously difficult to fix, will think about this for
a while..
On Mon, Jun 26, 2017 at 2:15 PM, rubenjavier notifications@github.com
wrote:
Operating system or device - Godot version:
Linux Ubuntu 64bit commit 36548a3
https://github.com/godotengine/godot/commit/36548a3fa58f00a3ef301f169f237b5641bdf635Issue description:
in OneWay collisions you can't set how far you can go inside the
CollisionShape2D, and for moving platforms going upward, you always go
throught the platform and fall, when the moving platform is moving downward
or horizontally, you dont fallSteps to reproduce:
set a KinematickBody2D with a CollisionShape2D and set the OneWay
Collision checkbox on the shape make the shape move upward with
set_transform and see your character fall through—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/godotengine/godot/issues/9399, or mute the thread
https://github.com/notifications/unsubscribe-auth/AF-Z25lBqHFhQ_7NtJsJFXtnZJFB4sQYks5sH-cXgaJpZM4OFmZ9
.
dont worry, take your time and do your thing... if someone is really good at thinking here, its you man
Confirmed by @damarindra in #9614, with a test project to reproduce the issue:
Download example project, and run TestScene
Platformer.zip
The issue affects rigid bodies too.
fixing this is difficult, will kick to 3.1
thinking about it, one alternative could be to, once collision happen, to apply it normally (not one-way) in the next frames (must remember that it was one way in the previous frame, this is where things get difficult specially for Kinematicbody), but it should be possible..
sad news to have it kicked into next release, this leaves many of my platforms broken... but I trust you reduz
First of all thank you for your report and sorry for the delay.
We released Godot 3.0 in January 2018 after 18 months of work, fixing many old issues either directly, or by obsoleting/replacing the features they were referring to.
We still have hundreds of issues whose relevance/reproducibility needs to be checked against the current stable version, and that's where you can help us.
Could you check if the issue that you described initially is still relevant/reproducible in Godot 3.0 or any newer version, and comment about its current status here?
For bug reports, please also make sure that the issue contains detailed steps to reproduce the bug and, if possible, a zipped project that can be used to reproduce it right away. This greatly speeds up debugging and bugfixing tasks for our contributors.
Our Bugsquad will review this issue more in-depth in 15 days, and potentially close it if its relevance could not be confirmed.
Thanks in advance.
Note: This message is being copy-pasted to many "stale" issues (90+ days without activity). It might happen that it is not meaningful for this specific issue or appears oblivious of the issue's context, if so please comment to notify the Bugsquad about it.
This still affects 3.0.2 and current master.
Is there any work-around for this issue? Like using a function like using a function similar to get_floor_velocity() to correct the velocity. (Tried that function, doesn't work)
@jahd2602 not easy, you can put 2 shapes on the platform, if the player touched the one side it on the solid part, enable the full contact shape, keep monitoring the player until it leaves, disabling the full contact shape.
Thanks, @eon-s, I could get a good behavior by disabling one-way and adding this to the moving platform:
func _physics_process(delta):
$CollisionShape2D.disabled = global_position.y <= global.player.global_position.y
Hi, It happens to me that when standing on one way collision ground, if a KinematicBody2D or RigidBody2D stands on another KinematicBody2d or RigidBody2d, ti sometimes makes the one below fall trhough the ground. Is this issue related to this? It still affects 3.1 alpha.
The fix was made after 3.1 alpha, and I guess yes your issue is related.
Thanks! And is there any workarround for this in stable release?
Thanks, @eon-s, I could get a good behavior by disabling one-way and adding this to the moving platform:
func _physics_process(delta):
$CollisionShape2D.disabled = global_position.y <= global.player.global_position.y
This does not work for me cause i have multiple bodies... should i open new question for this?
@PabloF7 this is marked as cherry pick so it will probably land on the next 3.0
A workaround for many bodies may be using special layers or exceptions, controlled on each body (or apply the fix and build a custom engine).
Hi,
I've cloned and compiled the master branch, and I've checked the fix is there in the correct file. However i still get the problem that one Body can make another one fall through one way platforms when standing on it. Could it not be the same issue that the one with moving platforms?
Thanks
@PabloF7 I think that is another problem, open a new issue and provide an example to so it can be tested easily.
Ok, Thanks!
I am seeing the same issue in 3.0.6 and 3.1 alpha. Attaching example. If you jump a few times (ui_up) you will fall through the platform.
@hedrickbt it was fixed after alpha, check on a more recent build.
If you cannot build from master, try with the daily builds from this site https://bintray.com/calinou/godot
@hedrickbt it was fixed after alpha, check on a more recent build.
If you cannot build from master, try with the daily builds from this site https://bintray.com/calinou/godot
@eon-s , confirmed! It is working great. Thanks for the help. I missed that I needed to run based on the nightly build of 3.1+: https://hugo.pro/projects/godot-builds/
Most helpful comment
This still affects 3.0.2 and current master.