From e6d78766799e8965b8a6dfe361216ed7cb4f4b45 Mon Sep 17 00:00:00 2001 From: "Eevee (Evelyn Woods)" Date: Tue, 8 Dec 2020 19:00:50 -0700 Subject: [PATCH] Fix directional blocks losing their arrows after being cloned --- js/tiletypes.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/js/tiletypes.js b/js/tiletypes.js index 35bdc35..15c23f1 100644 --- a/js/tiletypes.js +++ b/js/tiletypes.js @@ -1011,6 +1011,10 @@ const TILE_TYPES = { Math.min(actor.animation_speed, actor.animation_progress + 1)); // FIXME add this underneath, just above the cloner, so the new actor is on top let new_template = new actor.constructor(type, direction); + // TODO maybe make a type method for this + if (type.name === 'directional_block') { + new_template.arrows = new Set(actor.arrows); + } level.add_tile(new_template, me.cell); level.add_actor(new_template); }