PDA

View Full Version : Ref'Manual changes in 3.3.2.



celestian
September 26th, 2017, 07:01
So I noticed that in the PHB ref manual we now have the left/right and up arrows. Saw it during the vid for 3.3.2... I had just assumed it was a feature hooked into all ref manuals but when I loaded up another it did not.

Is there docs on this new method? I'm sure there is I just missed it and apologize.

damned
September 26th, 2017, 09:16
Its not for Reference Manuals - its for Story Entries and the Up Arrow requires you to have an entry called (Index) or (Contents)

Zacchaeus
September 26th, 2017, 10:45
Its not for Reference Manuals - its for Story Entries and the Up Arrow requires you to have an entry called (Index) or (Contents)

This is what you get for disappearing for months :)

Yes, 3.2.2 added the previous and next buttons to refmanuals as well (but not the up arrow).

@Celestian this should work on all core ruleset based systems I believe. Can you say which refmanuals you are seeing that don't have the feature?

damned
September 26th, 2017, 10:47
This is what you get for disappearing for months :)

Yes, 3.2.2 added the previous and next buttons to refmanuals as well (but not the up arrow).

@Celestian this should work on all core ruleset based systems I believe. Can you say which refmanuals you are seeing that don't have the feature?

I might have to go away again ya smelly haggis!
Tell me how I add these to the Call of Cthulhu reference manuals oh wise one.

Zacchaeus
September 26th, 2017, 10:53
I might have to go away again ya smelly haggis!
Tell me how I add these to the Call of Cthulhu reference manuals oh wise one.

Well as you know I have no coding knowledge so I just load up the text file in par5e and it just happens :)
I think you may need the #v2; tag at the top of the referencemanual.txt file

Some discussion in the test release thread here (https://www.fantasygrounds.com/forums/showthread.php?39182-Test-Release-v3-3-2&p=346519&viewfull=1#post346519), but probably not enough detail for you.

Talyn
September 26th, 2017, 13:09
It's automated, there's nothing special you need to do. It's not like Story where you need either a (Contents) or (Index) page. Having said that, there was an issue during the test phase where it wouldn't pick certain manuals up. I think it had to do with either what data node your entire refmanual was stored under, or possibly just where you stored your index data. JPG patched it and it's been fine for every manual I've used the past couple months, but I just double-checked Nickademus' Unearthed Arcana (because he keeps his index data in an odd place, but that shouldn't matter ideally) and it doesn't work on that one.

madman
September 26th, 2017, 13:17
I have looked over all the reference manuals that I have done. None of them have the nav. arrows.
If we are not using par5e, what do we need to add to have them?

Madman..

Talyn
September 26th, 2017, 13:26
You commented as I was editing mine about UA, @madman. May I ask which data node(s) you normally store your reference manuals?

PAR5E used reference.refmanualdata (for the content parts) and reference.refmanualindex (for the index/nav data).
Most of us hand-coders have settled on reference.referencemanual (combine index and content in one entry to cut down the amount of markup and eliminate the scrolling back and forth) here lately, and I can confirm that works fine in everyone's I've checked.

FG itself doesn't care where anything is stored; as long as the index data is pointing to the correct content FG will render it, so not sure why the nav button functionality is so finicky. Yesterday while revamping Lankhmar I even had two reference manuals (the original using the PAR5E node names because I didn't know better, plus my remaster using reference.referencemanual) and they both worked fine and they both had nav buttons.

@damned I just checked your 7E and CoM manuals; the nav buttons work as advertised for yours.

Moon Wizard
September 26th, 2017, 13:59
The index button at the bottom of the reference manual requires a reference page with a name that contains "(contents)" or "(index)". It's not case sensitive.

The code is in manager_referencemanual.lua in CoreRPG.

Cheers,
JPG

celestian
September 26th, 2017, 15:06
This is what you get for disappearing for months :)

Yes, 3.2.2 added the previous and next buttons to refmanuals as well (but not the up arrow).

@Celestian this should work on all core ruleset based systems I believe. Can you say which refmanuals you are seeing that don't have the feature?

