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

Yume2kki: Maiden Outlook background not showing properly #2195

Closed
purupurupuruin opened this issue May 4, 2020 · 7 comments · Fixed by #2714
Closed

Yume2kki: Maiden Outlook background not showing properly #2195

purupurupuruin opened this issue May 4, 2020 · 7 comments · Fixed by #2714
Labels
Maps Map content related. For map events please use event/interpreter instead Patch available Pictures
Milestone

Comments

@purupurupuruin
Copy link

purupurupuruin commented May 4, 2020

Name of the game:

Yume2kki

Player platform:

Linux

Attach files (as a .zip archive or link them)

easyrpg_log.txt

Describe the issue in detail and how to reproduce it:

The Maiden Outlook area in 2kki looks weird in EasyRPG:
1
2

And here's how it's supposed to look:
3

To reproduce:
Start/Load a game and head to the Maiden Outlook. (Sleep > Nexus > Library (Entrance looks like a roof) > read the book on the second bookcase to the left of the Library's entrance.
(Sorry if this ends up being a duplicate.)

@Ghabry
Copy link
Member

Ghabry commented May 4, 2020

Looks like a bug with panorama positioning. Thanks for reporting. Is not a known bug

@purupurupuruin
Copy link
Author

I'll leave a debug save here to make this bug faster to find.
maidenoutlook.zip

@purupurupuruin
Copy link
Author

Just a small update to this bug, it's still present in 0.6.2.3 as well as the continuous build I downloaded a few hours ago.
Since I made that debug save in an older version of 2kki (0.112 I think), here's a debug save I made in 2kki ver 0.116 just in case:

maidenoutlook2.zip

By the way, for some reason, in 0.116 the menu no longer works in Maiden Outlook. (Not a bug, it's like that in RPG_RT too)

@Ghabry
Copy link
Member

Ghabry commented Jan 5, 2022

The expected pan_x is 8960.

When changing the panorama RPG_RT executes the following code:

if ( !horScroll && !horLooping) {
    a = 16 * mapWidth - 20;
    b = max(0, imageWidth - 320);
    c = min(a, b);
    if ( b != 0 ) {
      pan_x = 2 * c * camera_pan_x / a;
    } else {
      pan_x = 0;
    }
  }

Player does:

if (params.scroll_horz || LoopHorizontal()) {
	panorama.pan_x = map_info.position_x;
} else if (GetWidth() > 20 && parallax_width > SCREEN_TARGET_WIDTH) {
	panorama.pan_x = std::min(
		map_info.position_x * (parallax_width - SCREEN_TARGET_WIDTH) * 2 / ((GetWidth() - 20) * TILE_SIZE),
		map_info.position_x * 2);
	}
}

My guess is that this is also related to the async code: The image width is required but not available when determining it. Maybe make panorama change a blocking async op.

@Ghabry Ghabry added this to the 0.7.1 milestone Jan 5, 2022
Ghabry added a commit to Ghabry/easyrpg-player that referenced this issue Jan 5, 2022
In some cases (not scrolling or looping) the position is reset after loading the panorama.
Here was the bug: Multiple ChangePanorama commands overwrote the reset indicator.

Added a async yield op to the event and made the panorama image important to ensure that the image is loaded.

Refactored Spriteset_Map to prevent deletion as the panorama change is otherwise a dangling reference.

Fix EasyRPG#2195
Ghabry added a commit to Ghabry/easyrpg-player that referenced this issue Jan 5, 2022
In some cases (not scrolling or looping) the position is reset after loading the panorama.
Here was the bug: Multiple ChangePanorama commands overwrote the reset indicator.

Added a async yield op to the event and made the panorama image important to ensure that the image is loaded.

Refactored Spriteset_Map to prevent deletion as the panorama change is otherwise a dangling reference.

Fix EasyRPG#2195
@fdelapena fdelapena added the Maps Map content related. For map events please use event/interpreter instead label Jan 10, 2022
@Ghabry
Copy link
Member

Ghabry commented Jan 10, 2022

Save04.zip

Some more bugs reported:
Load the Save and move to the left and then return to the previous map (This is necessary because pan chunks are not saved)

The door is misaligned:

screenshot_5

Must be like this:

screenshot_1

Then go down the stairs, watch out for the jumpscare (See below)
In the next room the next issue:

screenshot_6

screenshot_3

Bug in the game, not a Player bug:

When you go downstairs to the left there is a jump scare. Some quick flashing face.

scare

If you loaded the save, moved left, then right to the old room, left again and walk downstairs the face is misaligned:

scare2

@Ghabry
Copy link
Member

Ghabry commented Jan 10, 2022

This is actually a difference between 2k and 2k3.

The face is misaligned only in 2k3, in 2k it is correct.

Here is a better savegame: Go through the door in front of you and then to the right until you see another door.
Then you are in the red room again.

Save05.zip

With 2k:

screenshot_8

With 2k3:

screenshot_7

Ghabry added a commit to Ghabry/easyrpg-player that referenced this issue Jan 13, 2022
In some cases (not scrolling or looping) the position is reset after loading the panorama.
Here was the bug: Multiple ChangePanorama commands overwrote the reset indicator.

Added a async yield op to the event and made the panorama image important to ensure that the image is loaded.

Refactored Spriteset_Map to prevent deletion as the panorama change is otherwise a dangling reference.

Fix EasyRPG#2195
@Ghabry
Copy link
Member

Ghabry commented Feb 15, 2022

There was a regression when loading async in the Yume2kki balcony and in MAP0947 (Wooden Polycube Ruins). These are also fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Maps Map content related. For map events please use event/interpreter instead Patch available Pictures
Development

Successfully merging a pull request may close this issue.

4 participants