github.com/ncw/johnroids (go): JohnRoids - the conversion!  note that the error checking for object table full has been taken out...  make a rand_chance (x/y) function  Need to figure out what happens on gameover!  gamepause should be in main loop really...  Try making an explode image function which makes an object per pixel in the object and gives then the right velocities to make an explosion.  Could then have a fade table for each of 256 pixels.  Will run out of objects pretty quickly!  Perhaps only want to explode every 10th pixel in the roids or something like that.  Could record the x and y of the hit and use that as the centre of the explosion.  Could reduce the width and height of the sprite by removing all the black rows at the top and the bottom left and right.  This would speed up the plotter and enable us to calculate the c of g so we could split the roids so that the bits always came apart from the centre.  Could make the explosion always start from the bullet hit - this might be quite realistic.
Keywords: go|golang|gopherjs|sdl2|wasm