From e79b7ecfd1aa325dbdd9753f931162928db47db2 Mon Sep 17 00:00:00 2001 From: Thomas Weber Date: Thu, 22 Jul 2021 10:49:34 -0500 Subject: [PATCH] Init mouse scratch[X|Y] to 0 When autoplay is enabled, the runtime can start before a mouse event is fired --- src/io/mouse.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/io/mouse.js b/src/io/mouse.js index 95470dc2..7427ebaa 100644 --- a/src/io/mouse.js +++ b/src/io/mouse.js @@ -4,6 +4,8 @@ class Mouse { constructor (runtime) { this._clientX = 0; this._clientY = 0; + this._scratchX = 0; + this._scratchY = 0; this._buttons = new Set(); this.usesRightClickDown = false; this._isDown = false;