Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > HL - d20 System

Notices

Reply
 
Thread Tools Display Modes
ShadowChemosh
Senior Member
Volunteer Data File Contributor
 
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,695

Old February 7th, 2011, 10:14 AM
Quote:
Originally Posted by risner View Post
I could use some help from LawfulG or ShadowChemosh.

I've got a couple gating issues that are preventing me from integrating my changes:

1) I can't seem to find the timing to modify a Special (in the special tab) and have the change print on the character sheet? (This is blocking me adding the Druid changes to the PHB 3.5 Wild Shape in D20 data set.)
Hmm have you tried the RENDER phase as I remember I had an issue similar and only by going to the RENDER phase did it finally work.

Quote:
Originally Posted by risner View Post
2) How do you set a default value to a class special in the class tab that has an option to choose? It defaults to "-No Selection-". I need to make an if that "field[usrChosen1].ischosen = 0" then I need to choose for the user. I don't know how. The selection is based on a User. tag?
I know some feats like Weapon Focus can do this, or at least in Pathfinder, but when I tried it for Improved Natural Attack I could not get it to work. So this maybe only possible with special settings in the structural files.

Quote:
Originally Posted by risner View Post
3) Should we be directing bug reports to the WolfLair bug report thread? Or to a specific thread for community stuff?
We have a thread that is specifically made for bug reports it is sticked to the top of this forum.

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.

Last edited by ShadowChemosh; February 7th, 2011 at 10:16 AM.
ShadowChemosh is offline   #1 Reply With Quote
risner
Senior Member
Volunteer Data File Contributor
 
Join Date: Jun 2010
Posts: 616

Old February 8th, 2011, 06:06 AM
1) Here is an example feat demo:

Code:
  <thing id="fmessyes" name="Make a mess" description="test, you can delete" compset="Feat">
    <tag group="Helper" tag="ShowSpec"/>
    <eval phase="GlobalTest" priority="12000" index="2"><![CDATA[
field[livename].text = "Testing Global Tags/12000"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="PreLevel" index="3"><![CDATA[
field[livename].text = "Pre-Levels/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="UserPreLv" index="4"><![CDATA[
field[livename].text = "Pre-Levels Users/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="Level" index="5"><![CDATA[
field[livename].text = "Levels/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="PostLevel" index="6"><![CDATA[
field[livename].text = "Post-Levels/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="UserPostLv" index="7"><![CDATA[
field[livename].text = "Post-Levels Users/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="UserPreAt" index="8"><![CDATA[
field[livename].text = "Pre-Att Users/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="PreAttr" index="9"><![CDATA[
field[livename].text = "Pre-Att/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="Attr" index="10"><![CDATA[
field[livename].text = "Attributes/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="PostAttr" index="11"><![CDATA[
field[livename].text = "Post-Att/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="UserPostAt" index="12"><![CDATA[
field[livename].text = "Post-Att Users/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="UserFinal" index="13"><![CDATA[
field[livename].text = "Final Phase Users/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="Final" index="14"><![CDATA[
field[livename].text = "Final Phase/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="Validation" index="15"><![CDATA[
field[livename].text = "Validation/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="Render" index="16"><![CDATA[
field[livename].text = "Render/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    <eval phase="First"><![CDATA[
field[livename].text = "First/100"

field[xSumm].text = field[livename].text

field[CustDesc].text = field[xSumm].text]]></eval>
    </thing>
It modified the feat tab "livename" at Pre-Levels/100 and modifies the Specials tab and printout "livename" at Render/100

It doesn't modify the description on the Feat tab or printout, but does on the Specials tab at Render/100.
risner is offline   #2 Reply With Quote
risner
Senior Member
Volunteer Data File Contributor
 
Join Date: Jun 2010
Posts: 616

Old February 8th, 2011, 06:13 AM
Quote:
Originally Posted by ShadowChemosh View Post
2) I know some feats like Weapon Focus can do this, or at least in Pathfinder, but when I tried it for Improved Natural Attack I could not get it to work. So this maybe only possible with special settings in the structural files.
I opened Pathfinder and added INArmor, INAttack, and Weapon Focus.
INAttack and WF both show "-No Selection-" so they don't do what I need.

Let me try to phase it again.
I need to make an object that has a "-No Selection-" setting, but instead of being a herolab.exe "-No Selection-" it is actually another object. I need code to detect the herolab.exe "-No Selection-" (which is usrChosen1 set to 0) and if set to 0 then set it to the object instead.

The reason for this, is with my new Druid Wild Shape, if you have not made a selection you lose access to things you lose (in D20) when Wild Shaping (such as Darkvision, etc.) This is confusing to people who are not aware of why they don't have Darkvision when they should.
risner is offline   #3 Reply With Quote
risner
Senior Member
Volunteer Data File Contributor
 
Join Date: Jun 2010
Posts: 616

Old February 8th, 2011, 06:15 AM
Quote:
Originally Posted by ShadowChemosh View Post
3) We have a thread that is specifically made for bug reports it is sticked to the top of this forum.
Ok, thought so. But in another post Snowpaw asked and got directed to the HL bug report thread.
risner is offline   #4 Reply With Quote
risner
Senior Member
Volunteer Data File Contributor
 
