Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
I need input on a possible bug in v3.5.0
#43
@bplus The process of what it does is really rather simple:

1) It takes a look at your image, and assumes that the background is transparent color 0 (&H00000000).
2) Then it checks each pixel from top to bottom, left to right, and checks to see if it borders a transparent pixel.  (For example, point (100,100) is red, and point(100,101) is transparent.)  If a point has a transparent parner beside it, it stores that point into our array -- that's how it forms an outline of the image.
3) It then checks later to see if our point has changed from the default color of our image.  (In this case, I was only using the redStar, or redScribble, so I hardcoded to check to see if our array still pointed to all red pixels on the screen where our outline was produced.)  Other ways to do this check would be to make certain the pixel in question was still clear transparent 0 *before* placing the redStar onto the screen over it, or to store the redStar's pixel colors with the x/y point information to compare against in case we had multiple colors in our raindowStar...

But the overall process is rather simple in concept -- make an outline of the image and store that outline in an array.  Then just check those array points to see if they match what we expect our outline to be.  If not, the *something* has been drawn on top of our image, and *THAT* qualifies as a collision.  Wink
Reply


Messages In This Thread
RE: I need input on a possible bug in v3.5.0 - by SMcNeill - 01-22-2023, 08:24 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Is this a bug with Round or is it just me BarrySWTP 10 1,249 07-07-2025, 08:40 PM
Last Post: BarrySWTP
  Exiting FOR NEXT, maybe a bug? Version 4.1.0 on Linux Circlotron 4 844 05-09-2025, 02:22 AM
Last Post: Circlotron
  Mix mode input of a binary open file Question! doppler 5 1,476 11-28-2024, 03:06 PM
Last Post: Petr
  I have fallen in a bug or weird behaviour TempodiBasic 2 674 10-08-2024, 06:09 PM
Last Post: TempodiBasic
  3.13.1 bug report - keyboard characters swapped Circlotron 3 1,001 06-03-2024, 05:16 AM
Last Post: Circlotron

Forum Jump:


Users browsing this thread: 1 Guest(s)