4e interactive sheet & utilities

Framework(s) for D&D 4e, including Veggiesama's.

Moderators: dorpond, trevor, Azhrei, giliath, Gamerdude, jay, Mr.Ice

DeviantNull
Dragon
Posts: 685
Joined: Wed Sep 03, 2008 12:34 pm
Location: The Junkyard

Re: 4e interactive sheet & utilities

Post by DeviantNull »

Zalarian wrote:This is looking sweet! Can I request that the following line of code be changed for initiative rolling? This will help with breaking ties in the initiative order by adding the users init modifiers with bonus if rolled rather than entered.

May I have your blessings to work on a hybrid framework using your framework for the LFR games that are run here?
Will there be an updated regexparser to take advantage of this slick update?


I'll look into tie breaking initiative. I couldn't remember if 4e used the modifier to break 'em or not. Easy fix though.

You can do whatever you'd like with the framework. I can't exactly stop anyone, and as Pink Rose pointed out I sorta cribbed a fair bit early on from what other folks were doing. I'd sorta be flattered if folks were using it for that sorta stuff.

The Regexparser was done by TravisT. I know nothing about it. I was working with him for a bit and then I sort of fell off the radar and had a long stretch where I couldn't work on things and never managed to hook back up with him. I might dive into it, but I'm pretty burnt out after finally finishing this thing. I CAN answer questions or troubleshoot the whats and hows and whys of what I've done and how things are stored easily enough though if someone else wanted to pick it up.

DeviantNull
Dragon
Posts: 685
Joined: Wed Sep 03, 2008 12:34 pm
Location: The Junkyard

Re: 4e interactive sheet & utilities

Post by DeviantNull »

PinkRose wrote:Problem: when I updated the colours of, say Magic Item Usage, (I like a darker red then DN uses), it would not update on the character. Nothing. No amount of editing helped.


DOH! Yeah, I forgot to mention that... I switched from reading out the macros on another token to reading out the properties on the lib:token itself. It seemed like an unnecessary step I had in there previously. Now the macros are more like an easy way to get the info into the properties on the Lib:token. I need to remember to make sure to remember to mention it again in the new thread.

Also adding things or adjusting the colors is mainly why I did it that way. However, be wary of removing any of the default items. I think I guarded against it flat out breaking if something is gone but I can't guarantee it. Also, while a token should be transferable from one campaign to another (not very useful if it ain't) if one campaign had a custom thingy and the other one doesn't, it could cause some things not to work. Again, I tried to protect against that but I haven't really tested to find out what would happen.

User avatar
Natha
Dragon
Posts: 733
Joined: Sat Oct 11, 2008 3:37 am
Location: Limoges/Guéret, France
Contact:

Re: 4e interactive sheet & utilities

Post by Natha »

Venatius wrote:Natha: Wouldn't you just put "Until the end of your next turn, you and all your allies gain a +=(1+CHA) bonus to attack rolls against the target." on the Hit line of the single attack? That's where you put effects that go off on a hit. I'm not really sure why you would want to list it separately. The format I gave would automatically substitute in the character's CHA modifier plus 1, whatever that happened to be. The way you're proposing seems kind of unnecessarily roundabout.


Duh ... you're right.
Thanks !
ImageImageImageImage

DeviantNull
Dragon
Posts: 685
Joined: Wed Sep 03, 2008 12:34 pm
Location: The Junkyard

Re: 4e interactive sheet & utilities

Post by DeviantNull »

Venatius wrote:Natha: Wouldn't you just put "Until the end of your next turn, you and all your allies gain a +=(1+CHA) bonus to attack rolls against the target." on the Hit line of the single attack? That's where you put effects that go off on a hit. I'm not really sure why you would want to list it separately. The format I gave would automatically substitute in the character's CHA modifier plus 1, whatever that happened to be. The way you're proposing seems kind of unnecessarily roundabout.


Yeah, thats how I intended it to work. Thats why the hit line joins with the damage line in the info box, it's supposed to be all one chunk. Obviously, when it comes to chat output I can't do that as easily due to the way the attack and damage checks and loops operate so it's easier to just put it on it's own line after all the die rolling is done. Thats why I also tried to make the =() regex parser work with nearly all the raw text areas, baring things like flavor and a few others that didn't seem like it would be necessary for.

