• Please note: In an effort to ensure that all of our users feel welcome on our forums, we’ve updated our forum rules. You can review the updated rules here: http://forums.wolflair.com/showthread.php?t=5528.

    If a fellow Community member is not following the forum rules, please report the post by clicking the Report button (the red yield sign on the left) located on every post. This will notify the moderators directly. If you have any questions about these new rules, please contact support@wolflair.com.

    - The Lone Wolf Development Team

Fate Core - Use Gizmos for this?

TCArknight

Well-known member
Howdy!

I am hoping the responses to this post will not only help me, but anyone else working with gizmos, etc....

In the past, I've worked with gizmos a bit when creating gadgets for a DWAITAS custom dataset. That seemed a bit simpler though than what I'm attempting now.

In the dataset I'm working on, each character has 1 (or rarely 2) groups of Stunt-like abilities. Each of these abilities (a Talent for this clarification) can have 0 or more Additions which improve some kind of mechanic in the Talent. The Group also has at least 2 but possibly more FX types (each more than 2 costs a Stunt). A Group also has 1 Disad and 1 'Surroundings' Ability that allows for unusual ability (outside of the normal ones contained in the Group) while causing possible damage or difficulties for the area around him.

In summary:
Code:
Group
|- 1 or more Ability (cost as stunt) 
|   \_ 0 or more Enhancement (to the ability) (cost as stunt)
|- 2 or more FX ( each more than 2 costs as stunt)
|- 1 Disad
|- 1 Surroundings effect

My thought on how to do this is with the Group as a basic component with fields such as name, description, etc. The Ability, Enhancement, FX, Disad and Surroundings would each be a separate Gizmo attached to the Group thing. The Ability, Enhancement and FX would be built above a Stunt component while Disad and Environment would be their own separate components. The corresponding Tab portal would allow to Add a group, most likely A custom one but allowing for pre-defined ones as well.

1) is this a workable concept or is there a simpler way than gizmos?
2) assuming gizmos, is there a way to add the chooser for the actual gizmo in a way similar to the Ranger Favored Enemy/Terrain, Ranger Combat Style etc.? (What kind of portals are those?)
3) is there a way to add new Helper.XX tags or is the best way to create ones specific to the dataset?
4) Any Fate Core specific shortcuts, macros etc that would make things simpler?

All thoughts and comments welcome. :)
TC
 
I'm not familiar with the details of fate core, but in terms of using gizmos, this does sound like something that can be built with gizmos - like the custom powers in Mutants & Masterminds or a spell with metamagics in Pathfinder/d20.

If you wanted to avoid gizmos, it's probably do-able - there'd be separate tables for the various categories of things you can add, like an abilities table, an FX table, a disad table, etc., and then each of those selections would have a drop-down to let you select which group you wanted to apply that one to.

I can't help with #3 or #4 without taking a long time to study fate core, and I don't have that time right now. For #2, could you please clarify this? I'm not sure how favored enemies relate to the abilities you're talking about adding.
 
Thanks Mathias, this sounds like I'm on the right track.

Regarding #2, the way to engage the editing of the gizmo, that I'm familiar with and have seen, is an edit button (with the wrench image, etc).

When selecting the class special abilities in Pathfinder, the selector is the width of the entire panel and with text instead of an icon. I'm thinking this is just a variation on the edit portal, but I'm not sure...

Does that help?
 
The data file author has complete control about how to set up a pick template, which is how you define what you want the display to look like for an item in this table - it's your choice where to put the edit control, where to put the name, what else to put there, whatever.
 
Thanks for the help Mathias. :) A couple of follow ups:

1) the only examples for triggering the gizmo form that I've been able to find are using the edit portal with the the icon. Can you point me to an example doing it with a different portal?

2) Can a gizmo have a gizmo? If so, would parent.parent.field[descript].text &= field[myDesc].text be the way to append the gizmo1 gizmo's text in that field to gizmo1's parent description field?
 
1) If you want the user to be able to open a form to edit the gizmo, it must be an edit portal. But you're the data file author. You have control over what image is used as the display for that portal.

