I am looking to make an if/else sheet worker for my health tracker. Upon hitting the 'health_refresh' checkbox, I would like my sheet worker to look at the character's 'physique_base' attribute, and, should there be a '3' in it, change the radio buttons named 'healthbox_phy0', 'healthbox_phy1', and 'healthbox_phy3' radio buttons to value="1". So far, I have put this together, but it is not working? How does one fix this? //Health Refresh
on("change:health_refresh", function() {
getAttrs(["health_refresh", "physique_base", "healthbox_phy0", "healthbox_phyr1", "healthbox_phyl1", "healthbox_phyr2"], function(values) {
if (value.physique_base = 3) {
setAttrs({
healthbox_phy0: 1,
healthbox_phy1: 1,
healthbox_phy2: 1
})
}
if else (value.physique_base = 4) {
setAttrs({
healthbox_phy0: 1,
healthbox_phy1: 1,
healthbox_phy2: 1,
healthbox_phy3: 1
})
}
});
});