Merge branch 'main' into breaking_changes

# Conflicts:
#	Adjuster.py
#	AdjusterMain.py
#	BaseClasses.py
#	MultiClient.py
#	MultiServer.py
#	Mystery.py
#	Utils.py
#	WebHostLib/downloads.py
#	WebHostLib/generate.py
#	dumpSprites.py
#	test/TestBase.py
#	worlds/alttp/EntranceRandomizer.py
#	worlds/alttp/Main.py
#	worlds/alttp/Rom.py
This commit is contained in:
Fabian Dill
2021-01-03 13:13:59 +01:00
558 changed files with 13839 additions and 3095 deletions

View File

@@ -0,0 +1,5 @@
{% extends "tablepage.html" %}
{% block head %}
{{ super() }}
<script type="application/ecmascript" src="{{ static_autoversion("assets/autodatatable.js") }}"></script>
{% endblock %}

View File

@@ -1,23 +1,28 @@
{% extends 'layout.html' %}
{% extends 'pageWrapper.html' %}
{% block head %}
{{ super() }}
<title>Mystery Check Result</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/uploads.css") }}" />
<script type="application/ecmascript" src="{{ static_autoversion("assets/uploads.js") }}"></script>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/check.css") }}" />
<script type="application/ecmascript" src="{{ static_autoversion("assets/check.js") }}"></script>
{% endblock %}
{% block body %}
<div id="uploads-wrapper">
<div id="uploads" class="main-content">
{% include 'header/oceanHeader.html' %}
<div id="check-wrapper">
<div id="check" class="grass-island">
<h3>Upload Yaml</h3>
<p>This page checks a .yaml file for you, to be used as options for a mystery multiworld. You can also upload a .zip with multiple YAMLs.</p>
<div id="uploads-form-wrapper">
<form id="upload-form" method="post" enctype="multipart/form-data">
<p>
This page checks a .yaml file for you, to be used as options for a mystery multiworld.
You can also upload a .zip with multiple YAMLs.
</p>
<div id="check-form-wrapper">
<form id="check-form" method="post" enctype="multipart/form-data">
<input id="file-input" type="file" name="file">
</form>
<button id="upload-button">Upload</button>
<button id="check-button">Upload</button>
</div>
</div>
</div>
{% include 'islandFooter.html' %}
{% endblock %}

View File

@@ -0,0 +1,34 @@
{% extends 'autotablepage.html' %}
{% block head %}
{{ super() }}
<title>Mystery YAML Test Roll Results</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/checkResult.css") }}" />
{% endblock %}
{% block body %}
{% include 'header/oceanHeader.html' %}
<div id="check-result-wrapper">
<div id="check-result" class="grass-island">
<h1>Verification Results</h1>
<p>The results of your requested file check are below.</p>
<table class="table autodatatable">
<thead>
<tr>
<th>File</th>
<th>Result</th>
</tr>
</thead>
<tbody>
{% for filename, resulttext in results.items() %}
<tr>
<td>{{ filename }}</td>
<td>{{ "Valid" if resulttext == True else resulttext }}</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
</div>
{% include 'islandFooter.html' %}
{% endblock %}

View File

@@ -1,12 +0,0 @@
{% extends 'layout.html' %}
{% block head %}
{{ super() }}
<title>Upload Mystery YAML</title>
{% endblock %}
{% block body %}
{% for filename, resulttext in results.items() %}
<span>{{ filename }}: {{ "Looks ok" if resulttext == True else resulttext }}</span><br>
{% endfor %}
{% endblock %}

View File

