Hooray! Click+Drag! - Atomic Ivy MMO
Drag To Set Tiles - Atomic Ivy MMO - We can now set tiles by holding down the mouse and dragging in addition to the previous clicking method. This is great , but it lags horribly. Why? Well... Every time we set ONE(1) tile we are pushing up the entire 2048 x 2048 texture that encodes our tilemap data. Question : How many pixels encode a single tile? Answer : ONE(1) So... We are doing ( 2048 * 2048 ) more work than what needs to be done so.... Instead of pushing up 1 pixel evey time we set a tile we are pushing up... 4,194,304 pixels.. That's massively inefficient. If I had a dollar for every time I wasted 4 bytes of GPU bandwidth... Well.. I'd have 4 million dolla...