Turning a topic into interactive fiction ;)

AI-generated summary

The discussion starts with post 1 where merefield shares an interactive fiction game plugin that can be embedded in Discourse using an iframe. fearlessfrog thanks merefield and notes that adding the iframe URL to the allowed iframes config setting enabled embedding the game.

merefield replies that the results can look quite seamless and suggests not letting the game be too distracting from fearlessfrog’s project post 3. JanJoost discovers the game and is excited to try it out post 4.

smrtey shares that combining the iframe game with the media overlay component allows the game to be popped out while browsing the forum post 5. merefield previews a prototype to take things further post 6, and shares the released plugin in post 7.

Finally, Dannii, the maintainer of the Parchment iframe content, appreciates seeing it used but notes limited time for improvements to iframe embedding post 8. Overall, the discussion centers on using an iframe to embed interactive fiction games into Discourse, with positive reactions from the community.

:information_source: check out the plugin version of this here: Discourse Frotz 🧙

After whitelisting the URL, I embedded this iframe into a post in the Lounge for a bit of fun.

Result?: A fully working piece of classic Interactive Fiction embedded in a post that doesn’t look too out of place :slight_smile: (although you do need to manually scroll)

Why?: because you can

<iframe src="https://iplayif.com/?story=http%3A%2F%2Fwww.douglasadams.com%2Fcreations%2Fhhgg.z3" width="800" height="800" frameborder="0"></iframe>

Feel free to pull me up on security if you believe this is opening a hole … but iplayif.com is legit, I believe, here’s its GitHub page

In case you are not a Douglas Adams fan, you can find much more great work here.

11 Likes

Thanks!

I hadn’t used the Admin / Settings / Security / allowed iframes config setting before, but putting in https://iplayif.com/ in there and adding that iframe into a post worked great.

3 Likes

Yeah, it’s amazing how seamless the result can look :slight_smile:

PS Please don’t let it distract you too much from your interesting project, though :wink:

Oh wauw - only just discovered this, but THANK YOU!

Well, there goes my Sunday …

1 Like

Not sure how I just came across this but it’s lots of fun and combined with the Media Overlay component you can pop out the game and have it open as you continue browsing the rest of your forum, though you’ll want to make the iframe a little narrower so if doesn’t cover so much of the page. I found a width="400" works well

1 Like

OK, I’ve taken this a bit further … watch this space :wink:

4 Likes

The above prototype is now released here Discourse Frotz 🧙 - #2 by merefield

2 Likes

This is cool! I’m the maintainer of Parchment/iplayif.com, so it’s great to see it getting used.

Unfortunately I haven’t had the time or energy to work on it much recently. I would like to improve how it works when embedded in an iframe.

4 Likes

Hey @Dannii great to meet you. For the stories I tried it works very well save for the very minor scrolling issue. Thanks for your hard work to help keep all that great legacy alive!

1 Like