mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-16 17:31:24 +01:00
v1.4.29
This commit is contained in:
parent
79ebab8775
commit
184966802f
5 changed files with 5 additions and 33 deletions
BIN
Fantasy Map Generator.lnk
Normal file
BIN
Fantasy Map Generator.lnk
Normal file
Binary file not shown.
5
Readme.txt
Normal file
5
Readme.txt
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
Azgaar's Fantasy Map Generator
|
||||
This is an open-source software available under MIT license
|
||||
https://github.com/Azgaar/Fantasy-Map-Generator
|
||||
|
||||
To run the tool unzip ALL files and open index.html in browser
|
||||
BIN
images/icon.ico
Normal file
BIN
images/icon.ico
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 195 KiB |
|
|
@ -296,33 +296,6 @@ async function saveMap() {
|
|||
window.URL.revokeObjectURL(URL);
|
||||
}
|
||||
|
||||
// Send .map file to server [test function]
|
||||
async function sendToURL(URL = "http://localhost:8000/upload.php") {
|
||||
if (customization) {tip("Map cannot be saved when edit mode is active, please exit the mode and retry", false, "error"); return;}
|
||||
closeDialogs("#alert");
|
||||
|
||||
const blob = await getMapData();
|
||||
const xhr = new XMLHttpRequest();
|
||||
xhr.open("POST", URL, true);
|
||||
//xhr.setRequestHeader("Content-Type", "blob"); // set request header
|
||||
xhr.onload = e => console.log("onload", e.responseText);
|
||||
xhr.onreadystatechange = () => {if (xhr.readyState === 4 && xhr.status === 200) tip(`File is sent to cloud storage`, true, "success", 7000);}
|
||||
xhr.send(blob);
|
||||
}
|
||||
|
||||
// Load .map file from server [test function]
|
||||
async function loadFromCloud() {
|
||||
ldb.get("lastMap", blob => {
|
||||
if (blob) {
|
||||
loadMapPrompt(blob);
|
||||
} else {
|
||||
tip("No map stored. Save map to storage first", true, "error", 2000);
|
||||
console.error("No map stored");
|
||||
}
|
||||
});
|
||||
uploadMap(blob);
|
||||
}
|
||||
|
||||
function saveGeoJSON_Cells() {
|
||||
let data = "{ \"type\": \"FeatureCollection\", \"features\": [\n";
|
||||
const cells = pack.cells, v = pack.vertices;
|
||||
|
|
|
|||
|
|
@ -1,6 +0,0 @@
|
|||
<?php
|
||||
header("Content-type: text/plain");
|
||||
echo "received:";
|
||||
var_dump(file_get_contents('php://input'));
|
||||
print_r($_POST);
|
||||
?>
|
||||
Loading…
Add table
Add a link
Reference in a new issue