intfiction.org

The Interactive Fiction Community Forum
It is currently Sun May 26, 2013 3:39 am

All times are UTC - 6 hours [ DST ]




Post new topic Reply to topic  [ 152 posts ]  Go to page Previous  1, 2, 3, 4, 5, 6, 7, 8 ... 16  Next
Author Message
PostPosted: Mon Aug 15, 2011 2:12 pm 
Offline

Joined: Sun Aug 14, 2011 6:21 am
Posts: 127
After a national holiday well spent, I present to you version 0.9.2!
https://sourceforge.net/projects/grotes ... que/0.9.2/

0.9.2 Release Notes
  • The program will no longer crash upon failing to extract metadata from a file
  • Fixed a bug which prevented editing stories in GTK2/Windows
  • Added support for associating file types (extensions) with story formats
  • Added the ability to manually specify the story format in the edit dialog
  • Fixed the bug which prevented TADS3 games from being noticed during import
  • Made file availability during import depend on the file type extensions set by the user (ie whether Grotesque tries to import a file during recursive import or whether a file is visible during individual import)
  • Added automated library backup/recovery
  • Fixed a bug which prevented adding an interpreter
  • Added a button for finding an interpreter via a file dialog when adding/editing interpreters.
  • The Windows version should actually be able to save/load the library now. If you used 0.9.1 and 0.9.2 says that your library is corrupted, don't try to recover it. It'll fail. I'm sorry to say that Windows users will have to re-import their library

I'm pretty sure that this one is a lot more stable and solid than 0.9.1, but as always, your thoughts, bugs, ideas, etc are all welcome!

_________________
Grotesque: an interactive fiction library manager for Linux
PyIFBabel: a Treaty of Babel library for Python


Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 2:29 pm 
Offline

Joined: Sun Aug 14, 2011 6:21 am
Posts: 127
Tutorial: How to add support for a new story format

Out-of-the-box, Grotesque supports zcode, TADS2, TADS3, ADRIFT, and Glulx stories. Of course, there are many more formats out there than just these. Fortunately, it's easy to add support for other formats in Grotesque. In this tutorial, we'll add support for old DOS games using DOSBox to launch them.

1) First, we need to let Grotesque know about the DOS format. Click the Preferences button and switch to the Interpreters tab. Click the Add button. In the dialog that pops up, we have three fields to fill out. The first one is the format, which we will use to identify games. Type in "dos" (without the quotes). In the next field, we enter the extensions of files of this game format. Most DOS games have either .exe or .bat as their extension. Enter "exe,bat" (again without the quotes). But, don't worry. If you put spaces in there, or you include the leading ".", Grotesque will clean it up and put it in the format that it wants. Finally, we need to specfy DOSBox as our interpreter. We can click the Open button to try to find it on our filesystem, but say we know that it exists at "/usr/bin/dosbox", so we can just type it in directly. Click "OK" to finish and close the Preferences dialog

2) Let's say you store all of your DOS games in one folder. We'll import it by clicking the button with the folder on it, finding the folder and clicking OK. Since we told Grotesque that we expect some of our games to have .exe or .bat as their extension, it will now grab those files when it imports. However, it won't be able to extract any bibliographic information from them, so you will have to manually edit them.

3) The edit window will show the executable's name and will show that it's in the "dos" format. If you're not sure which game it is from the executable name, click the Play button on the edit dialog to launch the game and figure out what it is. Then, it's easiest to go to http://ifdb.tads.org and search for that game. Copy the IFID listed in the game information if it has one and paste it into the appropriate field on the edit dialog. Click the Search button and the rest of the fields will be filled in (and, if there is cover art on IFDB, it will be downloaded as well). If there's no IFID, sadly you'll have to fill it in manually. Click OK when you're finished. If there are more games to edit, you will move on to the next one, otherwise you're finished and you can play them now! Since .exe files are common and not all of them are IF games, if Grotesque tries to import some non-IF one, just hit cancel on the edit dialog and it'll skip it.

