TableSmith Tuedays (Part 4 – Displaying Mad Lib Tables)

Posted on Updated on

Mad libs, they are the heart and soul of Random Generation. And in this episode of TableSmith Tuesday, we continue our journey into the dark realm of groups. In TST: Part 2, I referenced these types of tables as story tables. So if you did not grow up in the golden time of Teenage Mutant Ninja Turtles, you may not know what a mad lib is;

Mad Libs (from ad lib, a spontaneous improvisation) is a phrasal template word game where one player prompts another for a list of words to substitute for blanks in a story, usually with funny results.

The majority of TableSmith tables are in fact “Mad Lib” tables. From Pocket Contents.tab, to Sites of Interest.tab. They have a strict template, and then groups of words that are randomly selected from to fill out the template, sometimes with quite hilarious results. Let’s look at a table that uses this concept, Fantastical Swords.Tab:

:Start
1,[Theme]This [Sword type] is made out of [Material].
_ {If~%hiltdescribe%=1 ? The Hilt [Describe Hilt]./[Themed Hilt Description]}
_ {If~%bladedescribe%=1 ? [Describe Blade]/[Themed Blade Description]} It was crafted by [Crafter Name], in [Crafter Country].

All of the groups in the Fantastical Swords.tab are simple and look something like this:

;Describe Blade Shape
15,The blade is in excellent shape.
10,The blade appears brand new.
2,The blade has some nicks and dings.
2,The blade has been chipped and scratched.
1,The blade has some moderate damage.
1,The blade has begun to rust.
1,The blade is rusty.
1,The blade is pitted.
1,The blade is in no shape to be used
1,The blade has been broken in half.

Pretty Mad Lib’ish huh? Simple but it can create thousands of different swords that add flavor to your game. A lot of table developers have taken these simple types of tables and have expanded them to create more depth and interesting descriptions. There’s a middle level Mad Lib type of table something akin to the Library Contents.tab, it has multiple levels of Mad Libs:


:Generate
1,The library seems [Description]. The room is [Size].
On examination of one of the shelves closer to you, you find that it contains about [ShelfContent].
On the opposite shelf you find [ShelfContent].
Further on in the section you find [ShelfContent].
[Special]

With the second level of depth making the output even more complex:

;ShelfContent
3,{Dice~1d10*10} Scrolls. The scrolls in this section of the shelf seem to [ScrollContent] and the scroll[ScrollCondition]
2,{Dice~2d6} Books. Selecting one of these [BookDesc] books from random on the shelf it seem to deal with [BookContent]
1,a set of {Dice~1d6+1} [TomeDesc] tomes. Found under the [TomeSection] section, its outer cover is made from [BookDescCover] and it seems to be in [Miscellaneous.General Quality] condition. The [BookDescPages] pages are [BookDescBinding] and on close examination the tome has the following protection. [TomeSecure]. [TomeContent].

The greatest culmination of Mad Lib type tables is one that always impresses me with its depth and pure TableSmith awesomeness, and mixes multiple levels of Mad Lib with advance TableSmith functionality, Volo.tab:


:Start
1,The village of |TownName=[Fantasy Names.Start]| %TownName% lies on the [LN~RoadName], a [LN~Roadtype] [LN~AmountWords] days' ride [LN~Direction] of the city of |CityName=[Fantasy Names.Start]|%CityName%. About {1d400+100} folk call %TownName% home ({1d600+200}, if the population of outlying farms is included). Most are humans, but there are half-elves and a smattering of dwarves and halflings. %TownName% is named for one of %CityName%'s early [Ruler], %TownName% [LN~ShortTitle], who had [LN~RulerProperty] here. Though all traces of his [LN~RulerHome] are long gone, [LN~RulerLegend].
_
_%TownName% is [VillageDescription] place. By night or in a snowstorm, the traveler can mark it by [LN~VillageMarker]. This village is [LN~VillageDescription2]. In hot summer weather, though, it is only pleasant to %E%. The folk of %TownName% are famous for the %ProduceVerb% of %VillageProduce%. They have traditionally supplied the noble families and armies of %CityName% and the armies of [LN~Town Names.Start], as well as merchants and satraps of [LN~Town Names.Start] and [LN~Town Names.Start].
_
_Two of %CityName%'s more famous noble families have extensive holdings in the %TownName% area. The %J% family, which produces %ProduceDesc%. The [Fantasy Names.Start] family makes more money than all other inhabitants of %TownName% combined. This clan dominates the chief business of %TownName%, the supply of %VillageProduce% to %CityName%. These %VillageProduce% are not same quality as %VillageProduce% from the %J% %ProduceSite% but are %K%. Any local %VillageProduce% that don't come out of %TownName% %ProduceSite% are purchased by the family at fair market prices and carted to %CityName% in large, well-armed family caravans. These caravans are always on the road between %TownName% and %CityName%.
_
_%TownName% is a [LN~VillageDescription3]. %TownName% [LN~VillageSurroundings].
_
_The town can be entered [LN~VillageEntrance]. [VillageFeature]
_
_For a local spot of interest, [LN~SiteInterest1].
[LN~SiteInterest2]
_
_At the [Direction] end of the village [LN~SiteInterest1].
_
To the [LN~Direction] [LN~SiteInterest1].
_
[LN~SiteInterest2]

