Posts by David César • 11 points
2 posts
-
0
votes2
answers60
viewsA: Canvas draw grid as backgound
Well, I know I already answered this post, however, I wanted to share how to develop a colorful grid that I developed for my Snake Game, just change the colors to suit your taste. const tileCount =…
-
1
votes2
answers60
viewsA: Canvas draw grid as backgound
I believe this will help. const canvas = document.querySelector("canvas") const c = canvas.getContext("2d") canvas.width = 400; canvas.height = 400; const tileCount = 20; let gridX = canvas.width /…