Lone Wolf Development Forums  

Go Back   Lone Wolf Development Forums > Hero Lab Forums > Hero Lab Discussion

Notices

Reply
 
Thread Tools Display Modes
nylanfs
Senior Member
 
Join Date: Sep 2007
Posts: 136

Old December 22nd, 2017, 08:55 AM
The back end data they have stated will be the same. Now the editor that makes that data may be different since the UI and engine that uses that data will be different.

Paul "Yes that Paul" Grosse
PCGen BoD - PR Silverback
Forums: Nylanfs (or Nylan)

Hero Lab Shadowrun 4E & 5e user
nylanfs is offline   #81 Reply With Quote
Nightfox
Senior Member
 
Join Date: Dec 2011
Posts: 100

Old December 22nd, 2017, 11:09 AM
Quote:
Originally Posted by ShadowChemosh View Post
As far I understand only UI scripts will not work in HLO. This will affect the Pathfinder Community Pack.
What are some examples of UI scripts? I have several custom data files for each campaign I've played in, ranging from items and feats, to a complex class/template addition to add an extra tab for structure without a class. Other then tricking the system into adding the extra class tab I don't think I have anything that affects the UI, but I've been wrong before. I had to rebuild most of my data files after v5 and I would prefer to isolate potential problems early this time.
Nightfox is offline   #82 Reply With Quote
ShadowChemosh
Senior Member
Volunteer Data File Contributor
 
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729

Old December 22nd, 2017, 11:20 AM
Quote:
Originally Posted by Nightfox View Post
What are some examples of UI scripts? I have several custom data files for each campaign I've played in, ranging from items and feats, to a complex class/template addition to add an extra tab for structure without a class. Other then tricking the system into adding the extra class tab I don't think I have anything that affects the UI, but I've been wrong before. I had to rebuild most of my data files after v5 and I would prefer to isolate potential problems early this time.
This is logic you would have had to create using Authoring Kit logic totally outside of the HL editor. Mostly a "tab" uses a Configurable that is again created in the editor itself. These will "should" all work without issue.

I am talking about custom UI created outside of the HL editor using raw XML in a text file:
Code:
<?xml version="1.0" encoding="UTF-8"?>
<document signature="Hero Lab Data">
<!--
  Created by: Tim Shadow
        Date: December 5, 2016

  This is a community created sheet.
