From 794f1b8e6d6cb7d58c3036241e2bd355bc55ece6 Mon Sep 17 00:00:00 2001 From: iainp5 Date: Sun, 29 Sep 2024 13:26:50 +0100 Subject: Changes to reduce size of game object --- play.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'play.js') diff --git a/play.js b/play.js index 9bc0e94..e2a5dc8 100644 --- a/play.js +++ b/play.js @@ -7,7 +7,8 @@ const options = 'none' const last_card = 110 const last_power_card = 52 let hover_timeout - +const height = 65 +const width = 105 const toolbar = document.getElementById('toolbar') const vpMarker = document.getElementById('vp') const counters = document.getElementById('counters') @@ -67,14 +68,14 @@ const spaceCharacteristicsElement = document.getElementById('space-characteristi if (space && space.box) { //CREATE SPACES - const { x, y, h, w } = space.box; + const { x, y} = space.box; const spaceArea = document.createElement('div'); spaceArea.classList.add('space-area', space.country) spaceArea.id=`space_${space.space_id}`; spaceArea.style.left = x + 'px'; spaceArea.style.top = y + 'px'; - spaceArea.style.width = w + 'px'; - spaceArea.style.height = h + 'px'; + spaceArea.style.width = width + 'px'; + spaceArea.style.height = height + 'px'; spaceArea.style.zIndex = 2; spaceArea.my_space = space.name_unique; spaceArea.addEventListener('mousedown', on_click_space); -- cgit v1.2.3