Re:Tools we used to create a hit HTML5 game on Steam
by Mirioron on Wednesday November 20, 2019 @04:47AM
(#21582460)
Canvas has also had some really weird performance issues in the past that are browser specific. Chrome once decided that the number of images used was too many in an animation, so it had to decode some of the images in the animation on the fly. This obviously killed all performance. This bug has been fixed, but I'm sure there are many others like it around.
- OSX likes to turn random Unicode symbols into emoji (extends past Canvas)
- Fractional font sizes on Chrome/Linux get bizarrely stretched out (after a transform that makes the font not a fractional size)
- Complex clipping operations freak Chrome out
- All the compositing rendering options are broken somewhere or mis-defined to the point that it's weirdly hard to render anything to an alpha channel
You also need input APIs to make a game, and the input APIs often have strange inconsistencies in function names, returned objects, or event ordering.
Canvas is nice and straightforward if you want a purely sprite-based game with only mouse/keyboard input (but even then you need to jump through hoops if you want pixel art). Anything beyond that is going to need cross-platform debugging.