Proper hooking and modification of the draw loop to save code