Kaynağa Gözat

Run the source through a formatter

tags/v0.1.0
Fen Dweller 5 yıl önce
ebeveyn
işleme
27940dfaf0
12 değiştirilmiş dosya ile 1230 ekleme ve 1233 silme
  1. +58
    -58
      macrovision.js
  2. +43
    -43
      media/attribution.js
  3. +2
    -2
      presets/buildings.js
  4. +156
    -156
      presets/characters.js
  5. +1
    -1
      presets/fiction.js
  6. +13
    -13
      presets/food.js
  7. +2
    -2
      presets/landmarks.js
  8. +887
    -887
      presets/naturals.js
  9. +14
    -17
      presets/objects.js
  10. +11
    -11
      presets/scenes.js
  11. +3
    -3
      presets/species.js
  12. +40
    -40
      presets/vehicles.js

+ 58
- 58
macrovision.js Dosyayı Görüntüle

@@ -195,7 +195,7 @@ function updateEntityElement(entity, element) {
element.style.left = position.x + "px";
element.style.top = position.y + "px";
element.style.setProperty("--xpos", position.x + "px");
element.style.setProperty("--entity-height", "'" + entity.views[view].height.to(config.height.units[0].unit.name).format({precision: 2}) + "'");
element.style.setProperty("--entity-height", "'" + entity.views[view].height.to(config.height.units[0].unit.name).format({ precision: 2 }) + "'");
const pixels = math.divide(entity.views[view].height, config.height) * (canvasHeight - 50);
const extra = entity.views[view].image.extra;
const bottom = entity.views[view].image.bottom;
@@ -206,7 +206,7 @@ function updateEntityElement(entity, element) {
if (entity.views[view].rename)
element.querySelector(".entity-name").innerText = entity.name == "" ? "" : entity.views[view].name;
else
element.querySelector(".entity-name").innerText = entity.name;
element.querySelector(".entity-name").innerText = entity.name;

const bottomName = document.querySelector("#bottom-name-" + element.dataset.key);

@@ -238,7 +238,7 @@ function updateSizes(dirtyOnly = false) {
} else {
return e1[1].views[e1[1].view].height.value - e2[1].views[e2[1].view].height.value
}
});

let zIndex = ordered.length;
@@ -256,7 +256,7 @@ function updateSizes(dirtyOnly = false) {

}

