SAM: Actor layering glitch
|Reported by:||eriktorbjorn||Owned by:||eriktorbjorn|
|Game:||Sam and Max|
Sam & Max, English CD version Latest ScummVM CVS snapshot
(This probably happens in other places as well, but this is the best example I've seen so far.)
When talking to the guy at the Ball of Twine Museum, if Max walks over to the spot where Sam is standing he will sometimes be drawn in front of Sam and sometimes behind, causing an annoying "flickering" effect. It would look better is Max was always drawn in front.
In this scene, I believe Sam is actor number 2 and Max is actor number 3. They're both in the same layer and on the same Y coordinate, giving them the same value in the sort order. Unless I'm mistaken they're always added to the unsorted list in the same order, so I guess the current sorting algorithm is not a stable one, i.e. it does not preserve the order of equal keys.
It's quite easy - and very, very tempting - to make the sorting stable. On the other hand, there's that big, scary comment to contend with...
Since Max's movements are random, it's not certain that he will stay in the same spot long enough for you to observe the phenomenon. If he moves away too quickly, just reload the savegame and try again, or wait for him to walk back to that spot.
Ticket imported from: #1220168. Ticket imported from: bugs/2064.