
My sheetworker is as follows...
on('change:crowns change:pennies change:farthings sheet:opened', function () {
getAttrs(['crowns'], function(v) {
const crowns = v.crowns *1||0;
const pennies = v.pennies *1||0;
const farthings = v.farthings *1||0;
const crowns_wgt = crowns/16;
const pennies_wgt = pennies/128;
const farthings_wgt = farthings/512;
const coins_wgt = crowns_wgt + pennies_wgt + farthings_wgt;
setAttrs({
crowns_wgt: crowns_wgt,
pennies_wgt: pennies_wgt,
farthings_wgt: farthings_wgt,
coins_wgt: coins_wgt
});
});
});
I am getting the following result...
So...the error is that the "pennies_wgt" and "farthings_wgt" are not being calculated.
Can anyone see why?