Fixed Default attribute sheet worker
This commit is contained in:
@@ -3837,6 +3837,21 @@ on("change:repeating_weapon", function() {
|
||||
});
|
||||
});
|
||||
|
||||
//Setting the Default attribute name for default skill
|
||||
on("change:default_attribute", function() {
|
||||
getAttrs(["default_attribute", "default_display"], function(v) {
|
||||
const display = (v.default_display);
|
||||
const attribute = (v.default_attribute);
|
||||
let update = {};
|
||||
|
||||
//This sets a hidden input with the Attribute name so the roll template can use it to indicate what attribute was rolled
|
||||
let attributeNew = attribute.slice(2, -1);
|
||||
if (attributeNew != display) {update["default_display"] = attributeNew;};
|
||||
|
||||
setAttrs(update);
|
||||
});
|
||||
});
|
||||
|
||||
//REFACTORED Range & MELEE UPDATES
|
||||
['repeating_range',
|
||||
'repeating_melee',
|
||||
|
||||
Reference in New Issue
Block a user