new desgine and some little changes others game previous desgine

This commit is contained in:
Suvodip
2024-06-21 20:43:54 +05:30
parent 94cfda779c
commit 64ab2bacd4
21 changed files with 904 additions and 422 deletions

View File

@@ -69,11 +69,11 @@ import Layout from '../../layouts/Layout.astro';
let tickIconWidth;
let cancelIconWidth;
if(isMobile){
topLogoWidth = 5;
muteIconWidth = 2;
resetIconWidth = 1.6;
tickIconWidth = 1.34;
cancelIconWidth = 1.16;
topLogoWidth = 4.5;
muteIconWidth = 1.8;
resetIconWidth = 1.5;
tickIconWidth = 1.28;
cancelIconWidth = 1.12;
noticeWidth = 100;
noticeHeight = 0;
buttonWidth = 67;
@@ -314,12 +314,20 @@ import Layout from '../../layouts/Layout.astro';
targetName: `target${data.right_match4}`,
},
];
const screenCenterX = this.cameras.main.worldView.x + this.cameras.main.width / 2;
const baseFontSize = 24;
const responsiveFontSize = (window.innerWidth / 940) * baseFontSize;
let wrapWidth;
if(isMobile){wrapWidth = 10;} else{wrapWidth = 200;}
const descrptText = this.add.text(screenCenterX, 100, data.description, { font: `${responsiveFontSize}px quicksand`, fill: '#60C6CB', align: "center", wordWrap: {width: window.innerWidth-wrapWidth}}, ).setOrigin(0.5);
let textSizeScale;
if(isMobile){
wrapWidth = 10;
textSizeScale = 540
} else{
wrapWidth = 200;
textSizeScale = 940
}
const screenCenterX = this.cameras.main.worldView.x + this.cameras.main.width / 2;
const baseFontSize = 24;
const responsiveFontSize = (window.innerWidth / textSizeScale) * baseFontSize;
const descrptText = this.add.text(screenCenterX, 90, data.description, { font: `${responsiveFontSize}px quicksand`, fill: '#60C6CB', align: "center", wordWrap: {width: window.innerWidth-wrapWidth}}, ).setOrigin(0.5);
// this.add.text(displayW / 14 - 15, 50, data.LearningArea, {font: `20px`}).setTint(0x7c4c23);
// this.add.text(displayW / 14 - 15, 70, data.LearningSubArea_copy, {font: `19px`}).setTint(0x7c4c23);
// Left Image Name