Paint with a torch, in Javascript