16 lines
508 B
JavaScript
16 lines
508 B
JavaScript
var a = actor;
|
|
var it = actor.items;
|
|
var at = it.find(i => i.name === "Rapier +1" && i.type === "attack");
|
|
var u = at.actions.find(a => a.name === "Attack");
|
|
var c = u.conditionals;
|
|
console.log(u);
|
|
console.log(c.values().next().value);
|
|
|
|
console.log("1" + scope.name)
|
|
conditional = c.find(e => e.data.name === scope.name);
|
|
|
|
var active = scope.status;
|
|
|
|
//ca.update writess to .data directly so no need for data.default but it should be only defualt
|
|
var up = { "default" : active};
|
|
await conditional.update(up); |