Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions arcade/camera/camera_2d.py
Original file line number Diff line number Diff line change
Expand Up @@ -482,6 +482,10 @@ def point_in_view(self, point: Point2) -> bool:
Take a 2D point in the world, and return whether the point is inside the
visible area of the camera.
"""
# This is unwrapped from standard Vec2 operations,
# The construction and garbage collection of the vectors would
# increase this method's cost by ~4x

pos = self.position
diff = point[0] - pos[0], point[1] - pos[1]

Expand Down
Loading