web capabilities
This release focuses on vastly improving capabilities on the web, by providing more useful events, better handling image loading, rendering individual components, and fixing lots of bugs. It contains a number of new features, major capability improvements, and API cleanups.
Features:
- a grid can be easily added to the display using
setGrid - jpg images can be loaded; their color gets downsampled
- sprites component, with flags (flip, behind, etc) for sprites
- dip switches allow easy run-time configuration
- attributes component, controls palette per position
- multiple scenes can run in the same web page
Improvements:
- SDL display no longer blocks the node.js event loop
loadImagecalls on the web fill thecolorMapdeterministically- fonts can be loaded from png files
tilesetscan be constructed from the plane after it has been drawn toready&rendereventsfoldmethod for chaining calls with similar parameterscolorMapuses a better cyan colorplane.resizemethod to downscale or upscale using nearest neighbor- components can be serialized to images
interruptscan use ranges of scanlinespalette.cycleconvenience method- on web, can choose which html element to render to using
useDisplay({displayElemID})
Bug fixes:
fillColoranddrawImagework on selections- gif saving takes zoom into account
- images on the web load using relative paths
API cleanups:
osciluses better named parameters- component construction is more consistent
drawCirclecan usecenterXandcenterYrahaswidthandheightfieldscolorMapin use everywhere, instead of "colorSet"image.lookmakes it easier to use images for palette cycling
Partially implemented:
- multiple layers, only 2 allowed and only in SDL
- ES6 features, not used everywhere yet
-vcommand-line flag for verbose logging, incomplete