Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > HL - d20 System
Register FAQ Community Today's Posts Search

Notices

Reply
 
Thread Tools Display Modes
ynnswa
Member
 
Join Date: Jul 2010
Posts: 33

Old September 2nd, 2011, 12:24 PM
My homebrew system finished (hooray!) I have use the scripting momentum productively and start on the OOP Conan RPG from Mongoose, which we play quite a lot.

Things were humming along swimmingly until I started outlining the "Versatility" Class Special Abilily for the Barbarian class. The upgrades to the ability are described as follows:

At 14th level, the barbarian doubles the threat range when
wielding any melee weapon, including simple, martial, exotic
and improvised weapons, as well as unarmed attacks and
grapples. At 20th level this threat range is tripled.


Improved Critical for all weapons I can figure out, but I'm not sure how to handle it if they already have Improved Critical on a weapon. The game doesn't have Keen weapons, so I could use that, I assume. But I'm not sure how to assign that universally through the hero rather than the specific weapon.

Any thoughts would be greatly appreciated.
ynnswa is offline   #1 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 13,213

Old September 5th, 2011, 01:29 PM
The threat range for a weapon is stored as a wCritMin tag. In the Develop menu at the top of the main Hero Lab window, make sure that "Enable Data File Debugging" is checked, and then add a selection of weapons with varying threat ranges, and for each, right-click it and select "Show Selection Tags for XXXXX" - look there for all the tags that are on that item. You'll see tags like wCritMin.20, wCritMin.18, etc.

Okay, so what you need to do with that is to figure out what range that represents (you want to turn wCritMin.20 into a 1 and wCritMin.18 into a 3) - then you can multiply that by either 2 or 3, then turn it back into a tag.

Code:
 
var threatrng as number
threatrng = 1 + 20 - tagvalue[wCritMin.?]
Next, multiply that by 2 or 3:

Code:
threatrng *= 2
And turn that into the lowest number of the threat range:

Code:
threatrng = 20 - threatrng + 1
After that, delete the wCritMin tag that's there, and assign a new wCritMin tag, based on the value you've calculated:

Code:
 
perform delete[wCritMin.?]
perform assignstr["wCritMin." & threatrng]
That script is something that would run on the weapon. Here's how to modify that to function from a class special:

Phase: Post-Levels, priority: 10000
Code:
 
~ If we're not shown, just get out now
doneif (tagis[Helper.ShowSpec] = 0)
 
~if we're 20th level, our multipler is 3, otherwise, it's 2
var threatmult as number
if (field[xTotalLev].value >= 20) then
  threatmult = 3
else
  threatmult = 2
  endif
 
var threatrng as number
foreach pick in hero from BaseWep where "wClass.Melee"
  threatrng = 1 + 20 - eachpick.tagvalue[wCritMin.?]
  threatrng *= threatmult
  threatrng = 20 - threatrng + 1
  perform eachpick.delete[wCritMin.?]
  perform eachpick.assignstr["wCritMin." & threatrng]
  nexteach
Mathias is online now   #2 Reply With Quote
ynnswa
Member
 
Join Date: Jul 2010
Posts: 33

Old September 6th, 2011, 03:12 AM
I really appreciate your step-by-step explanations. As for the script, it worked like a charm. Thank you.
ynnswa is offline   #3 Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 11:49 AM.


Powered by vBulletin® - Copyright ©2000 - 2024, vBulletin Solutions, Inc.
wolflair.com copyright ©1998-2016 Lone Wolf Development, Inc. View our Privacy Policy here.