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

Fix: Prevent player from walking off the map #72

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

rlc26
Copy link

@rlc26 rlc26 commented Nov 13, 2024

This pull request adds boundary checks in game_view.py to prevent the player from moving beyond the map's edges. This change ensures the player remains within the defined map dimensions at all times.

  • Checks player_sprite position against map boundaries
  • Keeps the player within the visible map area

Tested with default map sizes to ensure compatibility.

@maximelefrancois86
Copy link

related to #29 ?

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

Successfully merging this pull request may close these issues.

2 participants