Serwer Drasl
- Dodaje opcje na przełączenie się z serwerów Mojang na mój serwer Drasl - Każdy serwer używa teraz flag Aikara - 2 nowe reklamy: - I Want Your Donation - MCPanel Pro
This commit is contained in:
parent
b01a6b5034
commit
8e37b0cd55
6 changed files with 31 additions and 4 deletions
|
@ -90,6 +90,7 @@ def start_server(username):
|
|||
"EULA": "TRUE",
|
||||
"SERVER_PORT": ports[0],
|
||||
"ENABLE_RCON": "TRUE",
|
||||
"USE_AIKAR_FLAGS": "TRUE",
|
||||
"MOTD": f"Serwer użytkownika §9{username}",
|
||||
"TYPE": server_type,
|
||||
"VERSION": server_version,
|
||||
|
@ -106,6 +107,18 @@ def start_server(username):
|
|||
"MAX_MEMORY": "4G"
|
||||
}
|
||||
|
||||
if server_config["andus-drasl"]:
|
||||
drasl_args = (
|
||||
"-Dminecraft.api.env=custom "
|
||||
"-Dminecraft.api.auth.host=https://drasl.andus.ovh/auth "
|
||||
"-Dminecraft.api.account.host=https://drasl.andus.ovh/account "
|
||||
"-Dminecraft.api.session.host=https://drasl.andus.ovh/session "
|
||||
"-Dminecraft.api.services.host=https://drasl.andus.ovh/services"
|
||||
)
|
||||
environment["JVM_OPTS"] = drasl_args
|
||||
print(f"server {username} uses drasl {drasl_args}")
|
||||
print(f"env: {environment}")
|
||||
|
||||
client.containers.run(
|
||||
"itzg/minecraft-server",
|
||||
detach=True,
|
||||
|
|
BIN
app/static/ads/iWantYourDonation.png
Normal file
BIN
app/static/ads/iWantYourDonation.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.4 MiB |
BIN
app/static/ads/mcPanelPro.png
Normal file
BIN
app/static/ads/mcPanelPro.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 65 KiB |
|
@ -14,6 +14,7 @@ function loadConfig() {
|
|||
document.getElementById("allow-nether").checked = cfg["allow-nether"];
|
||||
document.getElementById("max-build-height").value = cfg["max-build-height"];
|
||||
document.getElementById("view-distance").value = cfg["view-distance"];
|
||||
document.getElementById("andus-drasl").value = cfg["andus-drasl"]
|
||||
})
|
||||
.catch(err => {
|
||||
console.error("Błąd wczytywania konfiguracji: ", err);
|
||||
|
@ -35,7 +36,8 @@ function saveConfig() {
|
|||
spawn_animals: document.getElementById("spawn-animals").checked,
|
||||
allow_nether: document.getElementById("allow-nether").checked,
|
||||
max_build_height: document.getElementById("max-build-height").value,
|
||||
view_distance: document.getElementById("view-distance").value
|
||||
view_distance: document.getElementById("view-distance").value,
|
||||
andus_drasl: document.getElementById("andus-drasl").value
|
||||
};
|
||||
|
||||
fetch('/api/config', {
|
||||
|
|
|
@ -68,8 +68,8 @@
|
|||
</div>
|
||||
|
||||
<div class="tab-panel" id="config">
|
||||
<h4>Konfiguracja Serwera:</h4>
|
||||
<form id="config-form">
|
||||
<h4>Konfiguracja Serwera:</h4>
|
||||
<div class="form-group">
|
||||
<label for="server-type">Typ serwera</label>
|
||||
<select id="server-type" class="form-control">
|
||||
|
@ -124,6 +124,15 @@
|
|||
<label for="view-distance">Zasięg widzenia</label>
|
||||
<input type="number" id="view-distance" class="form-control" min="1" value="{{ config['view-distance'] }}">
|
||||
</div>
|
||||
<h5>Inne:</h5>
|
||||
<div class="form-group">
|
||||
<label for="andus-drasl">Serwer Drasl Andusa</label>
|
||||
<h5>Tylko dla serwerów 1.16 i wyższych</h5>
|
||||
<h6>W tym trybie mogą dołączyć tylko gracze z kontem Drasl (https://drasl.andus.ovh).
|
||||
<br>Tryb online musi być włączony, ponieważ ten serwer dziala tak samo jak serwery Mojang (Ale bez konieczności kupowania Minecrafta).</h6>
|
||||
<h6 style="color: red">UWAGA: W tym trybie konta z kupionym Minecraftem nie mogą dołączyć na serwer, też muszą utworzyć konto Drasl.</h6>
|
||||
<input type="checkbox" id="andus-drasl" class="form-check-input" {% if config['andus-drasl'] %} checked {% endif %}>
|
||||
</div>
|
||||
<button type="button" class="btn btn-primary" onclick="saveConfig()">Zapisz zmiany</button>
|
||||
</form>
|
||||
</div>
|
||||
|
@ -286,7 +295,10 @@
|
|||
pointRadius: 0
|
||||
}]
|
||||
},
|
||||
options: chartOptions
|
||||
options: {
|
||||
...chartOptions,
|
||||
scales: { ...chartOptions.scales, y: { min: 0, max: 4096, ticks: { color: '#aaa' } } }
|
||||
}
|
||||
});
|
||||
|
||||
checkServerStatus();
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
{% block content %}{% endblock %}
|
||||
</div>
|
||||
<div id="ad-banner" class="ad-banner"></div>
|
||||
<p>Wersja: v0.3</p>
|
||||
<p>Wersja: v0.3.1</p>
|
||||
<script>
|
||||
window.addEventListener('dragover', e => e.preventDefault());
|
||||
window.addEventListener('drop', e => e.preventDefault());
|
||||
|
|
Loading…
Add table
Reference in a new issue