@@ -1,42 +1,46 @@
{% extends 'layout.html' %}
{% extends 'pageWrapper.html' %}
{% block head %}
{{ super() }}
<title>Generate Game</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/uploads.css") }}"/>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/generate.css") }}" />
<script type="application/ecmascript" src="{{ static_autoversion("assets/generate.js") }}"></script>
{% endblock %}
{% block body %}
<div id="uploads-wrapper">
<div id="uploads" class="main-content">
<h3>Upload YAML(s){% if race %} (Race Mode){% endif %}</h3>
{% include 'header/oceanHeader.html' %}
<div id="generate-game-wrapper">
<div id="generate-game" class="grass-island">
<h1>Upload Config{% if race %} (Race Mode){% endif %}</h1>
<p>
This page allows you to generate a game by uploading a yaml file or a zip file containing yaml files.
If you do not have a config (yaml) file yet, you may create one on the
<a href="/player-settings">Player Settings</a> page. If you would like more advanced options,
the <a href="/weighted-settings">Weighted Settings</a> page might be what you're looking for.
</p>
<p>
This page accepts a yaml file containing generator options.
You can find a documented example at <a
href="https://raw.githubusercontent.com/Berserker66/MultiWorld-Utilities/master/playerSettings.yaml">playerSettings.yaml</a>.
This file can be saved as .yaml, edited to your liking and then supplied to the generator.
You can also upload a .zip with multiple YAMLs.
A proper menu is in the works.
{% if race -%}
Race Mode means the spoiler log will be unavailable.
This game will be generated in race mode, meaning the spoiler log will be unavailable,
roms will be encrypted, and single-player games will have no multidata files.
{%- else -%}
You can go to <a href="{{ url_for("generate", race=True) }}">Race Mode</a> to create a game without
spoiler log.
If you would like to generate a race game,
<a href="{{ url_for("generate", race=True) }}">click here.</a> Race games are generated without
a spoiler log, the ROMs are encrypted, and single-player games will not include a multidata file.
{%- endif -%}
</p>
<p>
After generation is complete, you will have the option to download a patch file.
This patch file can be opened with the <a
href="https://github.com/Berserker66/MultiWorld-Utilities/releases">Client</a> to create a rom file.
In-Browser patching will come.
This patch file can be opened with the
<a href="https://github.com/Berserker66/MultiWorld-Utilities/releases">client</a>, which can be
used to to create a rom file. In-browser patching is planned for the future.
</p>
<div id="uploads-form-wrapper">
<form id="upload-form" method="post" enctype="multipart/form-data">
<div id="generate-game-form-wrapper">
<form id="generate-game-form" method="post" enctype="multipart/form-data">
<input id="file-input" type="file" name="file">
</form>
<button id="upload-button">Upload</button>
<button id="generate-game-button">Upload</button>
</div>
</div>
</div>
{% include 'islandFooter.html' %}
{% endblock %}

View File

@@ -0,0 +1,21 @@
{% block head %}
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/header/baseHeader.css") }}" />
{% endblock %}
{% block header %}
<header id="base-header">
<div id="base-header-left">
<a href="/" id="site-title">
<img src="/favicon.ico" alt="Favicon" />
</a>
<a href="/">multiworld randomizer</a>
</div>
<div id="base-header-right">
<a href="/player-settings">start game</a>
<a href="/uploads">host game</a>
<a href="/tutorial">setup guide</a>
<a href="/generate">upload config</a>
<a href="https://discord.gg/8Z65BR2">discord</a>
</div>
</header>
{% endblock %}

View File

@@ -0,0 +1,5 @@
{% block head %}
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/header/dirtHeader.css") }}" />
{% endblock %}
{% include 'header/baseHeader.html' %}

View File

@@ -0,0 +1,5 @@
{% block head %}
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/header/grassHeader.css") }}" />
{% endblock %}
{% include 'header/baseHeader.html' %}

View File

@@ -0,0 +1,5 @@
{% block head %}
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/header/oceanHeader.css") }}" />
{% endblock %}
{% include 'header/baseHeader.html' %}

View File

@@ -0,0 +1,30 @@
{% extends 'pageWrapper.html' %}
{% block head %}
{{ super() }}
<title>Upload Multidata</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/hostGame.css") }}" />
<script type="application/ecmascript" src="{{ static_autoversion("assets/hostGame.js") }}"></script>
{% endblock %}
{% block body %}
{% include 'header/oceanHeader.html' %}
<div id="host-game-wrapper">
<div id="host-game" class="grass-island {% if rooms %}wider{% endif %}">
<h1>Host Game</h1>
<p>
To host a game, you need to upload a .multidata file or a .zip file<br />
created by the multiworld generator.
</p>
<div id="host-game-form-wrapper">
<form id="host-game-form" method="post" enctype="multipart/form-data">
<input id="file-input" type="file" name="file">
</form>
<button id="host-game-button">Upload</button>
</div>
</div>
</div>
{% include 'islandFooter.html' %}
{% endblock %}

View File