-->

  <!-- Generate the text for a Maneuvers title label on the Manuevers printout -->
  <procedure id="PoWManLbl" scripttype="label"><![CDATA[
    var level as number
    var desc as string

    @text &= hero.actorname & " - Level " & level & " " & desc
    ]]></procedure>


  <!-- NOTE: The global variable pwmanout can have the following values:

      0 - output full descriptions
      1 - output summaries
  -->

  <!-- Manuever lists -->
  <portal
    id="oManTbl"
    style="outtable">
    <output_table
      component="PWManuever"
      showtemplate="oManPick"
      showpicks="yes"
      varyheight="yes"
      showsortset="SpellOut">
      <list><![CDATA[
        PathOfWar.Manuever & !Helper.Obsolete & !Helper.Helper
        ]]></list>
      </output_table>
    </portal>

  <!-- Stances lists -->
  <portal
    id="oStanceTbl"
    style="outtable">
    <output_table
      component="PWManuever"
      showtemplate="oManPick"
      showpicks="yes"
      varyheight="yes"
      showsortset="SpellOut">
      <list><![CDATA[
        PathOfWar.Stance & !Helper.Obsolete & !Helper.Helper
        ]]></list>
      </output_table>
    </portal>


  <!-- Manuever and Stances Header -->
  <template
    id="omHeader"
    name="Manuever and Stances Display Header"
    compset="Totals">

    <portal
      id="text"
      style="oNormal">
      <output_label>
        <labeltext><![CDATA[
          foreach pick in hero from PWManList
            @text = splice(@text,eachpick.field[name].text & " " & eachpick.field[cIL].value," / ")
          nexteach

          @text = splice(hero.actorname,@text,", ") 
          ~& " " & chr(150) & " Maneuvers"
          ]]></labeltext>
        </output_label>
      </portal>

    <position><![CDATA[
      perform portal[text].centerhorz
      height = portal[text].height
      ]]></position>

    </template>

  <!-- Maneuvers and Stances pick -->
  <template
    id="oManPick"
    name="Output Maneuvers and Stances Table"
    compset="PWManuever">

    <portal
      id="mName"
      style="oSplTitle">
      <output_label>
        <labeltext><![CDATA[
          @text = "{align left}{horz 15}" & tagnames[Ability.?] & " (" & tagnames[ClsCountAs.?] & ")"
          ]]></labeltext>
        </output_label>
      </portal>

    <portal
      id="mLevel"
      style="oSplTitle">
      <output_label>
        <labeltext><![CDATA[
          @text =  tagnames[mLevel.?]
          ]]></labeltext>
        </output_label>
      </portal>

    <portal
      id="mText"
      style="oSmall">
      <output_label>
        <labeltext><![CDATA[
          ~ TODO: Update this to use the new PWManSumm procedure once 
          ~       we are not updating the Thing text.
          @text = field[descript].text
          ]]></labeltext>
        </output_label>
      </portal>

    <portal
      id="mSummary"
      style="oSmall">
      <output_label>
        <labeltext><![CDATA[
          @text = field[abSumm].text
          ]]></labeltext>
        </output_label>
      </portal>

    <position><![CDATA[
      ~ The level portal has centered text, so by adding twice the padding we
      ~ want, we get a small gap at it's right-hand side, so that the number
      ~ doesn't bump right against the edge of the grey section.
      ~ The name accomplishes the same thing with a horz element, but the level
      ~ seems to be ignoring horz's and spaces at the end of the text
      portal[mLevel].width += 30
      portal[mName].width = width - portal[mLevel].width

      perform portal[mLevel].alignedge[right,0]

      if (scenevalue[pwmanout] = 1) then
        portal[mSummary].width = width
        perform portal[mSummary].autoheight
        perform portal[mSummary].alignrel[ttob,mName,10]
        height = portal[mSummary].bottom + 30
        portal[mText].visible = 0
      else
        portal[mText].width = width
        perform portal[mText].autoheight
        perform portal[mText].alignrel[ttob,mName,10]
        height = portal[mText].bottom + 30
        portal[mSummary].visible = 0
        endif
      ]]></position>
    </template>

  <layout
    id="oManeuvers">
    <portalref portal="oManTbl"/>
    <portalref portal="oStanceTbl"/>
    <position><![CDATA[
      perform portal[oManTbl].autoplace
      perform portal[oStanceTbl].autoplace
      ]]></position>
    </layout>

  <layout
    id="omHeader">
    <templateref template="omHeader" thing="Totals" ispick="yes"/>
    <position><![CDATA[
      template[omHeader].width = width
      perform template[omHeader].render
      height = template[omHeader].bottom
      ]]></position>
    </layout>

  <sheet
    id="shPWManDes"
    name="Maneuvers Sheet (Description)"
    spillover="yes">
    <layoutref layout="oManeuvers" reference="left"/>
    <layoutref layout="oManeuvers" reference="right"/>
    <layoutref layout="omHeader"/>
    <position><![CDATA[
      ~ Set our global variable to 'output description'
      scenevalue[pwmanout] = 0

      ~ Setup the gap to be used between the various sections of the character sheet
      autogap = 40
      scenevalue[sectiongap] = autogap

      layout[omHeader].width = width
      perform layout[omHeader].render

      layout[left].top = layout[omHeader].bottom + 40
      layout[right].top = layout[omHeader].bottom + 40

      ~ Calculate the width of the two columns of the character sheet, leaving a
      ~ Suitable center gap between them
      var colwidth as number
      colwidth = (width - 50) / 2

      ~ Output the layout on the lefthand side with whatever information will fit
      layout[left].width = colwidth
      layout[left].height = height - layout[left].top
      perform layout[left].render

      ~ Output the layout on the righthand side with whatever information will fit
      layout[right].width = colwidth
      layout[right].height = height - layout[right].top
      layout[right].left = width - colwidth
      perform layout[right].render
      ]]></position>
    </sheet>

  <sheet
    id="shPWManSum"
    name="Maneuvers Sheet (Summaries)"
    spillover="yes">
    <layoutref layout="oManeuvers" reference="left"/>
    <layoutref layout="oManeuvers" reference="right"/>
    <layoutref layout="omHeader"/>
    <position><![CDATA[
      ~ Set our global variable to 'output summaries'
      scenevalue[pwmanout] = 1

      ~setup the gap to be used between the various sections of the character sheet
      autogap = 40
      scenevalue[sectiongap] = autogap

      layout[omHeader].width = width
      perform layout[omHeader].render

      layout[left].top = layout[omHeader].bottom + 40
      layout[right].top = layout[omHeader].bottom + 40

      ~ Calculate the width of the two columns of the character sheet, leaving a
      ~ suitable center gap between them
      var colwidth as number
      colwidth = (width - 50) / 2

      ~ Output the layout on the lefthand side with whatever information will fit
      layout[left].width = colwidth
      layout[left].height = height - layout[left].top
      perform layout[left].render

      ~ Output the layout on the righthand side with whatever information will fit
      layout[right].width = colwidth
      layout[right].height = height - layout[right].top
      layout[right].left = width - colwidth
      perform layout[right].render
      ]]></position>
    </sheet>

  </document>