2) The picks in a gizmo can have their own gizmos, but a gizmo is just a container. It cannot have the same things picks can have, like gizmos.

Yes, parent.parent is code you can end up using in Shadowrun, where you can modify the mods of an item. But the descript field is usually read-only, and you shouldn't be trying to change it this way. I'd prefer that you describe what you're trying to accomplish, rather than just posting code without context.
 
Ah, ok. So I can create a bitmap that resembles standard look of a choser or additem button (from a dynamic table) but I still have to use a edit portal.
Sorry, that code was off the top of my head for an example. This is a procedure I'm using to display the combined descriptions of all gizmos on a label.

The eachpick in the current foreach loop is to get to the Power. The Power would then have a gizmo itself that I would need to grab the description from.

Code:
  <procedure id="PwrInfo" context="pick"><![CDATA[
    ~declare variables that are used to communicate with our caller
    var spacing as string
    var infotext as string
    var test as string
    var thisGiz as string
    var lastGiz as string
    var myDesc as string
    
    test = field[name].text
    notify test
    
    ~start with left-aligned text and append the descriptions
    infotext = "{align left}"
    myDesc = ""
    
    ~if (length(test) > 0) then
      
      infotext &= "{br}" & "{br}"
      infotext &= "{i}Power Breakdown"
      
      foreach pick in gizmo where "component.vcPower"
	        thisGiz = eachpick.field[name].text
            myDesc &= eachpick.field[descript].text
            
	        notify thisGiz
	        myDesc &= " "
	        
	        if (compare(thisGiz,lastGiz) = 0) then
	          infotext &= " x2"
	        else 
	          infotext &= "{br}  * " & thisGiz
	          endif
	          
	        lastGiz = thisGiz
	        nexteach
      infotext &= "{/i}{br}{br}"
      myDesc &= infotext
      infotext = myDesc
      ~endif

    ]]></procedure>
 
First, a code fix:

Code:
foreach pick in gizmo from vcPower
Then, inside your foreach, you would nest a second foreach to search through the picks inside the gizmo of that pick:

Code:
if (eachpick.isgizmo <> 0) then
  foreach pick in eachpick.gizmo from WHATEVERCOMPONENT where "WHATEVER.TAGEXPRESSION"
    nexteach
  endif
 
1) Huh? Why would you want an Add button showing on the display once the user's added the item? That won't look like anything else in Hero Lab.
 
First, a code fix:

Code:
foreach pick in gizmo from vcPower
Then, inside your foreach, you would nest a second foreach to search through the picks inside the gizmo of that pick:

Code:
if (eachpick.isgizmo <> 0) then
  foreach pick in eachpick.gizmo from WHATEVERCOMPONENT where "WHATEVER.TAGEXPRESSION"
    nexteach
  endif

Thanks Mathias! That's working exactly as I need it. I see what you mean about the Add button too, so I will consider the options...
 
Ok, I've got the Ability and Enhance working as I expected.

I expected to have the Suite have several gizmos, but when I add a second child to the Suite, I get:
Hero Lab was forced to stop compilation after the following errors were detected:

File: thing_abilities.dat (line 18) - Child element 'child' appears more times than its limit (1) in 'thing'

Am I looking at this the wrong way?
 
That's a limit that won't be expanded. You're going to need to rethink your project to all work from a single gizmo for each pick.
 
Ok, I figured out a way to do this.

The overall Suite will consist of several separate components (Power, Special Effect (SpecEff), Drawback and Collateral Effect (CollEff)). I've set up a sortset for them in a control.1st file:
Code:
  <!-- Define a sortset for showing Power Components -->
  <sortset
    id="PowerComp"
    name="Power Components By Type and Name">
    <sortkey isfield="no" id="Power"/>
    <sortkey isfield="no" id="SpecEff"/>
    <sortkey isfield="no" id="explicit"/>
    <sortkey isfield="no" id="_Name_"/>
    </sortset>

in Tags.1st:
Code:
  <!-- PowerComp group - Power Components
  -->
  <group
    id="PowerComp"
    dynamic="no"
    sequence="explicit">
    <value id="Power" order="10"/>
    <value id="SpecEff" order="20"/>
    <value id="Drawback" order="30"/>
    <value id="CollEff" order="40"/>
    </group>