ASIDE: I just realized that the RegEx parser I'm using will evaluate math. May not be shocking to anyone else out there but for some reason I thought I lost that functionality somehow when I adjusted a few things. So you can actually do =(STR + 4) and it'll replace your strength and then add 4, it'll also still work on dice codes. Technically this means that I'm running the modifiers boxes through 2 stages of evals but I don't think it hurts anything and it makes it easier to write and display the modifiers.

And to make sure folks know (I'll repeat it again in the repost) STR/CON/DEX/INT/WIS/CHA does the base modifier and adding MOD (CHAMOD) adds modifier + 1/2 level. There are other super secret things it'll substitute as well: Level, LevelMod, AC, Fort, Ref, Will, HP, Race, Class, Keyword, Speed, Move, Sense, and Wildsoul. Some of those are mainly for usage in things like Monster Knowledge checks, I'm lazy and have a template.

DeviantNull
Dragon
Posts: 685
Joined: Wed Sep 03, 2008 12:34 pm
Location: The Junkyard

Re: 4e interactive sheet & utilities

Post by DeviantNull »

The heavy armor detection was borked. The Equipment Calculation macro that adds up all the bonuses as well as stores Armor Info for easy retrieval (otherwise it would have to look up the armor every time it was needed, which requires ALOT more calls then simply looking up a few raw property values) was using the old style storage for heavy armor detection. For some unknown reason I changed it and didn't change the Equipment Calc macro. Also, it was far less gnarly then I remembered.

If you want the fix early; on Lib:Sheet in the Equipment Group change the line

Code: Select all

[H: DNA_ArmorIsHeavy = json.get(DNT_ItemArmor, "Heavy") + 0)]

to

Code: Select all

[H: DNA_ArmorIsHeavy = if(json.get(DNT_ItemArmor, "ArmorType") == "Heavy", 1, 0)]


Note: If you edited equipped armor or change the defense bonus values on an item you have equipped the change isn't reflected until you unequip it and reequip it. I added an item check into the editing macro to run the EquipCalc and CalcDefense on edited items. It adds a bit of delay to editing pre-existing items but it'll catch changes to items that effect defenses.
Last edited by DeviantNull on Sun Aug 29, 2010 4:25 pm, edited 1 time in total.

User avatar
Venatius
Dragon
Posts: 256
Joined: Mon Feb 16, 2009 7:12 pm

Re: 4e interactive sheet & utilities

Post by Venatius »

I'm not finding the line you refer to, DN. The closest on EquipmentCalc appears to be

Code: Select all

[H: DNA_ArmorIsHeavy = json.get(DNT_ItemArmor, "Heavy") + 0)]
. I'll experiment with changing that and see if it works, on the assumption that is the line you meant.

I've also noticed a weird tendency of some pulldowns in edit windows to "snap back" to other settings. They save correctly and all when you leave, but when you re-open the edit window, the option switches to something else. For instance, I have boots, a belt, and armor equipped. I go to the equip edit menu, and the pulldown for boots, waist, and armor are set to Nothing. It seems to do this with all EQ slots except main/off hand. Or, I set a power to do healing. When I re-open it, it's on temporary HP instead. Also, the mouseover statsheet doesn't seem to be updating right. I can strip a character naked (figuratively! figuratively!) and it will still display their fully armored AC.

UPDATE: Armor calculation still seems off. I fully removed all AC-affecting items and re-equipped them. The character in question has DEX 8 (-1) and INT 10 (+0), and is wearing a set of +2 plate (8+2=+10) and a heavy shield (+2), and is 10th level. Base AC 10+10(armor)+5(1/2 level)+2(shield) should equal 27, the number that is persistently on the character's mouseover no matter what I equip or unequip, but the main Stats page asserts their AC is 25. Yes, all relevant keywords are set on the armor. Heavy and Plate on the armor, Heavy (which shouldn't have any code effect on a shield, should it?) and Takes Arm Slot on the shield. If I had to guess, it would be that the shield bonus isn't being counted. The problem doesn't appear to be in the shield itself; creating a new heavy shield and equipping that instead yields the same end total.
Last edited by Venatius on Sun Aug 29, 2010 4:23 pm, edited 1 time in total.