From what I have been told if you have stuff like above, which I can only think of one other person that does, we will have to re-write this for HLO.

One of the reasons I have been holding off doing a big fix for Path of War is I am hoping to only have to write the new UI tab one time.

Trust me when I say you will remember writing UI for HLC because well it SUCKS! I love HL but the UI scripts are really PITA to work with.

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   #83 Reply With Quote
Ian
Senior Member
 
Join Date: May 2017
Posts: 135

Old December 24th, 2017, 06:00 PM
Quote:
Originally Posted by ShadowChemosh View Post
One of the reasons I have been holding off doing a big fix for Path of War is I am hoping to only have to write the new UI tab one time.
One thing to keep in mind here is that we don't have a projected date as to when we'll have this stuff available for third-party devs to work with, so you shouldn't hinge too heavily on expecting it to happen in a useful timeframe. The actual work involved with the HLO templating is much less than with current HL, though, so any "conversion" stuff later from existing HL script should be fairly straightforward once you get the gist of it.

Here's a quick, rough idea of the kind of thing it will look like. All subject to change, some of the stuff here isn't what we're currently doing, etc, but this is generally similar to what the current UI templates for HLO look like.

Code:
// locales/en-US/maneuvers.json
{
  "oManTbl": "Maneuvers",
  "oStanceTbl": "Stances"
}

// templates/manuevers.xml
<?xml version="1.0" encoding="UTF-8"?>
<LayoutContainer>
  <Iterate tagGroup="PWManList">
    <Text align="center">
      {~livename} {~textKey oManTbl} ({~field cIL})
    </Text>
    <LayoutContainer direction="horizontal">
      <Iterate tableIds="oManTbl, oStanceTbl">
        <SheetTable groupByTag="sLevel">
          <template:item>
            <TableCell align="left">
              {~tags Ability} ({~tags ClsCountAs})
            </TableCell>
            <TableCell>{~tags mLevel}</TableCell>
            <TableCell>{~field abSumm}</TableCell>
          </template:item>
        </SheetTable>
      </Iterate>
    </LayoutContainer>
  </Iterate>
</LayoutContainer>
This would result in an arrangement with a "(whatever) Maneuvers (CL X)" header above two tables (arranged in a horizontal split on a large screen or sequentially on a small screen), each of which would have the appropriate header (automatically sourced from the file in the locales folder) and, for each pick, tag names for the ability and its level and the text of the ability summary field. No need to specify layout details, deal with text vs number field details, manually assemble string labels, etc.

The idea is to have something with easy text handling, declarative- rather than imperative-oriented, with minimal hassle dealing with loops and tables, and with anything beyond minimal layout control neither allowed nor needed (because of the need to reflow everything to fit on different screen sizes).

Last edited by Ian; December 24th, 2017 at 06:03 PM.
Ian is offline   #84 Reply With Quote
ShadowChemosh
Senior Member
Volunteer Data File Contributor
 
Join Date: Jan 2010
Location: Chicago, IL (USA)
Posts: 10,729

Old January 2nd, 2018, 10:05 AM
Quote:
Originally Posted by Ian View Post
One thing to keep in mind here is that we don't have a projected date as to when we'll have this stuff available for third-party devs to work with, so you shouldn't hinge too heavily on expecting it to happen in a useful timeframe. The actual work involved with the HLO templating is much less than with current HL, though, so any "conversion" stuff later from existing HL script should be fairly straightforward once you get the gist of it.
I guess I was hoping HL would get to the point where two different UI's would not be needed. With limited time I would really like to just write a UI once and use in both HLC/HLO but it sounds like that is not anytime soon.

Quote:
Originally Posted by Ian View Post
Here's a quick, rough idea of the kind of thing it will look like. All subject to change, some of the stuff here isn't what we're currently doing, etc, but this is generally similar to what the current UI templates for HLO look like.