function drawScale(ifDirty=false) {
function drawScale(ifDirty = false) {
if (ifDirty && !worldSizeDirty)
return;
function drawTicks(/** @type {CanvasRenderingContext2D} */ ctx, pixelsPer, heightPer) {
@@ -538,7 +538,7 @@ function deselect() {
clearViewList();
clearEntityOptions();
clearViewOptions();
document.querySelector("#delete-entity").disabled = true;

document.querySelector("#grow").disabled = true;
@@ -554,13 +554,13 @@ function select(target) {
document.getElementById("options-selected-entity-" + target.dataset.key).selected = "selected";

selected.classList.add("selected");
displayAttribution(selectedEntity.views[selectedEntity.view].image.source);

configViewList(selectedEntity, selectedEntity.view);
configEntityOptions(selectedEntity, selectedEntity.view);
configViewOptions(selectedEntity, selectedEntity.view);
document.querySelector("#delete-entity").disabled = false;

document.querySelector("#grow").disabled = false;
@@ -605,7 +605,7 @@ function updateWorldOptions(entity, view) {

function configEntityOptions(entity, view) {
const holder = document.querySelector("#options-entity");
document.querySelector("#entity-category-header").style.display = "block";
document.querySelector("#entity-category").style.display = "block";

@@ -687,10 +687,10 @@ function configEntityOptions(entity, view) {
entity.dirty = true;
updateEntityOptions(entity, entity.view);
updateViewOptions(entity, entity.view);
if (!checkFitWorld()){
if (!checkFitWorld()) {
updateSizes(true);
}
});

defaultHolder.appendChild(button);
@@ -722,7 +722,7 @@ function clearEntityOptions() {

function configViewOptions(entity, view) {
const holder = document.querySelector("#options-view");
document.querySelector("#view-category-header").style.display = "block";
document.querySelector("#view-category").style.display = "block";

@@ -778,7 +778,7 @@ function configViewOptions(entity, view) {

select.setAttribute("oldUnit", select.value);

// TODO does this ever cause a change in the world?
// TODO does this ever cause a change in the world?
select.addEventListener("input", e => {
const value = input.value == 0 ? 1 : input.value;
const oldUnit = select.getAttribute("oldUnit");
@@ -809,7 +809,7 @@ function updateViewOptions(entity, view, changed) {
if (key != changed) {
const input = document.querySelector("#options-view-" + key + "-input");
const select = document.querySelector("#options-view-" + key + "-select");
const currentUnit = select.value;
const convertedAmount = entity.views[view][key].toNumber(currentUnit);
setNumericInput(input, convertedAmount);
@@ -818,7 +818,7 @@ function updateViewOptions(entity, view, changed) {
});
}

function setNumericInput(input, value, round=3) {
function setNumericInput(input, value, round = 3) {
input.value = math.round(value, round);
}

@@ -1045,9 +1045,9 @@ function checkEntity(entity) {
});
}

function displayEntity(entity, view, x, y, selectEntity=false, refresh=false) {
function displayEntity(entity, view, x, y, selectEntity = false, refresh = false) {
checkEntity(entity);
const box = document.createElement("div");
box.classList.add("entity-box");

@@ -1056,7 +1056,7 @@ function displayEntity(entity, view, x, y, selectEntity=false, refresh=false) {
img.addEventListener("dragstart", e => {
e.preventDefault();
});
const nameTag = document.createElement("div");
nameTag.classList.add("entity-name");
nameTag.innerText = entity.name;
@@ -1093,7 +1093,7 @@ function displayEntity(entity, view, x, y, selectEntity=false, refresh=false) {
box.id = "entity-" + entityIndex;
box.dataset.key = entityIndex;
entity.view = view;
entity.priority = 0;
entities[entityIndex] = entity;
entity.index = entityIndex;
@@ -1118,7 +1118,7 @@ function displayEntity(entity, view, x, y, selectEntity=false, refresh=false) {
topName.addEventListener("click", () => select(box));

world.appendChild(topName);
const entityOption = document.createElement("option");
entityOption.id = "options-selected-entity-" + entityIndex;
entityOption.value = entityIndex;
@@ -1154,17 +1154,17 @@ window.onfocus = function () {
function toggleFullScreen() {
var doc = window.document;
var docEl = doc.documentElement;
var requestFullScreen = docEl.requestFullscreen || docEl.mozRequestFullScreen || docEl.webkitRequestFullScreen || docEl.msRequestFullscreen;
var cancelFullScreen = doc.exitFullscreen || doc.mozCancelFullScreen || doc.webkitExitFullscreen || doc.msExitFullscreen;
if(!doc.fullscreenElement && !doc.mozFullScreenElement && !doc.webkitFullscreenElement && !doc.msFullscreenElement) {
requestFullScreen.call(docEl);
if (!doc.fullscreenElement && !doc.mozFullScreenElement && !doc.webkitFullscreenElement && !doc.msFullscreenElement) {
requestFullScreen.call(docEl);
}
else {
cancelFullScreen.call(doc);
cancelFullScreen.call(doc);
}
}
}

function handleResize() {
const oldCanvasWidth = canvasWidth;
@@ -1173,7 +1173,7 @@ function handleResize() {
canvasHeight = document.querySelector("#display").clientHeight - 50;

const change = oldCanvasWidth / canvasWidth;
doHorizReposition(change);

updateSizes();
@@ -1262,7 +1262,7 @@ function prepareMenu() {
button.classList.add("menu-button");
const icon = document.createElement("i");
icon.classList.add(...entry.icon.split(" "));
if (entry.rotates) {
icon.classList.add("rotate-backward", "transitions");
}
@@ -1318,7 +1318,7 @@ function setHelpDate() {

function doScroll() {
document.querySelectorAll(".entity-box").forEach(element => {
element.dataset.x = parseFloat(element.dataset.x) + scrollDirection/180;
element.dataset.x = parseFloat(element.dataset.x) + scrollDirection / 180;
});
updateSizes();
scrollDirection *= 1.05;
@@ -1335,7 +1335,7 @@ function doSize() {
if (selected) {
const entity = entities[selected.dataset.key];
const oldHeight = entity.views[entity.view].height;
entity.views[entity.view].height = math.multiply(oldHeight, 1 + sizeDirection/20);
entity.views[entity.view].height = math.multiply(oldHeight, 1 + sizeDirection / 20);
entity.dirty = true;
updateEntityOptions(entity, entity.view);
updateViewOptions(entity, entity.view);
@@ -1347,7 +1347,7 @@ function doSize() {

console.log(ownHeight, worldHeight)
if (ownHeight > worldHeight) {
setWorldHeight(config.height, entity.views[entity.view].height)
setWorldHeight(config.height, entity.views[entity.view].height)
} else if (ownHeight * 10 < worldHeight) {
setWorldHeight(config.height, math.multiply(entity.views[entity.view].height, 10));
}
@@ -1379,7 +1379,7 @@ document.addEventListener("DOMContentLoaded", () => {
document.addEventListener("click", e => {
document.querySelector("#popout-menu").classList.remove("visible");
});
window.addEventListener("unload", () => saveScene("autosave"));
document.querySelector("#options-selected-entity").addEventListener("input", e => {
if (e.target.value == "none") {
@@ -1387,7 +1387,7 @@ document.addEventListener("DOMContentLoaded", () => {
} else {
select(document.querySelector("#entity-" + e.target.value));
}
});

document.querySelector("#menu-toggle-sidebar").addEventListener("click", e => {
@@ -1522,7 +1522,7 @@ document.addEventListener("DOMContentLoaded", () => {
if (param === null) {
scenes["Default"]();
}
else {
try {
const data = JSON.parse(b64DecodeUnicode(param));
@@ -1546,7 +1546,7 @@ document.addEventListener("DOMContentLoaded", () => {

if (shiftHeld) {
if (selected) {
const dir = e.deltaY > 0 ? 10/11 : 11/10;
const dir = e.deltaY > 0 ? 10 / 11 : 11 / 10;
const entity = entities[selected.dataset.key];
entity.views[entity.view].height = math.multiply(entity.views[entity.view].height, dir);
entity.dirty = true;
@@ -1561,7 +1561,7 @@ document.addEventListener("DOMContentLoaded", () => {
}

} else {
const dir = e.deltaY < 0 ? 10/11 : 11/10;
const dir = e.deltaY < 0 ? 10 / 11 : 11 / 10;
setWorldHeight(config.height, math.multiply(config.height, dir));
updateWorldOptions();
}
@@ -1587,7 +1587,7 @@ document.addEventListener("DOMContentLoaded", () => {
document.querySelector("#entity-view").addEventListener("input", e => {
const entity = entities[selected.dataset.key];
entity.view = e.target.value;
const image = entities[selected.dataset.key].views[e.target.value].image;
selected.querySelector(".entity-image").src = image.source;

@@ -1608,7 +1608,7 @@ document.addEventListener("DOMContentLoaded", () => {
document.querySelector("#menu-clear").addEventListener("click", e => {
removeAllEntities();
});
document.querySelector("#delete-entity").disabled = true;
document.querySelector("#delete-entity").addEventListener("click", e => {
if (selected) {
@@ -1636,28 +1636,28 @@ document.addEventListener("DOMContentLoaded", () => {
document.querySelector("#scroll-left").addEventListener("mousedown", e => {
scrollDirection = 1;
clearInterval(scrollHandle);
scrollHandle = setInterval(doScroll, 1000/20);
scrollHandle = setInterval(doScroll, 1000 / 20);
e.stopPropagation();
});

document.querySelector("#scroll-right").addEventListener("mousedown", e => {
scrollDirection = -1;
clearInterval(scrollHandle);
scrollHandle = setInterval(doScroll, 1000/20);
scrollHandle = setInterval(doScroll, 1000 / 20);
e.stopPropagation();
});

document.querySelector("#scroll-left").addEventListener("touchstart", e => {
scrollDirection = 1;
clearInterval(scrollHandle);
scrollHandle = setInterval(doScroll, 1000/20);
scrollHandle = setInterval(doScroll, 1000 / 20);
e.stopPropagation();
});

document.querySelector("#scroll-right").addEventListener("touchstart", e => {
scrollDirection = -1;
clearInterval(scrollHandle);
scrollHandle = setInterval(doScroll, 1000/20);
scrollHandle = setInterval(doScroll, 1000 / 20);
e.stopPropagation();
});

@@ -1674,28 +1674,28 @@ document.addEventListener("DOMContentLoaded", () => {
document.querySelector("#zoom-in").addEventListener("mousedown", e => {
zoomDirection = -1;
clearInterval(zoomHandle);
zoomHandle = setInterval(doZoom, 1000/20);
zoomHandle = setInterval(doZoom, 1000 / 20);
e.stopPropagation();
});

document.querySelector("#zoom-out").addEventListener("mousedown", e => {
zoomDirection = 1;
clearInterval(zoomHandle);
zoomHandle = setInterval(doZoom, 1000/20);
zoomHandle = setInterval(doZoom, 1000 / 20);
e.stopPropagation();
});

document.querySelector("#zoom-in").addEventListener("touchstart", e => {
zoomDirection = -1;
clearInterval(zoomHandle);
zoomHandle = setInterval(doZoom, 1000/20);
zoomHandle = setInterval(doZoom, 1000 / 20);
e.stopPropagation();
});

document.querySelector("#zoom-out").addEventListener("touchstart", e => {
zoomDirection = 1;
clearInterval(zoomHandle);
zoomHandle = setInterval(doZoom, 1000/20);
zoomHandle = setInterval(doZoom, 1000 / 20);
e.stopPropagation();
});

@@ -1712,28 +1712,28 @@ document.addEventListener("DOMContentLoaded", () => {
document.querySelector("#shrink").addEventListener("mousedown", e => {
sizeDirection = -1;
clearInterval(sizeHandle);
sizeHandle = setInterval(doSize, 1000/20);
sizeHandle = setInterval(doSize, 1000 / 20);
e.stopPropagation();
});

document.querySelector("#grow").addEventListener("mousedown", e => {
sizeDirection = 1;
clearInterval(sizeHandle);
sizeHandle = setInterval(doSize, 1000/20);
sizeHandle = setInterval(doSize, 1000 / 20);
e.stopPropagation();
});

document.querySelector("#shrink").addEventListener("touchstart", e => {
sizeDirection = -1;
clearInterval(sizeHandle);
sizeHandle = setInterval(doSize, 1000/20);
sizeHandle = setInterval(doSize, 1000 / 20);
e.stopPropagation();
});

document.querySelector("#grow").addEventListener("touchstart", e => {
sizeDirection = 1;
clearInterval(sizeHandle);
sizeHandle = setInterval(doSize, 1000/20);
sizeHandle = setInterval(doSize, 1000 / 20);
e.stopPropagation();
});

@@ -1889,7 +1889,7 @@ function prepareEntities() {
button.id = "create-entity-" + category + "-button";

button.innerHTML = "<i class=\"far fa-plus-square\"></i>";
button.addEventListener("click", e => {
const newEntity = entityList[select.value].constructor()
displayEntity(newEntity, newEntity.defaultView, 0.5, 1, true, true);
@@ -1911,7 +1911,7 @@ function prepareEntities() {
});

console.log("Loaded " + Object.keys(availableEntitiesByName).length + " entities");
categorySelect.addEventListener("input", e => {
const oldSelect = document.querySelector("select.category-visible");
oldSelect.classList.remove("category-visible");
@@ -1987,7 +1987,7 @@ const fitModes = {
}
}

function fitWorld(manual=false, factor=1.1) {
function fitWorld(manual = false, factor = 1.1) {
const fitMode = fitModes[config.autoFitMode]
let max = fitMode.start

@@ -2045,7 +2045,7 @@ function setWorldHeight(oldHeight, newHeight) {
updateSizes();
}

function loadScene(name="default") {
function loadScene(name = "default") {
try {
const data = JSON.parse(localStorage.getItem("macrovision-save-" + name));
if (data === null) {
@@ -2060,7 +2060,7 @@ function loadScene(name="default") {
}
}

function saveScene(name="default") {
function saveScene(name = "default") {
try {
const string = JSON.stringify(exportScene());
localStorage.setItem("macrovision-save-" + name, string);
@@ -2070,10 +2070,10 @@ function saveScene(name="default") {
}
}

function deleteScene(name="default") {
function deleteScene(name = "default") {
try {
localStorage.removeItem("macrovision-save-" + name)
} catch(err) {
} catch (err) {
console.error(err);
}
}
@@ -2117,12 +2117,12 @@ function b64EncodeUnicode(str) {
return btoa(encodeURIComponent(str).replace(/%([0-9A-F]{2})/g,
function toSolidBytes(match, p1) {
return String.fromCharCode('0x' + p1);
}));
}));
}

function b64DecodeUnicode(str) {
// Going backwards: from bytestream, to percent-encoding, to original string.
return decodeURIComponent(atob(str).split('').map(function(c) {
return decodeURIComponent(atob(str).split('').map(function (c) {
return '%' + ('00' + c.charCodeAt(0).toString(16)).slice(-2);
}).join(''));
}


+ 43
- 43
media/attribution.js Dosyayı Görüntüle

@@ -1152,38 +1152,38 @@ const attributionData = {
{
prefix: "./media/cities/",
files: [
{ name: "city_atlanta.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_boston.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_calgary.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_chicago.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_columbus.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_dallas.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_detroit.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_edmonton.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_guadalajara.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_houston.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_indianapolis.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_jacksonville.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_kansas-city.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_los-angeles.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_mexico-city.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_mississauga.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_montreal.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_new-york-city.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_ottawa.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_philadelphia.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_phoenix.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_puebla.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_san-antonio.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_san-diego.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_san-francisco.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_seattle.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_st-louis.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_tijuana.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_toronto.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_vancouver.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_washington.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_winnipeg.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html"},
{ name: "city_atlanta.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_boston.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_calgary.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_chicago.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_columbus.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_dallas.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_detroit.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_edmonton.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_guadalajara.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_houston.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_indianapolis.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_jacksonville.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_kansas-city.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_los-angeles.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_mexico-city.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_mississauga.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_montreal.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_new-york-city.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_ottawa.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_philadelphia.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_phoenix.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_puebla.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_san-antonio.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_san-diego.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_san-francisco.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_seattle.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_st-louis.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_tijuana.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_toronto.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_vancouver.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_washington.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
{ name: "city_winnipeg.svg", source: "https://all-free-download.com/free-vector/download/big-cities-silhouette-set-vector_548864.html" },
],
authors: [
"freedesignfile"
@@ -2429,7 +2429,7 @@ const attributionData = {
{ name: "front.svg", source: "https://www.furaffinity.net/view/35993069/" },
{ name: "back.svg", source: "https://www.furaffinity.net/view/35993069/" },
{ name: "foot.svg", source: "https://www.furaffinity.net/view/35993069/" },
],
authors: [
"victni"
@@ -8396,8 +8396,8 @@ const attributionData = {
{
prefix: "./media/characters/gabira/",
files: [
{ name: "front.svg", source: "https://www.furaffinity.net/view/22244723/" },
{ name: "back.svg", source: "https://www.furaffinity.net/view/22244723/" },
{ name: "front.svg", source: "https://www.furaffinity.net/view/22244723/" },
{ name: "back.svg", source: "https://www.furaffinity.net/view/22244723/" },
],
authors: [
"gabira"
@@ -11456,7 +11456,7 @@ const attributionData = {
"evilwithin": {
"name": "evilwithin",
"url": "https://www.furaffinity.net/user/evilwithin/",
},
},
"dragondruid": {
"name": "dragondruid",
"url": "https://www.furaffinity.net/user/dragondruid/",
@@ -12388,7 +12388,7 @@ function prepareAttribution() {
}
})
}
});
}

@@ -12399,7 +12399,7 @@ function authorsOf(file) {
const found = attribution.prefixes[Object.keys(attribution.prefixes).find(path => {
return (file.indexOf(path) == 0);
})];

if (found === undefined) {
return undefined;
@@ -12421,7 +12421,7 @@ function authorsOfFull(file) {
const found = attribution.prefixes[Object.keys(attribution.prefixes).find(path => {
return (file.indexOf(path) == 0);
})];

if (found === undefined || found.authors === undefined) {
return undefined;
@@ -12441,7 +12441,7 @@ function ownersOf(file) {
const found = attribution.prefixes[Object.keys(attribution.prefixes).find(path => {
return (file.indexOf(path) == 0);
})];

if (found === undefined) {
return undefined;
@@ -12468,12 +12468,12 @@ function ownersOfFull(file) {
const found = attribution.prefixes[Object.keys(attribution.prefixes).find(path => {
return (file.indexOf(path) == 0);
})];

if (found === undefined) {
return undefined;
} else if (found.owners === undefined) {
return [];
return [];
} else {
found.owners.forEach(owner => {
result.push(attributionData.people[owner]);
@@ -12490,7 +12490,7 @@ function sourceOf(file) {
const found = attribution.prefixes[Object.keys(attribution.prefixes).find(path => {
return (file.indexOf(path) == 0);
})];

if (found === undefined) {
return undefined;


+ 2
- 2
presets/buildings.js Dosyayı Görüntüle

@@ -153,7 +153,7 @@ function makeBuildings() {
)

results.push(
makeHeight (
makeHeight(
[
["residential", 12, "feet"],
["freeway", 50, "feet"]
@@ -165,7 +165,7 @@ function makeBuildings() {
)

results.push(
makeHeight (
makeHeight(
[
["manhattan", 141.8, "meters"],
["houston", 93, "meters"]


+ 156
- 156
presets/characters.js Dosyayı Görüntüle

@@ -432,8 +432,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/elijah/front.svg",
extra: 639/626,
bottom: 58.7/697.8
extra: 639 / 626,
bottom: 58.7 / 697.8
}
},
side: {
@@ -442,8 +442,8 @@ characterMakers.push(() => makeCharacter(
name: "Side",
image: {
source: "./media/characters/elijah/side.svg",
extra: 1840/1795,
bottom: 106/1943
extra: 1840 / 1795,
bottom: 106 / 1943
}
},
back: {
@@ -452,8 +452,8 @@ characterMakers.push(() => makeCharacter(
name: "Back",
image: {
source: "./media/characters/elijah/back.svg",
extra: 661.2/639.5,
bottom: 21.2/682.5
extra: 661.2 / 639.5,
bottom: 21.2 / 682.5
}
},
foot: {
@@ -613,8 +613,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/flamm/front.svg",
extra: 1794/1677,
bottom: 31.7/1828.5
extra: 1794 / 1677,
bottom: 31.7 / 1828.5
}
},
},
@@ -691,8 +691,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/fory/front.svg",
extra: 2862/2674,
bottom: 180/3043.8
extra: 2862 / 2674,
bottom: 180 / 3043.8
}
},
back: {
@@ -701,8 +701,8 @@ characterMakers.push(() => makeCharacter(
name: "Back",
image: {
source: "./media/characters/fory/back.svg",
extra: 2962/2791,
bottom: 106/3071.8
extra: 2962 / 2791,
bottom: 106 / 3071.8
}
},
foot: {
@@ -1001,14 +1001,14 @@ characterMakers.push(() => makeCharacter(
characterMakers.push(() => makeCharacter(
{ name: "Talan" },
{
angled: {
height: math.unit(4, "meter"),
weight: math.unit(150, "kg"),
name: "Angled",
image: {
source: "./media/characters/talan/angled-sfw.svg",
bottom: 29/3734
bottom: 29 / 3734
}
},
angledNsfw: {
@@ -1017,7 +1017,7 @@ characterMakers.push(() => makeCharacter(
name: "Angled (NSFW)",
image: {
source: "./media/characters/talan/angled-nsfw.svg",
bottom: 29/3734
bottom: 29 / 3734
}
},
frontNsfw: {
@@ -1026,7 +1026,7 @@ characterMakers.push(() => makeCharacter(
name: "Front (NSFW)",
image: {
source: "./media/characters/talan/front-nsfw.svg",
bottom: 29/3734
bottom: 29 / 3734
}
},
sideNsfw: {
@@ -1035,7 +1035,7 @@ characterMakers.push(() => makeCharacter(
name: "Side (NSFW)",
image: {
source: "./media/characters/talan/side-nsfw.svg",
bottom: 29/3734
bottom: 29 / 3734
}
},
back: {
@@ -1254,8 +1254,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/elbial/front.svg",
extra: 1643/1556,
bottom: 60.2/1696
extra: 1643 / 1556,
bottom: 60.2 / 1696
}
},
side: {
@@ -1264,8 +1264,8 @@ characterMakers.push(() => makeCharacter(
name: "Side",
image: {
source: "./media/characters/elbial/side.svg",
extra: 1630/1565,
bottom: 71.5/1697
extra: 1630 / 1565,
bottom: 71.5 / 1697
}
},
back: {
@@ -1274,8 +1274,8 @@ characterMakers.push(() => makeCharacter(
name: "Back",
image: {
source: "./media/characters/elbial/back.svg",
extra: 1668/1595,
bottom: 5.6/1672
extra: 1668 / 1595,
bottom: 5.6 / 1672
}
},
frontDressed: {
@@ -1284,12 +1284,12 @@ characterMakers.push(() => makeCharacter(
name: "Front (Dressed)",
image: {
source: "./media/characters/elbial/front-dressed.svg",
extra: 1653/1584,
bottom: 57/1708
extra: 1653 / 1584,
bottom: 57 / 1708
}
},
genitals: {
height: math.unit(2/3.367, "meter"),
height: math.unit(2 / 3.367, "meter"),
name: "Genitals",
image: {
source: "./media/characters/elbial/genitals.svg"
@@ -2775,7 +2775,7 @@ characterMakers.push(() => makeCharacter(
image: {
source: "./media/characters/tobias/side.svg",
extra: 1474 / 1096,
bottom: 38.9/1513.1235
bottom: 38.9 / 1513.1235
}
},
},
@@ -9590,7 +9590,7 @@ characterMakers.push(() => makeCharacter(
}
},
elemental: {
height: math.unit(4 + 2/12, "feet"),
height: math.unit(4 + 2 / 12, "feet"),
weight: math.unit(150, "lb"),
name: "Elemental",
image: {
@@ -19003,8 +19003,8 @@ characterMakers.push(() => makeCharacter(
name: "Side",
image: {
source: "./media/characters/fixerdragon/side.svg",
extra: (1293.0514-116.03)/1106.86,
bottom: 116.03/1293.0514
extra: (1293.0514 - 116.03) / 1106.86,
bottom: 116.03 / 1293.0514
}
},
},
@@ -19046,7 +19046,7 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/kite/front.svg",
extra: 2796/2659,
extra: 2796 / 2659,
bottom: 0.002
}
},
@@ -19072,30 +19072,30 @@ characterMakers.push(() => makeCharacter(
{ name: "Poojawa Vynar" },
{
front: {
height: math.unit(5 + 10/12, "feet"),
height: math.unit(5 + 10 / 12, "feet"),
weight: math.unit(150, "lb"),
name: "Front",
image: {
source: "./media/characters/poojawa-vynar/front.svg",
extra: (1506.1547-55) / 1356.6,
bottom: 55/1506.1547
extra: (1506.1547 - 55) / 1356.6,
bottom: 55 / 1506.1547
}
},
frontTailless: {
height: math.unit(5 + 10/12, "feet"),
height: math.unit(5 + 10 / 12, "feet"),
weight: math.unit(150, "lb"),
name: "Front (Tailless)",
image: {
source: "./media/characters/poojawa-vynar/front-tailless.svg",
extra: (1506.1547-55) / 1356.6,
bottom: 55/1506.1547
extra: (1506.1547 - 55) / 1356.6,
bottom: 55 / 1506.1547
}
},
},
[
{
name: "Normal",
height: math.unit(5 + 10/12, "feet"),
height: math.unit(5 + 10 / 12, "feet"),
default: true
},
]
@@ -19110,7 +19110,7 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/violette/front.svg",
extra: 1227/1180,
extra: 1227 / 1180,
bottom: 0.005
}
},
@@ -19120,7 +19120,7 @@ characterMakers.push(() => makeCharacter(
name: "Back",
image: {
source: "./media/characters/violette/back.svg",
extra: 1227/1180,
extra: 1227 / 1180,
bottom: 0.005
}
},
@@ -19143,7 +19143,7 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/alessandra/front.svg",
extra: 960/912,
extra: 960 / 912,
bottom: 0.06
}
},
@@ -19170,8 +19170,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/person/front.svg",
extra: 3087/2945,
bottom: 91/3181
extra: 3087 / 2945,
bottom: 91 / 3181
}
},
},
@@ -19205,8 +19205,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/ty/front.svg",
extra: 1038/960,
bottom: 31.156/1068
extra: 1038 / 960,
bottom: 31.156 / 1068
}
},
back: {
@@ -19215,8 +19215,8 @@ characterMakers.push(() => makeCharacter(
name: "Back",
image: {
source: "./media/characters/ty/back.svg",
extra: 1044/966,
bottom: 7.48/1049
extra: 1044 / 966,
bottom: 7.48 / 1049
}
},
},
@@ -19233,20 +19233,20 @@ characterMakers.push(() => makeCharacter(
{ name: "Rocky" },
{
front: {
height: math.unit(5 + 4/12, "feet"),
height: math.unit(5 + 4 / 12, "feet"),
weight: math.unit(115, "lb"),
name: "Front",
image: {
source: "./media/characters/rocky/front.svg",
extra: 1012/975,
bottom: 54/1066
extra: 1012 / 975,
bottom: 54 / 1066
}
},
},
[
{
name: "Normal",
height: math.unit(5 + 4/12, "feet"),
height: math.unit(5 + 4 / 12, "feet"),
default: true
},
]
@@ -19261,8 +19261,8 @@ characterMakers.push(() => makeCharacter(
name: "Upright",
image: {
source: "./media/characters/ruin/upright.svg",
extra: 668/661,
bottom: 42/799.8396
extra: 668 / 661,
bottom: 42 / 799.8396
}
},
},
@@ -19283,8 +19283,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/robin/front.svg",
extra: 862/799,
bottom: 42.4/914.8856
extra: 862 / 799,
bottom: 42.4 / 914.8856
}
},
},
@@ -19306,8 +19306,8 @@ characterMakers.push(() => makeCharacter(
name: "Side",
image: {
source: "./media/characters/saian/side.svg",
extra: 566/356,
bottom: 79.7/643
extra: 566 / 356,
bottom: 79.7 / 643
}
},
maw: {
@@ -19336,8 +19336,8 @@ characterMakers.push(() => makeCharacter(
name: "Side",
image: {
source: "./media/characters/equus-silvermane/side.svg",
extra: 2176/2050,
bottom: 65.7/2245
extra: 2176 / 2050,
bottom: 65.7 / 2245
}
},
front: {
@@ -19346,8 +19346,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/equus-silvermane/front.svg",
extra: 4633/4400,
bottom: 71.3/4706.915
extra: 4633 / 4400,
bottom: 71.3 / 4706.915
}
},
sideStepping: {
@@ -19356,8 +19356,8 @@ characterMakers.push(() => makeCharacter(
name: "Side (Stepping)",
image: {
source: "./media/characters/equus-silvermane/side-stepping.svg",
extra: 1968/1860,
bottom: 16.4/1989
extra: 1968 / 1860,
bottom: 16.4 / 1989
}
},
},
@@ -19395,8 +19395,8 @@ characterMakers.push(() => makeCharacter(
name: "Side",
image: {
source: "./media/characters/windar/side.svg",
extra: 1491/1248,
bottom: 82.56/1568
extra: 1491 / 1248,
bottom: 82.56 / 1568
}
},
},
@@ -19418,8 +19418,8 @@ characterMakers.push(() => makeCharacter(
name: "Side",
image: {
source: "./media/characters/melody/side.svg",
extra: 1097/944,
bottom: 11.8/1109
extra: 1097 / 944,
bottom: 11.8 / 1109
}
},
sideOutfit: {
@@ -19428,8 +19428,8 @@ characterMakers.push(() => makeCharacter(
name: "Side (Outfit)",
image: {
source: "./media/characters/melody/side-outfit.svg",
extra: 1097/944,
bottom: 11.8/1109
extra: 1097 / 944,
bottom: 11.8 / 1109
}
},
},
@@ -19451,8 +19451,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/windera/front.svg",
extra: 3180/2845,
bottom: 178/3365
extra: 3180 / 2845,
bottom: 178 / 3365
}
},
},
@@ -19474,8 +19474,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/sonear/front.svg",
extra: 1041.1/964.9,
bottom: 53.7/1096.6
extra: 1041.1 / 964.9,
bottom: 53.7 / 1096.6
}
},
},
@@ -19518,8 +19518,8 @@ characterMakers.push(() => makeCharacter(
name: "Side",
image: {
source: "./media/characters/ereus/side.svg",
extra: 1157/959,
bottom: 153/1312.5
extra: 1157 / 959,
bottom: 153 / 1312.5
}
},
},
@@ -19541,8 +19541,8 @@ characterMakers.push(() => makeCharacter(
name: "Side",
image: {
source: "./media/characters/e-ter/side.svg",
extra: 1550/1248,
bottom: 146/1694
extra: 1550 / 1248,
bottom: 146 / 1694
}
},
},
@@ -19585,8 +19585,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/anders/front.svg",
extra: 570/539,
bottom: 14.7/586.7
extra: 570 / 539,
bottom: 14.7 / 586.7
}
},
},
@@ -19611,17 +19611,17 @@ characterMakers.push(() => makeCharacter(
{ name: "Reban" },
{
front: {
height: math.unit(7 + 2/12, "feet"),
height: math.unit(7 + 2 / 12, "feet"),
weight: math.unit(300, "lb"),
name: "Front",
image: {
source: "./media/characters/reban/front.svg",
extra: 516/487,
bottom: 42.82/558.356
extra: 516 / 487,
bottom: 42.82 / 558.356
}
},
dick: {
height: math.unit(7/5, "feet"),
height: math.unit(7 / 5, "feet"),
name: "Dick",
image: {
source: "./media/characters/reban/dick.svg"
@@ -19631,7 +19631,7 @@ characterMakers.push(() => makeCharacter(
[
{
name: "Natural Height",
height: math.unit(7 + 2/12, "feet")
height: math.unit(7 + 2 / 12, "feet")
},
{
name: "Macro",
@@ -19655,7 +19655,7 @@ characterMakers.push(() => makeCharacter(
image: {
source: "./media/characters/terrance-keayes/front.svg",
extra: 1.005,
bottom: 151/1615
bottom: 151 / 1615
}
},
side: {
@@ -19665,7 +19665,7 @@ characterMakers.push(() => makeCharacter(
image: {
source: "./media/characters/terrance-keayes/side.svg",
extra: 1.005,
bottom: 129.4/1544
bottom: 129.4 / 1544
}
},
back: {
@@ -19675,11 +19675,11 @@ characterMakers.push(() => makeCharacter(
image: {
source: "./media/characters/terrance-keayes/back.svg",
extra: 1.005,
bottom: 58.4/1557.3
bottom: 58.4 / 1557.3
}
},
dick: {
height: math.unit(6*0.208, "feet"),
height: math.unit(6 * 0.208, "feet"),
name: "Dick",
image: {
source: "./media/characters/terrance-keayes/dick.svg"
@@ -19704,8 +19704,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/ofelia/front.svg",
extra: 546/541,
bottom: 39/583
extra: 546 / 541,
bottom: 39 / 583
}
},
back: {
@@ -19714,8 +19714,8 @@ characterMakers.push(() => makeCharacter(
name: "Back",
image: {
source: "./media/characters/ofelia/back.svg",
extra: 564/559.5,
bottom: 8.69/573.02
extra: 564 / 559.5,
bottom: 8.69 / 573.02
}
},
maw: {
@@ -19751,8 +19751,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/samuel/front.svg",
extra: 265/258,
bottom: 2/266.1566
extra: 265 / 258,
bottom: 2 / 266.1566
}
},
},
@@ -19778,12 +19778,12 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/beishir-kiel/front.svg",
extra: 569/547,
bottom: 41.9/609
extra: 569 / 547,
bottom: 41.9 / 609
}
},
maw: {
height: math.unit(6*0.202, "feet"),
height: math.unit(6 * 0.202, "feet"),
name: "Maw",
image: {
source: "./media/characters/beishir-kiel/maw.svg"
@@ -19803,33 +19803,33 @@ characterMakers.push(() => makeCharacter(
{ name: "Logan Grey" },
{
front: {
height: math.unit(5 + 8/12, "feet"),
height: math.unit(5 + 8 / 12, "feet"),
weight: math.unit(120, "lb"),
name: "Front",
image: {
source: "./media/characters/logan-grey/front.svg",
extra: 2539/2393,
bottom: 97.6/2636.37
extra: 2539 / 2393,
bottom: 97.6 / 2636.37
}
},
frontAlt: {
height: math.unit(5 + 8/12, "feet"),
height: math.unit(5 + 8 / 12, "feet"),
weight: math.unit(120, "lb"),
name: "Front (Alt)",
image: {
source: "./media/characters/logan-grey/front-alt.svg",
extra: 958/893,
bottom: 15/970.768
extra: 958 / 893,
bottom: 15 / 970.768
}
},
back: {
height: math.unit(5 + 8/12, "feet"),
height: math.unit(5 + 8 / 12, "feet"),
weight: math.unit(120, "lb"),
name: "Back",
image: {
source: "./media/characters/logan-grey/back.svg",
extra: 958/893,
bottom: 2.1881/970.9788
extra: 958 / 893,
bottom: 2.1881 / 970.9788
}
},
dick: {
@@ -19843,7 +19843,7 @@ characterMakers.push(() => makeCharacter(
[
{
name: "Normal",
height: math.unit(5 + 8/12, "feet")
height: math.unit(5 + 8 / 12, "feet")
},
{
name: "The 500 Foot Femboy",
@@ -19861,20 +19861,20 @@ characterMakers.push(() => makeCharacter(
{ name: "Draganta" },
{
front: {
height: math.unit(8 + 2/12, "feet"),
height: math.unit(8 + 2 / 12, "feet"),
weight: math.unit(275, "lb"),
name: "Front",
image: {
source: "./media/characters/draganta/front.svg",
extra: 1177/1135,
bottom: 33.46/1212.1
extra: 1177 / 1135,
bottom: 33.46 / 1212.1
}
},
},
[
{
name: "Normal",
height: math.unit(8 + 6/12, "feet"),
height: math.unit(8 + 6 / 12, "feet"),
default: true
},
{
@@ -19897,8 +19897,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/voski/front.svg",
extra: 2076.22/2022.4,
bottom: 102.7/2177.3866
extra: 2076.22 / 2022.4,
bottom: 102.7 / 2177.3866
}
},
back: {
@@ -19907,8 +19907,8 @@ characterMakers.push(() => makeCharacter(
name: "Back",
image: {
source: "./media/characters/voski/back.svg",
extra: 2104/2051,
bottom: 10.45/2113.63
extra: 2104 / 2051,
bottom: 10.45 / 2113.63
}
},
},
@@ -19954,8 +19954,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/icowom-lee/front.svg",
extra: 3076/2933,
bottom: 51.4/3125.1889
extra: 3076 / 2933,
bottom: 51.4 / 3125.1889
}
},
},
@@ -19982,8 +19982,8 @@ characterMakers.push(() => makeCharacter(
name: "Front",
image: {
source: "./media/characters/shock-diamond/front.svg",
extra: 2204/2053,
bottom: 65/2239.47
extra: 2204 / 2053,
bottom: 65 / 2239.47
}
},
frontNude: {
@@ -19992,8 +19992,8 @@ characterMakers.push(() => makeCharacter(
name: "Front (Nude)",
image: {
source: "./media/characters/shock-diamond/front-nude.svg",
extra: 2514/2285,
bottom: 13/2527.56
extra: 2514 / 2285,
bottom: 13 / 2527.56
}
},
},
@@ -20014,43 +20014,43 @@ characterMakers.push(() => makeCharacter(
{ name: "Rory" },
{
front: {
height: math.unit(5 + 4/12, "feet"),
height: math.unit(5 + 4 / 12, "feet"),
weight: math.unit(120, "lb"),
name: "Front",
image: {
source: "./media/characters/rory/front.svg",
extra: 589/556,
bottom: 45.7/635.76
extra: 589 / 556,
bottom: 45.7 / 635.76
}
},
frontNude: {
height: math.unit(5 + 4/12, "feet"),
height: math.unit(5 + 4 / 12, "feet"),
weight: math.unit(120, "lb"),
name: "Front (Nude)",
image: {
source: "./media/characters/rory/front-nude.svg",
extra: 589/556,
bottom: 45.7/635.76
extra: 589 / 556,
bottom: 45.7 / 635.76
}
},
side: {
height: math.unit(5 + 4/12, "feet"),
height: math.unit(5 + 4 / 12, "feet"),
weight: math.unit(120, "lb"),
name: "Side",
image: {
source: "./media/characters/rory/side.svg",
extra: 597/564,
bottom: 55/653
extra: 597 / 564,
bottom: 55 / 653
}
},
back: {
height: math.unit(5 + 4/12, "feet"),
height: math.unit(5 + 4 / 12, "feet"),
weight: math.unit(120, "lb"),
name: "Back",
image: {
source: "./media/characters/rory/back.svg",
extra: 620/585,
bottom: 8.86/630.43
extra: 620 / 585,
bottom: 8.86 / 630.43
}
},
dick: {
@@ -20064,7 +20064,7 @@ characterMakers.push(() => makeCharacter(
[
{
name: "Normal",
height: math.unit(5 + 4/12, "feet"),
height: math.unit(5 + 4 / 12, "feet"),
default: true
},
{
@@ -20086,33 +20086,33 @@ characterMakers.push(() => makeCharacter(
{ name: "Sprisk" },
{
front: {
height: math.unit(5 + 9/12, "feet"),
height: math.unit(5 + 9 / 12, "feet"),
weight: math.unit(190, "lb"),
name: "Front",
image: {
source: "./media/characters/sprisk/front.svg",
extra: 1225/1180,
bottom: 42.7/1266.4
extra: 1225 / 1180,
bottom: 42.7 / 1266.4
}
},
frontNsfw: {
height: math.unit(5 + 9/12, "feet"),
height: math.unit(5 + 9 / 12, "feet"),
weight: math.unit(190, "lb"),
name: "Front (NSFW)",
image: {
source: "./media/characters/sprisk/front-nsfw.svg",
extra: 1225/1180,
bottom: 42.7/1266.4
extra: 1225 / 1180,
bottom: 42.7 / 1266.4
}
},
back: {
height: math.unit(5 + 9/12, "feet"),
height: math.unit(5 + 9 / 12, "feet"),
weight: math.unit(190, "lb"),
name: "Back",
image: {
source: "./media/characters/sprisk/back.svg",
extra: 1247/1200,
bottom: 5.6/1253.04
extra: 1247 / 1200,
bottom: 5.6 / 1253.04
}
},
},
@@ -20123,7 +20123,7 @@ characterMakers.push(() => makeCharacter(
},
{
name: "Normal",
height: math.unit(5 + 9/12, "feet"),
height: math.unit(5 + 9 / 12, "feet"),
default: true
},
{
@@ -20154,11 +20154,11 @@ characterMakers.push(() => makeCharacter(
name: "Side",
image: {
source: "./media/characters/bunsen/side.svg",
extra: 1644/358
extra: 1644 / 358
}
},
foot: {
height: math.unit(1.611*1644/358, "meter"),
height: math.unit(1.611 * 1644 / 358, "meter"),
name: "Foot",
image: {
source: "./media/characters/bunsen/foot.svg"
@@ -20182,20 +20182,20 @@ characterMakers.push(() => makeCharacter(
{ name: "Sesh" },
{
front: {
height: math.unit(4 + 11/12, "feet"),
height: math.unit(4 + 11 / 12, "feet"),
weight: math.unit(140, "lb"),
name: "Front",
image: {
source: "./media/characters/sesh/front.svg",
extra: 3420/3231,
bottom: 72/3949.5
extra: 3420 / 3231,
bottom: 72 / 3949.5
}
},
},
[
{
name: "Normal",
height: math.unit(4 + 11/12, "feet")
height: math.unit(4 + 11 / 12, "feet")
},
{
name: "Grown",
@@ -20232,10 +20232,10 @@ characterMakers.push(() => makeCharacter(
//characters

function makeCharacters() {
const results = [];
const results = [];

characterMakers.forEach(character => {
results.push(character());
});
return results;
}
characterMakers.forEach(character => {
results.push(character());
});
return results;
}

+ 1
- 1
presets/fiction.js Dosyayı Görüntüle

@@ -28,7 +28,7 @@ function makeFiction() {
)
});

results.sort((b1, b2) => {
e1 = b1.constructor();
e2 = b2.constructor();


+ 13
- 13
presets/food.js Dosyayı Görüntüle

@@ -7,13 +7,13 @@ function makeFood() {
"Human",
{
woman1: {
height: math.unit(5 + 7/12, "feet"),
height: math.unit(5 + 7 / 12, "feet"),
mass: math.unit(140, "lbs"),
image: { source: "./media/food/humans/woman-1.svg" },
name: "Woman 1"
},
man1: {
height: math.unit(5 + 11/12, "feet"),
height: math.unit(5 + 11 / 12, "feet"),
mass: math.unit(150, "lbs"),
image: { source: "./media/food/humans/man-1.svg" },
name: "Man 1"
@@ -82,10 +82,10 @@ function makeFood() {
["horse", 2.08, "meters", 550, "kg"],
["african-elephant", 3.2, "meters", 4000, "kg"]
],
"Animals",
"",
"food"
));
"Animals",
"",
"food"
));

results.push(
makeHeightWeight([
@@ -95,10 +95,10 @@ function makeFood() {
["tyrannosaurus", 5.2, "meters", 14e3, "kg"],
["velociraptor", 1.6, "meters", 15, "kg"]
],
"Dinosaurs",
"",
"food"
));
"Dinosaurs",
"",
"food"
));

results.push(makeHeight(
[
@@ -155,8 +155,8 @@ function makeFood() {

results.push(makeHeightWeight(
[
["m&m", 0.5262, "inches", 43/50, "g", "./media/objects/circle.svg"],
["skittle", 0.50, "inches", 53/50, "g", "./media/objects/circle.svg"],
["m&m", 0.5262, "inches", 43 / 50, "g", "./media/objects/circle.svg"],
["skittle", 0.50, "inches", 53 / 50, "g", "./media/objects/circle.svg"],
["gummy-bear", 2, "inches", 3.5, "g"],
["lifesaver", 0.925, "inches", 3.5, "g"],
],
@@ -170,7 +170,7 @@ function makeFood() {
e2 = b2.constructor();
return -math.subtract(e1.views[e1.defaultView].height, e2.views[e2.defaultView].height).value;
});

return results;
}

+ 2
- 2
presets/landmarks.js Dosyayı Görüntüle

@@ -96,7 +96,7 @@ function makeLandmarks() {
name: "Washington Monument",
constructor: () => makeLandmark(
"Washington Monument",
math.unit(555 + 5/12, "feet"),
math.unit(555 + 5 / 12, "feet"),
{ source: "./media/landmarks/washington-monument.svg" }
)
});
@@ -124,7 +124,7 @@ function makeLandmarks() {
constructor: () => makeLandmark(
"Leaning Tower of Pisa",
math.unit(185.93, "feet"),
{ source: "./media/landmarks/leaning-tower-of-pisa.svg", bottom: 84/3755 }
{ source: "./media/landmarks/leaning-tower-of-pisa.svg", bottom: 84 / 3755 }
)
});



+ 887
- 887
presets/naturals.js
Dosya farkı çok büyük olduğundan ihmal edildi
Dosyayı Görüntüle


+ 14
- 17
presets/objects.js Dosyayı Görüntüle

@@ -1,6 +1,3 @@



function makeObject(name, viewInfo) {
views = {};

@@ -42,13 +39,13 @@ function addShoeView(object, name, points) {
}
}

function makeHeight(info, category, prefix="", type="objects") {
function makeHeight(info, category, prefix = "", type = "objects") {
const views = {};


info.forEach(object => {
let src;
// this lets us provide our own source if needed
// useful for reusing existing art
if (object[3]) {
@@ -73,7 +70,7 @@ function makeHeight(info, category, prefix="", type="objects") {
}
}

function makeHeightWeight(info, category, prefix="", type="objects") {
function makeHeightWeight(info, category, prefix = "", type = "objects") {
const views = {};
info.forEach(object => {
let src;
@@ -196,7 +193,7 @@ function makeObjects() {
"Shot Glass",
{
glass: {
height: math.unit(2 + 3/8, "inches"),
height: math.unit(2 + 3 / 8, "inches"),
mass: math.unit(75, "g"),
image: { source: "./media/objects/shot-glass.svg" },
name: "Bottle"
@@ -455,15 +452,15 @@ function makeObjects() {
}
)
})
results.push(makeHeight(
[
["king", 4, "inches"],
["queen", 351/407*4, "inches"],
["bishop", 340/407*4, "inches"],
["knight", 309/407*4, "inches"],
["rook", 271/407*4, "inches"],
["pawn", 197/407*4, "inches"],
["queen", 351 / 407 * 4, "inches"],
["bishop", 340 / 407 * 4, "inches"],
["knight", 309 / 407 * 4, "inches"],
["rook", 271 / 407 * 4, "inches"],
["pawn", 197 / 407 * 4, "inches"],
],
"Chess Pieces",
"chess_"
@@ -556,7 +553,7 @@ function makeObjects() {
name: value.name,
rename: true
}
if (value.mass) {
views[key].attributes.mass = {
name: "Mass",
@@ -566,7 +563,7 @@ function makeObjects() {
};
}
});
return makeEntity({ name: "Strand" }, views);
}
})
@@ -586,13 +583,13 @@ function makeObjects() {
"cell_"
))

results.sort((b1, b2) => {
e1 = b1.constructor();
e2 = b2.constructor();
return -math.subtract(e1.views[e1.defaultView].height, e2.views[e2.defaultView].height).value;
});

return results;
}

+ 11
- 11
presets/scenes.js Dosyayı Görüntüle

@@ -1,11 +1,11 @@
const scenes = {};

scenes["Default"] = () => {
importScene({"entities":[{"name":"Fen","scale":1,"view":"back","x":"0.5152113970588236","y":"1"}],"world":{"height":2.9053707516337908,"unit":"meters"}});
importScene({ "entities": [{ "name": "Fen", "scale": 1, "view": "back", "x": "0.5152113970588236", "y": "1" }], "world": { "height": 2.9053707516337908, "unit": "meters" } });
fitWorld(true);
}
scenes["Demo"] = () => {
importScene({"entities":[{"name":"Fen","scale":13.37613697164259,"view":"back","x":"0.4739888072901602","y":"1"},{"name":"Cars","scale":1,"view":"Toyota Prius C (Side)","x":"0.5446325587240624","y":"1"},{"name":"Flagpole","scale":1,"view":"medium","x":"0.6884494749664603","y":"1"},{"name":"Aircraft","scale":1,"view":"Cessena 172 (Side)","x":"0.5554263161666061","y":"0.22135128477620036"},{"name":"Bus","scale":1,"view":"side","x":"0.3384726446176792","y":"1"},{"name":"Leopard 2 Rev. 1","scale":1,"view":"side","x":"0.6168929701770606","y":"1"},{"name":"Trees","scale":1,"view":"sycamore","x":"0.19678198200160846","y":"1"},{"name":"18-Wheeler","scale":1,"view":"side","x":"0.7563502890715608","y":"1"},{"name":"Cars","scale":1,"view":"Toyota Prius C (Top)","x":"0.5363900938385269","y":"0.7215473541048467"},{"name":"Human","scale":1,"view":"woman1","x":"0.4756975717747481","y":"1"},{"name":"Human","scale":1,"view":"man1","x":"0.47400075247875356","y":"0.2538019287833828"}],"world":{"height":38.5,"unit":"meters"}})
importScene({ "entities": [{ "name": "Fen", "scale": 13.37613697164259, "view": "back", "x": "0.4739888072901602", "y": "1" }, { "name": "Cars", "scale": 1, "view": "Toyota Prius C (Side)", "x": "0.5446325587240624", "y": "1" }, { "name": "Flagpole", "scale": 1, "view": "medium", "x": "0.6884494749664603", "y": "1" }, { "name": "Aircraft", "scale": 1, "view": "Cessena 172 (Side)", "x": "0.5554263161666061", "y": "0.22135128477620036" }, { "name": "Bus", "scale": 1, "view": "side", "x": "0.3384726446176792", "y": "1" }, { "name": "Leopard 2 Rev. 1", "scale": 1, "view": "side", "x": "0.6168929701770606", "y": "1" }, { "name": "Trees", "scale": 1, "view": "sycamore", "x": "0.19678198200160846", "y": "1" }, { "name": "18-Wheeler", "scale": 1, "view": "side", "x": "0.7563502890715608", "y": "1" }, { "name": "Cars", "scale": 1, "view": "Toyota Prius C (Top)", "x": "0.5363900938385269", "y": "0.7215473541048467" }, { "name": "Human", "scale": 1, "view": "woman1", "x": "0.4756975717747481", "y": "1" }, { "name": "Human", "scale": 1, "view": "man1", "x": "0.47400075247875356", "y": "0.2538019287833828" }], "world": { "height": 38.5, "unit": "meters" } })
fitWorld(true);
}

@@ -41,12 +41,12 @@ function makeSlice(min, max) {
const entity = x.constructor();
return math.compare(entity.views[entity.view].height, min) == 1 && math.compare(entity.views[entity.view].height, max) != 1
});
characters.forEach(character => {
const entity = character.constructor();
displayEntity(entity, entity.view, 0, 1);
});
arrangeEntities(getSortedEntities());
fitWorld(true);
}
@@ -129,7 +129,7 @@ function makeOwnerScene(owners) {
console.log(entity)
displayEntity(entity, entity.view, 0, 1);
});
arrangeEntities(getSortedEntities());
fitWorld(true);
}
@@ -160,7 +160,7 @@ function makeOwnerSceneViews(owners) {
console.log(entity)
displayEntity(entity, entity.view, 0, 1);
});
arrangeEntities(getSortedEntities());
fitWorld(true);
}
@@ -183,18 +183,18 @@ scenes["Neopuc"] = () => {
}).reduce((size, entity) => {
entity.views[entity.view].height = math.unit(100 * Math.sqrt(size) * (entity.name == "Ilisha Devya" ? 2 : 1), "meters");
displayEntity(entity, entity.view, 0, 1);
return size+1;
return size + 1;
}, 1)
arrangeEntities(getSortedEntities());
fitWorld(true);
}

scenes["Fidverse"] = () => {
makeOwnerSceneViews(["fidchell", "cam"])();
document.querySelector("#entity-" + (entityIndex-1)).dataset.x = 0.5;
document.querySelector("#entity-" + (entityIndex-2)).dataset.x = 0.25;
document.querySelector("#entity-" + (entityIndex-3)).dataset.x = 0.75;
document.querySelector("#entity-" + (entityIndex - 1)).dataset.x = 0.5;
document.querySelector("#entity-" + (entityIndex - 2)).dataset.x = 0.25;
document.querySelector("#entity-" + (entityIndex - 3)).dataset.x = 0.75;
updateSizes();
fitWorld(true, 1);
}

+ 3
- 3
presets/species.js Dosyayı Görüntüle

@@ -28,7 +28,7 @@ speciesMakers["Synx"] = () => {
name: "Synx",
image: {
source: "./media/species/synx/synx.svg",
extra: 8.06/6.6,
extra: 8.06 / 6.6,
bottom: 0.05
}
},
@@ -38,13 +38,13 @@ speciesMakers["Synx"] = () => {
name: "Weeper",
image: {
source: "./media/species/synx/weeper.svg",
extra: 8.04/7.5,
extra: 8.04 / 7.5,
bottom: 0.05
}
},
},
[
]
);



+ 40
- 40
presets/vehicles.js Dosyayı Görüntüle

@@ -68,8 +68,8 @@ function makeAircraft() {
],


sides = {}
const sorted = options.sort((a,b) => a[1]-b[1])
sides = {}
const sorted = options.sort((a, b) => a[1] - b[1])

sorted.forEach(plane => {
sides[plane[0] + " (Side)"] = {
@@ -102,23 +102,23 @@ function makeAircraft() {

entity.sizes.push({
name: "1:72",
height: math.unit(sorted[0][2]/72, "meters")
height: math.unit(sorted[0][2] / 72, "meters")
});
entity.sizes.push({
name: "1:24",
height: math.unit(sorted[0][2]/24, "meters")
height: math.unit(sorted[0][2] / 24, "meters")
});
entity.sizes.push({
name: "1:16",
height: math.unit(sorted[0][2]/16, "meters")
height: math.unit(sorted[0][2] / 16, "meters")
});
entity.sizes.push({
name: "1:8",
height: math.unit(sorted[0][2]/8, "meters")
height: math.unit(sorted[0][2] / 8, "meters")
});
entity.sizes.push({
name: "1:4",
height: math.unit(sorted[0][2]/4, "meters")
height: math.unit(sorted[0][2] / 4, "meters")
});
entity.sizes.push({
name: "1",
@@ -137,7 +137,7 @@ function makeCars() {
["Ford F-150", 5.89, 1.92, 1950, 1, 1, 1]
]
sides = {}
const sorted = options.sort((a,b) => a[1]-b[1])
const sorted = options.sort((a, b) => a[1] - b[1])

sorted.forEach(car => {
sides[car[0] + " (Front)"] = {
@@ -147,7 +147,7 @@ function makeCars() {
mass: math.unit(car[3], "kg"),
image: { source: "./media/vehicles/cars/car_" + car[0].replace(/ /g, "-").toLowerCase() + "-front.svg", extra: car[4] }
};
sides[car[0] + " (Side)"] = {
name: car[0] + " (Side)",
rename: true,
@@ -169,23 +169,23 @@ function makeCars() {

entity.sizes.push({
name: "1:72",
height: math.unit(sorted[0][2]/72, "meters")
height: math.unit(sorted[0][2] / 72, "meters")
});
entity.sizes.push({
name: "1:24",
height: math.unit(sorted[0][2]/24, "meters")
height: math.unit(sorted[0][2] / 24, "meters")
});
entity.sizes.push({
name: "1:16",
height: math.unit(sorted[0][2]/16, "meters")
height: math.unit(sorted[0][2] / 16, "meters")
});
entity.sizes.push({
name: "1:8",
height: math.unit(sorted[0][2]/8, "meters")
height: math.unit(sorted[0][2] / 8, "meters")
});
entity.sizes.push({
name: "1:4",
height: math.unit(sorted[0][2]/4, "meters")
height: math.unit(sorted[0][2] / 4, "meters")
});
entity.sizes.push({
name: "1",
@@ -212,7 +212,7 @@ function makeBuses() {
mass: math.unit(bus[3], "kg"),
image: { source: "./media/vehicles/buses/bus_" + bus[0].replace(/ /g, "-").toLowerCase() + "-front.svg", extra: bus[4] }
};
sides[bus[0] + " (Side)"] = {
name: bus[0] + " (Side)",
rename: true,
@@ -234,23 +234,23 @@ function makeBuses() {

entity.sizes.push({
name: "1:72",
height: math.unit(options[0][2]/72, "meters")
height: math.unit(options[0][2] / 72, "meters")
});
entity.sizes.push({
name: "1:24",
height: math.unit(options[0][2]/24, "meters")
height: math.unit(options[0][2] / 24, "meters")
});
entity.sizes.push({
name: "1:16",
height: math.unit(options[0][2]/16, "meters")
height: math.unit(options[0][2] / 16, "meters")
});
entity.sizes.push({
name: "1:8",
height: math.unit(options[0][2]/8, "meters")
height: math.unit(options[0][2] / 8, "meters")
});
entity.sizes.push({
name: "1:4",
height: math.unit(options[0][2]/4, "meters")
height: math.unit(options[0][2] / 4, "meters")
});
entity.sizes.push({
name: "1",
@@ -284,23 +284,23 @@ function makeVehicleGroup(info, name, prefix) {

entity.sizes.push({
name: "1:72",
height: math.unit(math.divide(defaultHeight,72))
height: math.unit(math.divide(defaultHeight, 72))
});
entity.sizes.push({
name: "1:24",
height: math.unit(math.divide(defaultHeight,24))
height: math.unit(math.divide(defaultHeight, 24))
});
entity.sizes.push({
name: "1:16",
height: math.unit(math.divide(defaultHeight,16))
height: math.unit(math.divide(defaultHeight, 16))
});
entity.sizes.push({
name: "1:8",
height: math.unit(math.divide(defaultHeight,8))
height: math.unit(math.divide(defaultHeight, 8))
});
entity.sizes.push({
name: "1:4",
height: math.unit(math.divide(defaultHeight,4))
height: math.unit(math.divide(defaultHeight, 4))
});

return entity;
@@ -336,7 +336,7 @@ function makeVehicles() {
{
side: {
name: "Side",
height: math.unit(883*1114/4250, "feet"),
height: math.unit(883 * 1114 / 4250, "feet"),
image: { source: "./media/vehicles/titanic.svg" },
},
sideVertical: {
@@ -398,22 +398,22 @@ function makeVehicles() {
}
)
});
results.push({
name: "Aircraft",
constructor: () => makeAircraft()
});
results.push({
name: "Cars",
constructor: () => makeCars()
});
results.push({
name: "Buses",
constructor: () => makeBuses()
});
results.push({
name: "Trains",
constructor: () => makeVehicleGroup([
@@ -437,23 +437,23 @@ function makeVehicles() {
name: "3250 Cubic Ft Hopper",
mass: math.unit(52000, "lbs"),
sides: {
"Side": { height: math.unit(15 + 3/12, "feet") },
"Front": { height: math.unit(15 + 3/12, "feet") },
"Side": { height: math.unit(15 + 3 / 12, "feet") },
"Front": { height: math.unit(15 + 3 / 12, "feet") },
}
},
{
name: "28600 Gallon Tank Car",
mass: math.unit(93000, "lbs"),
sides: {
"Side": { height: math.unit(15 + 5.7/12, "feet") },
"Front": { height: math.unit(15 + 5.7/12, "feet") },
"Side": { height: math.unit(15 + 5.7 / 12, "feet") },
"Front": { height: math.unit(15 + 5.7 / 12, "feet") },
}
}
],
"Trains",
"train")
});
"Trains",
"train")
});
results.push({
name: "Warships",
constructor: () => makeVehicleGroup([
@@ -512,8 +512,8 @@ function makeVehicles() {
}
},
],
"Warships",
"")
"Warships",
"")
});

return results;


Yükleniyor…
İptal
Kaydet