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

Camera doesn't follow the graphical scale #12

Open
arzcbnh opened this issue Feb 25, 2023 · 0 comments
Open

Camera doesn't follow the graphical scale #12

arzcbnh opened this issue Feb 25, 2023 · 0 comments

Comments

@arzcbnh
Copy link

arzcbnh commented Feb 25, 2023

When changing the graphical scale of the game, the camera will still use the default LÖVE scale. It ends up out of proportion. For example, when following a character, the camera might be scale times as slow. I believe this has something to do with using scissors, since they're unaffected by graphical transformations, and I'd be willing to look for a workaround. I'd just like to know if that's the default behaviour and you want to keep it that way, or if it's not working properly because I'm doing something wrong.

example.zip
Here's how to interpret the example:

  • love example.zip will load the original program as default. The magenta dot is at (0, 0), the white dot is at (100, 50), and the lines cross at (200, 100).
  • love example.zip 2 will double the graphical scale. All drawings remain at the same position, but that position is transformed by LÖVE into its double.
  • love example.zip 1 true loads the program with the default scale, but using the camera centered at the lines crossing. Nothing happens.
  • love example.zip 2 true will use both the doubled graphical scale and the camera. Since the camera doesn't follow the graphical scale, it still interprets as if the white dot was at (100, 50), when in reality it's doubled as is now at (200, 100), the original set position for the camera (the lines crossing). Because of that, the white dot appears centered.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant