Module Making Manual v 1.2 -by SoulOfTheReaver 1 Intro 1.1 Stuff you'll need 1.

2 XML Primer 2 FG2 general style Tags 3 The module 3.1 The structure of the Module 3.2 The libraries section 3.2.1 Library header 3.2.2 Library Entries Window Classes Links The referencetext class The referenceindex class The npc and item classes The feat class The skill class 3.3 The reference section 3.4 The image section 3.5 Adventure module sections 4 Final thoughts Errata – Making library modules without XMLs 1 - Intro So you wanna make a library module for your favourite game system, but don't know where to start? Well you've come to the right place. Fantasy Grounds 2 makes good use of a rather intuitive and human readable method of defining and storing everything from its user data to the very windows and rules of the software in the form of XML (extensible markup language) files as well as a bit of LUA scripting for the rulesets. This makes it extremely customizable, as the many community rulesets available stand testament. If you have a knack for programming there is ample documentation on making and changing rulesets on the FG2 website. Making adventure modules to store and transport encounters, items, NPCs and tokens is not a mystery either thanks to Xorne's excellent video tutorials found here. Now many rulesets also come with a library that can have anything from game rules to monster manuals or lists of feats or magic items, either for free (like Complete SRD) or for sale on the FG2 store. But what if neither of these is the case for your ruleset? FG2, while otherwise admirably well documented (as shown above) has little to no information on making library modules. Information on this subject is scarce and available only as snippets of information that you must hunt down on the forum. Failing that you have to learn to do so yourself by poking around in a module's guts. Having done that, I've decided to write this little guide to make the life of those that would do the same a bit easier. As I'm sure you've noticed by watching Xorne's videos you can easily export adventure modules from within FG2 itself, building them with the game's internal text editor and NPC character sheets and whatnot. This is not possible for Library modules. I've recently learned this is not true, you CAN use FG2 itself to make rudimentary library modules but using this method is highly limited in what you can do with it. If you want to learn more check out the errata at the end.

0" encoding="ISO-8859-1"?> It mentions the XML version and the character set (in this case Latin-1/West European)Don't forget to include that if you're building a module from scratch. Finally.The first tag that comes after the declaration is the root element. but these tools help make your life a bit easier: • Any archiving program that can open ZIP files. You can technically use FG2's internal editor but that one doesn't have support for making tables.Designing a proper library still requires you to get dirty and go under the hood. I use WINRAR. While you're at it make sure that: . I'm listing them here in order to avoid common mistakes and make sure your modules work as intended: . Please note that in FG2 the root element must have a version attribute like so <root version="2. hence well-defined tags. Conversely the last line should be </root>. It does however have a few rules that you should know about and keep in mind. .2 . those are up to the software reading it. you just need a bit of patience.When giving tags attributes don't forget to quote the value. learn what an HTML tag is. Simply put <b><i><u>text</u></i></b> is correct. It is very similar to HTML in concept but where HTML's purpose is to format and display data. human readable way of storing and transporting data. . • A basic HTML editor to help with writing reference pages. while <b><i><u>text</i></b></u> is not! Close child tags before closing their parent tags. and learn to properly use the most basic ones. 1.All XML files start with a declaration that looks like this <?xml version="1.When naming tags – you can use letters and numbers as well as special characters. you CAN make them. in this case FG2. XML is designed to organize and store it. more on those later. Stay away however from the characters . This means that it has no predefined set of tags. a bit of info(found here) and a few simple tools. This also means that you can make up your own tags where appropriate. ending the tag. The XML must start and end with that tag.That reminds me – make sure every tag is properly closed. like so: <name type="string"> . . be careful when giving tags names so they don't conflict with dedicated FG2 tags.All tags must be properly nested.Stuff you'll need Technically all you'll need is notepad. XML marker will scream at you if you leave any open ones by the way. For most XML documents the root element is simply <root>.0"> - without which the module will not be recognized! . This guide assumes it. • A dedicated XML editor like XML Marker. which should be the second line after the declaration(empty lines don't count). If you don't have it. and those are a bother to do by hand. this brings me to our first order of business: 1./:$& for obvious reasons. You'll thank yourself for it. Don't let them overlap. • Basic knowledge of writing HTML.1 . Get it. Also don't start the tag name with a number.XML Primer (skip to the next section if you know XML and/or Kung Fu) eXtensible Markup Language is a machine-independent. Fret not however. Now let's get down to business.

if the latter (as defined in the individual library's own <name> tag is the same as the module name in definition. Another file you may or may not have is thumbnail. <author> is self explanatory. It makes a chatbox with draggable text.FG2 general style Tags While XML has fully customizable tags. It's a small graphic that will show up next to the Module name in the browser. well unless you're into old-school music formats. and <ruleset> is what ruleset it will work with. Tags also found in HTML but with a different function: • <frame> . and of those it uses.png. is basically a ZIP archive renamed.simple paragraph tag. It looks sort of like this: <root version="2. • <b><i><u> .xml. FG2's custom formatting tags: • <h> is a paragraph tag with a different font. Google them.syntax is like that of <p>. To open them just rename them temporarily to . Underline.- If you need to type & within your text.0"> <name>Complete SRD Monsters</name> <author>Digital Adventures. they can be a treasure trove in helping you understand how to make your own. to avoid compared to HTML: The border attribute doesn't work. which is basically a label for the module. I'll reference each here: Tags that function like their HTML counterparts: • <p> . Furthermore it has some of its own custom style tags. use &amp. There are more. Heading basically. Quick note about the thumbnail. as is all XML by the way. • <listlink> and <link> are the link tags from within text windows. 2 . Just put it in the archive and it will show up. Check them out. possibly three. LLC. but don't worry about it if you didn't get that.mod by any other name would smell as sweet. • <list> opens a bulleted list like <ul> would in HTML.The module OK now we're getting to the juicy part! What's in a module? that which we call a . Case sensitive. which is an entity reference. some work differently. however it will only show up in the library itself next to the library name. Very important tags. More detail here. Make it square. That said it doesn't use all HTML tags.</author> <ruleset>d20</ruleset> </root> First is the <name> as it will show up in your library. Each item must have the <li> tag as normal. You can find plenty of them that come with FG2 in the program's application data folder under the Modules sub-folder. snoop around. no more than 100x100 for best results. which is to say not at all because all a . Nuff or even better get your archiver to be the default software to open . Inside a module you'll usually find two files.mod file is. . 3 . FG2 uses some in common with HTML where text formatting is concerned. Must be exactly as the ruleset's folder name. One is called definition.xml. While you're at it Google XML Tutorial for more information.mod files. it will show up in the module browser always. • <table> . Colspan works but rowspan does not. Use the decoration="underline" in the <tr> tags to draw the table lines. Italic.

• <image> lists images that show up in the FG's picture browser in-game. the one that holds most of the module's data. A common.1 . but it's a common category name. You can define your own categories and link to them at will.The structure of the Module All a module's main XML file really needs to have is the declaration and the <root> tag but that would make for a pretty boring module. 3. They are as follows: • <library> FG2 will look here upon the module's loading to check for library entries to display in the appropriate window • <reference> you don't need to strictly call it that since you can define what links to what. • <npcs> shiny happy people. and what name it has is important because it will alter the behaviour of the module.xml.xml or common.xml file will download the data to the players even if they don't have it. Speaking of adventure modules. which are basically just tags that hold other ones inside them like so: <root version="2. If all goes well it will show up in your module browser when you next load the ruleset. such as lists of feats or NPCs. Inside the root you can define several databases or info categories. as will be shown a further down. but there are certain categories that are default to FG2 and the program will look for them when doing certain things.xml.Now the most important file. If the module is an adventure module you may also see other files like tokens and stuff but those three files are the most common.xml will only show up for you. . it will only load for your players if they have the file on their computers. client. You can put adventure data and library data in the same module.xml. people separate them from library modules but the separation is false. If you name the file client. Blood for the Blood God! • <encounter> story entries. good to have in mind when linking across to existing modules. When making your own module. If you want to make pictures that are linked from library entries but do NOT show up in the browser. simply make these three files (either from scratch or by modifying an existing module) and put them together in a ZIP archive that you then rename mod and put in the modules folder. make a custom category tag to hold them that is structured like <image> but is called otherwise. It will either be db. Finally db. Use this for stuff like monster manuals which they don't need to see. Keep that in mind. Mind you this isn't strictly necessary as you can have said data inside the libraries themselves but it's easier for organizing your module.0"> <library> (stuff here) </library> <reference> (other stuff here) </reference> </root> In this case the <library> category would hold your libraries (a module can have several) while <reference> would have miscellaneous info that library windows will link to. The following categories contain adventure module data and stuff in them will show up in the relevant browsers: • <item> items for the item browser. This is useful if say you're building a campaign module which also includes special rules or new feats and such that you want the players to easily reference. will have one of three names. the players won't even see it. useful for the lazy.

Libraries with the same category will be nested together.2 . Otherwise the GM can edit the info from inside FG. say. Let's take a look more closely at it.2. Legal</name> <text type="formattedtext"> (boring legalese text) </text> </aacreditslegal> (other entries) </entries </csrdmonsters> . effectively a self-contained library. This category tag is basically very simple.xml) having this means that the module is read-only. • <categoryname> defines the group it's part of in the same window. 3. Most modules only need one sub-cat.2 . Note – Library modules will be listed on the left side in REVERSE alphabetical order. • <entries> contains the library content itself and here's where we go next. The attribute type=”string” lets FG2 know it's a text string and not. but you can.Library Entries The <entries> tag contains the list of items that is displayed in the right-hand side of the library window.2. In the XML a single entry will look like this: <csrdmonsters static="true"> <name type="string">Complete SRD Monsters</name> <categoryname type="string">Complete SRD</categoryname> <entries> <aacreditslegal> <librarylink type="windowreference"><class>referencetextwide</class><recordname>. the library's table of contents if you will. Let's take a look at this sample: <library> <csrdbasicrules> (some contents here) </csrdbasicrules> </library> Within the category tag itself you have a subcategory called <csrdbasicrules> I'm sure you can guess what that is.Library header Zooming in we see this: <csrdmonsters static="true"> <name type="string">Complete SRD Monsters</name> <categoryname type="string">Complete SRD</categoryname> <entries> (the library content is here in the entries tag) </entries> </csrdmonsters> The library's tag can have a static=”true” attribute. Each subcategory is one line that shows up in the left part of the library window. for what ever reason add several if you wish. as said before holds what shows up in the library window upon module loading.The libraries section The <library> category. All the tags before <entries> are what's called the category's header: • <name> defines what it shows up as in the left side of the library window. 3. On Host modules (ones with db.3.. Common and client modules are read-only regardless of this attribute. Best keep that in mind when naming them.1 .</recordname></librarylink> <name type="string">Credits &amp. a number. Let's take a look at what's inside that.

but you can snoop around the XMLs in your ruleset's folder for other window classes should you feel you need them. Reference link only. etc following if you'll check out the module for yourself) is that the entries in a library show up in the window in alphabetical order according to entry tag name not what's under <name>. either to link from the library categories on the left hand side of . Useful if you have big tables. • feat – a specialized feat window. A window class is a small set of rules that defines how a window in FG looks and behaves. and I will describe each in detail but first you gotta know about: 3. Now that those are out of the way let's talk about: 3. (for more information you can check out the Ruleset Modification guide on the FG2 website library). The <name> tag (notice the type=”string” attribute again) defines what it will be called in the library's table of contents on the right side. etc. Putting a little prefix in front of the tag name is an easy way to make them be ordered otherwise. The first two are used mainly in the library.This entry is called <aacreditslegal> but it can be called anything you want.2. ad. For details on that see the links section below. The syntax for telling that to FG2 depends on the type of link.2.2 . entity reference used to avoid conflicts with special characters in the name. The reason why the name starts with aa (with ab. Mostly relevant to d20-based systems but other rulesets make use of it too. ac. • npc – what it says on the tin. Same window that pops up in the personality browser. Those should be all you need for library modules.Window Classes Window classes are something we'll be working with a lot. The next line is the link that defines where you find the actual content that gets displayed when you pop up the window. Notice also the &amp. • referencetextwide – as above just wider. There are many kinds of entries. • item – see above.2. • skill – see above. Links can be defined by three tags: <librarylink>. so you need to know a bit about them beforehand. whether it's a character sheet or story entry or map. FG2 needs to know two things – what kind of window it opens. Useful for short blurbs of text. and what information it will be filled with. and simply <link>. The <text> tags kindly warns FG2 that a blob of text follows (formatted by the tags I mentioned earlier).</recordname></librarylink> Let's dissect that: When you have a link somewhere in a module entry. It's a small window with text in it.Links Remember that juicy large link line in the previous chapter? This one specifically: <librarylink type="windowreference"><class>referencetextwide</class><recordname>.1 . • referenceindex (comes in wide and bigwide varieties) – is a list of links. The tags are then closed in the proper order and another entry can begin.2. <listlink>. Now what window classes there are is largely dependent on the ruleset itself so you may wanna look into yours a bit more. but most rulesets derived from d20 use a few common ones which you'll need to know about when organizing your library: • referencetext – the most basic. The text itself I cut out for the sake of brevity and to prevent your death by boredom.. • imagewindow – opens up a picture.

image-charsheet_portraits_jpg@FGII User Manual Ref">Character Sheet Portrait Icons</link> As you can see. in this case a simple text window. In such cases the <recordname> tag will look like this: <recordname>reference. or from said page to other windows <listlink>. Now these two are formatted as in the example above. and <recordname> which tells FG where to look for the window's data.<librarylink> . where no referenceindex windows are involved. If you need to. a page on the right. In fact this is almost mandatory for tables unless you wanna spend ages coding them by hand.2. Let's now take a look at some specific window classes and see what they do and how. all of which can be found in the module called “Complete SRD Monsters”. handy for large tables. edit reference_basicclasses. After the same type of <name> header as referencetext. just defined by the <link> tag's own attributes instead of sub-tags. This class has a simple header consisting of <name type="string">Window Name Here</name> and contents wrapped in a <text type=”formattedtext”> tag.the library window .xml in the ruleset folder and add an even bigger window class to suit your needs. Pretty handy for organizing stuff. and are willing and able to modify the ruleset. A typical example is shown here . no? Finally. This way of linking is generally used from single pages to single pages. normally it will be “windowreference” since we open other windows in links.The referenceindex class This class is your basic list o' links.” in the present example means that the entry itself contains the data.4 . the same information is there.3 .2.animalmonsters. and not a separate <name> tag.. You can also edit the text in a visual HTML editor and then paste it into the XML. even other referenceindexes. subcategory <animalmonsters>. the <link> tag is a handy one-tag way of linking to other entries. Remember that every line of text needs to be in a <p> tag.wolverine@Complete SRD Monsters</recordname> That means that the information is in category tag <reference>. data tag <wolverine>. The “. Examine pre-made modules to see how that works in more detail. You can also use the referencetextwide class to get a wider version of that. or when you want to avoid code clutter. formattable text and tables. narrow. as well as links to other windows.2. Inside the link tag there are two other tags: <class> which defines the window class. However the data is sometimes stored outside the entry. A link with this class will spawn a small.2. It looks something like this: <link class="imagewindow" recordname="image. it will have an <index> tag that can hold other window links of any kind. more specifically: The attribute called type= tells FG what sort of link it is. All this means that you can store the data externally either in another part of the module or in a different module altogether.The referencetext class This class is your basic bread and butter when making a library module. non-resizable window with room to input basic. and is usually found within reference pages themselves. 3. Also the name of the link is the tag's value. Just make sure to clean up the tags afterward so your text isn't messed up by non-approved tags.

That said.animalmonsters. By the way you can use the same method with text entries if you don't need to draw tables. Saves a lot of time when creating monster manuals.2.<shroomrecipes> <librarylink type="windowreference"><class>referenceindex</class><recordname>. The window itself is a small.5 .baboon@Complete SRD Monsters</recordname></listlink> <name type="string">Baboon</name> </baboon> See reference category section below for more info about linking 3. Here's a down and dirty cheap trick to make these very fast. These are a bit special since they are very closely tied to the ruleset in question so the tags needed will be different for every one. so no empty headings. feats and skills in a separate reference category for easy access and link to them like so: <baboon> <listlink type="windowreference"><class>npc</class><recordname>reference. although perhaps by other names.The npc and item classes. Here's an example entry: .self explanatory • <type type=”string”> . 3. with a few notable differences. Enter your characters/monsters/items into the relevant browsers.Will show up below the title in brackets like so – [GENERAL] • <benefit type=”formattedtext”> description of feat will appear under a benefit subtitle. The talents in Dark Heresy come to mind here for instance. • <name type=”string”> . Its tags are few and generic so I will list them here. <name> header tag is still standard though. the feat class as well as its sister the skill class are also often used in other rulesets as well.. • <special type=”formattedtext”> same.2.2.</recordname></librarylink> <name type="string">list of magic mushroom recipes</name> <index> <recipe1> <listlink type="windowreference"><class>referencetextwide</class><recordname>. specialized text window. There are also the classes referenceindexwide and referenceindexbigwide for the window space hogs among you. Export them as an adventure module. Start up FG2. it's a good practice to keep things like NPCs. items.. • <prerequisites type="string"> one-line prereqs description Not all tags need be entered and only the ones that do will show up. although you can enter the data you get from FG2 (or create manually if you know the tags and are a masochist) in the library's entry directly. Then open up that module's XML and copy/paste as needed.</recordname></listlink> <name type="string">The Shroom of Doom</name> <text type="formattedtext"> (contents here) </text> </recipe1> (other recipes) </index> </shroomrecipes> You can also add a <description type=”formattedtext”> before the <index> to write a small intro for your list.6 .The feat class Everything said above about the item and npc classes applies to the feat class as well. One is that while it does tend to be used mainly for d20-based rulesets.2.

a description of the skill. 3. paladins.<armorproficiencyheavy> <name type="string">Armor Proficiency (Heavy)</name> <type type="string">GENERAL</type> <benefit type="formattedtext"> <p>See Armor Proficiency (light).subtag. and clerics automatically have Armor Proficiency (heavy) as a bonus feat.</p> </normal> <special type="formattedtext"> <p>Fighters.The skill class This is the same as the feat class only it just gets two tags: • <ability type=”string”> . These database or reference tags are very simple.entrytag@module name” . you don't need to call it that way quotes.. there's a sub-tag called <recordname>. and even allows you to link across modules as long as both of them are open in FG2. This chapter is about general reference sections specifically As mentioned before.</p> </benefit> <prerequisites type="string"> Armor Proficiency (light).2. For one anything appearing under this tag will show up in FG2's image browser.7 . • <text type=”formattedtext”> . then the linked window will get its data directly from within the parent tag of the <listlink> or <librarylink>.2.4 The image section <image> is a database-type category tag but with a few special details.</p> </special> </armorproficiencyheavy> 3. It's basically <reference> <subcategory> <item> (content of item) </item> </subcategory> </reference> all of which you can set up as you see fit. If you want to send it elsewhere for the data. Armor Proficiency (medium). 3. If you want to avoid this just place your images (with the syntax shown below) in a differently named database category.3 The reference section Although this section tag is usually encountered in official modules for FG2 as <reference>. they have no header. They need not select it. This gives you great flexibility with the content and organization of your module. use the syntax “tag. If you enter its value as . when you make a link type tag in any window.functions like <type> in the feat class. </prerequisites> <normal type="formattedtext"> <p>See Armor Proficiency (light). The image entries themselves are formatted thus: . Any legal name will do.

5 . <npc>. I hope this helps you get on your way to creating your very own Fantasy Grounds 2 library modules and helps you out with your gaming.the type of entry • <bitmap> which is the file path. Use in your self made modules if and where you believe it necessary. Other than that there is no difference between them and any other database categories. Just the file name if the image is in the module archive. <class> is its window class and <recordname> is what it points to. so any new information I come upon will be added as required. these categories will have a header tag that looks like this: <category name="" mergeid="Illum" baseicon="2" decalicon="6"> This refers to the separate tab that appears for the module in the relevant browser. and baseicon and decalicon define the visual style of the little bookmark thing that identifies the modules when you switch tabs in the browser. 4 – Final thoughts Well here we are at the end of this Module Making Manual. Then we have • <image type=”image”> . personalities and story entries and show up in their respective</recordname> </shortcut> (another map pin) </shortcuts> The <shortcut> tag is an individual map pin. Simple no? Images from here can be brought up in the library or anywhere else by making a link with the class imagewindow and pointing the <recordname> at the image entry in this section. See more below. along with any corrections. They function like spatially located links. In adventure modules created with the FG2 exporter.jpg</bitmap> <shortcuts> </shortcuts> </image> <image-d20reference_jpg> The entry name. Otherwise it is a relative path where the Fantasy Grounds II application data folder is the root (<bitmap>pictures/ideas/lighbtbulb. It is a living document. as far as I know the first of its kind. and <encounter> are automatically generated by the exporter when making adventure modules and any entries within are brought up are treated as items. mergeid is there to tell FG2 to display modules with the same value for this attribute in the same tab. The code looks like this: <shortcuts> <shortcut> <x>59</x> <y>33</y> <class>encounter</class> <recordname>encounter.png</bitmap> for instance) • <shortcuts> Place to store the map pins on the image.<image-d20reference_jpg> <image type="image"> <bitmap>d20reference. in the examples I've seen it's an underscored version of the file name but I'm willing to venture that's not necessary(any input on that by the way?). The <shortcuts> tag is an index of map pins that the GM can define. . 3. <x> and <y> are its coordinates on the image. named <item>. See Xorne's videos for more on making those in game. Otherwise avoid these names lest you clutter the browsers. See Xorne's videos for more about that.Adventure module sections These sections. Name is obvious.

Have fun creating and playing your games! Errata – Making library modules without XMLs I've recently noticed you can make library modules using FG2's built in exporter and not touch an XML file once. In the window that pops up. which consequentially means that you cannot make feat or skill windows or whatever else you can't do from within the game itself. Define a thumbnail file in the field above. . as well as griogre. personalities and items. Module Making Manual by SoulOfTheReaver is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3. moon_wizard and others who kindly and sagely answered the questions of others and some of mine about the module structure.0 Unported License. What you do is create your library data as story entries. and also select an index group which is basically the same as the <categoryname> tag and you should be good to go. Moreover. which will make them indexable as a library. Who knows perhaps in the future the software will come with a library editor's mode which allows you to customize the kind of data you build more (are you reading this developers?☺).Many thanks to DrZeuss on the forums who gave me a few invaluable starting tips. check the relevant data. and you can not make tables either for that matter. your library entries will still show up as story entries which is not that big of a deal but it's still annoying. then hit the /export command. The obvious disadvantages to this are that you cannot specify window classes on your own. the only real use this method has is to make a basic skeleton for your module which you then go in an edit and refine further. format and link them up with the in-game editor. and also check the I for each. Unless you're in a real hurry or completely unwilling to learn the manual way of making modules.

Sign up to vote on this title
UsefulNot useful