DICE PACKS BUNDLE
  1. #1

    Campaign DB Spell Parser to Module SpellList

    I wrote a little program that can parse in the campaign db to get all the spell data. It will then output the <spelllists> portion for a module.
    This includes:
    The Alphabatized Index of all spells.
    The section that links to each class
    and then the actual lists by level for each class.

    It builds the class list based on the Sources, all it requires is the spelldata.

    Compatible Systems:
    5E,
    3.5E,
    2E - It will import 2E spells no problem and generate the Indexed Alpha, and Per Class lists. It will not currently create separate lists for each School or Sphere. It could be done.

    Incompatible Systems:
    CoreRPG (No Spells)
    MoreCore (Spell data in a different format) - for these it has a concept of an Import interface, and Importers could be written/plugged in to handle other sources.
    Pathfinder (Spell data in a different format)

    I created it because I'm creating my own spells and I wanted an easy way to generate the module data for them.
    It's a dotnet core project.
    I have an entity dataset, an import/export library and then just a little console app that runs it all.

    This is just my quick/dirty version with very little hand holding.

    Instructions:
    Unzip it somewhere. It should be self-contained as far as everything it needs.
    Run the FGSpellListGen.exe file.
    This will pop up a window.
    In the Input box, browse to your campaign db.xml.
    In the output box, pick where you want the spelllist xml to be created. This is just the spelllist section, so don't overwrite your module.
    The Levels are optional. If you decide to use them it's a comma delimited list of levels that you want it to use. 0,1,2,3,4,5 for example.
    ModuleName - this needs to match what you have in the <name> field of your module's definition.xml file. If you leave it blank it will default to *.

    Click Generate. This will save your config for future runs. It will create the xml file where you told it to. Open that file up in NotePad++ or Visual Studio Code or whatever.
    Copy all of it.
    In your Module's client.xml or db.xml, paste over your reference/spelllist section.

    In your library section of the module's xml - have a link to the spell list.
    Example:
    Code:
    <library>
     <id-darkspyrecampaignguide static="true">
          <categoryname type="string">Campaign Guide</categoryname>
          <name type="string">darkspyrecampaignguide</name>
          <entries>
    <id-00050>
              <librarylink type="windowreference">
                <class>referenceindex</class>
                <recordname>reference.spelllists.spells</recordname>
              </librarylink>
              <name type="string">Spells</name>
            </id-00050>
         </entries>
       </id-darkspyrecampaignguide>
    </library>
    <reference static="true">
    
    <!-- Copy the <spell> section from campaign db, save here as <spelldata> -->
    
    <!-- Paste the SpellList text here -->
    </reference>
    Initial Release here:
    https://github.com/brandonm4/FGUtils/releases/tag/1.1

    Source Code here: https://github.com/brandonm4/FGUtils
    Last edited by bmathis; July 14th, 2019 at 20:36.

  2. #2
    Trenloe's Avatar
    Join Date
    May 2011
    Location
    Colorado, USA
    Posts
    33,402
    I'm sure people will be interested in this. What ruleset is it for?
    Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!

  3. #3
    I've added a link to github. So far I've only tested it with 5E. I'll create some test campaigns for 2E, 3E, Pathfinder and 4E tomorrow and see how much (if any) work it would take to bring those in.

    I'll release the source once I organize it a bit better. It's full of various tests and experiments right now and kind of all over the place.

  4. #4
    can't wait to see it..
    "Over thinking, over analyzing separates the body from the mind."...MJK... Tool frontman




  5. #5
    I've published the source - link in first post.
    I also updated the Spell definition to support 2E, 3.5E (and 5E).
    I only briefly played 4E so I forgot how radically different the spells were.
    It looks like they are powers instead. I'll probably leave that for someone else to implement.

    I've started a bit into the CharSheet importer and NPC importer but those aren't ready yet.

    The importer returns a data object (classed DataLibrary) that contains all the Spells, (and in the future NPCs, Items, etc) that it read in from the file.
    You can then do whatever you want with that data.
    For instance, I have a private site for my campaign that provides information to my player's when the game isn't running. I use my library to import the campaign data into a sql db.

    As another example I use the Squareware APC to run my NPC's/PCs that are away. On my website, I let the player's input their APC values, and then I can export that into my campaign db. (That part is not in the public source as I haven't talked to the creator of SquareWare to see if he would want me to release that) - it's just an example of how you could use the data.
    Last edited by bmathis; July 14th, 2019 at 17:11.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Starfinder Playlist

Log in

Log in