Junior Member
|
I have seen a feat on some of the open source 3.5 forums (on other sites) that have homebrew content on them, that I want to put into my own user files for Hero Lab. I do not know who created this stuff, but here is the fluff and crunch:
Quote:
Source: http://alcyius.com/dndtools/feats/so...311/index.html How would I code this? MY ONLY impression thus far is to just copy some of the mechanics of the eval script for Weapon Specialization, and change it to somehow search for any weapons that do FIRE typed damage, and then add +1 to each instance for as long a duration as the feat allows. This is the code i have copied from stock PF core so far, from Weapon Spec: Code:
~ If we're disabled, do nothing doneif (tagis[Helper.FtDisable] <> 0) ~ If we haven't chosen anything, get out now doneif (field[usrChosen1].ischosen + tagis[Target.?] = 0) if (tagcount[Hero.MartVersa] + hero.tagcount[Hero.MartMaster] <> 0) then perform field[usrChosen1].chosen.pulltags[wFtrGroup.?] foreach pick in hero from BaseWep if (eachpick.tagmatch[wFtrGroup,wFtrGroup,initial] <> 0) then perform eachpick.assign[Broadcast.WepSpec] perform eachpick.pulltags[WepSpec.?] endif nexteach perform hero.pushtags[WepSpec.?] else ~ Assign the appropriate tag to all weapons that meet the criteria var id as string var name as string call fTargetId foreach pick in hero where "IsWeapon." & id perform eachpick.assign[Broadcast.WepSpec] nexteach ~ Set our 'short name' field[shortname].text = "Spec: " & name field[sbName].text = "Weapon Specialization (" & lowercase(name) & ")" ~ Forward the weapon specialization tag for the weapon to the hero perform hero.assignstr["WepSpec." & id] endif ~ Pull the IsWeapon tag if we choose quarterstaff so that we can detect ~ that in the pre-req for this feat. if (field[usrChosen1].chosen.tagis[IsWeapon.wQtrstaff] <> 0) then perform field[usrChosen1].chosen.pulltags[IsWeapon.?] endif Please keep in mind that i am a TOTAL NEWB to Hero lab, and while i AM familiar with basic XML, and OTHER object oriented scripting languages, I feel like a total babe in the woods with Hero Lab development. Thanks. |
|
#1 |
Senior Member
Join Date: Oct 2011
Posts: 6,793
|
As I said in my answer to your previous thread, this feat would be text only because it interacts with something HL doesn't track, namely how much damage someone on fire takes. If it increased the damage fire weapons (like flamethrowers or lasers) did, then you'd have something to do, but by my reading it does not.
So, long story short, just create the feat in the editor, give it a unique ID and name, and paste the description into the description box. Save the file, and hit the blue "Test Now" button in the upper left, and you're done. |
#2 |
Junior Member
|
Quote:
How exactly is this something that HL does not track? I would think that HL could track this. I know you are more experienced than I am so i am just seeking to understand. So, on the flip side... How would i code it, if i do it the OPPOSITE way of what you thought? (IE: if it was to influence any damage TO BE done, when the PC is about to act with a fire based attack) |
|
#3 |
Senior Member
Join Date: Oct 2011
Posts: 6,793
|
If you'd prefer it to add to direct fire damage from weapons, then I would recommend you foreach through all weapons on the hero, looking for ones with the wType.Fire tag, and add +1 to their damage bonus field (dmmBonus or dmrBonus, or both depending on whether it is ranged or melee weapon).
For an example of something which does a foreach and adds to damage, check out the Skinsaw Mask (which is a magic item that adds +1 damage to all slashing weapons when equipped). |
#4 |
Junior Member
|
Quote:
I just copied the eval script from Skinsaw mask and am working on it now -- GREAT TIP! How would I extend the script to apply the +1 fire damage to other things BESIDES weapons? like even NATURAL attacks (ie: monk fists with fire, or breath weapons, or oil flask explosions, or torches, or fire type spells and SLAs, etc etc...) what are the various attack types or where can i find a list of them all? That way i can just extend the script to cover all bases that the feat applies to |
|
#5 |
Junior Member
|
oh and that also reminds me. I also need to raise the DC of all those other attacks or powers by 5. Thanks for being patient with me.
I am finally learning how to do this!!!!! |
#6 |
Senior Member
Volunteer Data File Contributor
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729
|
Quote:
So "Fireball" does not do this. A flaming weapon does not do this. I can only think of a few abilities that do this with one being Alchemist Fire and the second one being "Fire Jet" ability of the Fire wizard school. What you have here is a very situational ability that is pretty much left as 'Text' to remind you when that situation comes up. Hero Lab Resources: Pathfinder - d20pfsrd and Pathfinder Pack Setup 3.5 D&D (d20) - Community Server Setup 5E D&D - Community Server Setup Hero Lab Help - Hero Lab FAQ, Editor Tutorials and Videos, Editor & Scripting Resources. Created by the community for the community - Realm Works kickstarter backer (Alpha Wolf) and Beta tester.- d20 HL package volunteer editor. |
|
#7 |
|
|