From d1e08b721a9306b4912a7bee8f114d1866a1bfca Mon Sep 17 00:00:00 2001 From: dev sp Date: Sun, 17 Dec 2023 10:58:07 +0000 Subject: [PATCH] drawing game depth change cause of no available tranasparent image --- src/pages/drawing/index.astro | 23 +++++++++++++---------- src/pages/tick/v2.astro | 4 ++-- 2 files changed, 15 insertions(+), 12 deletions(-) diff --git a/src/pages/drawing/index.astro b/src/pages/drawing/index.astro index 351fd6c..c622b46 100644 --- a/src/pages/drawing/index.astro +++ b/src/pages/drawing/index.astro @@ -18,15 +18,19 @@ import Layout from '../../layouts/Layout.astro'; height: window.innerHeight / 2, }; if(isMobile){ - submitWidth = 230; - submitHeight = 95; + submitWidth = 250; + submitHeight = 110; noticeWidth = 100; noticeHeight = 0; + downloadWidth = 67; + downloadHeight = 200; } else { submitWidth = 380; submitHeight = 95; noticeWidth = 0; noticeHeight = 0; + downloadWidth = 180; + downloadHeight = 70; } var assetsList = {} var snapshotButton; @@ -158,17 +162,17 @@ import Layout from '../../layouts/Layout.astro'; }) const textStyle = {font: 'bold 40px quicksand', fill: '#05b3a4',}; if(!isMobile){ - this.add.text(customWidth / 10, 20, "Drawing", textStyle); - this.add.image(customWidth / 2 * 1.6 - 0.5, 50, 'topLogo'); + // this.add.text(customWidth / 10, 20, "Drawing", textStyle); + // this.add.image(customWidth / 2 * 1.6 - 0.5, 50, 'topLogo'); } else { - this.add.text(customWidth / 30, 0, "Drawing", textStyle); - this.add.image(customWidth / 2 * 1.6 - 0.5, 25, 'topLogo'); + // this.add.text(customWidth / 30, 0, "Drawing", textStyle); + // this.add.image(customWidth / 2 * 1.6 - 0.5, 25, 'topLogo'); } const outlineImage = this.add.image(customWidth / 2, customHeight / 2, 'outline'); if(isMobile){ - outlineImage.setDepth(1).setScale(0.5); + outlineImage.setDepth(-1).setScale(0.33); } else{ - outlineImage.setDepth(1).setScale(0.7); + outlineImage.setDepth(-1).setScale(0.75); } graphics = this.add.graphics(); @@ -429,7 +433,7 @@ import Layout from '../../layouts/Layout.astro'; snapWidth = 200; snapHeight = 70; } - snapshotButton = this.add.image(window.innerWidth - snapWidth, window.innerHeight - snapHeight, 'buttonIcons'); + snapshotButton = this.add.image(window.innerWidth - downloadWidth, window.innerHeight - downloadHeight, 'buttonIcons'); // snapshotButton = this.add.text(150, 80, 'SAVE', { fill: '#7c4c23', backgroundColor : '#5e17eb', font: '600 30px quicksand', borderRadius: '20px'}).setPadding(10, 10); snapshotButton.setInteractive(); snapshotButton.on('pointerdown', () => { @@ -460,7 +464,6 @@ import Layout from '../../layouts/Layout.astro'; // graphics.clear(); }); } - function startDrawing(x, y) { if (!isErasing) { graphics.lineStyle(brushSize * 2, Phaser.Display.Color.HexStringToColor(selectedColor).color); diff --git a/src/pages/tick/v2.astro b/src/pages/tick/v2.astro index d5775d2..061138d 100644 --- a/src/pages/tick/v2.astro +++ b/src/pages/tick/v2.astro @@ -290,9 +290,9 @@ import Layout from "../../layouts/Layout.astro"; /* border: 4px solid red; border-radius: 5%; */ } - .round-checkbox-input { + /* .round-checkbox-input { display: none; - } + } */ .round-checkbox-label { display: inline-block; /* width: 30px; */