[video output=day299 member=cmuratori stream_platform=twitch stream_username=handmade_hero project=code title="Improving Sort Keys Part 2" vod_platform=youtube id=EbaM2XwuscQ annotator=Miblo] [0:11][Recap and set the stage for the day] [1:51][Blackboard: Tile Z Sorting] [2:38][Blackboard: How to sort when looking directly top-down] [6:08][Blackboard: The complication that arises from tilting the camera] [8:29][Blackboard: Quantising entities to tiles] [10:14][Blackboard: The problem with rugs] [13:02][Blackboard: Painter's Algorithm] [14:35][Blackboard: The cases of the rug situation] [22:03][Blackboard: Top-down 2D vs 3D] [27:01][Blackboard: Using planar maths] [29:42][Blackboard: Considering this as a 3-dimensional problem] [36:02][Blackboard: Flat vs Upright Entities] [41:50][Blackboard: The problem of Y inside a single cell] [46:32][Blackboard: The case with a tilted camera looking down on a hero standing on a rug] [49:53][Blackboard: Using the closest point entities have in common to determine the sorting] [58:34][Q&A][:speech] [59:59][@sssmcgrath][If you're only concerned about sprites that exist on more than one cell, why not split the polygons on cell boundaries? There can't be that many / can't be that expensive?] [1:02:28][Wind down][:speech] [/video]