The things:
Code:
  <!-- Separator Components -->
  <thing
    id="SepPower"
    name="- Powers -"
    compset="Power"
    isshowonly="yes"
    description="">
    </thing>

  <thing
    id="SepSpecEff"
    name="- Special Effects -"
    compset="SpecEff"
    isshowonly="yes"
    description="">
    </thing>
  <!-- Powers -->    
  <thing
    id="pwrFlight"
    name="Flight"
    compset="Power"
    isunique="yes"
    description="You can move vertically through the air as easily as moving along the ground. Use Athletics to overcome obstacles or create advantages related to flying.">
    </thing>

  <!-- Special Effects -->        
  <thing
    id="sfxForMov"
    name="Forced Movement"
    compset="SpecEff"
    isunique="yes"
    description="You move your target up to two zones.">
    <tag group="Power" tag="NoDesc"/>
    </thing>         
    
  <thing
    id="sfxAreaAtt"
    name="Area Attack"
    compset="SpecEff"
    isunique="yes"
    description="Attack everyone in a zone.">
    <tag group="Power" tag="NoDesc"/>
    </thing>

I have a dynamic table with
Code:
choosesortset="PowerComp"
.

However, when the table is displayed, I get:
Code:
- Powers -
Flight
Area Attack
Forced Movement

The items themselves are displayed in the order I would expect, however the - Special Effects - separator isn't displayed.

Also, if I have
Code:
showsortset="PowerComp"
with a couple of other powers, I get:
Code:
Power 1
Power 2
Spec Eff 1
Spec Eff 2
Power 3

Am I missing something?
 
Your sortset starts with the Power group. Forced Movement and Area Attack both have Power.NoDesc, but none of your other example powers have any Power tags. That means those two powers will always sort before all the other powers you've listed - things lacking a tag in the group will always sort after anything with a tag from that group. There must be a Power tag assigned as part of a component, in order for Flight to sort before them.

You also don't list your Power group's definition, so I can't see what sort order you've set up for that group.

By the Ids, I'd think that you had intended for your PowerComp tag group to go in the PowerComp sortset, but it's not part of that.
 
Your sortset starts with the Power group. Forced Movement and Area Attack both have Power.NoDesc, but none of your other example powers have any Power tags. That means those two powers will always sort before all the other powers you've listed - things lacking a tag in the group will always sort after anything with a tag from that group. There must be a Power tag assigned as part of a component, in order for Flight to sort before them.

You also don't list your Power group's definition, so I can't see what sort order you've set up for that group.

By the Ids, I'd think that you had intended for your PowerComp tag group to go in the PowerComp sortset, but it's not part of that.
Ahha! So the ids used in the sortset should be a specific tag group, and not the components, right? :)

I changed some stuff around:
Code:
  <sortset
    id="PowerComp"
    name="Power Components By Type and Name">
    <sortkey isfield="no" id="PowerComp"/>
    <sortkey isfield="no" id="_Name_"/>
    </sortset>
tags:
Code:
  <group
    id="PowerComp"
    dynamic="yes"
    sequence="explicit">
    <value id="Power" order="10"/>
    <value id="SpecEff" order="20"/>
    <value id="Drawback" order="30"/>
    <value id="CollEff" order="40"/>
    </group>
changing the sortset to be PowerComp instead, the display on the showsortset="PowerComp" works correctly with it displaying as:
Power 1
Power 2
Power 3
Special Effect 1
Special Effect 2

However, I'm still having an issue on the choose form with it displaying as:
Code:
-- Special Effects --
Special Effect 1 (Area Attack)
Flight
Special Effect 2 (Forced Movement)
Special Effect 3 (Inflict Condition)
They are in alpha order, but also missing the Power seperator...
(I planned to see:
Code:
-- Powers --
Flight
-- Special Effects --
Area Attack
Forced Movement
Inflict Condition
)
the form:
Code:
  <portal
    id="prtPower"
    style="tblInvis">
    <table_dynamic
      component="PowerComp"
      showtemplate="tmpShowPwr"
      showsortset="PowerComp"
      choosetemplate="tmpPickPwr"
      choosesortset="PowerComp"
      scrollable="yes"
      alwaysupdate="yes"
      candidatepick="PwrHelper"
      candidatefield="PowerExpr"
      addpick="PwrHelper"
      headerpick="PwrHelper">
      <headertitle>
        @text = "Select Power Components"
        </headertitle>
      <additem><![CDATA[
        @text = "Add Power Component"
        ]]>
        </additem>
      </table_dynamic>      
    </portal>

