-
ReaperSWE
- Posts: 21
- Joined: Sat Sep 19, 2009 7:36 pm
Tree stump highlighting missing
On this occasion, a birch tree stump wasn't being highlighted when hidden behind an apple tree. Forcing me to cut down the apple tree to remove the birch stump.
-
loftar
- Posts: 9096
- Joined: Fri Apr 03, 2009 7:05 am
- Location: Your character database
Re: Tree stump highlighting missing
The problem with highlighting is that only the base coordinate of objects is checked for obstruction. Probably, that coordinate for the stump happened to be behind a pixel on the apple tree that wasn't opaque enough to be considered an obstruction. To be properly fixed, more than just the base coordinate should be checked, but I haven't yet figured out how to do that in a way that doesn't waste a ton of CPU time.
"Object-oriented design is the roman numerals of computing." -- Rob Pike
-
ReaperSWE
- Posts: 21
- Joined: Sat Sep 19, 2009 7:36 pm
Re: Tree stump highlighting missing
You could check the top left, base, and bottom right for obstruction, average the numbers, and draw the highlighting based on that?