Lone Wolf Development Forums  

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

Notices

Reply
 
Thread Tools Display Modes
barrelv
Member
 
Join Date: Aug 2014
Posts: 87

Old October 14th, 2014, 06:26 AM
I'm getting this error message:

Portal 'caSkills' - Candidate field 'acCrSkills' must be text field.

Here's the code for that field

Code:
    <field
      id="acCrSkills"
      name="Career Skills"
      type="derived"
      defvalue="Skill.skForgery">
      </field>
Do I need to do something special to designate a field as text? I'm not seeing that anywhere in the wiki page for Field Elements.
barrelv is offline   #1 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 13,213

Old October 14th, 2014, 07:05 AM
Read the description for the "maxlength" attribute. That tells you how to change between a value field and a text field.

Based on the defvalue you're setting, why store this information as a field? Why not store it as a tag?
Mathias is offline   #2 Reply With Quote
barrelv
Member
 
Join Date: Aug 2014
Posts: 87

Old October 14th, 2014, 07:26 AM
I was on the way to delete this post since I just found that part about non-zero length

I'm trying to build a chooser that only has a small number of skills on it. This is back to my whole 'trying to let careers pick their starting skills' thing.
barrelv is offline   #3 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 13,213

Old October 14th, 2014, 07:33 AM
If I were building a chooser that only offered a small number of skills to choose from, I'd create an identity tag group on the skill component to use for this, and then place those identity tags on the career things.

Then, use a script on the Career component to fill in a text field, rather than making whomever's building the careers remember the Ids and write them out manually.

Last edited by Mathias; October 14th, 2014 at 08:47 AM. Reason: corrected a typo
Mathias is offline   #4 Reply With Quote
barrelv
Member
 
Join Date: Aug 2014
Posts: 87

Old October 14th, 2014, 08:41 AM
Quote:
Originally Posted by Mathias View Post
If I were building a chooser that only offered a small number of skills to choose from, I'd create and identity tag group on the skill component to use for this, and then place those identity tags on the career things.

Then, use a script on the Career component to fill in a text field, rather than making whomever's building the careers remember the Ids and write them out manually.
This is probably a better idea...
barrelv is offline   #5 Reply With Quote
barrelv
Member
 
Join Date: Aug 2014
Posts: 87

Old October 14th, 2014, 10:46 AM
I'm having a bit of problem here. I can get my identity tag on the Career container, but I can't get the NEEDTAG part to reference it. It's saying nothing's found, but I can right-click and have it show the tags and see there are tags for CareerSkl1.

From the Career
Code:
  <!-- Tag all the skills that this career can choose from--> 
  <tag group="CareerSkl1" tag="skPistol"/>
  <tag group="CareerSkl1" tag="skHandW"/>
On the tab
Code:
  <portal
    id="crSkPick1"
    style="chsNormal">
    <chooser_table
      component="Skill"
      choosetemplate="LargeItem">
      <needtag container="Career" thing="CareerSkl1"></needtag>
      <chosen><![CDATA[
        if (@ispick = 0) then
          @text = "{text clrwarning}Select Skill"
        else
          @text = field[name].text
          endif
        ]]></chosen>
      <titlebar><![CDATA[
        @text = "Choose the Skill for your career"
        ]]></titlebar>
      </chooser_table>
    </portal>
barrelv is offline   #6 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 13,213

Old October 14th, 2014, 12:00 PM
This portal's container is the hero, not the career, so you'll need to copy the tags from the career to the hero before needtag can be used.
Mathias is offline   #7 Reply With Quote
barrelv
Member
 
Join Date: Aug 2014
Posts: 87

Old October 14th, 2014, 12:05 PM
hmmm. then I might have an issue. There are multiple careers, each with their own selections. The chooser_table would need to be unique to that career. Or at least have its options unique to that career.

Last edited by barrelv; October 14th, 2014 at 12:22 PM. Reason: clarity
barrelv is offline   #8 Reply With Quote
Mathias
Senior Member
Lone Wolf Staff
 
Join Date: May 2005
Posts: 13,213

Old October 14th, 2014, 01:07 PM
In that case, needtag isn't going to be an option in this case. You'll need candidate expressions.
Mathias is offline   #9 Reply With Quote
barrelv
Member
 
Join Date: Aug 2014
Posts: 87

Old October 14th, 2014, 05:16 PM
Going in circles

so this is where I started today, but I ran into errors. Those errors eventually led me to Needtag. Are there any examples of using Candidates?
barrelv is offline   #10 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 05:24 AM.


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