intfiction.org

The Interactive Fiction Community Forum
It is currently Sat May 25, 2013 5:37 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 ... 16  Next
Author Message
PostPosted: Mon Aug 15, 2011 8:11 am 
Offline

Joined: Sun Aug 14, 2011 6:21 am
Posts: 127
Campbell wrote:
I don't think IFDB recognises it as the Babel software is out of date. I've sent an email to IFDB support about this. You can see an example here. As for the blorb extension, I would have been happy with .ablorb, but Zarf wasn't keen on that as there are other systems beginning with a, and .adriftblorb just seems too long an extension.


Ok thanks. I just tested it and the Grotesque software recognizes it as an Adrift file.

Now, back to the original concern. Grotesque chooses which interpreter to use based off of which format the story is in, not based off its extension. If someone would prefer to use a different interpreter for each version of Adrift, for example, it still is no problem to create three formats, say, adrift3, adrift4, and adrift5, assign whatever extensions they want to them and their respective interpreters. Then, when stories are imported, they would have to manually change the story format to use whichever interpreter they prefer. There's really no way for me to automate this.

If the user imports a file that can't have its Treaty of Babel info read, and it has an extension which is shared by multiple formats, then it will just have to default to "Unknown" for its format.

_________________
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 8:12 am 
Offline

Joined: Sun Aug 14, 2011 6:21 am
Posts: 127
Peter Pears wrote:
I suppose in terms of Grotesque it's not really that big a problem, for the end-user - if I can set some games as "GitGlulx" and others as "Glulx", surely I can set some games as "Blorb" and "AdriftBlorb".

But it does bother me that I might have to change file associations - which program am I going to want to open blorb files? If I could at least rename "blorb" to "adriftblorb" myself and know that despite the different extension ADRIFT was going to recognise it as an ADRIFT game... but I tried that in TAF, I tried making .t39 and .t4x extensions, and ADRIFT wouldn't open the files saying they weren't TAF...


The way Grotesque is set up, you shouldn't have to change the extensions. You can just work with the formats, which are only stored in Grotesque's library and do not affect your files.

_________________
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 8:23 am 
Offline
User avatar

Joined: Mon Jun 14, 2010 7:49 am
Posts: 208
You could always do what Microsoft do when opening a *.sln file. It opens with "Microsoft Visual Studio Version Selector" which analyzes the file, then sends to the relevant executable. In the case of a Blorb it should be easy enough to analyze it to grab the Executable format, then process as appropriate.

_________________
ADRIFT Developer developer.


Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 8:26 am 
Offline

Joined: Mon Dec 07, 2009 5:14 am
Posts: 902
To jakobcreutzfeldt: Yeah, I know, I was just thinking aloud about my file associations regardless of Grotesque.

Incidently, as long as I'm here, I had a thought... it would be aces if you could allow ".lnk" files (shortcuts) to be added to the list and executed normally. You see, my new Windows doesn't seem to run any DOS-based IF by itself, so I use Dosbox and D-Fend to create shortcuts I can just double-click to play. If I can't put those shortcuts in Grotesque, I can't really add DOS-games to the library.

By the way, you said:

Quote:
this will only work if your emulator allows you to launch files from a command line like: spectrum.exe game.tzx


What if the emulator works more like:

"C:\Interactive Fiction\Tools and Interpreters\AppleWin\Applewin.exe",1

That extra "1" in there. I know very little about these things, but some of my programs don't load properly on double-clicking the file unless there's that "1" or maybe "%1" after the filename, as a parametre. Would this be an inconvenience?


Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 8:33 am 
Offline

Joined: Sun Aug 14, 2011 6:21 am
Posts: 127
Campbell wrote:
You could always do what Microsoft do when opening a *.sln file. It opens with "Microsoft Visual Studio Version Selector" which analyzes the file, then sends to the relevant executable. In the case of a Blorb it should be easy enough to analyze it to grab the Executable format, then process as appropriate.


This is more or less what's happening. If you open a .blorb file, it checks the format and opens the appropriate interpreter. Since I've (just now) determined that it's correctly extracting the format to be Adrift or Glulx or whatever from .blorb files (to continue the example), it will always choose the interpreter that you set for those formats.

_________________
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 8:40 am 
Offline
User avatar

Joined: Mon Jun 14, 2010 7:49 am
Posts: 208
Cool. :D

_________________
ADRIFT Developer developer.


Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 8:42 am 
Offline

Joined: Sun Aug 14, 2011 6:21 am
Posts: 127
Peter Pears wrote:
Incidently, as long as I'm here, I had a thought... it would be aces if you could allow ".lnk" files (shortcuts) to be added to the list and executed normally. You see, my new Windows doesn't seem to run any DOS-based IF by itself, so I use Dosbox and D-Fend to create shortcuts I can just double-click to play. If I can't put those shortcuts in Grotesque, I can't really add DOS-games to the library.