DeviantNull
Dragon
Posts: 685
Joined: Wed Sep 03, 2008 12:34 pm
Location: The Junkyard

Re: 4e interactive sheet & utilities

Post by DeviantNull »

Venatius wrote:I'm not finding the line you refer to, DN. The closest on EquipmentCalc appears to be

Code: Select all

[H: DNA_ArmorIsHeavy = json.get(DNT_ItemArmor, "Heavy") + 0)]
. I'll experiment with changing that and see if it works, on the assumption that is the line you meant.


Whoops. yeah, bad undo/copy/paste on my part. I didn't undo far enough enough back to get the full code line before I copied it. I'll fix it in my post as well.

I've also noticed a weird tendency of some pulldowns in edit windows to "snap back" to other settings. They save correctly and all when you leave, but when you re-open the edit window, the option switches to something else. For instance, I have boots and armor equipped. I go to the equip edit menu, and the pulldown for boots and armor are set to Nothing. Or, I set a power to do healing. When I re-open it, it's on temporary HP instead. Also, the mouseover statsheet doesn't seem to be updating right. I can strip a character naked (figuratively! figuratively!) and it will still display their fully armored AC.


The equipment selection was broken, I was passing an incorrectly named variable so it didn't know what the previously equipped item was. I'll check power damage selection and make sure it's doing the right comparison for saved selection. They're typically identical so sometimes copy/paste errors slip through where I forget to update something.... yup, they're all checking for value 2 instead of 3 & 4.

DIY fix is to edit PowerAttackEntry on Lib:Sheet Powers group and find the DamageSpecial select/option section. It'll have entries that look like

Code: Select all

<option value="1" [R: if(json.get(DNT_Entry, "DamageSpecial" + DNT_SlotCount) == 1, "selected", "")]>No Damage</option>


the last two need to have their 2's in the if equals changed to 3 & 4 respectively so they match their values. They're matching on Healing even though they're saving the proper values.

The AC thing is because it was a converted token. I forgot that an old token will hang onto it's property value so the Statsheet property of AC reads the tokens value instead of the default {DNA_AC}. To fix it you either need to rename the display AC property and put AC in the short name OR reset the value on the token to the default {DNA_AC} so it'll read and eval the tokens AC.

User avatar
Venatius
Dragon
Posts: 256
Joined: Mon Feb 16, 2009 7:12 pm

Re: 4e interactive sheet & utilities

Post by Venatius »

Oh, I see! Maybe I should just wait until the next release before I try updating my tokens. It seems like that might be easier at this rate. :mrgreen: Thanks for the super-prompt reply!

Now back to trying to beam out thought-waves to get the RegEx parser updated to match...

DeviantNull
Dragon
Posts: 685
Joined: Wed Sep 03, 2008 12:34 pm
Location: The Junkyard

Re: 4e interactive sheet & utilities

Post by DeviantNull »

Venatius wrote:UPDATE: Armor calculation still seems off. I fully removed all AC-affecting items and re-equipped them. The character in question has DEX 8 (-1) and INT 10 (+0), and is wearing a set of +2 plate (8+2=+10) and a heavy shield (+2), and is 10th level. Base AC 10+10(armor)+5(1/2 level)+2(shield) should equal 27, the number that is persistently on the character's mouseover no matter what I equip or unequip, but the main Stats page asserts their AC is 25. Yes, all relevant keywords are set on the armor. Heavy and Plate on the armor, Heavy (which shouldn't have any code effect on a shield, should it?) and Takes Arm Slot on the shield. If I had to guess, it would be that the shield bonus isn't being counted. The problem doesn't appear to be in the shield itself; creating a new heavy shield and equipping that instead yields the same end total.


PM me the token so I can take a look at it and figure out where the calculations are breaking down. Heavy doesn't effect shields, and Takes Arm Slot is for magic item equipping detection so a shield can be used to prevent equipping a magical arm item.

