mirror of
https://github.com/migatu/vtt_work.git
synced 2026-07-14 21:38:39 +00:00
asd
This commit is contained in:
@@ -95,6 +95,7 @@ try {
|
||||
data.rtRawString = "{}";
|
||||
}
|
||||
|
||||
|
||||
// expose a minimal config (labels)
|
||||
data.cfg = {
|
||||
labels: {
|
||||
@@ -145,17 +146,17 @@ try {
|
||||
callback: async (html) => {
|
||||
const form = html[0].querySelector("form") || html[0];
|
||||
const get = (k) => Number(form.querySelector(`[name="${k}"]`)?.value || 0);
|
||||
const patch = {
|
||||
"base.armour": get("armour"),
|
||||
"base.integrity": get("integrity"),
|
||||
"base.manoeuvre": get("manoeuvre"),
|
||||
"base.detection": get("detection"),
|
||||
"base.speed": get("speed"),
|
||||
"base.space": get("space"),
|
||||
"base.power": get("power")
|
||||
};
|
||||
for (const [k, v] of Object.entries(patch)) await this.actor.setFlag(VB_MOD, k, v);
|
||||
this.render(true);
|
||||
const patchBase = {
|
||||
armour: get("armour"),
|
||||
integrity: get("integrity"),
|
||||
manoeuvre: get("manoeuvre"),
|
||||
detection: get("detection"),
|
||||
speed: get("speed"),
|
||||
space: get("space"),
|
||||
power: get("power")
|
||||
};
|
||||
await this.actor.setFlag(VB_MOD, "base", patchBase);
|
||||
this.render(true);
|
||||
}
|
||||
},
|
||||
cancel: { label: "Cancel" }
|
||||
|
||||
Reference in New Issue
Block a user