prepared answer box in html

This commit is contained in:
Yannik
2023-05-27 15:21:03 +02:00
parent 4aa35684ab
commit b50fe68f77
3 changed files with 25 additions and 4 deletions

View File

@@ -15,8 +15,11 @@
<p id="title"></p>
<p id="dlg-text"></p>
</div>
<div id="answer-box">
<p>Test</p>
<div hidden="true" id="answer-box">
<p id="answer"></p>
<p id="answer"></p>
<p id="answer"></p>
<p id="answer"></p>
</div>
<img draggable="false" hidden="true" id="triangle" src="text_horror/assets/triangle.png">
<p class="thx-for-playing">Thanks for playing</p>

View File

@@ -1,8 +1,8 @@
var speed = 50;
var typeindex = 0;
var dlgFile = {};
let dlgLines = [];
var dlgPointer = 0;
var dlgFile;
let dlgLines;
function load() {
fetch("text_horror/dialogue.json")

View File

@@ -57,6 +57,24 @@ body {
animation: float 1.5s ease-in-out infinite;
}
#answer-box {
border-style: solid;
border-width: 5px;
border-color: white;
background-color: black;
width: 15%;
padding-inline: 20px;
position: absolute;
right: 12%;
bottom: 68%;
}
#answer {
text-decoration: underline;
font-size: 30px;
}
@keyframes float {
0% {
transform: translatey(0px);