Showing posts with label abiathar. Show all posts
Showing posts with label abiathar. Show all posts

Tuesday, October 27, 2020

FMod - Minor audio bug fixes

Tonight I got some Abiathar audio improvements packaged into a beta release for the person who requested them. Along the way I found a couple minor other bugs. Previously the music mapping patches would be generated if audio files were linked regardless of whether Song Mappings had been used, leading to a zero-length song list being patched. Audio export apparently (probably as of v2.11.2) wrote zero-byte IMF files for empty chunks in the IMF range. This is fixed now so that empty chunks are always properly skipped.

Monday, October 26, 2020

FMod - Automatic audio chunk boundary adjustment

Today I spent a little time continuing improvement of Abiathar's audio import process. It now checks whether the chunk ID regions used by each type of sound are compatible with the archive layout that the project is configured to use for export. If not, it offers to adjust the project configuration to be consistent with the added chunks. The adjustment code is fiddly since I'm trying to avoid shifting the "original" IMF start chunk when possible so that Music Mappings doesn't break unnecessarily.

Sunday, October 25, 2020

FMod - Relaxing audio assumptions

FleexCore2's GalaxyAudio class used to require the layout of the audio archive to be provided in a chunk settings object. As of v2.11.2, only the ImfEnd field is used, since chunks will only be encoded or decoded when needed but the total number of chunks must be specified to save the archive. Abiathar still populated the chunk settings directly from its project's audio settings block, which assumes that an IMF region will exist and will be at the end of the audio archive. As part of the audio IO improvements started yesterday I relaxed some assumptions in this area. There might not be any IMF songs, so the maximum chunk ID given to FleexCore2 is now computed as the maximum of the last chunk ID of each of the three audio chunk ranges.

FMod - Starting audio IO improvements

A PCKF member is working on a mod with several extra sounds and often needs to adjust Abiathar's audio archive layout settings. This is somewhat difficult to do - it requires editing the project file manually. I don't have time for a major overhaul of Abiathar's audio support or for the addition of a fancy UI, but I have a couple ideas for useful improvements. Tonight I added a + directive to the ASNDS format that can be used in place of a chunk ID to automatically assign the next ID, which can remove the need to manually renumber everything after inserting a chunk. There's also now a BLANK directive to skip a chunk and advance to the next ID.

Sunday, September 13, 2020

FMod - v2.11.3

I received a report from a PCKF user that Abiathar was unable to open a certain mod's levels because one level was wider than 255 tiles. Indeed, Abiathar's level size restrictions structure uses one byte to store each dimension, so it couldn't handle larger levels. Such levels have weird behavior in-game past coordinate 255, but they can be played. 

So I increased the default limits to 65,535 (the maximum that can be stored in the standard level format). It wasn't as simple as just increasing some constants, though, because some parts need to pack two coordinates into one 16-bit number, mostly having to do with links. I added some checks to reject link destinations with coordinates larger than 255. Then I found that saving really huge levels crashed because their compressed plane data sizes couldn't be fit into two bytes. I introduced a "maximum area" field to the level size restrictions and added checks for this to the level properties dialog and row/column manipulators.

Since inability to open valid levels is a major problem, I released these changes (and the IMF-related ones waiting in beta) immediately as v2.11.3.

Sunday, May 24, 2020

FMod - Grid size inconsistency fix

While using Abiathar to make some of my own levels today, I noticed a small bug. I enabled the grid to see tile boundaries in the simultaneous tileset, but the grid was too fine: 16x16, even though I had zoomed the tileset to a tile size of 32x32. The grid size was appropriate for the level viewer, though. Apparently I missed a spot when giving the simultaneous tileset its own zoom level. This is fixed now.

Wednesday, May 20, 2020

FMod - Song format flexibility

Today I rearchitected the GalaxyAudio class in FleexCore2 (which represents a Keen Galaxy audio archive) to lazily parse the different kinds of sounds only when requested. If a parsed sound is requested, the stream of bytes is parsed and the sound is stored in a cache. Other components can request raw chunks, which serialize the sounds back to bytes if they've been parsed or just return the original byte stream if not. Abiathar now avoids triggering the parsing of IMF songs unless needed to turn a headerless IMF into a chunk. This allows preserving audio entries of arbitrary format in IMF chunks.