You should be able to see the values for Armor and Shield AC on the token itself, they're the properties called DNA_EquipmentModArmorAC and DNA_EquipmentModShieldAC. The defense calculation string is pretty much straight forward 10 + both those + DNA_LevelBonus + DNA_DefenseModAC (what gets entered on the stats page as a character inherent bonus) + DNA_EquipmentModAC (a number consisting of all magical AC Enhancement modifiers of all equipped items, created via the EquipmentCalc macro loop) + a max() of Dex/Int/AltDefense values.

I don't have a lot of places it can be going wrong and I'm not see where it is from just looking at the code.

EDITED: I Think I found where it's breaking down, and I'm working on why. It's not counting the Armor Enhancement. So if the Armor is AC 8 and it has a +2 Armor Enhancement it's not taking the +2.

EDITED AGAIN! And I found it. JSON key names need to be uniform. I renamed the Enhancement Bonus key to Armor but left it as AC in the EquipCalc macro. Fixed.

Man this was buggier then I thought.

User avatar
Venatius
Dragon
Posts: 256
Joined: Mon Feb 16, 2009 7:12 pm

Re: 4e interactive sheet & utilities

Post by Venatius »

That was fast! You had both updates up before I could even look again. I assume you don't still need the token? If not, I'll say congratulations and well-done!

Edit/Update: I'm not 100% sure how augmentation is intended to work in this setup. I notice you can attach an augment cost to attacks if you've checked Augmentable (still seems to require separate powers for separate augmentation levels, alas, but so it goes!). But in the dialog box for using the power, you're still prompted for PP. Shouldn't that just be whatever augment cost is listed on the power? Also, if different augmentation levels need to be different powers (at the moment, they do, unless you list a bunch of conditionals, which I suppose is an option), shouldn't the augment be on the main power, rather than prompted for on each attack the power makes? I may be completely misunderstanding how this is meant to work. Also, what's that odd little clickable icon beside the PP box in the power use dialog? It clears the box when clicked, but somehow it doesn't seem like there'd be a button for that, so I am guessing it has some other use.

Aeraggo
Kobold
Posts: 2
Joined: Mon Aug 30, 2010 4:41 am

Re: 4e interactive sheet & utilities

Post by Aeraggo »

Natha wrote:
DeviantNull wrote:Right now No Damage suppresses the damage roll. This allows for powers that have an attack roll and an effect on hit but keeps the 0d0 damage from displaying so it should just display the hit/miss lines. Can you give me an example of a power that has a hit effect but no attack or damage roll for that specific hit effect?


The effects I would like to handle are not really "hits" but here's what I'd like to be able to do :
The power card :

What I would like to enter in the framework :

The chat output :


Okay, so...I'm a bit new and lost...I found this framework and think it works well for my group, however...the pics you posted look nothing like mine. I'm guessing there's a more recent version than what's posted in the OP that I'm having difficulty finding?

User avatar
PinkRose
Dragon
Posts: 732
Joined: Sat Nov 15, 2008 2:28 pm
Location: The City of Roses, Oregon

Re: 4e interactive sheet & utilities

Post by PinkRose »

The link for Monster Knowledge is not working in skills because it looks like it's an exact copy from build v4.3, which obviously isn't going to work.
How do you make the code below link to the Knowledge Macro in group Skills on the Lib:Information

Code: Select all

<span color="black">[r: macroLink("Knowledge Checks", "[email protected]:Information", "none", "Knowledge", currentToken())].</span>


If that line gets fixed I'll be able to slap it into the skills that need it and have them all done up.
Thanks.
I am a special snowflake!

DeviantNull
Dragon
Posts: 685
Joined: Wed Sep 03, 2008 12:34 pm
Location: The Junkyard

Re: 4e interactive sheet & utilities

Post by DeviantNull »

Venatius wrote:That was fast! You had both updates up before I could even look again. I assume you don't still need the token? If not, I'll say congratulations and well-done!