I'm not sure how trivial this is; I'll have to look. But in the case of Dosbox, you can just set the interpreter as dosbox (or the full path to the dosbox executable) and then import the .exe games as normal. When Grotesque launches them, it will correctly handle sending the game to Dosbox. This, at least, is working fine on my system. I'd love for you to try it on 0.9.2 to let me know how it works. The shortcuts shouldn't be necessary...

Quote:
By the way, you said:

Quote:
this will only work if your emulator allows you to launch files from a command line like: spectrum.exe game.tzx


What if the emulator works more like:

"C:\Interactive Fiction\Tools and Interpreters\AppleWin\Applewin.exe",1

That extra "1" in there. I know very little about these things, but some of my programs don't load properly on double-clicking the file unless there's that "1" or maybe "%1" after the filename, as a parametre. Would this be an inconvenience?


I haven't used AppleWin before. How do you typically use it? Do you start the application and then from within the application, select and open a game to run? If this is the only way to do things, there's no way for Grotesque to launch AppleWin and tell it which game to run. If you're comfortable with a DOS-like interface, you can launch the Windows command prompt (in the start menu, type cmd.exe in the search box), navigate to C:\Interactive Fiction\Tools and Interpreters\AppleWin\ and then type Applewin.exe followed by a path to a game for which you would normally require this emulator, and hit enter to try to launch it. If that works, then yes, you can use it in Grotesque by setting the interpreter as that full path (no 1 or %1 needed).

After I finish 0.9.2, we can give it a try.

_________________
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 8:48 am 
Offline

Joined: Mon Dec 07, 2009 5:14 am
Posts: 902
Re applewin: ah, too bad, it just loads up the program. See, that's one of the reasons I would sometimes prefer to let Windows handle that sort of thing... would it be too much of a hassle to make it toggleable, or something? Or do "Unknown" file-types default to allowing the OS to do whatever it thinks best? Because in that case I might just leave these files as "Unknown" and be the happier for it. :)

Re DOSBOX: I can do it like that, I suppose... I just like the D-Fend way of doing things... but if Grotesque were to just assume it as "Unknown" and allow the OS to run it normally, then it would work well enough, I suppose...

I hope I'm not being too much of a pain - you're doing a wonderful job. :)


Top
 Profile Send private message  
 
PostPosted: Mon Aug 15, 2011 9:27 am 
Offline

Joined: Sun Aug 14, 2011 6:21 am
Posts: 127
Peter Pears wrote:
Re applewin: ah, too bad, it just loads up the program. See, that's one of the reasons I would sometimes prefer to let Windows handle that sort of thing... would it be too much of a hassle to make it toggleable, or something? Or do "Unknown" file-types default to allowing the OS to do whatever it thinks best? Because in that case I might just leave these files as "Unknown" and be the happier for it. :)

Re DOSBOX: I can do it like that, I suppose... I just like the D-Fend way of doing things... but if Grotesque were to just assume it as "Unknown" and allow the OS to run it normally, then it would work well enough, I suppose...

I hope I'm not being too much of a pain - you're doing a wonderful job. :)


You're not being a pain, you're helping me make Grotesque the best program possible! Ok, ok, the best program with some bugs here and there, but good nonetheless. :P

Re: AppleWin, that's a shame. But...When we get 0.9.2 up and running (I think I've finished the GTK3 one, then I have to port to GTK2, then I have to build the Windows version), we'll try it anyway following what I've done for getting Dosbox to work:

So the best practice now would be to first set up your interpreters, and then import your library. So, in addition to the default formats supported by Grotesque, I added a format called "dos" (no quotes). In the interpreter, I set it as "dosbox" (which my system knows means the application; I could have also provided the full path). For extensions, I put "exe,bat", since DOS games are usually either executables or batch files.

Next, I imported a folder which contains the original Zork. When importing a folder or individual files, Grotesque now knows to also look for *.exe and *.bat files. It found two .exes, in the Zork folder but it couldn't extract ToB info from them so it drops me into edit mode. The first .exe was some other utility and not a game, so I hit 'Cancel', which skips it. For the actual zork.exe, Grotesque saw the .exe extension and, since no other formats use .exe, it figured that it must be a "dos" format game. If you click the big play button in the edit dialog, it launches Dosbox and Zork starts up right away. I went on IFDB, found the IFID for Zork and entered it in the field, hit the search button and the rest of the metadata was automagically filled.

So now, all .exe files are automatically recognized as Dosbox games. If it were a blorb and Grotesque can't extract the metadata, though, the format would be unknown, because it can't figure it out just from the extension.

Incidentally, I realized that ever since the original 0.2.1 code that I inherited, TADS3 games were being ignored (it wasn't looking for the .t3 extension)! So that's fixed too!

I think with this version, it will be much more stable and I can focus on smoothing out whatever rough edges and filling whatever holes remain.

_________________
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 10:27 am 
Offline

Joined: Mon Dec 07, 2009 5:14 am
Posts: 902
It seem an ideal way of going about it. :)


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 ... 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