@@ -1,18 +1,19 @@
{% extends 'layout.html' %}
{% extends 'pageWrapper.html' %}
{% import "macros.html" as macros %}
{% block head %}
<title>Multiworld {{ room.id|suuid }}</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/host_room.css") }}"/>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/hostRoom.css") }}"/>
{% endblock %}
{% block body %}
{% include 'header/grassHeader.html' %}
<div id="host-room">
{% if room.owner == session["_id"] %}
Room created from <a href="{{ url_for("view_seed", seed=room.seed.id) }}">Seed #{{ room.seed.id|suuid }}</a>
Room created from <a href="{{ url_for("viewSeed", seed=room.seed.id) }}">Seed #{{ room.seed.id|suuid }}</a>
<br>
{% endif %}
{% if room.tracker %}
This room has a <a href="{{ url_for("get_tracker", tracker=room.tracker) }}">Multiworld Tracker</a> enabled.
This room has a <a href="{{ url_for("getTracker", tracker=room.tracker) }}">Multiworld Tracker</a> enabled.
<br>
{% endif %}
This room will be closed after {{ room.timeout//60//60 }} hours of inactivity. Should you wish to continue

View File

@@ -0,0 +1,18 @@
{% block footer %}
<footer id="island-footer">
<div id="copyright-notice">Copyright 2020 Archipelago</div>
<div id="links">
<a href="https://github.com/Berserker66/MultiWorld-Utilities">Source Code</a>
-
<a href="https://github.com/Berserker66/MultiWorld-Utilities/wiki">Wiki</a>
-
<a href="https://github.com/Berserker66/MultiWorld-Utilities/graphs/contributors">Contributors</a>
-
<a href="https://github.com/Berserker66/MultiWorld-Utilities/issues">Bug Report</a>
</div>
</footer>
{% endblock %}
{% block head %}
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/islandFooter.css") }}" />
{% endblock %}

View File

@@ -1,59 +1,61 @@
{% extends 'layout.html' %}
{% extends 'pageWrapper.html' %}
{% block head %}
<title>Berserker's Multiworld</title>
<title>MultiWorld</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/landing.css") }}" />
{% endblock %}
{% block body %}
<div id="landing-wrapper">
<div id="landing" class="main-content">
<div id="landing-header">
<h3>Berserker's Multiworld</h3>
<p id="landing-header-links">
<a href="https://github.com/Berserker66/MultiWorld-Utilities">Source Code</a>
-
<a href="https://github.com/Berserker66/MultiWorld-Utilities/wiki">Wiki</a>
-
<a href="https://github.com/Berserker66/MultiWorld-Utilities/graphs/contributors">Contributors</a>
</p>
</div>
<div id="landing-buttons">
<a href="{{ url_for("generate") }}">
<button>Start a New Game</button>
</a>
<a href="{{ url_for("uploads") }}">
<button>Host Existing Game</button>
</a>
<a href="{{ url_for('tutorial') }}">
<button>Setup Guide</button>
</a>
<a href="{{ url_for('player_settings') }}">
<button>Player Settings</button>
</a>
<a href="{{ url_for("mysterycheck") }}">
<button>Test YAML Config</button>
</a>
</div>
<div id="landing-header">
<h4>the legend of zelda: a link to the past</h4>
<h1>MULTIWORLD RANDOMIZER</h1>
</div>
<div id="landing-links">
<a href="/player-settings" id="player-settings-button">start<br />playing</a>
<a href="/uploads" id="uploads-button">host<br />game</a>
<a href="/tutorial" id="setup-guide-button">setup guide</a>
<a href="/generate" id="generate-button">upload config</a>
<a href="https://discord.gg/8Z65BR2" id="discord-button">discord</a>
</div>
<div id="landing-clouds">
<img id="cloud1" src="/static/static/backgrounds/clouds/cloud-0001.png"/>
<img id="cloud2" src="/static/static/backgrounds/clouds/cloud-0002.png"/>
<img id="cloud3" src="/static/static/backgrounds/clouds/cloud-0003.png"/>
</div>
<div id="landing-decorations">
<img id="landing-deco-1" class="landing-deco deco-island" src="/static/static/decorations/island-b.png" />
<img id="landing-deco-2" class="landing-deco deco-island" src="/static/static/decorations/island-c.png" />
<img id="landing-deco-3" class="landing-deco deco-rock" src="/static/static/decorations/rock-a.png" />
<img id="landing-deco-4" class="landing-deco deco-rock" src="/static/static/decorations/rock-a.png" />
<img id="landing-deco-5" class="landing-deco deco-rock" src="/static/static/decorations/rock-a.png" />
<img id="landing-deco-6" class="landing-deco deco-rock" src="/static/static/decorations/rock-a.png" />
</div>
<div id="landing" class="grass-island">
<div id="landing-body">
<p id="first-line">Welcome to the Archipelago Multiworld Randomizer!</p>
<p>This is a <span data-tooltip="Allegedly.">randomizer</span> for The Legend of Zelda: A
Link to the Past.</p>
<p>This is also a multiworld, meaning your items may be placed into other players' worlds, and
other players's items may be placed into your world. When a player picks up an item which does
not belong to them, it is sent back to the player it belongs to over the internet.</p>
<p>This website allows you to host a multiworld game, and provides item and location trackers for all
games hosted here.</p>
<p>Currently, a locally installed client is required to play. This client should handle patching
your ROM files and connecting to the multiworld server. More information on how to set up a local
client may be found on the
<a href="{{ url_for("tutorial") }}">Setup Guide</a>.</p>
<p>This website is under active development. As such, your hosted rooms may occasionally disappear,
and there may be bugs. If you do happen to find a bug, please report it
<a href="https://github.com/Berserker66/MultiWorld-Utilities/issues">here</a>.</p>
<p>{{ seeds }} games were created and {{ rooms }} hosted in the last 7 days.</p>
<p>It is also a multi-world, meaning Link's items may have been placed into other players' games.
When a player picks up an item which does not belong to them, it is sent back to the player
it belongs to.</p>
<p>On this website you are able to generate and host multiworld games, and item and location
trackers are provided for games hosted here.</p>
<p>
This project is the cumulative effort of many
<a href="https://github.com/Berserker66/MultiWorld-Utilities/graphs/contributors">talented people.</a>
Together, they have spent countless hours creating a huge repository of
<a href="https://github.com/Berserker66/MultiWorld-Utilities">source code</a> which has turned
our crazy idea into a reality.
</p>
<p>
<span class="variable">{{ seeds }}</span>
games were created and
<span class="variable">{{ rooms }}</span>
were hosted in the last 7 days.
</p>
</div>
</div>
<iframe src="https://discordapp.com/widget?id=731205301247803413&theme=light"
width="300" height="500" allowtransparency="true"></iframe>
</div>
{% include 'islandFooter.html' %}
{% endblock %}

View File

@@ -1,7 +1,7 @@
{% macro list_rooms(rooms) -%}
<ul>
{% for room in rooms %}
<li><a href="{{ url_for("host_room", room=room.id) }}">Room #{{ room.id|suuid }}</a></li>
<li><a href="{{ url_for("hostRoom", room=room.id) }}">Room #{{ room.id|suuid }}</a></li>
{% endfor %}
{{ caller() }}
</ul>
@@ -15,4 +15,4 @@
{% endfor %}
</ul>
{% endif %}
{%- endmacro -%}
{%- endmacro -%}

View File

@@ -2,11 +2,15 @@
<html lang="en">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/layout.css") }}" />
<link rel="preconnect" href="https://fonts.gstatic.com">
<link href="https://fonts.googleapis.com/css2?family=Jost:wght@400;500;600&display=swap" rel="stylesheet">
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/tooltip.css") }}" />
<script type="application/ecmascript" src="{{ static_autoversion("assets/layout.js") }}"></script>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/cookieNotice.css") }}" />
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/globalStyles.css") }}" />
<script type="application/ecmascript" src="{{ static_autoversion("assets/styleController.js") }}"></script>
<script type="application/ecmascript" src="{{ static_autoversion("assets/cookieNotice.js") }}"></script>
{% block head %}
<title>Berserker's Multiworld</title>
<title>MultiWorld</title>
{% endblock %}
</head>
<body>
@@ -15,7 +19,7 @@
{% if messages %}
<div>
{% for message in messages %}
<div class="alert alert-danger" role="alert">{{ message }}</div>
<div class="user-message">{{ message }}</div>
{% endfor %}
</div>
{% endif %}

View File

@@ -0,0 +1,45 @@
{% extends 'pageWrapper.html' %}
{% block head %}
<title>Player Settings</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/playerSettings.css") }}" />
<script type="application/ecmascript" src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
<script type="application/ecmascript" src="{{ static_autoversion("assets/js-yaml.min.js") }}"></script>
<script type="application/ecmascript" src="{{ static_autoversion("assets/playerSettings.js") }}"></script>
{% endblock %}
{% block body %}
{% include 'header/grassHeader.html' %}
<div id="player-settings">
<h1>Start Game</h1>
<p>Choose the options you would like to play with! You may generate a single-player game from this page,
or download a settings file you can use to participate in a MultiWorld. If you would like to make
your settings extra random, check out the advanced <a href="/weighted-settings">weighted settings</a>
page. There, you will find examples of all available sprites as well.</p>
<p>A list of all games you have generated can be found <a href="/user-content">here</a>.</p>
<p><label for="player-name">Please enter your player name. This will appear in-game as you send and receive
items, if you are playing in a MultiWorld.</label><br />
<input id="player-name" placeholder="Player Name" data-key="name" maxlength="16" />
</p>
<h2>Game Options</h2>
<div id="game-options">
<div id="game-options-left" class="left"></div>
<div id="game-options-right" class="right"></div>
</div>
<h2>ROM Options</h2>
<div id="rom-options">
<div id="rom-options-left" class="left"></div>
<div id="rom-options-right" class="right"></div>
</div>
<div id="player-settings-button-row">
<button id="export-settings">Export Settings</button>
<button id="generate-game">Generate Game</button>
<button id="generate-race">Generate Race</button>
</div>
</div>
{% endblock %}

View File

@@ -0,0 +1,19 @@
{% extends 'pageWrapper.html' %}
{% import "macros.html" as macros %}
{% block head %}
<title>Generation failed, please retry.</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/waitSeed.css") }}"/>
{% endblock %}
{% block body %}
{% include 'header/oceanHeader.html' %}
<div id="wait-seed-wrapper" class="grass-island">
<div id="wait-seed">
<h1>Generation failed</h1>
<h2>please retry</h2>
{{ seed_error }}
</div>
</div>
{% include 'islandFooter.html' %}
{% endblock %}

View File

@@ -1,4 +1,4 @@
{% extends "layout.html" %}
{% extends "pageWrapper.html" %}
{% block head %}
<link rel="stylesheet"
type="text/css"

View File

@@ -6,7 +6,9 @@
<script type="application/ecmascript" src="{{ static_autoversion("assets/jquery.scrollsync.js") }}"></script>
<script type="application/ecmascript" src="{{ static_autoversion("assets/tracker.js") }}"></script>
{% endblock %}
{% block body %}
{% include 'header/dirtHeader.html' %}
<div id="tracker-wrapper" data-tracker="{{ room.tracker|suuid }}">
<div id="tracker-header-bar">
<input placeholder="Search" id="search"/>
@@ -18,7 +20,7 @@
Multistream
</a>
</span>
<span>This tracker will automatically update itself periodically.</span>
<span class="info">This tracker will automatically update itself periodically.</span>
</div>
<div id="tables-container">
{% for team, players in inventory.items() %}
@@ -122,7 +124,7 @@
<td>{{ player_names[(team, loop.index)]|e }}</td>
{%- for area in ordered_areas -%}
{%- set checks_done = checks[area] -%}
{%- set checks_total = checks_in_area[area] -%}
{%- set checks_total = checks_in_area[player][area] -%}
{%- if checks_done == checks_total -%}
<td class="item-acquired center-column">
{{ checks_done }}/{{ checks_total }}</td>

View File

@@ -1,6 +1,7 @@
{% extends 'layout.html' %}
{% extends 'pageWrapper.html' %}
{% block head %}
{% include 'header/grassHeader.html' %}
<title>Setup Tutorial</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/tutorial.css") }}" />
<script src="https://cdnjs.cloudflare.com/ajax/libs/showdown/1.9.1/showdown.min.js"

View File

@@ -1,55 +0,0 @@
{% extends 'tablepage.html' %}
{% block head %}
{{ super() }}
<title>Upload Multidata</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/uploads.css") }}" />
<script type="application/ecmascript" src="{{ static_autoversion("assets/uploads.js") }}"></script>
{% endblock %}
{% block body %}
<div id="uploads-wrapper">
<div id="uploads" class="main-content">
<h3>Upload Multidata</h3>
<p>To host a game, you need to upload a .multidata file or a .zip file created by the
multiworld generator.</p>
<div id="uploads-form-wrapper">
<form id="upload-form" method="post" enctype="multipart/form-data">
<input id="file-input" type="file" name="file">
</form>
<button id="upload-button">Upload</button>
</div>
{% if rooms %}
<p>Your Rooms:</p>
<table id="uploads-table" class="table">
<thead>
<tr>
<th>Seed</th>
<th>Room</th>
<th>Players</th>
<th>Created</th>
<th>Last Activity</th>
</tr>
</thead>
<tbody>
{% for room in rooms %}
<tr>
<td><a href="{{ url_for("view_seed", seed=room.seed.id) }}">{{ room.seed.id|suuid }}</a>
</td>
<td><a href="{{ url_for("host_room", room=room.id) }}">{{ room.id|suuid }}</a></td>
<td>{{ room.seed.multidata.names[0]|length }} Total:
{{ room.seed.multidata.names[0]|join(", ")|truncate(256, False, " ...") }}</td>
<td>{{ room.creation_time.strftime("%Y-%m-%d %H:%M") }}</td>
<td>{{ room.last_activity.strftime("%Y-%m-%d %H:%M") }}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% else %}
<p>No rooms owned by you were found. Upload a file to get started.</p>
{% endif %}
</div>
</div>
{% endblock %}

View File

@@ -0,0 +1,79 @@
{% extends 'tablepage.html' %}
{% block head %}
{{ super() }}
<title>Generate Game</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/userContent.css") }}" />
<script type="application/ecmascript" src="{{ static_autoversion("assets/userContent.js") }}"></script>
{% endblock %}
{% block body %}
{% include 'header/oceanHeader.html' %}
<div id="user-content-wrapper">
<div id="user-content" class="grass-island">
<h1>User Content</h1>
Below is a list of all the content you have generated on this site. Rooms and seeds are listed separately.
<h2>Your Rooms</h2>
{% if rooms %}
<table id="rooms-table" class="table">
<thead>
<tr>
<th>Seed</th>
<th>Room</th>
<th class="center">Players</th>
<th>Created (UTC)</th>
<th>Last Activity (UTC)</th>
</tr>
</thead>
<tbody>
{% for room in rooms %}
<tr>
<td><a href="{{ url_for("viewSeed", seed=room.seed.id) }}">{{ room.seed.id|suuid }}</a></td>
<td><a href="{{ url_for("hostRoom", room=room.id) }}">{{ room.id|suuid }}</a></td>
<td
class="center"
data-tooltip="{{ room.seed.multidata.names[0]|join(", ")|truncate(256, False, " ...") }}"
>{{ room.seed.multidata.names[0]|length }}</td>
<td>{{ room.creation_time.strftime("%Y-%m-%d %H:%M") }}</td>
<td>{{ room.last_activity.strftime("%Y-%m-%d %H:%M") }}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% else %}
You have not created any rooms yet!
{% endif %}
<h2>Your Seeds</h2>
{% if seeds %}
<table id="seeds-table" class="table">
<thead>
<tr>
<th>Seed</th>
<th class="center">Players</th>
<th>Created (UTC)</th>
</tr>
</thead>
<tbody>
{% for seed in seeds %}
<tr>
<td><a href="{{ url_for("viewSeed", seed=seed.id) }}">{{ seed.id|suuid }}</a></td>
<td class="center"
{% if seed.multidata %}
data-tooltip="{{ seed.multidata.names[0]|join(", ")|truncate(256, False, " ...") }}"
{% endif %}
>{% if seed.multidata %}{{ seed.multidata.names[0]|length }}{% else %}1{% endif %}
</td>
<td>{{ seed.creation_time.strftime("%Y-%m-%d %H:%M") }}</td>
</tr>
{% endfor %}
</tbody>
</table>
{% else %}
You have no generated any seeds yet!
{% endif %}
</div>
</div>
{% include 'islandFooter.html' %}
{% endblock %}

