Be notified of new releases
Create your free GitHub account today to subscribe to this repository for new releases and build software alongside 50 million developers.Sign up
The major new feature of this release is to have responsive wheels. All wheel type and features should work correctly in responsive mode which is turned on by setting the Winwheel.responsive = true.
- Changed var to let in all code
- Updated code style to PSR2
- Added pins and sound to the wheel of fortune example
The main new feature of this release is the ability to specify a soundTrigger callback for animations. Change of segment or change of pin under the pointer can cause the trigger. The callback function can then play a sound such as a "tick" sound.
Other changes and fixes this release...
- Animation can now have functions as callbacks and the callback finished passes the winning segment in (thanks LorisZ )
- Converted all examples to use the new function callback.
- Fixed bug where the defaults for the SpinOngoing animation were not as stated in examples or the docs.
- Added Continuously spinning wheel example.
- Added Pins and Sound wheel example.
- Added ability to have multiline text for all text orientations.
- Added feature to have pins around the edge of the wheel.
- Added basic image wheel example.
- Fixed bug in One image per segment example which became apparent once the multiline was done.
- Fixed #12 which was an issue around the stopAngle when the pointerAngle was not the default and the wheel stopping at unexpected places.
- Fixed #8 which was an JS error if stopAnimation was called before the animation had run for the first time
- Discovered an issue with using the Greensock tick event for the animation loop where at times it did not appear to render the last frame (so final state of the wheel). Changed to use onUpdate() callback instead.
- Added most requested feature - to be able to create wheels out of one image per segment.
- Added more examples, including...
- One Image Per Segment
- Hollow (doughnut) wheel
- Wheel of Fortune
- Fixed bug where some code was still using canvas.width / 2 or canvas.height / 2 rather than centerX and centerY
See http://dougtesting.net/winwheel/docs/tut17_one_image_per_segment for tutorial about the One image per Segment feature.