checkpoint: bun server + game UI before multiplayer refactor
This commit is contained in:
1 parent
b5fb570df4
commit
e688c2bdf1
9 files changed
+548
-203
No files matched your search
+38
-109
@@ -10,7 +10,39 @@
|
||||
href="https://fonts.googleapis.com/css2?family=Almendra:ital,wght@0,400;0,700;1,400;1,700&display=swap"
|
||||
rel="stylesheet"
|
||||
/>
|
||||
<style></style>
|
||||
<style>
|
||||
body {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
min-height: 100vh;
|
||||
}
|
||||
button {
|
||||
min-height: 20vh;
|
||||
/* flex: 1; */
|
||||
}
|
||||
.Content {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
|
||||
flex-direction: column;
|
||||
max-width: 600px;
|
||||
margin: 0 auto;
|
||||
width: 100%;
|
||||
}
|
||||
.part {
|
||||
flex: 1;
|
||||
margin: 5px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
row-gap: 10px;
|
||||
}
|
||||
|
||||
input {
|
||||
padding: 1vh;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<header>
|
||||
@@ -21,115 +53,12 @@
|
||||
</div>
|
||||
</div>
|
||||
</header>
|
||||
<div class="Content">
|
||||
<div class="Instruction">
|
||||
<p>Backstory</p>
|
||||
<details>
|
||||
<summary>Click to expand</summary>
|
||||
<p>
|
||||
You and your class planned to go on a one week cruise trip over
|
||||
spring break to learn about how inflation affects nautical
|
||||
exploration and catching some sun. The cruise ship is built a pirate
|
||||
ship which you all find amusing at first. However, issues arise from
|
||||
an underlying problem. They didn't have the money to get schedule a
|
||||
final inspection before departing, but they still let you go anyways
|
||||
(because they are broke). As the boat leaves and cruises away from
|
||||
land, you see rocky terrain that has formed in the middle of the
|
||||
ocean (shocking). Your boat hits it and as people don't learn from
|
||||
the titanic, you don't have enough life boats to fit everyone and
|
||||
make it home safely. Everybody else gets on boats while you and your
|
||||
classmates are still on the boat (coincidentally). One of your
|
||||
friends believes he has a boat license (he doesn't) and tries to
|
||||
steer the boat before you sink. Magically you find an island. You
|
||||
all get onto the island safely but with no way home, scattered and
|
||||
disoriented.
|
||||
</p>
|
||||
</details>
|
||||
</div>
|
||||
<div class="Instruction">
|
||||
<p>Objective</p>
|
||||
<details>
|
||||
<summary>Click to expand</summary>
|
||||
<p>
|
||||
You will have 16 hours each day to gain as many resources as
|
||||
possible to survive. You must choose what to spend your hours doing
|
||||
each day carefully. The survival requirement for the end of each day
|
||||
is to have 8 fish and 4 pieces of lumber. Otherwise, you die (lose).
|
||||
You will be able to trade with other classmates you have found
|
||||
stranded at no expense of your daily hours.
|
||||
</p>
|
||||
</details>
|
||||
</div>
|
||||
<div class="Instruction">
|
||||
<p>Requirements</p>
|
||||
<details>
|
||||
<summary>Click to expand</summary>
|
||||
<ol>
|
||||
<li>
|
||||
In order to escape, you must have 24 stockpiled fish and a boat at
|
||||
the START of a new day.
|
||||
</li>
|
||||
<li>Fish will go bad without a preserver.</li>
|
||||
<li>
|
||||
Improving skills requires 8 hours and adds 1 per hour the next
|
||||
day.
|
||||
</li>
|
||||
<li>Building a preserver requires 8 hours and 25 wood</li>
|
||||
<li>Building a boat requires 16 hours and 100 wood</li>
|
||||
<li>You can only trade with "found" players</li>
|
||||
<li>
|
||||
It is recommended to donate resources to other players at end of
|
||||
day if you have a boat (Need to have 24 fish to leave)
|
||||
</li>
|
||||
</ol>
|
||||
</details>
|
||||
</div>
|
||||
<div class="game">
|
||||
<div class="table-container">
|
||||
<table>
|
||||
<tr>
|
||||
<th></th>
|
||||
<th>Fishing Stats</th>
|
||||
<th>Foraging Stats</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th style="width: 25%">Days: <span id="days">0</span></th>
|
||||
<td id="fish_p_hour">0</td>
|
||||
<td id="wood_p_hour">0</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th style="width: 25%">
|
||||
Players Found: <span id="found">0</span>
|
||||
</th>
|
||||
<td>Preserver: <span id="preserver">No</span></td>
|
||||
<td>Boat: <span id="boat">No</span></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th style="width: 25%">Hours Left: <span id="hours">16</span></th>
|
||||
<td>Stored Fish: <span id="fish_stored"></span></td>
|
||||
<td>Stored Wood: <span id="wood_stored"></span></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div class="button-container">
|
||||
<div class="button-container-part">
|
||||
<button type="button" id="go-fishing">Go Fishing</button>
|
||||
<button type="button" id="go-foraging">Go Foraging</button>
|
||||
<!-- <button type="button" id="trading">Trade</button> -->
|
||||
</div>
|
||||
<div class="button-container-part">
|
||||
<button type="button" id="improve-fishing">
|
||||
Improve Fish Per Hour
|
||||
</button>
|
||||
<button type="button" id="build-preserver">Build Preserver</button>
|
||||
|
||||
<button type="button" id="improve-forgaing">
|
||||
Improve Wood Per Hour
|
||||
</button>
|
||||
<button type="button" id="build-boat">Build Boat</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="Content" style="padding-top: 25px">
|
||||
<div class="part">
|
||||
<input type="text" placeholder="Name:" id="name" />
|
||||
<input type="number" placeholder="Join Code:" id="join-code" />
|
||||
</div>
|
||||
<button type="button" id="join-button">Join as Student</button>
|
||||
</div>
|
||||
<footer>
|
||||
<h3 style="padding: 10px 0px 0px 10px">
|
||||
|
||||
Reference in new issue
Block a user