View File

@@ -1,16 +1,21 @@
{% extends 'layout.html' %}
{% extends 'pageWrapper.html' %}
{% import "macros.html" as macros %}
{% block head %}
<title>Multiworld Seed {{ seed.id|suuid }}</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/view_seed.css") }}"/>
<script type="application/ecmascript" src="{{ static_autoversion("assets/view_seed.js") }}"></script>
<title>View Seed {{ seed.id|suuid }}</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/viewSeed.css") }}"/>
<script type="application/ecmascript" src="{{ static_autoversion("assets/viewSeed.js") }}"></script>
{% endblock %}
{% block body %}
{% include 'header/oceanHeader.html' %}
<div id="view-seed-wrapper">
<div class="main-content">
<h3>Seed Info</h3>
<div id="view-seed" class="grass-island">
<h1>Seed Info</h1>
{% if not seed.multidata and not seed.spoiler %}
<p>Single Player Race Rom: No spoiler or multidata exists, parts of the rom are encrypted and rooms
cannot be created.</p>
{% endif %}
<table>
<tbody>
<tr>
@@ -27,6 +32,7 @@
<td><a href="{{ url_for("download_spoiler", seed_id=seed.id) }}">Download</a></td>
</tr>
{% endif %}
{% if seed.multidata %}
<tr>
<td>Players:&nbsp;</td>
<td>
@@ -55,8 +61,26 @@
{% endcall %}
</td>
</tr>
{% else %}
<tr>
<td>Patches:&nbsp;</td>
<td>
<ul>
{% for patch in seed.patches %}
<li>
<a href="{{ url_for("download_raw_patch", seed_id=seed.id, player_id=patch.player) }}">Player {{ patch.player }}</a>
</li>
{% endfor %}
</ul>
</td>
</tr>
{% endif %}
</tbody>
</table>
</div>
</div>
{% include 'islandFooter.html' %}
{% endblock %}

