Pheonix on 30/10/2012 at 13:51
Ok, working with Snobel (Thief 3 Sneaky Upgrade creator,) a couple of changes have been added to FMSel. The new dll file and full source are available here (
http://www.filedropper.com/fmsel) FMSel.zip I have no idea about the file server I'm using (just did a google search for file hosting and picked one that didn't cause a bunch of pop-ups when I went there. So if someone wants to mirror it, please do so :)
The changes:
First Snobel put in some changes I don't know the details too that will make it work with the next version of (
http://www.ttlg.com/forums/showthread.php?t=138607) Sneaky Upgrade currently being tested. He also helped by checking over my code and cleaning it up for me (I'm not very good at programming.)
Second, I added in a method to Clean the Database of bad entries. The original had an advanced option (hold CTRL down while right clicking on an entry or left clicking on the gear icon,) that would allow you to delete an entry in the database. The problem with what was included is that if you had multiple entries that needed removing it could get tedious. Now, if you hold CTRL and left click on the gear icon (settings,) there is an entry "Clean DB" that will scan the entire DB and remove all entries that do not have an archive or an install. May not really be needed but I like it. If you remove a batch of FMs from the archived directory and delete all the install folders, you can just use that to clear them all out of the DB without having to lose any of your other DB info (missions completed, ratings, etc...)
Finally, I added in an option that will allow the sorting process to ignore leading articles in the mission names (The, An, A) while sorting. In most cases when something is alphabatized (sp?) those are ignored (Books, Music, etc...) The option defaults to off, though, so if you don't want to use it, you don't have to do anything. If you do, just click on the gear icon (settings,) and click the little check box. Currently it only works with english, as that is the only language I know. I have considered trying to come up with localization code that would change what is looked for depending on the language set by the host sytem. The problem is, I don't know if anyone really wants or needs it and I don't know what words would be skipped in other languages.
The final change I thought about, but haven't done anything with, mainly because I don't particularly want it, is to have the displayed name actually move the leading articles to the end like other programs did. It would be another on/off option, and I really would only do it if a lot of people really wanted it.
clearing on 30/10/2012 at 15:28
Quote Posted by Pheonix
Ok, working with Snobel (Thief 3 Sneaky Upgrade creator,) a couple of changes have been added to FMSel. The new dll file and full source are available here (
http://www.filedropper.com/fmsel) FMSel.zip I have no idea about the file server I'm using (just did a google search for file hosting and picked one that didn't cause a bunch of pop-ups when I went there. So if someone wants to mirror it, please do so :)
Mirror: (
http://darkfate.org/view/details/files/projects/thief_2_v1_19/FMSel.zip) FMSel.zip
Hit Deity on 7/11/2012 at 16:03
I've not been able to get this to work either. Followed all the instructions, and no matter what I pick (Skip.. or Load..), Dromed always starts up in vanilla mode. No fm loaded, just the starting 16x16x16 cube with nothing loaded. Must've missed something simple..:grr:
I'm tired of fooling with it though after an hour or so. Going back to Dromeding. If it's still behaving, that is.
Pheonix on 8/11/2012 at 23:45
Ok, I've made several changes based on messages of what people want. I used the source from snobel's sneaky upgrade version of FMSel (and a lot of help from him on simplifying my code - not really that good a programmer.) What the new version does:
1 - Snobel added in changes so that it would work with Deadly Shadows, once his new Sneaky Upgrade becomes available. As of Sneaky Upgrade 1.1.2, the FMSel included is exactly the same as below.
2 - Added in an option (advanced) to clean out all database entries that are no longer available (hold down CTRL while clicking on the gear/options icon to see it.) So if a FM no longer has a zip file and is not installed it gets removed.
3 - Added in a Name Format menu that defaults to normal (or Keep Leading Article.) The other 2 options Ignore & Move will either ignore the leading articles when sorting by name, or actually move the leading articles to the end of the name (ala GarrettLoader - "A Weakend Getaway" becoming "Weakend Getaway, A".) These options do not actually change the name of the FM (so "A Weakend Getaway" is still "A Weakend Getaway" in the database,) it just changes how they are displayed in the list. Note: in case you don't know, leading articles are the words "The", "An", and "A" which are generally not used when sorting titles.
I had considered adding in options to change the leading articles that are searched for, but I only know the english ones. If someone wants to send me lists of the leading articles in other languages, I will try to find a way to allow people to either select language or select which articles are & are not used.
Also, I am considering adding in a FM specific setting that will allow a single specific mission to be exempt from the leading article setting, but I'm unsure about how to actually go about that. Thoughts on this would be appreciated.
I've been giving thoughts to actually adding in a "sub mission" names for FM's. As it stands, a series such as "The Trickster's Gem Mine" would have an individual mission listed (with Move,) as "Trickster's Gem Mine 4 - Making Tracks, The". That is one that I "personally" would prefer appear as "Trickster's Gem Mine, The 4 - Making Tracks". What this would be is the FM would be "The Trickster's Gem Mine" with a sub-mission name of "4 - Making Tracks." Maybe have 2 values "Sub Mission number" and "Sub Mission Name". Thoughts on this would be appreciated as well.
(
https://www.dropbox.com/s/484bep4pt2lmjbx/FMSel%201.21%20Updated.zip) FMSel 1.21 Updated.zip is the file ready for download, but again it will need to be mirrored as that site has a limited availability window :( **Availability issue fixed**
Pheonix on 19/11/2012 at 08:26
Quote Posted by Albert
Well it's been a little bit since I last checked in on this. FMSel still is lacking in at least two things, and that's the ability to display readme files, and the freaking FM Titles being updated for the loaded FMs like in DarkLoader...
It's not a major problem, but it does get annoying when I want to play an FM and need to remember the title of the zip file. The ONLY FM that seems to have a title for it is Sensut's Cryptic Realms for 1.19. But that's because he figured something out for FMSel, that nobody else seems to have figured out yet.
Never really worked with DarkLoader, I always used GarrettLoader because it worked with T3 as well (for the most part.) There are 2 things that FMSel does for you here. If you right click on the mission you can select "View Info File". It isn't very smart and sometimes displays the wrong file. But you can select "Edit" and it will bring up a box that will let you chose which text file to set as the "info file." It will also let you specify the release date (it defaults to the latest date stamp on the files in the zip I believe,) and allows you to type in a Nice Name (it defaults to the name of the zip file.)
Once you've done this, with the mission you just edited selected, you can click on the gear icon and select "Tasks" and "Export FM.INI from FM". That will create the fm.ini in the install directory (if the fan mission is installed,) or in a directory of your choice if it hasn't been installed. That FM.INI file can be placed in the zip file and in the future FMSel will read that FM.INI file to get the "Nice Name", "Release Date", and the name of the "Info File" to use as the readme. I'm assuming that "Sensut's Cryptic Realms" probably has that FM.INI file included. Snobel's alteration also has code to convert .glml (GarrettLoader's special info file,) into HTML format to be displayed as the info file, but I'm not sure if it works in T1, T1G, or T2, it may only do that if you are loading with T3.
If you edit the FM entry in the database, it will keep the information on its own unless you delete the entry (an advanced option,) or delete the fmsel.ini file in the FMs directory. If you haven't exported it to an FM.INI file and packed it in the zip file, you will have to re-enter all that information again in that case.
Sensut on 19/11/2012 at 09:02
Yep. The instruction from "modders_notes" :
Code:
FM Author Notes
---------------
Even if you, as an FM author, don't use the FM Selector (fmsel.dll) yourself, it's strongly suggested that you
include an "fm.ini" when creating FMs from now on, and a "fmthumb.jpg" would also be preferable. These are
standardized files with information about the FM, such as release date, author(s) or description. Currently only
the FM Selector uses them, but standardized conventions will aid other potential future uses. Such as making the
job easier for web based FM databases, other potential FM selector implementations or loader/mod manager updates.
Although an "fm.ini" could be created manually in a text editor, the preferable method is to create/export it from
the FM Selector. That ensures that formatting and content is correct.
The "fmthumb.jpg" file is an (optional) image that's used to make the FM information presentation look more
appealing. It can be a JPG version of the main/logo image in Thief's main menu, or it can be something fancier.
In the FM Selector it's displayed at the top of the "View Summary" window. Potential future web based FM databases
may do something similar. The width of the image should be at most 500 pixels, and the height should be kept under
200 pixels. The logo image on Thief's main menu is 300 x 168, which is a good guideline to go by.
The "fm.ini" and "fmthumb.jpg" files have to be located in the root directory of the FM.
Pheonix on 21/11/2012 at 02:30
There is really only 2 ways I can think of to get the Nice name automatically, and I'm not really up to programing either one. One would be to use the long (or short) mission name from the Titles.str file and the other would be to find it in the info file. To use the second method would require improving the way FMSel finds the info file (as it misses, and assigns the wrong file half the time with the missions I have at least.) The problem with the first method would be with multi-mission FM's. Sure, it could examine the zip file and find miss20.mis and know to look for "title_20: " in the titles.str file, but that would only assigne the name from the first mission (or miss??.mis) file it finds. Someone else would have to program that though :( I don't think I'm up to it, I used the in-place routines for most of my changes.
gnartsch on 27/3/2013 at 13:28
Hmmm.... with Snobel and Phoenix working on a branch for TDS, I might imagine there have been a few bug-fixes made as well?
Question: Any chance to get them reported back to
Le Corbeau ?
Since new updates are coming along more or less regularly from our stealthy friend I wonder if there are other bug-fixes around already which have been made by the community that would be worth integrating into the original code.
Some things that showed up during the FMSel localization project:
(really more or less nits, but if they would be fixed in the original code it would be even better)
Inline Image:
http://www.gnartsch.de/Thief-FM/beta/FMSel-german.jpgSimple fixes:
Move the release-date a bit in fl_taged.cpp.h, line 92:
Code:
{ Fl_Box* o = new Fl_Box(
300, 76, 70, 16, $("Release Date"));
Make 'files' localizable in fmsel.cpp, line 5855:
Code:
_snprintf_s(buf, sizeof(buf), _TRUNCATE, "<br><b><font color=\"#87C5F0\">%s: </font>%s </b>(%d %s)", $("Estimated install size"), s, filecount, $("files"));
Oh, and a rather nasty bug:
FMSel can not handle pathes that contains any accents.
For example I keep all missions in a sub-folder specific to each author.
Quote Posted by fmsel.ini
[FM=darkness]
Archive=Tomi Väisänen\darkness.zip
Flags=2
FMSel can not tell you anything about that mission because of the 'ä' in the directory name, although the FM gets at least listed.
And you can not install it either.
snobel on 27/3/2013 at 14:12
Quote Posted by gnartsch
Make 'files' localizable in fmsel.cpp, line 5855:
Code:
_snprintf_s(buf, sizeof(buf), _TRUNCATE, "<br><b><font color=\"#87C5F0\">%s: </font>%s </b>(%d %s)", $("Estimated install size"), s, filecount, $("files"));
Strings wrapped in $(...) should be translatable, but "files" is not in the .po file. I've added it to the template linked to in the translation thread.
snobel on 10/4/2013 at 20:02
FMSel will find all the readme files in the archive root and assign a score to them according to the file format and the name. The one with the highest score is the one you get when you select View Info File from the context menu. If it gets it wrong you can select View Summary instead and select the correct file from the list in that dialog.
If you know of missions which have an info file that FMSel misses then report their names here.
Also, if you want the auto-name feature you can help by examining a bunch of FMs, (
http://www.ttlg.com/forums/showthread.php?t=140093&p=2154870&viewfull=1#post2154870) looking for patterns that can be used to identify the titles. Auto-naming is already implemented for most T3 FMs (easy to do because they have readme files in a special GarrettLoader format), which means that improving this is not high on my to-do list. But if someone can figure out how to approach it for T1-2 then I might have a try.