+nanochess Posted July 22, 2021 Share Posted July 22, 2021 (edited) Hi. While I was correcting the FreeIntv emulator, I discovered the off-screen collision areas weren't documented. I intended to do an automatic testing tool, but my mind couldn't dilucidate how could it be automatic (and besides it would have took too much time using a single pixel MOB). So instead I made a manual tool to test over real hardware the collision bits. I displaced a single-pixel MOB over the screen at any of the possible coordinates. I setup also a border in black or blue (pressing a side-button), and also I setup sprites off-screen (a single pixel or a 8x8 block with a single pixel being displayed on the visible screen corners). The results surprised me. I thought the border was thick around the visible screen, but instead for collision purposes is a single pixel thick at top, right, and bottom, and SURPRISE! It is 7 pixels thick at the left. Besides the border at right starts in the invisible last column of the visible screen (MOB X-coordinate = 167) Also the sprites collisions off-screen are only detected on the positions occupied by the border, this means: row 7, row 104, columns 1-7, and column 167. Any other row or column outside these coordinates doesn't generate collisions. These results were tested and generated using an Intellivision System III. I think @intvnut and @Zendocon will find interesting these results. testcol.bas testcol.rom Edited July 22, 2021 by nanochess 5 Quote Link to comment Share on other sites More sharing options...
Zendocon Posted July 22, 2021 Share Posted July 22, 2021 I recall the EXEC allowed for dispatch routines that fired when a sprite: tried to go outside a defined rectangular boundary, touched the border, went beyond the border, and went outside the valid range of world coordinates. That might have something to do with the collision tests. 1 Quote Link to comment Share on other sites More sharing options...
+DZ-Jay Posted July 22, 2021 Share Posted July 22, 2021 9 hours ago, nanochess said: Hi. While I was correcting the FreeIntv emulator, I discovered the off-screen collision areas weren't documented. I intended to do an automatic testing tool, but my mind couldn't dilucidate how could it be automatic (and besides it would have took too much time using a single pixel MOB). So instead I made a manual tool to test over real hardware the collision bits. I displaced a single-pixel MOB over the screen at any of the possible coordinates. I setup also a border in black or blue (pressing a side-button), and also I setup sprites off-screen (a single pixel or a 8x8 block with a single pixel being displayed on the visible screen corners). The results surprised me. I thought the border was thick around the visible screen, but instead for collision purposes is a single pixel thick at top, right, and bottom, and SURPRISE! It is 7 pixels thick at the left. Besides the border at right starts in the invisible last column of the visible screen (MOB X-coordinate = 167) Also the sprites collisions off-screen are only detected on the positions occupied by the border, this means: row 7, row 104, columns 1-7, and column 167. Any other row or column outside these coordinates doesn't generate collisions. These results were tested and generated using an Intellivision System III. I think @intvnut and @Zendocon will find interesting these results. testcol.bas 1.83 kB · 1 download testcol.rom 2.56 kB · 1 download This sort of makes sense. Collision detection is typically performed in hardware as an AND operation on registers, not as a range comparison. It is cheaper circuitry that way. This means that for them to be triggered, pixels must actually overlap. It does not surprise me that the active collision area on the left side extends to the border, but it does surprise me that it does not do so as well on the top border. Very interesting indeed. dZ. 1 Quote Link to comment Share on other sites More sharing options...
+nanochess Posted July 27, 2021 Author Share Posted July 27, 2021 Just patched FreeIntv to implement the border collision https://github.com/nanochess/FreeIntv It should be available in the servers in a few days for anyone using Intellivision with RetroArch. 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.