Edit/Update: I'm not 100% sure how augmentation is intended to work in this setup. I notice you can attach an augment cost to attacks if you've checked Augmentable (still seems to require separate powers for separate augmentation levels, alas, but so it goes!). But in the dialog box for using the power, you're still prompted for PP. Shouldn't that just be whatever augment cost is listed on the power? Also, if different augmentation levels need to be different powers (at the moment, they do, unless you list a bunch of conditionals, which I suppose is an option), shouldn't the augment be on the main power, rather than prompted for on each attack the power makes? I may be completely misunderstanding how this is meant to work. Also, what's that odd little clickable icon beside the PP box in the power use dialog? It clears the box when clicked, but somehow it doesn't seem like there'd be a button for that, so I am guessing it has some other use.


Yeah, I don't need a token. I build a shield myself and managed to figure out.

As for the Augmentable and PP thing, here's what I was thinking (and am still finding out how well it works):

The Augmentable keyword lets you put in an augment cost for attack/damage routine entries. These list directly before the routine in the info box. They're not strictly needed for pure effects since you can effectively do the same thing with a carriage return. When you use an Augmentable power you get an option to enter in a PP cost which should subtract from your total PP and will also output to chat what Augment cost was spent. Now, all the attack/damage routines will still fire off, but you can just look and compare to find out which attack/damage set to use.

I might try to set it so it suppresses the augment routines that are greater then the cost spent, but it requires another level of nested IF()'s checks and I wanted to get the thing out the door instead of doing that.

As for the white crosshairs icon in the top right of the power use dialogs, this is the target refresh link. When used, a power or item will auto-target selected tokens and then select those tokens from the Target drop down list. However, GM's character sheets change when they select a token since they always own everything. Thus, unlike a player, they can't select a token and THEN fire the power and have the list populate. But they can start the power use and then with the dialog box open, select tokens and hit the target icon and the list will auto-populate with their selections. This is another reason the sheet doesn't auto change when you have a dialog box open on the screen. Given how dialog/frame refresh works, clicking it reloads the window which means it will also wipe any entry selections made so you want to target first and then put in your mods.

It will never auto-target the user of the power. It's too hard to make it tell what is a beneficial power and what is an attack power. If it auto-targeted the user, every attack would have the user as the first target to hit as default and that is never good. However, the user should be the very first actual entry in the list (I think I even called it Self).

DeviantNull
Dragon
Posts: 685
Joined: Wed Sep 03, 2008 12:34 pm
Location: The Junkyard

Re: 4e interactive sheet & utilities

Post by DeviantNull »

PinkRose wrote:The link for Monster Knowledge is not working in skills because it looks like it's an exact copy from build v4.3, which obviously isn't going to work.
How do you make the code below link to the Knowledge Macro in group Skills on the Lib:Information

Code: Select all

<span color="black">[r: macroLink("Knowledge Checks", "[email protected]:Information", "none", "Knowledge", currentToken())].</span>


If that line gets fixed I'll be able to slap it into the skills that need it and have them all done up.
Thanks.


I misunderstood the question at first and thought you ment something was broken with monster knowledge checks... so I fixed that. Which is funny, because that was not what you were asking about it. However, it was broken. The chat output link wasn't working.

FYI, in the KnowledgeInfo macro the line

Code: Select all

[H: DNT_Entry = getProperty(DNT_StorageGroup + DNT_Slot)]

needs to be changed to

Code: Select all

[H: DNT_Entry = getProperty("DNA_Knowledge" + DNT_Slot)]

like everything else, it's fixed for the release tomorrow.

What you want is how to call the Skill Info window... piece of cake.

Code: Select all

[r: macroLink("Knowledge Checks", "[email protected]:Sheet", "none", json.set("", "WindowType", "Skill", "Skill", "Knowledge"), currentToken())]

In that, Knowledge is the name of the skill macro on Lib:Info that you're wanting. So you could substitute it for Acrobatics or Nature or Whatever. You could even make new ones.

drkissinger1
Kobold
Posts: 3
Joined: Mon Aug 30, 2010 1:22 pm

Re: 4e interactive sheet & utilities

Post by drkissinger1 »

What is the latest build of Maptool with which the v4-3 files are compatible?

Post Reply

Return to “D&D 4e Frameworks”