Detecting collision of two sprites that can rotate [duplicate]
问题 This question already has answers here : How to check intersection between 2 rotated rectangles? (10 answers) Closed 5 years ago . I have a problem with collision detection in a 2D Java game. Normally, what I would do is create a getBounds() method for an object that can collide with other objects. This method would return a new Rectangle(x,y,width,height) , where x and y are the coordinates for the top-left corner of the sprite, and width and height are the width and height of the sprite.