Since FleexCore2 changed, the ImfPreview extension had to be updated as well. While I was working on that I also made ImfPreview use Abiathar's standard "one moment" dialog instead of its own copy.

Monday, May 18, 2020

FMod - Song name migration

An Abiathar user asked for the ability to import a different format of song into the audio archive. I think the best way to implement this would be to allow importing any file directly into the audio archive without having Abiathar try to parse it. Unfortunately FleexCore2 currently isn't designed to load files without parsing them fully. Abiathar also assumes that IMF songs in the audio archive can have a "tag block" after the song data and takes advantage of that area to store the user-provided song name. Not every format will have space for a tag, so today I changed the Music Mappings dialog to store the name in the ADEPS (Abiathar project) file instead. 

That would be a simple change if not for the backwards compatibility concern. Users may already have set song names that existing Abiathar versions then wrote into the audio archive. It would be bad to lose those when updating. I wrote some migration code to detect when the project's audio files haven't been saved since an old Abiathar version and, if so, load them using the old architecture just to copy the names from the tags to the project file. With this working, I can start on a new architecture to allow greater format flexbility.

Sunday, April 12, 2020

FMod - v2.11.2

Today I did some final testing on the new Abiathar version comprised of my long-languishing beta and my tweaks from the past week. I noticed a discrepancy between the default side tile properties' names in freshly created projects vs. older ones using generic tile property definitions. I fixed that and published the new version as v2.11.2 for the first update of 2020. Somehow it had been almost two years since v2.11.1!

Friday, April 10, 2020

FMod - Less VeriMaps advertisement

A long time ago, I introduced a levels signing feature to Abiathar, mostly for fun and to recognize people who contributed. However, it doesn't actually seem to have been used despite being almost always mentioned in the status bar. To avoid confusing new users, I've now changed the status bar text to not mention VeriMaps unless the levels are signed.

Thursday, April 9, 2020

FMod - Unknown configuration section detection

For a long time, Abiathar has allowed extensions to save additional information on a project by adding another configuration section to the project file. While this has never been used to my knowledge (except by my as-yet-unreleased Abiathar Live Studio extension), I happened to be thinking about it recently. When Abiathar sees a configuration section, it asks all loaded extensions whether they recognize it. If an extension claims it, the configuration template provided by the extension is used to load the section.

If no extension claimed a section, it was silently ignored. This could be a problem if a project was opened without the extension used to create some important information, since the section would be lost upon saving. So I added a confirmation/warning when an unclaimed section is loaded.

Wednesday, April 8, 2020

FMod - More color customizability

I've had some Abiathar progress sitting in a beta release for a long time now. Since I've heard no reports of problems from that beta's user, I figured I might as well get a release out including those Tile Property Modifier updates and a few tiny tweaks.

A long time ago I added brightly colored bars to active planes' bays so that you can tell at a glance which ones are active. I tried to keep the three colors distinguishable from each other without looking garish and repelling new users. They ended up different shades of blue to match the overall Abiathar color scheme. But some users might want to sacrifice an attractive color scheme for more distinguishability, so the colors of those bars are now customizable on the Colors tab of the Settings. The bold blue color of the label "Active" can now also be changed, e.g. in case someone wants the very noticeable but eye-searing red of the Abiathar 1.x series.

Sunday, June 23, 2019

FMod - Side tileinfo customization

One Abiathar user told me today that their mod uses nonstandard side tileinfo values to trigger special behavior. Abiathar (and FleexCore2) turn all nonzero left and right tile property values into 1, which is a problem if those fields are to be used for something more than "blocking vs. not".

So today I changed FleexCore2 to have byte Left and Right fields rather than Boolean SolidLeft and SolidRight, then adjusted Abiathar's tileinfo translation functions to account for non-Boolean side values. In the interest of backward compatibility to extensions, I kept the functions that take Booleans; they now delegate to the byte-accepting versions, passing 0 or 1.

Virtually all users will only need binary side properties, so rather than entirely replacing the "Solid" checkboxes in the Tile Property Modifier UI I made dropdowns only appear if configured or if that tile has nonbinary side properties. Like with top, bottom, and special properties, custom side properties can be added to the ADEPS file and will appear in the dropdowns.

I also noticed that canceling the entry of a custom tile property value reset the dropdown to the first entry rather than leaving it where it was before. That's now fixed.

Thursday, October 4, 2018