Please note that this will only work if your interpreter can launch a game from the command line. If you can only open games from within the interpreter's own graphical user interface, Grotesque won't be able to work with it.

If you need help with anything, let me know!

_________________
Grotesque: an interactive fiction library manager for Linux
PyIFBabel: a Treaty of Babel library for Python


Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 2:45 pm 
Offline

Joined: Mon Dec 07, 2009 5:14 am
Posts: 902
Looking seriously good, but I'm sorry to say that Adrift is one of those cases where all Grotesque can do is launch the app... but hey, I thought of something: wouldn't it make sense for Grotesque to try to run a game with the interpreter the user defines... but if the user defined no interpreter at all then use the usual OS file association?

By the way, in windows double-clicking on a game still doesn't launch it.

And hey... great work. :)


Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 2:53 pm 
Offline

Joined: Sun Aug 14, 2011 6:21 am
Posts: 127
Peter Pears wrote:
Looking seriously good, but I'm sorry to say that Adrift is one of those cases where all Grotesque can do is launch the app... but hey, I thought of something: wouldn't it make sense for Grotesque to try to run a game with the interpreter the user defines... but if the user defined no interpreter at all then use the usual OS file association?

By the way, in windows double-clicking on a game still doesn't launch it.

And hey... great work. :)


Damnation, I forgot to test the double-clicking.

Ok, I'm also having errors running adrift games. I'll look into that.

As for using the OS defaults, I'm afraid that's non-trivial to implement. :( If I do it, that'll come at a much later time.

These problems aside, I hope that you can at least use it for most cases!

_________________
Grotesque: an interactive fiction library manager for Linux
PyIFBabel: a Treaty of Babel library for Python


Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 2:57 pm 
Offline

Joined: Sun Aug 14, 2011 6:21 am
Posts: 127
Scratch that. I can run *.taf ADRIFT games with no problem. If I try to run a *.blorb one, it fails, but it's not Grotesque that's failing, it's Gargoyle.

Can you send me a link to an ADRIFT game that's failing for you?

_________________
Grotesque: an interactive fiction library manager for Linux
PyIFBabel: a Treaty of Babel library for Python


Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 3:03 pm 
Offline

Joined: Mon Dec 07, 2009 5:14 am
Posts: 902
Oh, I just tested with Adrift 5 (which I haven't used and don't plan on using until it allows me to customize fonts and colours and until it plays 3.90 games), and with Adrift 5 it does work.

Pity to hear the OS default thing is not trivial... it would have allowed for every instance where for some reason or other something didn't quite go as well as planned.

EDIT - Hey, I found a way to use D-Fend with Grotesque. ;) Things look a log uglier in D-Fend, but I can now load it from Grotesque, so it's perfectly ok.

BTW, I thought up two suggestions for the future.

1 - the OS thing. It's always good to have, even if it's a lowlowlow priority. And that's it, I won't ever pester you with it again. :)

2 - an option to open the folder of the game. I know it sounds unnecessary, but many games have feelies, manuals, graphics, critical for play. If we could open the folder where the game is located, if we have all our feelies there, we can easily access them.

And that's it from me. I'm now off to happily export my IF library to a front-end I've been dreaming of for years.

:D

EDIT 2 - The only problem I foresee is when I want to play Windows games. Naturally, there's no emulator for those... I mean, I CAN create an "interpreter" entry for every Windows-only game... like an interpreter called "Adventures in Egypt", linking to the game, then create the entry for "Adventures in Egypt" and put - you guessed it - "Adventures in Egypt" as the format. THAT works. It's ugly and hacky but it works. ;) I might well do that.


Last edited by Peter Pears on Mon Aug 15, 2011 3:19 pm, edited 1 time in total.

Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 3:17 pm 
Offline

