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

HOME (OFF fangame) Hang when entering level 'SH1' #1082

Closed
ghost opened this Issue Dec 14, 2016 · 5 comments

Comments

Projects
None yet
3 participants
@ghost

ghost commented Dec 14, 2016

Name of the game: HOME

Player platform: Arch Linux

Attach files

save.zip
easyrpg_log.txt

Describe the issue in detail and how to reproduce it:

Entering the room to the upper left causes Player to hang and take up all of one CPU. Tested with the continuous build.

@fdelapena fdelapena added the Hang label Dec 14, 2016

@Ghabry

This comment has been minimized.

Show comment
Hide comment
@Ghabry

Ghabry Jan 24, 2017

Member

This somehow happens when too many events are pushing each other (MakeWay) and the event in front can't move.
HOME has 15 events that push each other. In my debug build it starts to lag with 4 events.
So it's not getting stuck, just running too slow.

Member

Ghabry commented Jan 24, 2017

This somehow happens when too many events are pushing each other (MakeWay) and the event in front can't move.
HOME has 15 events that push each other. In my debug build it starts to lag with 4 events.
So it's not getting stuck, just running too slow.

@Ghabry Ghabry added the Performance label Jan 24, 2017

@Ghabry

This comment has been minimized.

Show comment
Hide comment
@Ghabry

Ghabry Jan 24, 2017

Member

And every of these 15 events has 15 Move right events with attribute "skip if not possible". So this accumulates to tons of "makeway" calls when cascaded from the leftmost to the rightmost :/

Member

Ghabry commented Jan 24, 2017

And every of these 15 events has 15 Move right events with attribute "skip if not possible". So this accumulates to tons of "makeway" calls when cascaded from the leftmost to the rightmost :/

@scurest

This comment has been minimized.

Show comment
Hide comment
@scurest

scurest Jan 26, 2017

Contributor

I'm still breaking things with that MakeWay commit - -;;;;;

The frame_count_at_last_update_parallel field is supposed to prevent this: it lets us know if we already tried to update on the current frame so we only visit every character once in a frame. That's what this block does. I just failed to also place this block in Game_Event::UpdateParallel (which is rather embarrassing since I named the field after it and all :p).

If you add it there, the Player won't lock up.

Contributor

scurest commented Jan 26, 2017

I'm still breaking things with that MakeWay commit - -;;;;;

The frame_count_at_last_update_parallel field is supposed to prevent this: it lets us know if we already tried to update on the current frame so we only visit every character once in a frame. That's what this block does. I just failed to also place this block in Game_Event::UpdateParallel (which is rather embarrassing since I named the field after it and all :p).

If you add it there, the Player won't lock up.

@Ghabry

This comment has been minimized.

Show comment
Hide comment
@Ghabry

Ghabry Jan 26, 2017

Member

Great, because I had no idea how to fix it :)

Member

Ghabry commented Jan 26, 2017

Great, because I had no idea how to fix it :)

Ghabry added a commit to Ghabry/easyrpg-player that referenced this issue Jan 26, 2017

Prevent multiple MakeWay calls on the same event during one frame. Th…
…anks scurest.

This fixes a hang with the cow events in HOME (in Room SH1).

Fix #1082
@Ghabry

This comment has been minimized.

Show comment
Hide comment
@Ghabry

Ghabry Jan 26, 2017

Member

I fixed this in the development branch and added some comments to make the purpose more clear.

Member

Ghabry commented Jan 26, 2017

I fixed this in the development branch and added some comments to make the purpose more clear.

@Ghabry Ghabry modified the milestone: 0.5.1 Feb 21, 2017

Ghabry added a commit to libretro/easyrpg-libretro that referenced this issue May 22, 2018

Prevent multiple MakeWay calls on the same event during one frame. Th…
…anks scurest.

This fixes a hang with the cow events in HOME (in Room SH1).

Fix #1082

Ghabry pushed a commit to libretro/easyrpg-libretro that referenced this issue May 22, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment