JohnSundell / JohnSundell/ImagineEngine
Extract collision detection logic from Actor
Open
discussion
improvement
- Dominant language
- Swift
- Stars
- 1.8k
- Forks
- 104
- PR merge metrics
- No merged PRs in 30d
Description
To be able to add new types of `SceneObjects` that support collision detection without duplicating code, the collision detection logic in `Actor` needs to be extracted.
We probably need a new protocol something like this:
```swift
internal protocol Collidable {
var isCollisionDetectionEnabled: Bool { get set }
var rectForCollisionDetection: Rect { get }
}
```
Collision events also need to be extracted from ActorEventCollection.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.