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

Refactor and fix for parallax BGs #1133

Merged
merged 3 commits into from Apr 1, 2017
Merged

Refactor and fix for parallax BGs #1133

merged 3 commits into from Apr 1, 2017

Conversation

scurest
Copy link
Contributor

@scurest scurest commented Mar 26, 2017

The parallax_* values in the SaveMapInfo object are currently treated as "the current value of the parallax parameteres", but in RPG_RT they seem to be treated as an override, and the values in the map properties should be used if they aren't set. This PR implements this, which fixes #1071.

There's also a general refactor of the parallax handling into one namespace, more docs, and readability improvements for Scroll{Left,Right,Up,Down}.

Refactor parallax handling into a dedicated namespace in Game_Map.

Treats SaveMapInfo::parallax_* info as an override and uses the
RPG::Map parallax fields as fallback when they are empty. This
fixes #1071.
ie. using the values from GetParallaxParams.

Also, Game_Map now interacts with the parallax variables only
through the function is Game_Map::Parallax.
@carstene1ns carstene1ns added this to the 0.5.1 milestone Mar 27, 2017
Copy link
Member

@carstene1ns carstene1ns left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested, works. Nice refactor again!

@Ghabry
Copy link
Member

Ghabry commented Apr 1, 2017

Thanks for the code cleanup and the docs

@Ghabry Ghabry merged commit af58797 into EasyRPG:master Apr 1, 2017
Ghabry added a commit to libretro/easyrpg-libretro that referenced this pull request May 22, 2018
Refactor and fix for parallax BGs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Alex Unleashed: Black panorama after loading savegame
3 participants