JB did a great job in creating the Volo.tab table. And he meshed a lot of the concepts that we talked about back in the TST- Part 2. So let’s talk a little about the concepts that JB used, and make a well crafted Mad Lib Table.

[LN~]

The [LN~], according to the TS help file: in TS 5.0 “LN~” tag; replaced with “~”. This is the Re-Roll Tag. Again from the Help File:

If you preceed a group name with “~” in a group call, you can “re-roll” the results of that call. For instance: “[~Treasure.Weapons]”.

This tag allows the user to “re-roll” the results generated from the group call. Whatever text is returned by the call is displayed in the Results Window and is treated similar to an HTML hyperlink. The text will be in a dark-blue color (not underlined, however), and will change to light-blue when the cursor is placed over it. Clicking the text will “re-roll” it, while preserving the rest of the results. Note that this feature will not regenerate or recalculate other parts of a display. Variable changes that occur in the “re-roll” will not be reflected elsewhere in the results window (the primary purpose of this feature is to “tweak” results).

This is essential to any great Mad Lib table. You may display a table that has mostly good stuff, but then there’s just one or two little bits that you don’t like! Well by using the Re-Roll tag you can make it so that we can re-roll just that one small tiny entry in an otherwise good-looking result!

Variable Assignment

JB must have had a vision in his mind when he wrote the table, and he accomplished something great. He discovered on of the most important pieces of building a great story table, but used it surprisingly little:

1,The village of |TownName=[Fantasy Names.Start]| %TownName% lies on the [LN~RoadName], a [LN~Roadtype] [LN~AmountWords] days' ride [LN~Direction] of the city of |CityName=[Fantasy Names.Start]| %CityName%. About {1d400+100} folk call %TownName% home ({1d600+200}, if the population of outlying farms is included). Most are humans, but there are half-elves and a smattering of dwarves and halflings. %TownName% is named for one of %CityName%'s early [Ruler], %TownName%[LN~ShortTitle], who had [LN~RulerProperty] here. Though all traces of his [LN~RulerHome] are long gone, [LN~RulerLegend].

See the Emphasised Lines there? To build a great Mad Lib or story based table that line is essential almost all the way through the whole table! The best part of this is if you use the ~ tag, if you don’t like the CityName, it’ll re-populate throughout the ENTIRE TABLE! But without knowing where the next developer is going to take your table, why not assign all the groups to a variable? You should here’s a quick re-write of that entry:

1,
#VARIABLE ASSIGNMENTS:
_|TownName=[~Fantasy Names.Start]| |RoadName=[~RoadName]| |RoadType=[~RoadType]| |AmountWords=[~AmountWords]| |Direction=[~Direction]|
_|CityName=[~Fantasy Names.Start]| |Population={Dice~1d400+100}| |TotalPop={Dice~1d600+%Population}| |Ruler=[~Ruler]|
_|RulerShortTitle=[~ShortTitle]| |RulerProperty=[~RulerProperty]| |RulerHome=[~RulerHome]| |RulerLegend=[~RulerLegend]|
#OUTPUT:
_The village of %TownName% lies on the %RoadName%, a %RoadType% %AmountWords% days' ride %Direction% of the city of
_%CityName%. About %Population% folk call %TownName% home (%TotalPop%, if the population of outlying farms is
_included). Most are humans, but there are half-elves and a smattering of dwarves and halflings. %TownName% is named for
_one of %CityName%'s early %Ruler%, %TownName% %RulerShortTitle%, who had %RulerProperty% here. Though all traces of
_his %RulerHome% are long gone, %RulerLegend%.

Group Calls and Grammar Rules:

It should be noted here that when you build a Mad Lib table, your groups should follow a couple of rules:
1 – No leading space!____ 1,entry ________ not ________ 1, entry
2 – No Ending!__________1,entry ________ not ________ 1,entry?
3 – Don’t capitalize! _____1,entry ________ not ________ 1, Entry
Following these simple rules will help you control your grammar. When you are building a complex table. While you may have developed the table with specific grammar rules, you are always going to run into a problem somewhere. For example with the {Cap~} function call, I can capitalize when I want in my output and display. I don’t need Fantasy Names.tab to Capitalize my Characters names.