Join Date: Jun 2010
Posts: 616

Old February 8th, 2011, 06:16 AM
Sorry about cluttering the community thread.
risner is offline   #5 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 12,606

Old February 8th, 2011, 08:13 AM
Will this work? (this example uses Cleric as the default class selection)

Code:
 
if (field[usrChosen1].ischosen = 0) then
  perform hero.childfound[cHelpClr].setfocus
else
  perform field[usrChosen1].chosen.setfocus
  endif
 
doneif (state.isfocus = 0)
 
~now do things with the class you've set the focus to.
Personally, I don't normally bother with that - HL will be reporting an error message until the user fills something into the menu, displaying that menu in red, and there's no way to go back to "-No Selection-" once you've selected something, so ischosen = 0 is a very temporary state.
Mathias is offline   #6 Reply With Quote
ShadowChemosh
Senior Member
Volunteer Data File Contributor
 
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,695

Old February 8th, 2011, 08:18 AM
Quote:
Originally Posted by risner View Post
I opened Pathfinder and added INArmor, INAttack, and Weapon Focus.
INAttack and WF both show "-No Selection-" so they don't do what I need.
Just in example if you pull up the Worg from Pathfinder it pre-sets the Skill Focus feat to Perception. In the xml you find that the feat has the tag Target.skPercep. That's the only thing I have seen that allows for pre-selection of a drop down box. Don't even know for sure it will work with a script setting it....

Will look at the rest of what you have in a bit later.

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
risner
Senior Member
Volunteer Data File Contributor
 
Join Date: Jun 2010
Posts: 616

Old February 8th, 2011, 09:33 AM
Quote:
Originally Posted by Mathias View Post
there's no way to go back to "-No Selection-" once you've selected something
That is exactly what I'm trying to avoid:
The user being set to "-No Selection-"

Because it is invalid and messes everything else up.

Specifically, I have a Class Special (cDrdWild1) that I replace.
In this Class Special, I have these settings:
Select From ... -None-
Custom Expression User.WSF?
Restrict First List To.. All Things

I have Templates all with User.WSFblah unique assignments.
I have a bootstrap for all templates in this Class Special.
A worker object looks to see what is chosen and if "-No Selection-" is chosen, it malfunctions. I have a template for "No Form" that is needed to be applied. So I need to force a choice and prevent the user from leaving a new druid in "-No Selection-" mode.

If that isn't set to "No Form" the worker object disables Darkvision and anything else gone while wild shaped.

I guess I could work around this by adding the script code from the "No Form" Special to all the 5 scripts working on the Wild Shape Worker Object?
But that is duplicating a bunch of lines of code in 5 different scripts to bail out if not set.

What I need is some way in the script to detect when not set (I have this) and then force a selection (like the Worg does with a tag) but in a script?
risner is offline   #8 Reply With Quote
risner
Senior Member
Volunteer Data File Contributor
 
Join Date: Jun 2010
Posts: 616

Old February 8th, 2011, 09:36 AM
I tried:
if (field[usrChosen1].ischosen = 0) then
perform hero.childfound[xNoForm].setfocus
endif

It still says "-No Selection-"
risner is offline   #9 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 12,606

Old February 8th, 2011, 10:54 AM
OK, you want no selection as a way to turn off the ability.

It sounds like you've already got a "no selection" special made, and you're getting errors once its selected, because it's not a template.

In that case, you'll need to make sure you've selected something, and make sure that what you've selected is a template, before you start looking up fields that will only exist on a template:

Code:
 
if (field[usrChosen1].ischosen <> 0) then
  if (field[usrChosen1].chosen.tagis[component.BaseTempl] <> 0) then
    ~apply all your effects
    endif
  endif
Mathias is offline   #10 Reply With Quote
Reply

Thread Tools
Display Modes

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 05:30 AM.


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