Making Hyperlink Interface work

You’re right–I had misread the error message from the IFAnswers site.

So it looks like we need to change the Table of User Styles (continued) to this:

Table of User Styles (continued) style name fixed width boldness relative size color special-style-1 false bold-weight 0 "#0000FF" special-style-2 false bold-weight 0 "#339933"

and delete the Table of Common Color Values (continued)–would that do it?

…ah, what got me was that the continuation of the Table of User Styles doesn’t need to include every column of the Table of User Styles, as noted in the Glulx Text Effects documentation.

I haven’t tested it, but that looks pretty similar to the changes that were made to Keyword Interface.

github.com/i7/extensions/commit … dc212e3e36

Oh hey, that works! I’ve got a basic hyperlink bar in my test game! :smiley: It seems that the extension is conflicting with Small Kindnesses by Aaron Reed, but deleting the ‘Listing exits’ rules from Small Kindnesses shuts it up pretty quick. Thanks a lot guys, I’m going to tweak the extension a bit and see if I can’t get put it up somewhere for people to use. If nobody minds, I’ll try and get them to add it as an update the version in the extension database since Leonardo doesn’t seem to be around anymore. It would be nice if everyone could use this and I’m sure Leo wouldn’t mind if he’s gone for good.

By the way, I’ve made a major upgrade to the command line - it now lists directions like the exit lister mod, only these ones are hyperlinked. :smiley:

This is the set hyperlink command prompt rule: let count of exits be the number of viable directions; now the command prompt is "[set link 2]look[end link] | [set link 3]inv[end link] | [set link 1]menu[end link][line break][line break][if the count of exits is 0][It] [seem] there [are] nowhere to go.[otherwise if the number of viable directions is 1]From here, the only way out [are] to [d][a list of viable directions][x][otherwise]From here, [we] [can go] to [d][a list of viable directions][x][end if][Paragraph Break]>" (A);

Tangential, but I’d recommend you add an option to turn off the fancy command prompt. When I’m on my phone that’s likely to run off the screen.

Ok, I’ll add in a simple truth state that gives you the original prompt.

Fixed it for you! This will still drop the prompt one line so it’s clearer that there is a prompt. The hyperlink menu still makes messy duplicates once you have clicked it, but I can’t think of a way to stop it without using flexible windows or another extension.

[code]
ExtendedCommands is initially true.

This is the set hyperlink command prompt rule:
If ExtendedCommands is true:
let count of exits be the number of viable directions;
now the command prompt is “[set link 2]look[end link] | [set link 3]inv[end link] | [set link 1]menu[end link][line break][line break][if the count of exits is 0][It] [seem] there [are] nowhere to go.[otherwise if the number of viable directions is 1]From here, the only way out [are] to [d][a list of viable directions][x][otherwise]From here, [we] [can go] to [d][a list of viable directions][x][end if][Paragraph Break]>” (A);
Otherwise:
now the command prompt is “[set link 2]look[end link] | [set link 3]inv[end link] | [set link 1]menu[end link][line break]>” (B);[/code]

EDIT

One minor bug with that is that if there is nowhere to go, the game gives you a line saying “From here, you can go to nothing”. Clicking it doesn’t break the game, but it does show that the [if the count of exits is 0] line isn’t triggering and is automatically going to the last [otherwise]. Anyone know how we could fix this?

If you can use a construction like “if the number of viable directions is 1”, why do you need a separate “count of exits” variable for a construct like “if the count of exits is 0”?

This won’t answer your question, but it’s made me curious.

Oh, I just copied that from the extention’s own code. Thanks a lot, I’ll try it!

It works, but I have a new problem! If you can go in more than one direction, it screws up the hyperlink like so:

Meaning that the link is broken, since it is linking to that phrase ‘the north and the south’, not ‘the north’ and then after it, ‘the south’. Can anyone think of a way to fix this?

Hi guys, I’ve got a new problem! It seems that if you play my game for a while ALL hyperlinks of the [o]Link here[x] variety will just suddenly vanish and everything will be in plain text again. Often this seems to happen like this: You will click a hyperlink to go north, but only half the description for the room will load and you can’t see the > prompt. So you press a hyperlink to move on and it works, but suddenly there are no more hyperlinks. This seems to be happening pretty consistently and the problem continues even if you save and then load the game!

Since it continues even after you save and load, I’m thinking it’s something that something is accidentally turning most of them. It isn’t getting rid of all of them, however, as the inbuilt menu links still work if you type in ‘menu’ manually, and you can still see the hyperlink bar.

Can anyone help?

Oh, wait! Worked it out! Sorry! It’s what happens when you have tags set up like this [o]South [o]East[x]

[rant]It looks like Flexible Windows by Jon Ingold has been bit by the same problem and it’s documentation examples no longer work (because it includes 6L38’s newer version of Glulx Text Effects).
Anyone know of an update?[/rant]

Nevermind… I had to go to github and pretty much bleed the edge of all extensions. Looks like 6L38 already has several included extensions that are already out of date.

do you know if it’s possible to get a previous version of this extension, for the 6G60 inform7? All the ones I can find (including on github) are for 6L## version…

You may be able to use the extension on the inform7 web site - the web site versions are for old releases of Inform 7. If you’re using other extensions in your story make sure to get them from the same source so they are all compatible. Obviously, these old extensions don’t work with the latest version of Inform 7, 6M62.

Flexible Windows by Jon Ingold. Tested for Inform 7 version 6F95.

I’m still around, but my extensions on github are quite old in comparison to the version on another site:
sourceforge.net/projects/milleun … sions/3.0/
I’ll try to update them, but the new 6M62 has broken the “Italian Language” extension, and I want to find a workaround for it before considering to update the other extensions, since I wrote IF in italian and “Italian Language” is fundamental.

Here is a 2009 version: prdownloads.sourceforge.net/mill … p?download
Here another of 2013: prdownloads.sourceforge.net/mill … p?download

The second one is compatible with 6G60.

Thanks a lot Leonardo! I managed to include it in our 6G60 game, and it works like a charm. ifiction.free.fr/concours2016/ob … play2.html (it’s only in French)

Great! It works very well. I’m happy to see that finally someone (me apart) has included Hyperlink Inferface in his own work.