Further down in Volo.tab JB, did another great thing! In the :VillageProduce he made the WHOLE entry a set of variables!

:VillageProduce
1,horses
_|ProduceType=horse breeders| |ProduceSite=stables| |E=the noses of those who like horse manure|
_|ProduceVerb=breeding and training | |G=fresh|
_|ProduceDesc=skilled animal tenders, maintains a farm where sick animals are nursed, and a shop where tack of the finest sort is made and sold The Eagleshield harness is made for the lone rider's mount. It is of black leather, adorned with silver-plated studs bearing the spread-winged eagle that is the heart of the family blazon|
_|K=tough and versitile|
_|L=the Great Shalarn, a famous war stallion bred in %TownName% 39 winters ago. Gelded long ago by a prankster, the rearing horse image is often painted various hues by high-spirited locals. There is a local rule that allows children to use slings, flung stones, or hand crossbows to bring down birds perching on the statue, so it remains free of the usual bird-droppings. The children often climb it themselves, and perch precariously in the high, tilted saddle, waving their arms and commanding imaginary armies into battle.|
_|S=The statue is a popular place to leave cryptic messages, either tucked under the hind hooves, or slid between the sculpted curls of the tail. It's also a common place for arranged signals, which are usually a bit of colored cloth tied to a particular part of the horse|
_|T=Local lore holds that if the grim, ghostly figure of the [HeroRace] [Hero]%M% %N%, a long-ago hero of %TownName%, is ever seen in the saddle, war will soon come to the town|

It looks like, the table went through a Valminder Revision. [CC~] was what [LN~] used to be before it was all [~], and Val, without having a guiding #Comments from JB, had to piecemeal some things together to make the table more readable: If you investigate the table you’ll see #Comment tags that Remove sections of a display, and there are variable declarations that aren’t actually used. But if I were to apply my thought process to what I see here, it looks like JB was setting up his to have different stories which he could have a random group that would call L,S,T to give a different flavor to each Horse Town.

So to wrap up this week, MAD Lib tables are great, they are the foundation of TableSmith, and the majority of the tables. Remember to use a couple of very important elements:
Grammar Rules, Variable Assignments, #Comments, and the Re-Roll tag, and your table will become infinitely more useable, readable, and interesting.

About these ads

5 thoughts on “TableSmith Tuedays (Part 4 – Displaying Mad Lib Tables)

    […] TableSmith so powerful is the scripting elements.  It lets you do more than Fill-in-the blanks Mad-Libs, or create straight Stat Tables.  It lets you make tables that contain an internal […]

    Allen Westillers said:
    June 29, 2011 at 2:33 am

    Thanks for the compliment(s). I would like to know, did someone ever “update” or fix volo.tab to work with latest version of Tablesmith? When I wrote it, Tablesmith was still as version 4 or 5 (I think).

    You were quite right that the main purpose was to create this whole world where PC’s walk into not just…”You enter a small village called Smithsville”.

    All my tables have always ended up this way. My first attempt was a copy and paste affair from a game called Daggerfall (look for Daggerfall Bio.tab)
    – creating a one click biography/background generator for you Character or NPC.

    If you like Mad Lib tables also look for a Library Description table floating around with similar spectacular descriptions.

    Ps. Love the blog.

      JB Willers said:
      June 29, 2011 at 2:37 am

      WordPress seems to stuff-up my contact details:
      JB Wilelrs
      jaybee@tiscali.co.za

      TheRandomDM responded:
      June 29, 2011 at 6:35 am

      Valminder updated it and renamed it Village Descriptions.tab. I wonder though, when you created the table did you base it on The Travels of Marco Polo? Because it gave text that is very similar to the descriptions of cities that he writes about?

      The Library Description had a lot of Madlib style too it but it also had some pretty indepth story telling elements to it, but still one of the best tables out there.

        JB Willers said:
        June 29, 2011 at 8:44 am

        I’ll look for that Table then…When I look at it now, I still think it can be greatly expanded.

        In any event Volo refers to a published book and a character (Bard) in the Forgotten Realms universe that travelled and wrote a travelling guide for adventurers in Faerun.

        The table was loosely based on that.

        I still want to create a generated page in TableSmith that looks similar to a published Adventure, with boxes that describe the town (in short) on one side, an Npc in another block, a map maybe and or a random encounter, etc.

        Have you ever checkout out the Tiny Adventures Stories.tab under Adventuring category?

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s