Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > HL - Pathfinder Roleplaying Game
Register FAQ Community Today's Posts Search

Notices

Reply
 
Thread Tools Display Modes
Corwyn
Member
 
Join Date: Jul 2010
Posts: 42

Old July 9th, 2010, 05:20 PM
Hi,
I've been wracking my brain for the programming (it's been well over 15 years since I used this type) and frankly I'm pounding my forehead against the wall now. I've been able to add a new race, new weapons, and some new abilities (all stuff based off other stuff, like suggested elsewhere).
However, I'm trying to add this Feat and after a few EPIC fail attempts, I found this. which failed to pass as well.

Feat does the following (for those that don't know)
+2 bonus to all Cha-based skill checks
+1 bonus on saves vs spells & spell-like abilities
+1 skill point per level.

==================================
~search through all the class levels
foreach pick in hero from BaseClass
~for each class level that's at or above the level we've chosen
if (field[cLvlIndex].value >= field[hUsed].value) then
~retrieve the cClsIndex from the class helper, and use that to figure
~out which arrayvalue of the skill totals array to add a bonus to

~we'll add +1, since this will repeat once for every class level
herofield[tSkTotals].arrayvalue[eachpick.linkage[helper].field[cClsIndex].value] += 1

~if the feat was taken at level 1, and we're modifying the class level
~at level 1, add another 3 skill points, so that we've added +4 total
~for this level
if (field[hUsed].value= 1) then
if (field[cLvlIndex].value = 1) then
herofield[tSkTotals].arrayvalue[eachpick.linkage[helper].field[cClsIndex].value] += 3
endif
endif
endif
nexteach

=======================


ANY help would be greatly appriciated. I think I found an older verison user file maybe... I don't know.

Please and thank you for any help.
Corwyn
Corwyn is offline   #1 Reply With Quote
ShadowChemosh
Senior Member
Volunteer Data File Contributor
 
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729

Old July 10th, 2010, 11:59 AM
Wow! So I think what you have their is allot of older or d20 file stuff? Either way what you want is pretty easy to do. You can not do the +1 bonus on saves as that is a situtional modifier and should be applied by the player. The rest is not too bad to script.

The only skill that is a pain is the Perform skill as their can be new ones added by classes or players and their is a large list. Luckely HL tags these all with a helper tag that makes finding them all easy. After that the list of Cha skills is pretty small and then we just need to apply a single point per level to our total skills point to spend. We don't have to do anything weird now in PFPRG as classes don't get x4 Sp at level 1.

Here is the final working script for you. The first comment line is telling you what timing to put the script at which you have to do at the top of the eval window.

Code:
~Phase: First, Priority 5,000

~Adjust all Peformance skills by one
foreach pick in hero from BaseSkill where "Helper.SkCatPerf"
  eachpick.field[Bonus].value += 1
nexteach
~Adjust the rest of the Cha skills by one
#skillbonus[skBluff] += 1
#skillbonus[skDiplo] += 1
#skillbonus[skDisguise] += 1
#skillbonus[skIntim] += 1
#skillbonus[skUseMagic] += 1
~Give a bonus skill point equal to the total level of the hero
hero.childfound[resSkill].field[resMax].value += #totallevelcount[]
Hope that helps.

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.
ShadowChemosh is offline   #2 Reply With Quote
Corwyn
Member
 
Join Date: Jul 2010
Posts: 42

Old July 10th, 2010, 03:19 PM
Awesome, thanks. Working with out info would explain why I was trying to pull my hair out (not that I have that much left)

Appreciate all your help.
Corwyn
Corwyn is offline   #3 Reply With Quote
risner
Senior Member
Volunteer Data File Contributor
 
Join Date: Jun 2010
Posts: 623

Old July 10th, 2010, 08:09 PM
Quote:
Originally Posted by ShadowChemosh View Post
Hope that helps
IIRC it is more complicated for the skills.
I think it only works from when you take the feat.

So can you determine when the feat was taken somehow?
risner is offline   #4 Reply With Quote
ShadowChemosh
Senior Member
Volunteer Data File Contributor
 
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729

Old July 11th, 2010, 05:51 AM
Quote:
Originally Posted by risner View Post
So can you determine when the feat was taken somehow?
I don't know of any way of storing such information but that does not guarantee their is no way. The problem is from what I know is that all the different values are constantly being re-calculated. You would need to be able to store a static value somehow on the feat to represent the level you assigned the feat to the hero.

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.
ShadowChemosh is offline   #5 Reply With Quote
risner
Senior Member
Volunteer Data File Contributor
 
Join Date: Jun 2010
Posts: 623

Old July 11th, 2010, 09:43 AM
Quote:
Originally Posted by ShadowChemosh View Post
store a static value somehow on the feat to represent the level you assigned the feat to the hero.
Is there a way to put a text field? I needed this for things like Area Map (so you could describe what the map is.)

If so, could you convert the text field to number? You could then enter when you took it in a field and the math would just subtract this from the total.
risner is offline   #6 Reply With Quote
ShadowChemosh
Senior Member
Volunteer Data File Contributor
 
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729

Old July 11th, 2010, 03:48 PM
Their is such a thing and I did fix the area map to allow exactly that. The issue is from the little testing I did that text area is a String(ie character field) and I would need some type of Built In Function(BIF) to convert string to numeric. I know HL converts numeric into string very easily, but didn't seem to like doing the other way around.

Granted I could just not know how, but usually in the languages I usually use their is a function that allows one to convert from one field type to another(ie %Dec or %Int). If we had something like that than it could maybe work with the player typing in the level......

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.
ShadowChemosh is offline   #7 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 13,213

Old July 11th, 2010, 04:12 PM
Actually, I'd recommend using the "Choose Amount of Activation" to set the level it was chosen at - the user will have to flip to the In-Play page, but it's better than trusting the user to enter exactly the format you want, and not include anything extraneous.
Mathias is offline   #8 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 03:45 AM.


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