View File

@@ -0,0 +1,19 @@
{% extends 'pageWrapper.html' %}
{% import "macros.html" as macros %}
{% block head %}
<title>Generation in Progress</title>
<meta http-equiv="refresh" content="1">
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/waitSeed.css") }}"/>
{% endblock %}
{% block body %}
{% include 'header/oceanHeader.html' %}
<div id="wait-seed-wrapper" class="grass-island">
<div id="wait-seed">
<h1>Generation in Progress</h1>
Waiting for game to generate, this page auto-refreshes to check.
</div>
</div>
{% include 'islandFooter.html' %}
{% endblock %}

View File

@@ -1,16 +0,0 @@
{% extends 'layout.html' %}
{% import "macros.html" as macros %}
{% block head %}
<title>Multiworld Seed {{ seed_id|suuid }} (generating...)</title>
<meta http-equiv="refresh" content="1">
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/view_seed.css") }}"/>
{% endblock %}
{% block body %}
<div id="wait-seed-wrapper">
<div class="main-content">
Waiting for game to generate, this page auto-refreshes to check.
</div>
</div>
{% endblock %}

View File

@@ -1,19 +1,23 @@
{% extends 'layout.html' %}
{% extends 'pageWrapper.html' %}
{% block head %}
<title>Player Settings</title>
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/player-settings.css") }}" />
<link rel="stylesheet" type="text/css" href="{{ static_autoversion("styles/weightedSettings.css") }}" />
<script type="application/ecmascript" src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
<script type="application/ecmascript" src="{{ static_autoversion("assets/js-yaml.min.js") }}"></script>
<script type="application/ecmascript" src="{{ static_autoversion("assets/player-settings.js") }}"></script>
<script type="application/ecmascript" src="{{ static_autoversion("assets/weightedSettings.js") }}"></script>
{% endblock %}
{% block body %}
<div id="game-settings" class="main-content">
<h3>Player Settings</h3>
{% include 'header/grassHeader.html' %}
<div id="weighted-settings">
<h1>Weighted Settings</h1>
<div id="instructions">
This page is used to configure your player settings. You have three presets you can control, which
This page is used to configure your weighted settings. You have three presets you can control, which
you can access using the dropdown menu below. These settings will be usable when generating a
single player game, or you can export them to a <code>.yaml</code> file and use them in a multiworld.
If you already have a settings file you would like to validate, you may do so on the
<a href="/mysterycheck">verification page</a>.
</div>
<div id="settings-wrapper">
@@ -61,9 +65,11 @@
</tbody>
</table>
</div>
<div id="game-settings-button-row">
<div id="weighted-settings-button-row">
<button id="reset-to-default">Reset to Defaults</button>
<button id="export-button">Export Settings</button>
<button id="generate-game">Generate Game</button>
<button id="generate-race">Generate Race</button>
</div>
</div>
{% endblock %}