From 66b42f0c83369251e9e0009231fdb36544f19cd2 Mon Sep 17 00:00:00 2001 From: Jacoder23 Date: Tue, 25 Oct 2022 14:55:24 +0800 Subject: [PATCH] v1.1.1 - Fixed a game-breaking bug --- index.html | 56 ++++++++++++++++++++++++++++++-------- v1.0.3.twee => v1.1.1.twee | 56 ++++++++++++++++++++++++++++++-------- 2 files changed, 90 insertions(+), 22 deletions(-) rename v1.0.3.twee => v1.1.1.twee (98%) diff --git a/index.html b/index.html index 8d0ac25..df9d130 100644 --- a/index.html +++ b/index.html @@ -145,10 +145,22 @@ DIOTIMA: *[[Here comes one of my students now.|SOCRATES 2]]* [continued] [JavaScript] +var firstimage = "Diotima Human.png"; +var secondimage = "trans parent.png"; + +const element1 = document.getElementById('leftContainer'); + +element1?.remove(); + +const element2 = document.getElementById('rightContainer'); + +element2?.remove(); + + /////////// const img1 = document.createElement("img"); -img1.setAttribute("src", "Assets/Images/Diotima Human.png"); +img1.setAttribute("src", "Assets/Images/" + firstimage); /////////// img1.setAttribute("id", "leftPortrait"); @@ -160,16 +172,14 @@ document.getElementById("backdrop").prepend(cont1); ////////// const img2 = document.createElement("img"); -img2.setAttribute("src", "Assets/Images/trans parent.png"); +img2.setAttribute("src", "Assets/Images/" + secondimage); /////////// img2.setAttribute("id", "rightPortrait"); const cont2 = document.createElement("div"); cont2.setAttribute("id", "rightContainer"); cont2.appendChild(img2); -document.getElementById("backdrop").appendChild(cont2); - -document.body.removeAttribute("class");progressA: 0 +document.getElementById("backdrop").appendChild(cont2);progressA: 0 progressB: 0 inventory: ["People are naive and can be tricked.", "Your argument is a sham and you are an idiot."] cred: 4 @@ -994,17 +1004,41 @@ DIOTIMA: Oh. [[What exactly can I "get for myself"?|INTERLUDE 3]] [continued] [JavaScript] -/////////// -const img1 = document.getElementById("leftPortrait"); +var firstimage = "Diotima.png"; +var secondimage = "trans parent.png"; + +const element1 = document.getElementById('leftContainer'); + +element1?.remove(); + +const element2 = document.getElementById('rightContainer'); + +element2?.remove(); + -img1.setAttribute("src", "Assets/Images/Diotima.png"); /////////// +const img1 = document.createElement("img"); + +img1.setAttribute("src", "Assets/Images/" + firstimage); +/////////// + +img1.setAttribute("id", "leftPortrait"); +const cont1 = document.createElement("div"); +cont1.setAttribute("id", "leftContainer"); +cont1.appendChild(img1); +document.getElementById("backdrop").prepend(cont1); ////////// -const img2 = document.getElementById("rightPortrait"); +const img2 = document.createElement("img"); -img2.setAttribute("src", "Assets/Images/trans parent.png"); -///////////SUIKA: [[Love!|INTERLUDE 4]] +img2.setAttribute("src", "Assets/Images/" + secondimage); +/////////// + +img2.setAttribute("id", "rightPortrait"); +const cont2 = document.createElement("div"); +cont2.setAttribute("id", "rightContainer"); +cont2.appendChild(img2); +document.getElementById("backdrop").appendChild(cont2);SUIKA: [[Love!|INTERLUDE 4]] SUIKA: I don't want anything to do with love anymore! diff --git a/v1.0.3.twee b/v1.1.1.twee similarity index 98% rename from v1.0.3.twee rename to v1.1.1.twee index c966c6a..be62955 100644 --- a/v1.0.3.twee +++ b/v1.1.1.twee @@ -126,10 +126,22 @@ DIOTIMA: *[[Here comes one of my students now.|SOCRATES 2]]* [continued] [JavaScript] +var firstimage = "Diotima Human.png"; +var secondimage = "trans parent.png"; + +const element1 = document.getElementById('leftContainer'); + +element1?.remove(); + +const element2 = document.getElementById('rightContainer'); + +element2?.remove(); + + /////////// const img1 = document.createElement("img"); -img1.setAttribute("src", "Assets/Images/Diotima Human.png"); +img1.setAttribute("src", "Assets/Images/" + firstimage); /////////// img1.setAttribute("id", "leftPortrait"); @@ -141,16 +153,14 @@ document.getElementById("backdrop").prepend(cont1); ////////// const img2 = document.createElement("img"); -img2.setAttribute("src", "Assets/Images/trans parent.png"); +img2.setAttribute("src", "Assets/Images/" + secondimage); /////////// img2.setAttribute("id", "rightPortrait"); const cont2 = document.createElement("div"); cont2.setAttribute("id", "rightContainer"); cont2.appendChild(img2); -document.getElementById("backdrop").appendChild(cont2); - -document.body.removeAttribute("class");progressA: 0 +document.getElementById("backdrop").appendChild(cont2);progressA: 0 progressB: 0 inventory: ["People are naive and can be tricked.", "Your argument is a sham and you are an idiot."] cred: 4 @@ -975,17 +985,41 @@ DIOTIMA: Oh. [[What exactly can I "get for myself"?|INTERLUDE 3]] [continued] [JavaScript] -/////////// -const img1 = document.getElementById("leftPortrait"); +var firstimage = "Diotima.png"; +var secondimage = "trans parent.png"; + +const element1 = document.getElementById('leftContainer'); + +element1?.remove(); + +const element2 = document.getElementById('rightContainer'); + +element2?.remove(); + -img1.setAttribute("src", "Assets/Images/Diotima.png"); /////////// +const img1 = document.createElement("img"); + +img1.setAttribute("src", "Assets/Images/" + firstimage); +/////////// + +img1.setAttribute("id", "leftPortrait"); +const cont1 = document.createElement("div"); +cont1.setAttribute("id", "leftContainer"); +cont1.appendChild(img1); +document.getElementById("backdrop").prepend(cont1); ////////// -const img2 = document.getElementById("rightPortrait"); +const img2 = document.createElement("img"); -img2.setAttribute("src", "Assets/Images/trans parent.png"); -///////////SUIKA: [[Love!|INTERLUDE 4]] +img2.setAttribute("src", "Assets/Images/" + secondimage); +/////////// + +img2.setAttribute("id", "rightPortrait"); +const cont2 = document.createElement("div"); +cont2.setAttribute("id", "rightContainer"); +cont2.appendChild(img2); +document.getElementById("backdrop").appendChild(cont2);SUIKA: [[Love!|INTERLUDE 4]] SUIKA: I don't want anything to do with love anymore!