diff --git a/apps/multidice/ChangeLog b/apps/multidice/ChangeLog index ce7632d7c..ca48267be 100644 --- a/apps/multidice/ChangeLog +++ b/apps/multidice/ChangeLog @@ -9,3 +9,4 @@ 1.07: IDK how to use promises properly 1.08: still trying to fix the lack of vibrations 1.09: hopefully now it's fixed? +1.10: not having web bluetooth to debug is a PAIN diff --git a/apps/multidice/app.js b/apps/multidice/app.js index 8f027c47a..98a43eef8 100644 --- a/apps/multidice/app.js +++ b/apps/multidice/app.js @@ -35,6 +35,9 @@ function touchHandler (button, xy) { return; } + rollDice(); + return; + if (xy.x <= 87) { // left if (xy.y <= 43) { @@ -122,6 +125,13 @@ function rollDice() { g.drawString ((" " + resultsArr [i]).slice (-3), 96, 10 + 40 * (i - 4)); } } + + Bangle.on ('accel', voidFn); + console.log ("before"); + Bangle.buzz().then(()=>{ + Bangle.on ('accel', accelHandler); + }); + console.log ("after"); } function random (max) { @@ -134,7 +144,8 @@ function vibrate() { Bangle.on ('accel', voidFn); Bangle.buzz().then ((value) => { - Bangle.on ('accel', accelHandler) + console.log ("I ran."); + Bangle.on ('accel', accelHandler); }); } diff --git a/apps/multidice/metadata.json b/apps/multidice/metadata.json index 95071c67b..37adcac91 100644 --- a/apps/multidice/metadata.json +++ b/apps/multidice/metadata.json @@ -1,7 +1,7 @@ { "id": "multidice", "name": "multiple dice roller", "shortName":"multidice", - "version":"1.09", + "version":"1.10", "description": "roll anywhere from 1-8 dice at the same time", "icon": "app.png", "tags": "tool,game",