The tmpShowPwr and tmpPickPwr are:
Code:
  <template
    id="tmpPickPwr"
    name="Power Pick"
    compset="PowerComp"
    marginhorz="3"
    marginvert="1">
...
    </template>
    
  <template
    id="tmpShowPwr"
    name="Power Show"
    compset="PowerComp"
    marginhorz="3"
    marginvert="1">
...
    </template>
compsets:
Code:
  <!-- Suite - all power suites derive from this compset -->
  <compset
    id="vcSuite">
    <compref component="vcSuite"/>
    <compref component="Domain"/>
    <compref component="CanAdvance"/>
    </compset>
    
  <!-- Power - all powers derive from this compset -->
  <compset
    id="Power">
    <compref component="vcPower"/>
    <compref component="xTracker"/>
    <compref component="PowerComp"/>
    <compref component="Domain"/>
    <compref component="Custom"/>
    </compset>
    
  <compset
    id="Enhance">
    <compref component="vcEnhance"/>
    <compref component="xTracker"/>
    <compref component="Domain"/>
    <compref component="Custom"/>
    </compset>

    
  <compset
    id="SpecEff">
    <compref component="vcSpecEff"/>
    <compref component="xTracker"/>
    <compref component="PowerComp"/>
    <compref component="Domain"/>
    <compref component="Custom"/>
    </compset>
    
  <compset
    id="PowerComp">
    <compref component="PowerComp"/>
    <compref component="Domain"/>
    <compref component="Custom"/>
    </compset>

Does that help or should I go ahead and attach my files to see where I'm missing it?
 
Last edited:
I need to see the definitions of the 6 items you've listed, or if your PowerComp tags are being assigned in the components, not on the individual things, show me how those are being assigned.
 
In the component definition:
Code:
  <component
    id="vcPower"
    name="Power"
    autocompset="no"
    addbehavior="customize">
    
    <field
      id="pwrDesc"
      name="Power Description"
      type="derived"
      maxlength="1000">
      </field>
          
    <field
      id="Value1"
      name="Value 1"
      type="derived"
      defvalue="0">
      </field>
    
    <field
      id="Value2"
      name="Value 2"
      type="derived"
      defvalue="0">
      </field>
            
    <!-- Each skill needs its own identity tag so existing skills can be identified during advancement -->
    <identity group="Power"/>
    <identity group="HasPower"/>
    <identity group="Enhance"/>

[B]    <tag group="PowerComp" tag="Power"/>[/B]

    </component>
     
  <!-- vcSpecEff component
        Each Special Effect derives from this component
  -->
  <component
    id="vcSpecEff"
    name="Special Effect"
    autocompset="no"
    addbehavior="customize">

    <field
      id="sfxDesc"
      name="Enhancement Description"
      type="derived"
      maxlength="1000">
      </field>
          
    <field
      id="sfxValue1"
      name="Value 1"
      type="derived"
      defvalue="0">
      </field>
    
    <field
      id="sfxValue2"
      name="Value 2"
      type="derived"
      defvalue="0">
      </field>
            
    <!-- Each Special Effect needs its own identity tag so existing SpecEffs can be identified during advancement -->
    <identity group="HasSFX"/>

[B]    <tag group="PowerComp" tag="SpecEff"/>[/B]
    </component>
 
Does the PowerComp component have its own PowerComp tag?

You've double-checked the compsets that each of those things were built with?

Try adding several abilities from that table, and debug their tags - make sure there's only one PowerComp tag on each.
 
Thank you!!

The issue was that I had an identity tag on the PowerCOmp component itself. I removed that and the Chose display is as I planned it.

I really appreciate the help!
 
Back
Top