Oh, it was my own. I wanted to add them to mine.

I'm still not clear on where the index/contents bits need to be for this to work. Is there a ref manual somewhere I can look at for this?

Talyn
September 26th, 2017, 16:03
The index button at the bottom of the reference manual requires a reference page with a name that contains "(contents)" or "(index)". It's not case sensitive.

The code is in manager_referencemanual.lua in CoreRPG.

Cheers,
JPG

Not a single one of the manuals I have with working nav buttons have those names anywhere...

Note: please don't "fix" it to force those names, which would break every reference manual out there, not to mention uglify the manuals. It's one thing in Story where (Contents) sets itself apart visually for the GM as well as functioning for the nav buttons but that is aesthetically unnecessary in a manual.

damned
September 26th, 2017, 17:49
Hi Talyn can you post a screenie? I cant seem to see it...

Trenloe
September 26th, 2017, 17:58
I cant seem to see it...
You need to select one of the subsections to see the right/left arrows, e.g. select the "About" subsection in the Call of Cthulhu 7e module reference manual.

Talyn
September 26th, 2017, 18:00
@damned Disregard (maybe?), I think @MoonWizard is talking about the "up arrow" button, which indeed does not appear in a reference manual unless you have a (Contents) or (Index) page. Which I'm perfectly fine with, we have an entire index column to click, I don't see a need to add an extra page just to get the index "up arrow" button.

My bad for not paying attention to when you asked about the "up arrow" the first time. Not paying attention is kinda my thing, thought you knew that by now! :p

Both your 7E and CoM manuals have the left/right arrows, though; you're seeing those, right?

Nickademus
September 26th, 2017, 18:19
...but I just double-checked Nickademus' Unearthed Arcana (because he keeps his index data in an odd place, but that shouldn't matter ideally) and it doesn't work on that one.

The UA module isn't a book where you would flip through from page to page, nor do I feel an index page is needed as there is an index to the left of the page already. I could modify the UA article to have the buttons, but I doubt anyone would use them. Honestly, I doubt anyone uses the reference manual in that module at all now that there are masterindex lists that pull out the module content out.

Talyn
September 26th, 2017, 18:54
I only mentioned UA because it doesn't have the left/right button either, and I don't know why. Not that it's necessary at all, like you say, just not seeing a reason for it to not be working.

Nickademus
September 26th, 2017, 21:38
It doesn't have the left and right buttons because I don't use the default naming mechanism (id-00001, id-00002, etc.) so FG can't figure out the order of the pages.

Talyn
September 26th, 2017, 22:01
I don't use that either... I've looked over your markup and I'm not seeing a reason it's not working.

Moon Wizard
September 26th, 2017, 22:22
If someone can send me a download link to [email protected] for a module that doesn’t have the arrows, I can tell you why.

Most likely, it will be because the data path for your manual data does not match the expected data path in ReferenceManualManager script. Since the data within FG data files has no inherent meaning, the only way to determine the intent of the record to display using a data path.

Cheers,
JPG

Moon Wizard
September 26th, 2017, 23:18
celestian just sent me an example.

In the module he built, the navigation buttons aren't showing up because the reference page data is separate from the navigation data.