Code:
// locales/en-US/maneuvers.json
{
  "oManTbl": "Maneuvers",
  "oStanceTbl": "Stances"
}

// templates/manuevers.xml
<?xml version="1.0" encoding="UTF-8"?>
<LayoutContainer>
  <Iterate tagGroup="PWManList">
    <Text align="center">
      {~livename} {~textKey oManTbl} ({~field cIL})
    </Text>
    <LayoutContainer direction="horizontal">
      <Iterate tableIds="oManTbl, oStanceTbl">
        <SheetTable groupByTag="sLevel">
          <template:item>
            <TableCell align="left">
              {~tags Ability} ({~tags ClsCountAs})
            </TableCell>
            <TableCell>{~tags mLevel}</TableCell>
            <TableCell>{~field abSumm}</TableCell>
          </template:item>
        </SheetTable>
      </Iterate>
    </LayoutContainer>
  </Iterate>
</LayoutContainer>
This would result in an arrangement with a "(whatever) Maneuvers (CL X)" header above two tables (arranged in a horizontal split on a large screen or sequentially on a small screen), each of which would have the appropriate header (automatically sourced from the file in the locales folder) and, for each pick, tag names for the ability and its level and the text of the ability summary field. No need to specify layout details, deal with text vs number field details, manually assemble string labels, etc.

The idea is to have something with easy text handling, declarative- rather than imperative-oriented, with minimal hassle dealing with loops and tables, and with anything beyond minimal layout control neither allowed nor needed (because of the need to reflow everything to fit on different screen sizes).
[/QUOTE]
Thanks! The above looks much more like normal HTML in many ways which would make doing the UI stuff allot faster/easier for me.

Maybe I won't wait and will do the stuff now..... Appreciate the info...

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   #85 Reply With Quote
Ian
Senior Member
 
Join Date: May 2017
Posts: 135

Old January 4th, 2018, 10:35 AM
Quote:
Originally Posted by ShadowChemosh View Post
I guess I was hoping HL would get to the point where two different UI's would not be needed. With limited time I would really like to just write a UI once and use in both HLC/HLO but it sounds like that is not anytime soon.
There's an extremely distant chance it might happen someday, but the basic limitations of web stuff (layout on extremely varying screen sizes, the language in use, etc) mean that all the internals of what we're doing for the web UI are hugely, drastically different in every way from the internals of the desktop UI.
Ian is offline   #86 Reply With Quote
Warwolf
Junior Member
 
Join Date: Jul 2018
Posts: 2

Old July 18th, 2018, 03:03 PM
I am new to Hero Lab and I am very curious as to which version I should get. It sounds almost like I would need to get a version that is purely for online use to be able to do anything with it. I am not always able to be online though— that or just not being in the mood to be— so is there a version I can use that has full functionality offline or what?
Warwolf is offline   #87 Reply With Quote
Parody
Senior Member
 
Join Date: Jan 2013
Location: Rochester, MN
Posts: 1,515

Old July 19th, 2018, 07:46 AM
Quote:
Originally Posted by Warwolf View Post
I am new to Hero Lab and I am very curious as to which version I should get. It sounds almost like I would need to get a version that is purely for online use to be able to do anything with it. I am not always able to be online though— that or just not being in the mood to be— so is there a version I can use that has full functionality offline or what?
Right now it's pretty simple: if you want Starfinder, get Hero Lab Online. If you want any other system, get Classic.

Parody is offline   #88 Reply With Quote
Warwolf
Junior Member
 
Join Date: Jul 2018
Posts: 2

Old July 19th, 2018, 10:05 AM
Quote:
Originally Posted by Parody View Post
Right now it's pretty simple: if you want Starfinder, get Hero Lab Online. If you want any other system, get Classic.
Is Classic a fully usable version for offline use?
Warwolf is offline   #89 Reply With Quote
Farling
Senior Member
 
Join Date: Mar 2013
Location: Greater London, UK
Posts: 2,623

Old July 19th, 2018, 12:55 PM
Quote:
Originally Posted by Parody View Post
Right now it's pretty simple: if you want Starfinder, get Hero Lab Online. If you want any other system, get Classic.
If you want Pathfinder 2nd edition playtest/beta, that'll be Online soon(ish).

Farling

Author of the Realm Works Import tool, Realm Works Output tool and Realm Works to Foundry module

Donations gratefully received via Patreon, Ko-Fi or Paypal
Farling is offline   #90 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 11:28 PM.


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