3 ms·
Bug Report: http://prntscr.com/mcyc1b http://prntscr.com/mcyc1b When the website loads, if I put in a large number such as 500 and hit the generate button, it
by bhargav 8y ago
Bug Report: http://prntscr.com/mcyc1b http://prntscr.com/mcyc1b
When the website loads, if I put in a large number such as 500 and hit the generate button, it does not clear the previous puzzle and overlays on top. Second click still shows it bit now its a but transparent. Third click removes it altogether. I tried to skim through the code but not sure what the cause is given that you create a new Maze every single time. It seems to be some sort of canvas rendering bug as if I clear the canvas [1] it seems to work.
1: https://stackoverflow.com/a/2142549 https://stackoverflow.com/a/2142549
- davidim 8y agoThanks a lot for the bug report! You're right - I was forgetting to clear the canvas on render. So I added ctx.clearRect(0, 0, WIDTH, HEIGHT); to the start of the render method.
- deleted 8y ago[deleted]