I am coding a mapper

It’s extremely early days, but, just in case anyone might want a new mapper, I will outline my plans and invite comments and suggestions. That seems a better approach than coding it, announcing it, and getting a bunch of change requests. It will run natively on Widows, Mac & Linux.

So, here a rough overview of proposed functionality, all of which is negotiable - including the name, and suggestions for further features are welcome. I give no guarantee of completion, although Plugh! shows that I can put a lot of effort into a project.

  • Add/rename/delete locations, aka rooms
  • Add/delete passages between locations
  • Add/rename/delete/move items
  • inventory is just a special location? NPCs too, I guess
  • Attach notes to items, locations and passages
  • attributes, some defaults, plus user defined - light, dark. water, unsolved puzzle, NPC, etc
  • Search - items. locations, “all” - start/contain/end with, given text, plus optionally with given attribute(s)
  • nested locations - e.g the note is in bag, which is in the car, which is in the garage

There’s a very, very basic webpage with a few screenshots at http://herebedragons.great-site.net/?i=1

3 Likes

Hi, nice to see this sort of thing :slightly_smiling_face:

I’m really interested in story design tools.
What GUI library are you using, by the way?

1 Like

Some quick questions:

  1. What does this do?
    I mean, does it draw maps or does it generate code in some IF language. Or both?

  2. Can there be a text format import/export

1 Like

I am using Embarcadero’s Delphi (not sure why I chose OO Pascal over C++), community edition, which is free and one set of code can generate executables for Windows, Linux, Mac, Andoid & iOs. See https://www.embarcadero.com/

Once it is stable, I will open source it for others to fork.

If you would like to suggest anything, please do

1 Like

What does it do? What would you like it to do?

I really wanted an automapper, to take the tedium out of handdrawing maps as I play. But, several threads here have convinced me that that is not possible. i could get close, but never 100% accurate.

Since I don’t author, this will initially be a player aid. To be honest, the only major advantage I see over paper is the search functionality.

It won’t take long to complete, at which point, I can add authoring features. Can you think of any, other than code generation?

If you do want an authoring system, perhaps I should resurrect Wayback Machine ?

That is a 95% complete, good enough to use, tool for TADS (can’t remember if it was TADS 2 or 3), with round trip editing.

It had a few users, including one school’s creative writing class. IIRC, it is as good as complete, but I got bogged done in the esoterica of the verb system - making it full Object Oriented, so that verbs could be built on top of other verbs. Technically required for completeness, but nit very likely to be used.

Perhaps I should resurrect it & support a few more languages? Please take a look & let me know what you think. Thanks

1 Like

I tried out Plugh, but it was only for TADS. The problem with code generation is that the target moves!

Here’s a suggestion:

Your new mapper doesn’t generate any system specific code. Instead it emits a well-documented text format, that’s also human readable. This format is also the import format for round tripping.

Developed separately are a bunch of tools or scripts that convert that format into specific IF systems script. Separation means the mapper tool does not have to constantly accommodate changes in other system formats and it is always possible to whip up a new conversion tool.

A while back I wanted to write a conversion tool from Trizbort to do exactly this. But as i understand it, Trizbort’s save format is intended as internal rather than a stable export format.

Edit: Forgot to add, the mapper export format needs also to be easy to parse syntactically.

3 Likes

This looks great. I also prefer Wirthian languages over C-likes. A part of me wishes you were using Lazarus / Free Pascal rather than Delphi but it’s your project and a hobby one at that so you have my full support! :slight_smile: Looking forward to checking it out!

3 Likes

Seconded. Especially because TADS in particular is not restricted to a single specific world model, so it might be necessary for a particular TADS game to have its own converter for the map software.

2 Likes

thirded! ( is that a word? :thinking: )

actually, i’ve always been curious about trying something like Graphviz https://graphviz.org/ or Mermaid State diagrams | Mermaid for that

They both use text descriptions to make graphs, and so maybe that same text format could be used for maps… and from there into or out of some particular if system. ( Graphviz also has a visual editor)

also, @mawg, don’t know if it’s helpful, but i know Inform7 has a mapper in it. if that’s part of its Github source, it might be a nice reference. ( tho i haven’t looked at it so i’m not even sure what its licensing terms are )

2 Likes

GraphViz is a wonderful tool and I use it for all sorts of things, but fundamentally it’s designed not to specify the exact positions of things, which makes it tricky to use for mapping.

2 Likes

fourthed !! :smiley:

Best regards from Italy,
dott. Piergiorgio.

2 Likes

oh yeah, good point. you’d get a relationship between rooms, but not specific positioning or distances. ( and Inform’s mapper might be similar. Though it probably does a bit better at specifically square maps - like room connections - than Graphviz or Mermaid would do by default )

1 Like

Excellent point about Graphviz (and others). It would be, at least, feasible to convert the output into graphviz or any other system.

2 Likes

This is an excellent idea !! Thanks. I am leaning towards XML as a save file format. What do you think?

Any comments on Plugh? Should I develop it further, rather than this new project?

I can understand why you lean to Lazarus. It’s a great project. I tend to use Delphi because of the many free VCL components. It’s free, as in beer, if not as in speech. But, yes, I really ought to support Open Source.

Please, feel free to suggest features

I used Graphviz a lot. I am a great fan of tools which take their input form text files and develop a lot of tools which generate such input. If you use Message Sequence charts, you simply can’t beat msc-generator / Msc-generator · GitLab The author is extremely helpful and quick to respond, even to add new features.

If I used Gaphviz in a project, though, it would have to generate the map every time a change was made. And every user would have to install Graphviz.

So, alas, no auto-layout, but you can drag the rooms around and the passages will remain linked.

1 Like

Trizbort uses XML. You might like to take a look at that to see if it works for you.

1 Like

that’s a good recommend. i also really like: https://sequencediagram.org/ – it’s not opensource, but it is free to use.

imo, json can be a bit nicer on the eyes, as can yaml. but, if you use some standard ( like xml, or the others ) it’s not too hard to translate between them.

Trizbort is really cool. It’s interesting that, because most if games don’t have specific room sizes or room positions – its custom format is “larger” than all the formats it exports.

It’d be kind of wild to take a 2D editor ( like Tiled ) and do something similar. Using its layers ( or something ) to define different rooms, and then sprites to indicate doors and directions. ( A door sprite with an up arrow on it is north, for instance. )

1 Like

XML would be a good choice, but by no means the only one.

With XML, you could go the whole hog and make a DTD schema for the formal specification. You could also build a XSLT translator that maps the XML into, say HTML for easy reading.

On the downside, DTDs are often quite impenetrable unless you’re custom to them and might be harder for the casual reader to understand as docs.

A different idea altogether, but one more risky would be to invent your own domain specific description language for maps. On the plus side this could be made much more suitable to IF. But on the downside you are at risk of making something where you might run into a design limitation later on.

Nevertheless you have the same design problem regardless of the representation. In XML, for example, you have to design your tag space and properties that you will accommodate. So just choosing XML doesn’t give you answers to how you will represent information - only the syntax.

1 Like

Please consider JSON over XML. XML is horrendously verbose and there are so many good, easy-to-use parser libraries for JSON.