Simulationist needs... (timing and interactive descriptions)

I am approaching IF from an Role-Playing Games (as in Pen& Paper) and Scientist / Programmers view (As in Biologist who had high-level classes in Programming and did code small thins since his childhood). Quite some time has passed since I last coded something like a parser that understood whole sentences and a mapping system that knew 10 directions on a commodore 64, however with the new mobile devices and e-book readers I can imagine a Renaissance of text-adventure and would like to get involved. From my perspective TADS seems a lot easier to use then Inform, but that is just my perspective i guess. However, there are two things I would need in TADS3:

A timing System
Actions need a set (or variable, depending on skill) amount of time. I would like to have a defined attribute for every action, so that “look apple” does not take as long as the NPC sneaking up behind you, arming a Ballista and shooting your back. Is there an easy way in TADS to do this? changeing location, different weapons with different speed, NPC walking slow or fast (as an attribute, not by defining stop-go-phases for each npc) and different command form “look apple” to “build castle” to take different amounts of time?

A full character simulation including combat and perspective
I would like the World (including NPC and Locations) to be different for different Characters. The Lady at the Bakery that needs A heavy bag of flour from the top shelf should react differently to a 5 foot girl with a red hood and a backpack full of toys than to a 6 foot warrior with blood stains on his bare chest and an axe in his hand. I would also like the bakery itself (and the possibilities to get the flour from the top shelf) to look different for the girl an the warrior. I know I will have to write descriptions for at least three different sizes of characters times the two genders, but don’t worry about the writing afford: Is it possible in TADS3?

Last but not least: If I have to implement those things myself, is there someone around to help me get it shared and usable for others?

Every action can take a variable amount of time. By default, that amount is 1. You can change it to whatever you want. Furthermore, there is a real-time system available. You can use it if you want stuff to happen regardless of whether the player pressed ENTER or not; in other words, the game is not frozen between each turn.

As for the second question, TADS is a simulationist system. The world model is very similar to that of sandbox games (for example you could do a Grand Theft Auto text adventure in TADS.) To give you an idea, here are the header comments of the “pov.t” library module:

Strange, I looked at the modules on the TADS site, found library extensions like autosave and compass… must have missed that one? Or is point of view already integrated? I only had time to dig through roughly 1/4 of the stuff… is there a tutorial on how to use it?

Sounds very good so far, thank you :slight_smile:

This is an integrated module. These are all found in the “lib/adv3/” firectory. They always include documentation in form of comments in them. If you’re asking whether they’re documented in the various guides in the TADS Bookshelf, I don’t know; I didn’t read the books :stuck_out_tongue:

Note that the POV module isn’t the kind of point of view you mentioned in your first post. What you have in mind doesn’t actually require any special module or anything. You just implement the different character classes the way you want.

So i define classes and the description of the room changes depending on the class?

The description of a location is generated by code inside a method. You can present different descriptions according to who is actually looking at it. You also have generic text that is static and never changes, but embed small parts in it that do change. For example:

desc = "Static text here. <<if gPlayerChar.ofKind(Warrior)>>Text for warriors here.<<end>> "

If you like the more traditional approach:

desc()
{
    "Static text here. ";
    if (gPlayerChar.ofKind(Warrior) {
        "Text for warriors here. ";
    }
}

Or you can set it up in a totally different manner, like moving the description to a different method and call that from the desc() method. The usual stuff; I assume you’ve done some programming in C-derived languages like C++ or Java.

I don’t think it’s easy to put into code, to have different text for different characters (like: calculating the text for different characters and returning it). Looks a little messy but the easiest solution to just put the alternative descriptions for different classes into the text itself (like your example detailed).

Now i just need to get something workbench like running on Linux :frowning:

Coming back to this issue:

Could I just define a descWarrior and descMage, give each room a descWarrior and a descMage description in addition to the normal one? Wouldn’t this be the “cleanest” way to go? The point of view part seems… unclear to me. It’s designed if you use another, intermediate view (like a crystal ball?) but even how I could use it for that is not clear to me… could you please give a brief example?

What about calculated descriptions? The characters have an “strength” attriute now (defined in the main, where me is defined as actor, too). I would like to output a description of objects depending on this attribute like: “blabla static text” and when strength << 10 it should add “it looks too heavy to carry”.
Where would be a good place to put this?

That’s essentially what RealNC was suggesting. You can write a descWarrior property (or method), but the library is never going to call it. You would have to call it yourself. So:

desc() { "Static text here. "; if (gPlayerChar.ofKind(Warrior) { descWarrior(); } }

In the desc property of the object – something like this:

desc = "It's a boulder.<<if gPlayerChar.strength < 10>> It looks too heavy to carry.<<end>> "