Joined: Sun Aug 14, 2011 6:21 am
Posts: 127
Peter Pears wrote:
Oh, I just tested with Adrift 5 (which I haven't used and don't plan on using until it allows me to customize fonts and colours and until it plays 3.90 games), and with Adrift 5 it does work.


*phew*

Quote:
EDIT - Hey, I found a way to use D-Fend with Grotesque. ;) Things look a log uglier in D-Fend, but I can now load it from Grotesque, so it's perfectly ok.


Cool! Technically, it's so flexible now that you can use it with just about anything...got a bunch of old non-IF games? You can now organize them with Grotesque (not that I can support such deviant behavior, of course)

Quote:
1 - the OS thing. It's always good to have, even if it's a lowlowlow priority. And that's it, I won't ever pester you with it again. :)


Don't worry, I'll keep it in mind. If someone else has already written a library in Python which implements similar behavior, I can just use that rather than re-inventing the wheel. So, I'll look into it!

Quote:
2 - an option to open the folder of the game. I know it sounds unnecessary, but many games have feelies, manuals, graphics, critical for play. If we could open the folder where the game is located, if we have all our feelies there, we can easily access them.


Ah good idea! I've thought of that too. I've been trying to think of the best way to do it though. Right now I like how Grotesque has a fairly minimal interface with few buttons and no menus. I've planned to include in each game's description some hyperlinks to the game's presence on the web (IFDB site, etc). I think I can also include a Open Game Folder hyperlink that doesn't link to the web but opens a folder instead. I need to experiment though. This will be in by 1.0 for sure!

Quote:
And that's it from me. I'm now off to happily export my IF library to a front-end I've been dreaming of for years.

:D


Glad to hear that you like it! As you use it more if you think of other ideas that could improve it, just let me know.
I hope your library isn't so big it's going to launch a denial-of-service attack on the IFDB site :D
(seriously...we should all probably do it a bit at a time, just out of politeness :P)

_________________
Grotesque: an interactive fiction library manager for Linux
PyIFBabel: a Treaty of Babel library for Python


Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 3:23 pm 
Offline
User avatar

Joined: Wed Feb 03, 2010 4:25 pm
Posts: 264
Location: Sweden
Peter Pears wrote:
Pity to hear the OS default thing is not trivial...

I don't know Python, but if you can call the Windows API from it (is that possible?), it is trivial to do in Windows: Simply call ShellExecute on the filename. Sorry if that's completely irrelevant (I mainly use C, C++ or ObjectC).

_________________
"The thing I like about deadlines is the wonderful whooshing noise they make as they go past."
- Douglas Adams


Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 3:37 pm 
Offline

Joined: Sun Aug 14, 2011 6:21 am
Posts: 127
Turns out that the functionality is built-in for Windows. There's a 3rd party library that implements it for Gnome & KDE, and its license allows me to bundle it with Grotesque!

Ok, so how about this:
In the settings dialog, on the Interpreters tab, at the top there's a checkbox that says something like "Use Operating System Defaults". If that's checked, the interpreters list and the add/edit/remove buttons are all inactive (greyed out). Launching any game will use this method to let the OS figure it out. It's up to the user to make sure the OS has programs associated with all the filetypes. If the checkbox is unmarked, the user can specify interpreters as he/she wishes.

Alternative, less obvious method:
The user simply leaves the interpreter field blank for any story format that he/she wants the OS to handle. This way, a mixed strategy can be used, with some formats having their interpreters specified and others under OS control.

Which do you prefer?

_________________
Grotesque: an interactive fiction library manager for Linux
PyIFBabel: a Treaty of Babel library for Python


Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 3:40 pm 
Offline

Joined: Mon Dec 07, 2009 5:14 am
Posts: 902
Honestly? Both. :) Have the checkbox and, if the checkbox is unchecked and the interpreter field is empty, launch the OS default.


Top
 Profile Send private message  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 152 posts ]  Go to page Previous  1, 2, 3, 4, 5, 6, 7, 8 ... 16  Next

All times are UTC - 6 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group