aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--index.html3
-rw-r--r--pottwal.pngbin0 -> 354788 bytes
-rw-r--r--script.js49
-rw-r--r--styles.css32
4 files changed, 83 insertions, 1 deletions
diff --git a/index.html b/index.html
index a856478..1ccf761 100644
--- a/index.html
+++ b/index.html
@@ -13,6 +13,8 @@
<div id="starBackground" class="starBackground"></div>
+<img src="pottwal.png" id="whaleParty" class="spermWhale">
+
<div class="contentWrapper">
<div class="content">
<b>Fook:</b> O Deep Thought computer, the task we have designed you to perform is this.
@@ -51,6 +53,7 @@
<b>Loonsuawl:</b> Yes..!!!...?
<br>
<b>Deep Thought:</b> Four-o-four.
+ <h2><b>DON'T PANIC!</b></h2>
</div>
</div>
diff --git a/pottwal.png b/pottwal.png
new file mode 100644
index 0000000..89df9c2
--- /dev/null
+++ b/pottwal.png
Binary files differ
diff --git a/script.js b/script.js
index 44fad4b..977cd58 100644
--- a/script.js
+++ b/script.js
@@ -102,4 +102,51 @@ particlesJS("starBackground", {
}
},
"retina_detect": true
-}); \ No newline at end of file
+});
+
+/*
+ Whale Partyy!
+ */
+const timeout = 10000;
+const whaleDialog =
+ "Ah … ! What’s happening? it thought.\n" +
+ "\n" +
+ "Er, excuse me, who am I?\n" +
+ "\n" +
+ "Hello?\n" +
+ "\n" +
+ "Why am I here? What’s my purpose in life?\n" +
+ "\n" +
+ "What do I mean by who am I?\n" +
+ "\n" +
+ "Calm down, get a grip now … oh! this is an interesting sensation, what is it? It’s a sort of … yawning, tingling sensation in my … my … well I suppose I’d better start finding names for things if I want to make any headway in what for the sake of what I shall call an argument I shall call the world, so let’s call it my stomach.\n" +
+ "\n" +
+ "Good. Ooooh, it’s getting quite strong. And hey, what’s about this whistling roaring sound going past what I’m suddenly going to call my head? Perhaps I can call that … wind! Is that a good name? It’ll do … perhaps I can find a better name for it later when I’ve found out what it’s for. It must be something very important because there certainly seems to be a hell of a lot of it. Hey! What’s this thing? This … let’s call it a tail – yeah, tail. Hey! I can can really thrash it about pretty good can’t I? Wow! Wow! That feels great! Doesn’t seem to achieve very much but I’ll probably find out what it’s for later on. Now – have I built up any coherent picture of things yet?\n" +
+ "\n" +
+ "No.\n" +
+ "\n" +
+ "Never mind, hey, this is really exciting, so much to find out about, so much to look forward to, I’m quite dizzy with anticipation …\n" +
+ "\n" +
+ "Or is it the wind?\n" +
+ "\n" +
+ "There really is a lot of that now isn’t it?\n" +
+ "\n" +
+ "And wow! Hey! What’s this thing suddenly coming towards me very fast? Very very fast. So big and flat and round, it needs a big wide sounding name like … ow … ound … round … ground! That’s it! That’s a good name – ground!\n" +
+ "\n" +
+ "I wonder if it will be friends with me?\n" +
+ "\n" +
+ "And the rest, after a sudden wet thud, was silence.";
+const flowerPotDialog = "Not again...";
+
+setTimeout(() => {
+ let whale = document.getElementById("whaleParty");
+ whale.classList.add("dropWhale");
+ console.log(whaleDialog);
+ setInterval(() => {
+ let randomNumber = Math.floor(Math.random() * 70) + 1;
+ whale = document.getElementById("whaleParty"); // update
+ whale.style.left = randomNumber.toString() + "%";
+ const newWhale = whale.cloneNode(true);
+ whale.parentNode.replaceChild(newWhale, whale);
+ }, timeout);
+}, timeout);
diff --git a/styles.css b/styles.css
index 76a9cc5..0206f74 100644
--- a/styles.css
+++ b/styles.css
@@ -52,4 +52,36 @@ canvas {
.content {
font-size: 1.5vh;
}
+}
+
+@media only screen and (max-height: 1000px) and (max-width: 600px) {
+ .content {
+ font-size: 2.5vh;
+ }
+}
+
+/*
+ Whale falling down
+ */
+.spermWhale {
+ position: absolute;
+ display: none;
+ width: auto;
+ height: 30vw;
+}
+
+.dropWhale {
+ display: block;
+ z-index: 1;
+ bottom: 0;
+ animation: drop 3s ease-in forwards;
+}
+
+@keyframes drop {
+ from {
+ transform: translate(0, -100vh) rotate(0deg);
+ }
+ to {
+ transform: translate(0, 200vh) rotate(360deg);
+ }
} \ No newline at end of file