Great!
Thanks.
Clipped line routine
Was it using the DrawLine or the DrawClippedLine routines ? What are the clipping parameters you used ?Chema wrote:Greetings.
Working on a possible radar display for the 3D game, I noticed the line drawer does NOT draw a line when origin and destination are the same.
Drying to draw a line from (24,24) to (24,24) I expected to see a dot at that position, but nothing was drawn.
Don't know if this is the desired behaviour or not...
Cheers.
I tried this:
Code: Select all
LargeX0=24;
LargeY0=24;
LargeX1=24;
LargeY1=24;
DrawClippedLine();
Code: Select all
CurrentPixelX=24;
CurrentPixelY=24;
OtherPixelX=24;
OtherPixelY=24;
DrawLine();
Ok, I am completely embarssed. I don't know what I did or what I broke, but it is working nowDbug wrote: Both correctly displayed one single dot in (24,24).
![Embarassed :oops:](./images/smilies/icon_redface.gif)
I'd swear I made several tests and notice that behaviour. I did one today and it displayed the dot correctly, so I am completely confused. Most probably some kind of bug in my code that now has disappeared.
Sorry Dbug.
I get that sometimes, bugs disappearing. I had one the other day with Wurlde whereupon you walked to a particular screen and it worked for about 30 seconds then crashed. I had left it for some time before i decided to try and fix it and strangely the bug was not happening anymore.
Sometimes i have found that the bug is when you have lots of source files (like Wurlde) and they all refer to a zeropage source file but i change this file and realise i must recompile all the other files again. In Wurlde now thats about 25 recompilations!![Razz :P](./images/smilies/icon_razz.gif)
Sometimes i have found that the bug is when you have lots of source files (like Wurlde) and they all refer to a zeropage source file but i change this file and realise i must recompile all the other files again. In Wurlde now thats about 25 recompilations!
![Razz :P](./images/smilies/icon_razz.gif)