From 506e9c32be428a4dbe3edf78aeaf4ebce31bbdb2 Mon Sep 17 00:00:00 2001 From: Tim Mickel Date: Fri, 10 Jun 2016 08:48:39 -0400 Subject: [PATCH] Don't attempt to glow a block that isn't known in the VM --- src/engine/runtime.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/engine/runtime.js b/src/engine/runtime.js index a56c063c..aff2a3ae 100644 --- a/src/engine/runtime.js +++ b/src/engine/runtime.js @@ -233,6 +233,9 @@ Runtime.prototype._step = function () { * @param {boolean} isGlowing True to turn on glow; false to turn off. */ Runtime.prototype.glowBlock = function (blockId, isGlowing) { + if (!this.blocks.getBlock(blockId)) { + return; + } if (isGlowing) { this.emit(Runtime.BLOCK_GLOW_ON, blockId); } else {