Vorple in Glulx mix

#1

Okay, now I am asking the impossible.

I am using Glulx for a LOT of reasons I can’t avoid, but really want to include one Vorple function.

The ‘Wiki’ lookup function. I am comfortable with picking apart I6 code to get just the few functions I need if I have to.

But is it even possible to add something like this from Vorple (where it works great) to a Glulx project? And in a Glulx interpreter? The Vorple interpreter does not support the other functions I need for this project.

Release along with JavaScript "encyclopedia.js".

Looking up is an action applying to one topic.
Understand "look up [text]" as looking up.

Carry out looking up when Vorple is supported:
	place a block level element called "dictionary-entry";
	execute JavaScript command "wikipedia_query('[escaped topic understood]')";
	say run paragraph on;
	block the user interface.

I am guessing not… but if possible, it would be a great addition to those of us using Glulx for functions not supported by Vorple.

Thanks!

0 Likes

(Daniel Stelzer) #2

On the plus side, the latest versions of Vorple do use Glulx, so in theory Glulx-specific things can work fine.

On the minus side, Vorple is fundamentally a different interpreter, which is how it’s able to offer all its web-based functionality. There’s no way to do Vorple things in a non-Vorple interpreter. So if you’re relying on something that even the newer Glulx Vorple interpreter can’t handle, you’re out of luck. You’ll have to pick one or the other.

2 Likes

#3

This reminds me of a Glk function I’d like to see added: open a URL (in the user’s default browser). Specifying it wouldn’t be difficult, just getting the interpreter authors on board. But it’s good to know that there are game authors who would make use of it.

1 Like

(Nathanaël Marion) #4

Technically, you could hack Quixe (which supports most of Glk features) to make it execute JavaScript. It won’t be as sophisticated as Vorple, and may not be a really good idea, but it may work for your use case.

(I think @mathbrush did something like that, where he used the status line to execute JavaScript?)


Vorple does not implement the majority a Glk features because it’s possible to add them with HTML, CSS and JavaScript, and even make them more sophisticated.

Want multiple windows? Use HTML blocks and CSS to arrange them. Want sounds? Use the Web audio API (or a JS library that use it, such as Howler.js; I made an Inform extension that interfaces with it.) Want real time? Use JavaScript timers. And so on.

But then, I agree that if you don’t have notions in Web development, it’s not straightforward at all. What features are you using? If you really want to go the Vorple route, I can try to help you.

0 Likes

#5

All of the above actually. Having the Wiki lookup feature would be cool… but it is really not needed. This project is going to be used as a learning tool so I don’t want to make it too complicated for a beginner, I just want to show off some of the best features (and wow them with the possibilities) then allow the students to either write their own or hack mine up to get more experience. I will probably make a Vorple example too so they can see what it can do, but just the basics. No web-dev required. That would have to be a separate class. :wink:

So I may take you up on your offer of help… once I get this project as “blinged-out” as possible and ready for the summer class. I am pretty good at web-dev, so I will probably just need to be pointed in the right direction.

I would like to get more knowledge of Vorple… and knowing it can be customized this way is going to prod me to try it.

0 Likes

#6

I really really hate this idea. I play my IF mostly on a computer that has a default web browser, but I want my IF interpreters to leave it alone. I don’t ever ever play IF online. Have you thought about the privacy and security implications?

0 Likes

#7

Well as with other multimedia features it would make sense for an interpreter to give you the option to disable it, or to approve opening the page each time. (This should perhaps be recommended.)

I can’t see any security implications. I appreciate that there would be a potential privacy issue as it could be used to track who is playing the game, but they could also just track who originally downloaded it. Low impact IMO.

1 Like

#8

I agree… every access to the Internet is a risk, so an IF game from a trusted source has the same or less risk because the links have already been vetted. Now would I open an IF game I found on some sleazy site, or from a random spam email… Of course not. I would use the same judgement I use when I am on the Internet for any reason.

0 Likes