PDA

View Full Version : Is it possible to merge library modules?



meathome
March 22nd, 2014, 17:40
Is it possible to get reference library entries from different modules to show in a single list? I tried adding a a mergeid="myid" property to the <reference> node in my library module but that didn't do anything. Next i tray adding a <category name="" mergeid="myid"> </category> around my entries didn't do anything either.

Its a custom made ruleset using parts of corerpg. And i am talking about reference modules in the library not campaign entries. The idea would be that all abilities from all loaded modules should show up in a single list in the reference library (I would also need this because I have classes that link to abilities in multiple modules and to avoid having to manually link all the abilities for each class I parse a string in the windowclasses onInit that displays character classes in the library. The problem is the script doesn't know what ability is in what module or which modules are loaded -> This is where a single list with all abilities form all modules would come in super handy -> I could simply use that list in the parsing part).

So is this possible? If yes what would be a good way to do it? ATM the only solution I have is entering ALL the data into a single giant module but that seems quite inelegant...

dr_venture
March 22nd, 2014, 19:15
That is a *great* question. In my limited experience, content in FG modules is always segmented into its source module as if you're actually looking at different physical books... so with things in exhaustive lists like monsters and spells, you wind up having to look in multiple places to see if you have the right content. As a GM, what I'd really like is to just have a Master List for monster & spells (etc.), and just go one place to find all the content of that nature that I have available.

Moon Wizard
March 22nd, 2014, 21:39
The reference list windows do not support categories or merged lists, only campaign lists. The Library is more like a book paradigm.

If you are looking to list items that already have a campaign list (ie NPCs, stories, maps, etc), you can just use modules to add to those XML trees, since the lists support global access and categories.

Otherwise, you would need to define a new reference list windowclass via an extension for your module to access which is global and supports categories. Also, you would need to decide how users should access. Is there a link in each module to access global list?

I've thought about this before, since it's common in 4E and PFRPG to want to see global lists of character options. I think the optimal solution would add a "data" window to desktop, which would contain data sets for character options (ie feats, powers, spells, etc). It's only been on my internal list, and not on wish list; so, it hasn't had priority that other projects have had.

Regards,
JPG

dr_venture
March 22nd, 2014, 21:43
I've thought about this before, since it's common in 4E and PFRPG to want to see global lists of character options. I think the optimal solution would add a "data" window to desktop, which would contain data sets for character options (ie feats, powers, spells, etc). It's only been on my internal list, and not on wish list; so, it hasn't had priority that other projects have had.

Glad to know it's on the radar :)

Nickademus
March 22nd, 2014, 22:17
(Psst. He also hinted to add it to the wish list...)

meathome
March 23rd, 2014, 01:56
Ok my idea would then be to either try to build a list dynamically from script.. Could I make a link from the desktop to a new windowclass in which I simply loop through all loaded modules and add the nodes I want from the module to a windowlist work? How could I ensure that this list gets updated every time a module is opened or closed (Where do I use the onModuleLoad and onModuleUnload events? ). How can I get access to this new window from my reference window ( I assume I have to define some kind of desktop panel that opens my new window and save that in a lua variable somewhere maybe) ? And would this cause client server issues ?

Or do it the dumb way simnply make an additional module that has everything in it (maybe with a simple c# programm that does it automatically for all selected modules), and simply assume that compilation module exists and referenc everything from there.

Moon Wizard
March 24th, 2014, 06:10
Each windowlist control points to only a single path in the campaign database. The way that multiple modules are shown in a single list is by using the "usealltrees" tag in the windowlist control definition, and having the modules store the data in the same structure as the campaign database.

You could build a custom windowlist control with no datasource that monitored multiple database locations for adds, edits and deletions; but it would take some coding and testing to make sure it all worked the way you wanted.

Regards,
JPG

meathome
March 25th, 2014, 02:54
Thank you very much exactly what I needed to know. I was actually in the process of writing custom stuff for it, but this makes it much much easier (I did actually manage to implement lists with entries from multiple modules where the actual data entry is a simple string containing the entry names separated by coma and the windowlist's script pulls the relevant entries from all loaded modules if they exist... It does only work if each entry exists only once though. )