Simplify getting X and Y coordinates
Simplify render logic