Skip to content

Conversation

Sparky1743
Copy link

Issue
Fixed a bug where bullets could pass through walls when tanks were positioned directly adjacent to them.
This occurred because no collision detection was performed when bullets were initially spawned. If a tank was placed right next to a wall and fired, the bullet would appear on the other side of the wall boundary.

Changes Made

  • Added collision detection at bullet creation time.
  • Created a temporary bullet object to validate the spawn position before actual creation.
  • Bullets are now only spawned if the initial position does not result in a collision.

Before
Screenshot 2025-04-21 012403

After
Screenshot 2025-04-21 014148

@Sparky1743
Copy link
Author

@dotnet-policy-service agree

@ZacharyPatten
Copy link
Collaborator

@Sparky1743 Thanks for your interest in contributing. :) I will review this pull request as soon as I can.

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