Add dynamic code map

This commit is contained in:
clerie 2021-02-26 15:54:24 +01:00
parent e023b9df8b
commit 2e11fe0248

View File

@ -53,8 +53,9 @@
} }
konfi_button.addEventListener("click", () => { konfi_button.addEventListener("click", () => {
if (valid_world_code(konfi_code.value)) { var code = konfi_code.value;
location.href = "https://play.world.fem-net.de/_/" + konfi_code.value + "/prediger.riese.space/map/konfi.json"; if (valid_world_code(code)) {
location.href = "https://play.world.fem-net.de/_/" + code + "/prediger.riese.space/dyn/" + code + "/konfi.json";
konfi_code.classList.remove("is-invalid"); konfi_code.classList.remove("is-invalid");
konfi_code.classList.add("is-valid"); konfi_code.classList.add("is-valid");
} }