This is the 2nd part of a demo showing 128 sprites. This application adds collision detection. The details are in the README file in the repository, but the collision detection involves combining several techniques, including pre-computing many numbers needed to make the demo happen. Specifically, the X/Y coordinates of the sprites, their corresponding spatial maps, and the decisions of whether sprites collide, based on their relative (not absolute) coordinates, are all pre-computed.
This program uses 3 collision detection techniques, in a nested (general to specific) fashion:
* Quadrant-level detection (4 parts of the screen)
* Spatial-level detection (256 parts of the screen)
* Pixel-level detection
Note that the program uses the VERA hardware collision detection for the quadrant-level detection. It does not use hardware to detect which kinds of sprites collide, only the general screen area where they collide.
https://github.com/TurboVega/128_collision_detection
Collision Detection with 128 Sprites
For Scene Demos that display animations, graphics, and music. Also for tech demos of graphics capability of VERA or the audio capabilities of the PSG, FM, or PCM audio channels.
Jump to
- Forums
- ↳ Official Announcements
- ↳ X16 Bug Reporting
- ↳ Introductions
- ↳ Commander X16 Forums
- ↳ Rules & Policies
- ↳ CX16 General Chat
- ↳ Programming
- ↳ How-To
- ↳ CX16 Hardware Support
- ↳ X16 Software Support
- ↳ X16 Feature Requests
- ↳ Website Feedback And Support
- ↳ Murray2 CX16 Discussion Archive
- ↳ Works In-Progress Discussion
- ↳ Libraries and Examples
- ↳ Lounge
- ↳ General Retro Chat
- ↳ Creative Arts
- ↳ Maker Projects
- ↳ Memes
- ↳ Modern Computing
- ↳ Off Topic
- ↳ Help Wanted
- ↳ Trade, Buy, Sell
- Downloads
- ↳ Official Software
- ↳ Games
- ↳ Productivity Apps
- ↳ Graphics Apps
- ↳ Audio Apps
- ↳ Development Tools
- ↳ Libraries And Demo Code
- ↳ Emulation, PC Connectivity, Networking
- ↳ Misc Apps
- ↳ Tutorials
- ↳ Demoscene
- ↳ WIP Demos
- ↳ Archive
- ↳ Program Requests, Suggestions, Ideas
- ↳ Monarch Open ROM
- ↳ Video/Podcast talk