Tharify package for Keen 3

The PCKF community is continuing its relatively new tradition of minimalistic community level packs. Levels are very constrained in what tiles they may use, making design/gameplay the focus as opposed to aesthetics. The first time this kind of pack was done, some people had technical issues with the usual Vorticons editors, so I whipped up a development environment based on Abiathar and Tharify. Abiathar is an unusual choice for this application because it's a Galaxy editor - I only suggested it as a last resort if no Vorticons editor would run - but apparently it worked well for people, and they requested a Keen 3 setup for this pack. So yesterday I put it together. It was a fairly simple matter of tweaking the Tharify-invoking batch file to work on Keen 3 and once again placing all allowed tiles in the level for people's convenience.

Monday, September 17, 2018

Why is Y the Abiathar hotkey for Grid?

Here's a little tidbit of Abiathar history.

The keyboard shortcut to toggle the visibility of the grid is Y, not G. Before version 1.0, the menu item to start a new project was called Gather because project creation involves gathering up the several files that represent a level set. (The window to do that, which survived the entire 1.x series and was only retired in 2.0, was internally called the Dependency Gatherer. I don't recall whether or for how long that name was displayed.) The first letter of Gather is G, so that was the hotkey. When I added the grid, I figured that Y was a decent choice because it's close to G on the keyboard.

Feedback I received on the pre-release version informed me that the "gather" terminology was confusing, so I changed the menu item's text to New and the hotkey to N. The grid hotkey apparently didn't cross my mind when I was making that change because it didn't get changed to take advantage of the now-free G.

In version 2.0, the two tools that had no hotkey were given shortcuts. G and H went to the Tile Instance Remapper (effectively a find-and-replace tool) and Tile Instance Locator (find), respectively. H was for "highlight" (the TIL added a highlight to the desired tile) and G was next to it (replace is a related operation to find). Later down the line, the Tile Instance Locator tool became the Find Highlight view mode, but the TIR is still a tool with hotkey G.

Thursday, August 16, 2018

FMod - IMF import crash fix

Today I received a bug report from an Abiathar user. He found that importing a certain IMF song using the Song Mappings dialog caused Abiathar to crash. Investigating, we found that just the specific IMF file was corrupt - its header specified far more notes than the file actually contained, so Abiathar unexpectedly hit the EOF when trying to load it all. So Abiathar didn't have so much an IMF handling problem as an error handling one, but obviously it's bad to bring down the entire application when confronted with invalid resources, so I added the appropriate error handling.

Saturday, June 30, 2018

A newer CK5Patch fixes the %egadict issue

Only a day or so after releasing Abiathar v2.11.1, including among other things a workaround for CK5Patch's incorrect %egadict command, I was informed that there is a more direct fix. NY00123 released a new unofficial version of CKPatch a couple years ago that fixes CK5Patch itself. When I was originally embedding CKPatch, I went with the newest official version I could find, but I might have to consider updating to this new version.

Thursday, June 28, 2018

FMod - v2.11.1

Today I released the pending Abiathar changes as v2.11.1. That includes:

  • The Level Inspector's new switch-related checks
  • The Resource Accountant's new ability to show the number of each kind of item
  • The fix for the vertical lines in the selected tile crosshairs not scrolling properly
  • The workaround for CK5Patch's %egadict malfunction
Auto-update to v2.11.1 only works in v2.11 because of my hosting provider's recent security protocol change.

Tuesday, June 26, 2018

FMod - Level Inspector for switches

One new level creator had some trouble with switches in Keen 4. Unlike episode 6, episodes 4 and 5 have two different kinds of switches: one that affects the infoplane (to control moving platforms) and one that affects the foreground (to open/close bridges). Using the wrong kind of switch will produce absolutely no visible effect. To make navigating this issue easier for new modders, I added some new checks to the Level Inspector. It will now warn about pointerless switches, switches that point outside the level, and switches with the wrong kind of target.

Monday, June 18, 2018

FMod - Resource Accountant improvement

One Abiathar user requested the ability to count how many of each kind of resource item are in the level, e.g. the number of 500-point items, in addition to how many total resources of each type there are. I implemented that today along with a new configuration option to control whether that new information is shown. The list is currently sorted by instances of the resource item kind, though that can look a little strange and might be changed.

Resource Account's results with item instance counts enabled