Nested table calls syntax

I am trying to make a treasure generator for Rolemaster 2nd edition (very out of date I know, but I'm old school). As such, there are lots of nested tables. So for example if (General Treasure Table) -> (Bonus items) -> (Blades) -> (Blade properties), how would this work?

For example if I want to be able to generate a +2 (+10, RM uses d100s) Broadsword of dancing, I have to go from the general treasure table to items with a bonus (+10), from there to blades (broadsword), from there to see if it has any special abilities (sword of dancing). And yet I want it to display all as a single item, even though it called from 3 different files.

Does that make sense?

Comments

  • You can nest as deep as you want. There is more than one solution but as a partial example:

    Table: Treasure
    You find a [@GeneralTreasure].

    Table: GeneralTreasure
    [@BonusItems]
    [@DailyItems]
    [@PowerEnhancers]

    Table: BonusItems
    [@Blades]
    [@OtherWeapons]
    [@GeneralItems]

    Table: Blades
    [@Plus5Blades]
    [@Plus10Blades]
    [@Plus15Blades]

    Table: Plus10Blades
    +10 Broadsword of Dancing
    +10 Flaming Broadsword

  • Do they all have to be part of the same file? As it stands, I'd have Bonus.ipt call BonusItem.ipt, which would call Blades.ipt, which would call BladeProp.ipt.

    If they need to be in the same file, I have a lot of cutting and pasting to do, and a lot of files to delete. Not to mention the end result is gonna be huge, as you know, knowing how much is available in RM2.

  • They don't need to be in the file, but if they aren't, you need to include a "use" line at the top of the file for each other file you want to reference. For example,

    use: nbos/Animals.ipt

    That will look for the file in /Common/nbos called Animals.ipt

    You can have multiple "use" lines in the same file.

  • Thanks. That probably isn't everything I need to know (like getting the results from several different files to output as a single result), but it gives me a place to start, and experimentation will probably get me some way from there.

  • What I do is I have one file which is all the use commands and one table that basically just says go. You don't want to upload that file somewhere. Keep it local (I put most of my files up on my dropbox). If you upload it somewhere else, the program tends to want to take all of those files being used and it tacks on a copy of them at the end of your parent file, which can be a bother later when you change things and there are suddenly two tables with the same name.

Leave a Comment