Lone Wolf Development Forums

Lone Wolf Development Forums (http://forums.wolflair.com/index.php)
-   HL - d20 System (http://forums.wolflair.com/forumdisplay.php?f=46)
-   -   Class skill code... need some help (http://forums.wolflair.com/showthread.php?t=12488)

risner February 23rd, 2011 11:52 AM

Quote:

Originally Posted by Kendall-DM (Post 52549)
The number of ranks bought is not the problem (I'm not changing the cross-class or class skill maximum ranks structure). They difficulty is in how many skill points each class spends on cross-class skills.

Ok, I guess I had trouble explaining my proposed solution to you. I will try again.

Try this:
1) Look up the class number of points spent on the class you wish to "double" points spent to accomplish 1 for 1.
2) Add the required amount to ranks to make sure they reflect as you wish.

risner February 23rd, 2011 12:01 PM

This is not actual code, just design and actual code mixed in.

Example code:
Code:

var a as number

search to find the kValue for the class you want to change (kListen) (say 3 = 3rd class you have taken)
a = blah.field[kValue3].value
hero.child[kListen].field[kUserRanks].value += a

Repease last 3 lines for thingid.kSpeakLang|thingid.kSpot"


risner February 23rd, 2011 12:35 PM

Did some searching:

var index as number
index = hero.child[cHelpWiz].field[cClsIndex].value

that tells you which one it is, so:

if (index = 0) then kValue0
...
if (index = 5) then kValue5

Kendall-DM February 24th, 2011 08:49 PM

Well, I was able to get around this, as long as I'm careful when creating a character. All I have to do is check that there are no remaining skill points in the class that gets the general skills in my game, and only apply the code segment while there are points to be spent. Obviously, I need to spend for each class independently before adding new classes, that's the careful part. Here is what I added to the code segment (using Wizard again).

var index as number
index = hero.child[cHelpWiz].field[cClsIndex].value

if (hero.child[Totals].field[tSkTotals].arrayvalue[index] <> 0) then

*code above*

endif

EDIT: Nevermind, still needs work, forgot it changes the ranks as soon as the skill points are empty. Ergh.

Kendall-DM February 25th, 2011 12:16 PM

Ok, I went back to my original code for doing this, which works. It just isn't doing validity tests like I would like. But it works, and doesn't cause me the headaches that trying to do things across the hero does. Not the ideal solution, but a solution. Oh and I have to use the eval rules panel and set all these skill types to a class skill, then restrict their ranks. Something like this for Speak Languages on a Wizard.

@valid = 1
doneif (#levelcount[Bard] >= 1)

var genRanks as number
genRanks = (#totallevelcount[] + 3) / 2
if (#skillranks[kSpeakLang] > genRanks) then
@message = "Skill " & hero.child[kSpeakLang].field[name].text & " has too many ranks for a general skill."
@valid = 0
endif

Of course, the problem here is it happens within the class, making error validation on the skill difficult at best. As of now, it does a warning. Now I just have to do the same for all the other skills across the classes.

Kendall-DM March 4th, 2011 03:04 PM

Quote:

Originally Posted by risner (Post 52555)
Did some searching:

var index as number
index = hero.child[cHelpWiz].field[cClsIndex].value

that tells you which one it is, so:

if (index = 0) then kValue0
...
if (index = 5) then kValue5

risner, my apologies. I did in fact get this to work just as you said. I was simply approaching it the wrong way. By adding 1/2 the specific classes KValue into the kUserRanks, it produced the results I needed that didn't apply it across the hero. Thank you, thank you, and thank you. What I found out is, the only thing I needed to modify was the kUserRanks, as any other modification to kUserPts, kValueX, or the class/cross-class skills of the class were just too inter-connected to not affect something. When I realized that the only thing tracked by class was in the kValue, and the only thing I needed to modify was the kUserRanks, add 0.5 * that kValue back into the kUserRanks worked like a charm, and without messing up any other classes that are using the same skill as cross-class or class. Thank you once again (this was the one and only thing I couldn't stomach a half measure on).

Dark Lord Galen September 29th, 2016 01:19 PM

Quote:

Originally Posted by Kendall-DM (Post 52995)
risner, my apologies. I did in fact get this to work just as you said. I was simply approaching it the wrong way. By adding 1/2 the specific classes KValue into the kUserRanks, it produced the results I needed that didn't apply it across the hero. Thank you, thank you, and thank you.

Kendall DM (or any), could you clarify the code you used to "make this work"? As the thread mentions and your determinations, adding a skill is pretty straight forward, but I need to create some that are cross-class, specifically languages that would be more difficult to learn. Using Skills would seem the easiest approach except not knowing how to make them cross-class and thus more difficult to master. I think yours is the solution I am needing.
Thanks for the response in advance

Dark Lord Galen September 20th, 2018 06:31 PM

Thread Bump.... Still trying to figure this out..any help is appreciated

Sendric September 21st, 2018 04:47 AM

Quote:

Originally Posted by Dark Lord Galen (Post 270661)
Thread Bump.... Still trying to figure this out..any help is appreciated

What exactly are you trying to accomplish? If you want what Kendall did, then the script he posted above looks like an eval rule:

Code:

@valid = 1
doneif (#levelcount[Bard] >= 1)

var genRanks as number
genRanks = (#totallevelcount[] + 3) / 2
if (#skillranks[kSpeakLang] > genRanks) then
@message = "Skill " & hero.child[kSpeakLang].field[name].text & " has too many ranks for a general skill."
@valid = 0
endif

PS. If you just want a new skill to be cross-class, then you don't need to do anything. All skills are cross-class unless a class is assigned that class as a class skill.

Dark Lord Galen September 21st, 2018 06:08 AM

Sendric, Thanks For Rapid Response.... there was a short between the floor and the keyboard.... :p

When adding more language types (in this case there is a series of gestures and visual markers ) unique to The World of Greyhawk's "Gnarley Rangers" that allow them to mark a trail warning of dangers or things nearby. As this is only learnable from a specific type of Ranger I wanted to set the degree of difficulty up a notch.

BUTTTTT I had forgotten that when setting up other campaign specific languages to show as selections on the Personal tab, I had duplicated the list in both the languages and skills tabs in the editor user file. I was adding this particular "secret language" on the wrong tab oooopppps...

Thanks Again:D


All times are GMT -8. The time now is 10:19 PM.

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