Bläddra i källkod

Update Synx weight; make adult form default

Entities can have now a default view other
than the first one provided for them.
master
Fen Dweller 5 år sedan
förälder
incheckning
a581a3d441
3 ändrade filer med 11 tillägg och 4 borttagningar
  1. +5
    -0
      macrovision.js
  2. +2
    -1
      presets/characters.js
  3. +4
    -3
      presets/species.js

+ 5
- 0
macrovision.js Visa fil

@@ -459,6 +459,11 @@ function makeEntity(info, views, sizes) {
this.view = viewKey; this.view = viewKey;
} }


if (view.default) {
this.defaultView = viewKey;
this.view = viewKey;
}

Object.entries(view.attributes).forEach(([key, val]) => { Object.entries(view.attributes).forEach(([key, val]) => {
Object.defineProperty( Object.defineProperty(
view, view,


+ 2
- 1
presets/characters.js Visa fil

@@ -16,7 +16,8 @@ function makeCharacter(info, viewInfo, defaultSizes) {
image: value.image, image: value.image,
name: value.name, name: value.name,
info: value.info, info: value.info,
rename: value.rename
rename: value.rename,
default: value.default
} }


if (value.weight) { if (value.weight) {


+ 4
- 3
presets/species.js Visa fil

@@ -24,17 +24,18 @@ speciesMakers["Synx"] = () => {
}, },
synx: { synx: {
height: math.unit(3.4, "feet"), height: math.unit(3.4, "feet"),
weight: math.unit(150, "lb"),
weight: math.unit(300, "lb"),
name: "Synx", name: "Synx",
image: { image: {
source: "./media/species/synx/synx.svg", source: "./media/species/synx/synx.svg",
extra: 8.06 / 6.6, extra: 8.06 / 6.6,
bottom: 0.05 bottom: 0.05
}
},
default: true
}, },
weeper: { weeper: {
height: math.unit(3.9, "feet"), height: math.unit(3.9, "feet"),
weight: math.unit(300, "lb"),
weight: math.unit(450, "lb"),
name: "Weeper", name: "Weeper",
image: { image: {
source: "./media/species/synx/weeper.svg", source: "./media/species/synx/weeper.svg",


Laddar…
Avbryt
Spara