
Greetings, I'm currently looking for a means to effect the way roll20 calculates weapon damage. I'm interested in running a solo adventure with a friend of mine and wanted to make some alterations to the basic D&D5e character sheet / roll templates (create my own home-brew variant). Not sure if what I want to do is possible. What I want is to find some way of overriding or replacing the default behavior of, say, the roll_MeleeAttack1 button--changing the roll template to include some logic: If the damage dice results in 1: 0 points of damage. If the damage dice results in 2, 3, 4, or 5: 1 point of damage. If the damage dice results in 6, 7, 8, or 9: 2 points of damage. If the damage dice results in 10+: 4 points of damage. I created some functions within the API which work well when processing through chat. What I want is the processing to occur when the button is pressed. Is this possible? I've already discovered that API functions cannot be called within roll templates. My work-around was to create the roll template through javascript. I've also considered using rollable tables, but it seems like I'm wanting them to do something beyond their scope. I'm starting to see my efforts are heading down a dead end street. I'm not new to programming and I can handle a fair degree of complexity, but I'm far from an expert and could use some guidance. Thought I'd ask around and see if anyone had some ideas on what to try or tips that might help. I appreciate your consideration.