In the wiki page example on the developer wiki (https://www.fantasygrounds.com/wiki/index.php/Reference_Manuals), the page data needs to be inline in order for the individual articles to be able to determine chapter groupings. The ReferenceManualManager code does this by looking at the article path. Remember that the reference manual manager allows navigation even when the windows are popped out and stored on the hot bar, so we can't rely on the "reference manual" window with the navigation sidebar to exist.

There is one exception built into the code to support Par5E modules. This means that the "path" of the reference manual must be "reference.refmanualindex". (thus, "reference.refmanualindex.chapters.*.subchapters.*. refpages.*")

So, the net result, you need to embed the articles within the navigation information, or if you really want to break out the page data, then the reference manual navigation must be at "reference.refmanualindex".

Regards,
JPG

celestian
September 26th, 2017, 23:49
celestian just sent me an example.

In the module he built, the navigation buttons aren't showing up because the reference page data is separate from the navigation data.

In the wiki page example on the developer wiki (https://www.fantasygrounds.com/wiki/index.php/Reference_Manuals), the page data needs to be inline in order for the individual articles to be able to determine chapter groupings.

So it needs to be like this?



<[reference_manual_navigation_data_path]>
<chapters>
<[chapter_00]>
<name type="string">[Chapter Name]</name>
<subchapters>
<[subchapter_00]>
<name type="string">[Subchapter Name]</name>
<refpages>
<[refpage_00]>
<name type="string">[Page Name]</name>
<text type="formattedtext">[Optional. Any formatted text to display before the manual data.]</text>
<blocks>
<[block_01]>
<blocktype type="string">[See below]</blocktype>
<align type="string">[See below]</align>
<size type="string">[Only used for image/token blocks. Comma delimited width and height of image/token.]</size>
<frame type="string">[Only used for text blocks. See below.]</size>
<image type="image"><bitmap>[Only used for image blocks. Local file path to image within the module.]</bitmap></image>
<picture type="token">[Only used for token blocks. Local file path to token within the module.]</picture >
<text type="formattedtext">[Only used for text blocks. Textual information to display]</text>
<text2 type="formattedtext">[Only used for multi-column text blocks. Textual information to display]</text2>
</[block_01]>
...
</blocks>
</[refpage_00]>
</refpages>
</[subchapter_00]>
...
</subchapters>
</[chapter_00]>
...
</chapters>
</[reference_manual_navigation_data_path]>

Moon Wizard
September 26th, 2017, 23:52
Yes.

Or, you can leave your reference page data as is, and move all your navigation data to "reference.refmanualindex".

Regards,
JPG

celestian
September 27th, 2017, 00:05
Or, you can leave your reference page data as is, and move all your navigation data to "reference.refmanualindex".


This works, thanks!

Talyn
September 27th, 2017, 02:48
Here's how I go about my inline pages; all the index nav data and the content all in one page:



<reference static="true">
<referencemanual>
<name type="string">[Optional Window Title]</name>
<chapters>
<chapter_00> <!-- however you prefer to label your chapters -->
<name type="string">Index Column Name - Chapter Level</name>
<subchapters>
<subchapter_00>
<name type="string">Index Column Name - Subchapter Level</name>
<refpages>
<refpage_00>
<name type="string">Page Name</name>
<blocks>
<!-- ALL YOUR BLOCKS ARE BELONG TO US -->
</blocks>
<keywords type="string"></keywords>
<listlink type="windowreference">
<class>reference_manualtextwide</class>
<recordname>..</recordname>
<description field="name" />
</listlink>
</refpage_00>
</refpages>
</subchapter_00>
</subchapters>
</chapter_00>
</chapters>
</referencemanual>
</reference>


I keep a file with that to get me started on a fresh manual, then another blank template with everything between <refpage_NN> so I can do a quick copy/paste and get working on the next page.

Moon Wizard
September 27th, 2017, 03:34
If you gave one that’s not working that you think should be based on all this, send me the MOD file or a DropBox link to [email protected]

Thanks,
JPG

Nickademus
September 27th, 2017, 04:59
Here's how I go about my inline pages; all the index nav data and the content all in one page:



<reference static="true">
<referencemanual>
...
</referencemanual>
</reference>




Yes.
Or, you can leave your reference page data as is, and move all your navigation data to "reference.refmanualindex".


I think 'referencemanual' needs to be changed to 'refmanualindex'.

Talyn
September 27th, 2017, 05:36
I think 'referencemanual' needs to be changed to 'refmanualindex'.

Not at all. As I stated, all my reference manuals use inline pages. All the content and the index data are contained in one place. Saves a ton of time not having to scroll up and down between sections, and results in less markup as well. Many (not all) of we hand-coding types have switched to reference.referencemanual and use this technique, as stated by Moon Wizard above:



::snip::
…the page data needs to be inline in order for the individual articles to be able to determine chapter groupings.…
::snip::
So, the net result, you need to embed the articles within the navigation information, or if you really want to break out the page data, then the reference manual navigation must be at "reference.refmanualindex".


He suggested Celestian use reference.refmanualindex because Celestian's manual was already split into content data and index data paths, so it's easier to just rename the index data path to "refmanualindex" (and point the Library link there) rather than reconstruct his entire manual to the inline technique.

Nickademus
September 27th, 2017, 06:15
What do you do about duplicate page: a single page that appear in multiple places in the index?

celestian
September 27th, 2017, 06:37
What do you do about duplicate page: a single page that appear in multiple places in the index?

Copy paste ;)

Talyn
September 27th, 2017, 12:26
What do you do about duplicate page: a single page that appear in multiple places in the index?

It's never come up? Off-hand, you could just literally duplicate the page in the markup or, in theory I think creating the refpage with only the <name> then the <nav index data> stuff might work, and put in the recordname link to the first page instead of ".."? Or it might totally throw off the left/right buttons, not sure? That's purely a "just woke up and haven't had coffee yet" idea. Which probably means it's a bad one. :)

In what situation would we need multiple copies of the same page in one manual?

madman
September 27th, 2017, 12:28
Edit:
I moved referencemanual to reference but did not rename it to refmanindex needed more coffee.

Madman..

damned
September 27th, 2017, 12:29
In what situation would we need multiple copies of the same page in one manual?

When you promised 96 pages and you only have 94!

Talyn
September 27th, 2017, 12:35
When you promised 96 pages and you only have 94!

LOL isn't that what full-page artwork is for? :p

@madman Dunno... if you're on the FG discord hit me up, I'll take a look at the markup.

madman
September 27th, 2017, 13:00
Got it sorted Thanks..
Madman

Nickademus
September 27th, 2017, 16:56
In what situation would we need multiple copies of the same page in one manual?

In a reference manual that organizes the content multiple ways in the index. For instance, the UA module has two main sections in the ref manual: the assets and the articles. That means that every asset page appears twice in the index and the user gets to it whichever way suits their needs, either browsing the articles or by looking through the list of a single asset type.

I think the primary miscommunication here is based on the perspective of what a reference manual is. Technically a reference manual is a UI that displays data. It is frequently used to express a book or pdf in a format that has a linear progression and page numbers, but that's not the only use for the reference manual (nor is it required). The format of the manual also allows non-linear databases of pages. In which case I doubt the inline method would be practical. I was just curious if you had run into issues with this while using the inline method.

Talyn
September 27th, 2017, 17:26
No, but as you say, I use the reference manual to either replicate a PDF outright, or in the case of adventures, I put just the GM info and story background there, then the playable story content in Story.

Again, without trying this, I think simply making a "blank" refpage and pointing the recordname to the page that actually has that content will work, similar to the way the various list classes work.

Moon Wizard
September 27th, 2017, 18:10
The reference manual as built in this context is designed for linear progression. I didn't even design the original code, just integrated and enhanced. ;)

Cheers,
JPG

Nickademus
September 27th, 2017, 20:02
It seems to work fine for non-linear as well so, bonus.

Gubben
September 27th, 2017, 20:11
I'm still unable to get the left/right arrow to apear in the library... :(

Moon Wizard
September 27th, 2017, 20:20
Send a copy of your module to [email protected], and I can take a look.

Regards,
JPG

Gubben
September 27th, 2017, 20:28
Send a copy of your module to [email protected], and I can take a look.

Regards,
JPG

Thanks a lot! I've send you a copy of the tests I've done. The library module works but no arrow appearing. Its Made for the VtM 'fanmade' ruleset using CoreRpg

Gubben
September 27th, 2017, 20:46
Solved!

Moon Wizard
September 27th, 2017, 20:52
Do I still need to look at the module, or are you good to go? What was the issue?

Regards,
JPG

Gubben
September 27th, 2017, 22:04
The issue was on the first ref_page.. the recordname tag must be .. the rest can be links to another refpages