From 10e3c429a82bb7f24db5e418d7568221fe32a8b0 Mon Sep 17 00:00:00 2001 From: Harley White Date: Wed, 2 Jun 2021 18:51:33 -0400 Subject: [PATCH] Fixed everything with branches --- demo.html | 7 +++++-- js/Demo/demoLayers.js | 2 ++ js/Demo/demoTree.js | 1 + js/components.js | 1 + js/technical/canvas.js | 2 -- js/technical/displays.js | 2 -- js/technical/systemComponents.js | 10 +++++++--- js/utils/options.js | 1 + style.css | 15 +++++++++++++-- 9 files changed, 30 insertions(+), 11 deletions(-) diff --git a/demo.html b/demo.html index 71cc528..8778e11 100644 --- a/demo.html +++ b/demo.html @@ -98,7 +98,7 @@ - + @@ -117,12 +117,15 @@ -
+
+ +
+
\ No newline at end of file diff --git a/js/Demo/demoLayers.js b/js/Demo/demoLayers.js index 14d8457..6aaf667 100644 --- a/js/Demo/demoLayers.js +++ b/js/Demo/demoLayers.js @@ -328,6 +328,8 @@ addLayer("c", { ["display-image", "discord.png"],], }, jail: { + style() {return {'background-color': '#222222'}}, + content: [ ["infobox", "coolInfo"], ["bar", "longBoi"], "blank", diff --git a/js/Demo/demoTree.js b/js/Demo/demoTree.js index 72b00e4..55f1046 100644 --- a/js/Demo/demoTree.js +++ b/js/Demo/demoTree.js @@ -50,5 +50,6 @@ addLayer("tree-tab", { tabFormat: [["tree", function() {return (layoutInfo.treeLayout ? layoutInfo.treeLayout : TREE_LAYERS)}]], previousTab: "", leftTab: true, + style() {return {'background-color': '#222222'}}, }) \ No newline at end of file diff --git a/js/components.js b/js/components.js index d9eb8dc..ab23ccd 100644 --- a/js/components.js +++ b/js/components.js @@ -550,6 +550,7 @@ function loadVue() { Vue.component('options-tab', systemComponents['options-tab']) Vue.component('tooltip', systemComponents['tooltip']) Vue.component('particle', systemComponents['particle']) + Vue.component('bg', systemComponents['bg']) app = new Vue({ diff --git a/js/technical/canvas.js b/js/technical/canvas.js index 9ab7a88..4ebe9a5 100644 --- a/js/technical/canvas.js +++ b/js/technical/canvas.js @@ -7,7 +7,6 @@ function retrieveCanvasData() { let treeCanv = document.getElementById("treeCanvas") let treeTab = document.getElementById("treeTab") if (treeCanv===undefined||treeCanv===null) return false; - if (treeTab===undefined||treeTab===null) return false; canvas = treeCanv; ctx = canvas.getContext("2d"); return true; @@ -52,7 +51,6 @@ function drawTree() { function drawTreeBranch(num1, data) { // taken from Antimatter Dimensions & adjusted slightly let num2 = data let color_id = 1 - if (Array.isArray(data)){ num2 = data[0] color_id = data[1] diff --git a/js/technical/displays.js b/js/technical/displays.js index df7096e..c79634b 100644 --- a/js/technical/displays.js +++ b/js/technical/displays.js @@ -51,7 +51,6 @@ function achievementStyle(layer, id){ function updateWidth() { let screenWidth = window.innerWidth - let last = tmp.other.splitScreen let splitScreen = screenWidth >= 1024 if (player.forceOneTab) splitScreen = false if (player.navTab == "none") splitScreen = true @@ -60,7 +59,6 @@ function updateWidth() { tmp.other.splitScreen = splitScreen tmp.other.lastPoints = player.points - if (last !== tmp.other.splitScreen) needCanvasUpdate = true } function updateOomps(diff) diff --git a/js/technical/systemComponents.js b/js/technical/systemComponents.js index 62ba9be..3f6642c 100644 --- a/js/technical/systemComponents.js +++ b/js/technical/systemComponents.js @@ -66,7 +66,7 @@ var systemComponents = { 'layer-tab': { props: ['layer', 'back', 'spacing', 'embedded'], - template: `
+ template: `
@@ -136,8 +136,6 @@ var systemComponents = { The Modding Tree {{TMT_VERSION.tmtNum}} by Acamaeda
The Prestige Tree made by Jacorb and Aarex -
- Original idea by papyrus (on discord)


{{modInfo.discordName}}
@@ -211,5 +209,11 @@ var systemComponents = { ` }, + 'bg': { + props: ['layer'], + template: `
+ ` + } + } diff --git a/js/utils/options.js b/js/utils/options.js index 737e6bf..ca8d8ad 100644 --- a/js/utils/options.js +++ b/js/utils/options.js @@ -25,6 +25,7 @@ function changeTreeQuality() { } function toggleAuto(toggle) { player[toggle[0]][toggle[1]] = !player[toggle[0]][toggle[1]]; + needCanvasUpdate=true } const MS_DISPLAYS = ["ALL", "LAST, AUTO, INCOMPLETE", "AUTOMATION, INCOMPLETE", "INCOMPLETE", "NONE"]; diff --git a/style.css b/style.css index 4fd584f..9e27b1d 100644 --- a/style.css +++ b/style.css @@ -7,6 +7,7 @@ margin: auto; -webkit-text-size-adjust: none; text-size-adjust: none; + } *:focus { @@ -15,12 +16,12 @@ } body { - background-color: var(--background); color: var(--color); overflow: hidden; --background: #0f0f0f; --color: #dfdfdf; --points: #ffffff; + background: var(--background) } html, body { @@ -643,7 +644,6 @@ ul { .overlayThing { z-index: 10000; pointer-events:auto; - background-color: var(--background); } .sideLayers { @@ -652,6 +652,8 @@ ul { position: absolute; right: 55px; top: 65px; + background-color: transparent; + } button > * { @@ -754,3 +756,12 @@ button > * { .star:after { transform: rotate(35deg); } + +.bg { + z-index: -9000; + width: 100%; + height: 100%; + position: absolute; + background-color: var(--background); + top: 0 +}