Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In-Game: Non-solid Instance colliding with a solid resets the non-solid before and again after its Collision Event #5687

Closed
ParodyKnaveBob opened this issue Apr 30, 2024 — with GM Bug Reporter · 1 comment
Assignees
Labels
documentation Improvements or additions to documentation are required by this issue gmrt project This issue has a sample project attached runner-bug In-game bugs with the "GameMaker Studio 2" runtimes
Milestone

Comments

@ParodyKnaveBob
Copy link

ParodyKnaveBob commented Apr 30, 2024

Description

The full narrative:
https://forum.gamemaker.io/index.php?threads/trying-to-better-understand-move_contact_solid-in-different-events.111517/

As briefly summarized as I can while keeping the main content:

The Collision Event is documented as such: if a moving non-solid collides with a stationary solid, the non-solid will be reset to its previous coordinates and then the Collision Event code will execute. (I'm not dealing with other combinations of non/solid in these tests or this report.) The order of when Collision triggers is only important here in the context of testing what happens after the Collision Event ends, and thus I'll bring to attention that currently undocumented moment: GM moves instances, then Collision triggers, then End Step triggers.

My GMC post (10th in the thread linked above) declares all the necessary setup from my included demo. (There's also some other pre-written tests in the Collision Event that I've commented out which you can use if you find helpful.)

Expected behavior: A collision gets detected. GM resets the non-solid instance to its previous coordinates. The Collision Event code executes. All is well.

Unexpected actual behavior: A collision gets detected. GM resets the non-solid instance to its previous coordinates. The Collision Event code executes. GM again resets the non-solid instance to its previous coordinates!

Steps To Reproduce

Test on Windows and GX.games for sure. I started to test on Android but didn't want to complicate the project with virtual keys; be my guest (for any/all other runners) once you're satisfied with this test as-is. I could describe what happens differently on HTML5, but first, we'd have to talk about parallel universes.

Using the demo project:

  1. Run.
  2. Use the arrow key(s) to move the left square into the solid right square.
  3. Observe.
  4. Toggle the exit lines in o_hero's Collision and End Step.
  5. Repeat 1-3.

When the End Step is allowed to handle the collision, the "onscreen" outcome is smooth, and the debug messages deliver expected results. When the Collision Event is instead allowed to handle the collision, the "onscreen" outcome has the infamous GameMaker solid stutter-gap, and the debug messages prove the non-solid instance is reset both before and after the Collision Event.

Which version of GameMaker are you reporting this issue for?

IDE v2024.2.0.132 Runtime v2024.2.0.163

Which operating system(s) are you seeing the problem on?

Windows 10.0.19045.0

69fba261-221e-419f-87bf-d9a8a0692d06

@gm-bug-reporter gm-bug-reporter bot added runner-bug In-game bugs with the "GameMaker Studio 2" runtimes project This issue has a sample project attached labels Apr 30, 2024
@stuckie stuckie added the gmrt label Apr 30, 2024
@stuckie stuckie moved this from Triage to Backlog in Team Workload Apr 30, 2024
jackerley added a commit to YoYoGames/GameMaker-HTML5 that referenced this issue May 20, 2024
@jackerley jackerley added this to the 2024.6 milestone May 20, 2024
@github-project-automation github-project-automation bot moved this from Backlog to Done in Team Workload May 20, 2024
@YYBartT YYBartT added the documentation Improvements or additions to documentation are required by this issue label May 20, 2024
@YYBartT YYBartT self-assigned this May 20, 2024
@YYDan YYDan changed the title solid Resets an Instance Before and After the Collision Event In-Game: non-solid Instance colliding with a solid resets the non-solid before and again after its Collision Event May 24, 2024
@YYDan YYDan changed the title In-Game: non-solid Instance colliding with a solid resets the non-solid before and again after its Collision Event In-Game: Non-solid Instance colliding with a solid resets the non-solid before and again after its Collision Event Jun 26, 2024
YYBartT added a commit to YoYoGames/GameMaker-Manual that referenced this issue Jun 26, 2024
YoYoGames/GameMaker-Bugs#5494
YoYoGames/GameMaker-Bugs#5687

* Documented the precise order of events on the Event Order page
* Mentioned the differences when using Collision Compatibility Mode
@YYBartT YYBartT moved this from Done to Ready for QA in Team Workload Jun 26, 2024
@scott-dunbar
Copy link
Collaborator

Confirmed fixed in Beta IDE v2024.600.0.585 Beta Runtime v2024.600.0.609

@scott-dunbar scott-dunbar moved this from Ready for QA to Verified in Team Workload Jul 1, 2024
gurpreetsinghmatharoo pushed a commit to YoYoGames/GameMaker-Manual that referenced this issue Aug 8, 2024
YoYoGames/GameMaker-Bugs#5494
YoYoGames/GameMaker-Bugs#5687

* Documented the precise order of events on the Event Order page
* Mentioned the differences when using Collision Compatibility Mode

(cherry picked from commit 690c7c0)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation are required by this issue gmrt project This issue has a sample project attached runner-bug In-game bugs with the "GameMaker Studio 2" runtimes
Projects
Status: Verified
Development

No branches or pull requests

5 participants