TheXTech

TheXTech - it's a platform game engine written in C++, is a full port of source code of SMBX 1.3 which was originally written in Visual Basic 6. Created by Wohlstand after one month since original SMBX source code was been released for two purposes: providing a free and open-source, cross-platform and accurate implementation of the SMBX Engine to allow playing of old levels and episodes, created for an original game, with the same behavior as the original game had; get a more convenient research model for a PGE Engine development.

Version history
Development of TheXTech was started after a week after releasing of SMBX' source code into the public. The versioning starts at 1.3 to continue the history of original SMBX game in a new form.

1.3
A first working thing which was developed in 2 weeks after SMBX's source code was opened and researched. It was a working but buggy build which was polished later to prepare it for 1.3.1. It was developed in hide with a purpose to make a sudden surprise for a community.

1.3.1
A first public release out in March 14, 2020.

1.3.2
An update released in April 26, 2020. This version fixes some bugs and introduces minor improvements. A level testing integration with PGE Editor since now is supported natively.

1.3.2.1
An update released in July 12, 2020. This version fixes some bugs like software render support, extends the support for joysticks, and adds the workaround for case-sensitive file systems to resolve glitches with some episodes.

1.3.2.2
An update released in July 18, 2020. This update fixes an incorrect sizes of customized effects: effects should be able to have any GFX size, but in a condition that it has the same count of frames as original.

1.3.2.3
An update released in July 30, 2020. This update fixes a crash, caused by some custom effects, and fixes the inability to properly catch any vegetables on the fly.

1.3.2.4
An update was released on November 30, 2020. Adds an ability to set the custom music for an outro level (If section music is not set, the default outro theme will be used). This update fixes the inability to have more than 100 episodes and battle levels in the same game copy. Also, fixes some glitches related to graphical processing.

1.3.3
An update was released on December 19, 2020. This update adds some new functional features such as "gameinfo.ini" to partially customize some internal text content including the extra block of credits; native support for playable character calibrations files; added an ability to customize item settings globally by placing of npc-*.txt or player's calibration at the graphics/npc or graphics/mario,luigi,peach,toad,link directory, and some other things.

1.3.3.1
An update was released on January 2, 2021. This update fixes two bugs and adds the experimental support for Windows ARM64 and macOS Apple Silicon platforms.

1.3.4
An update was released on February 12, 2021. This version fixes several vanilla bugs and introduces the "compat.ini" file that allows to re-enable some bugs back if they required for a work of some levels and episodes. This version resolves the annoying frame-skip and fast-forward problems that had to cause a temporary blindless when computer gets lagged. The speed-testing system was added to display the walkthrough stopwatch and tune the compatibility required for the fair SMBX speed-running. This is the minimal version approved for speed-runs of SMBX episodes.

Differences with the original game
While game is an accurate port of an original game, it has several differences and enhancements:


 * First off, it's written in C++ while original (as we already know) is written in VB6.
 * Doesn't have an Editor. Instead, since 1.3.2 it have a deep integration with PGE Editor that allows to use it with the same functionality as in original editor (the "magic hand" functionality was kept to allow real-time editing of the level while testing, it's needed to use IPC communication with PGE Editor to get the ability to use it better).
 * Full support of UTF-8 in filename paths and internal text data (original game had the only 8bit ANSI support).
 * For graphics and controlling, it uses an SDL2 library while original game have used WinAPI calls and GDI library.
 * It uses PGE-FL that has better file formats support.
 * A support for WLDX world maps are allowing unlimited credits lines and custom music without it being necessary to use a music.ini for music replacements.
 * Some LVLX exclusive features now working: vertical section wrap, two-way warps, custom "star needed" message, warp enter event, ability to disable stars printing in HUB episodes for specific doors, ability to disable interscene showing when going to another level through a warp.
 * Built-in support for episode and level wide music.ini and sounds.ini to override default music and sounds assets.
 * World maps now supports a custom directory to store any specific resources like custom tiles/scenes/paths/levels and not spam the episode root folder with world map resources anymore.
 * Default config format is INI, old config.dat format is no longer supported, mainly because of incompatible key code values (SDL_Scancode versus VirtualKeys enum of Windows API).
 * Game saves now using the SAVX format instead of a classic SAV. However, if you already have an old gamesave, you still can resume your game by using a new engine now (next gamesave attempt will result a SAVX file, old gamesave in SAV format will be kept untouched).
 * Built-in PNG support for custom and default graphics. Masked GIFs are still supported for backward compatibility, however, without making an unexpected auto-conversion like SMBX-38A does.
 * Checkpoints now have multi-points! You can use them in your levels multiple times without limits!
 * It does use of lazy-decompress algorithm to speed-up the loading of a game and reduce the memory usage.
 * For music and SFX, the MixerX library is used to give a support for a wide amount of sound and music formats!
 * It doesn't embeds any graphics: there are NO trurely hardcoded graphics, everything is now represented by external graphics!
 * Some internal limits have been expanded.
 * Built-in GIF recorder by F11 key (F10 on macOS, F11 is reserved by system UI for a "show desktop" action).
 * As of 1.3.2: The maximum sections limit has been extended up to 201.
 * As of 1.3.2: The 20 entries limit for layers lists to show/hide/toggle has been removed.
 * As of 1.3.2.4: Allows to customize the outro level music.
 * As of 1.3.3: The Purple Yoshi's Ground Pound can be changed to Alt Run by adding  to settings/thextech.ini, preventing accidental deaths while duck-jumping.
 * As of 1.3.3: Supports playable character calibration files to customize hitbox offsets and metrics.
 * As of 1.3.4: Supports the compat.ini files to tune the compatibility for levels and episodes by enabling or disabling certain bugfixes and features.

Cheat Codes
TheXTech has the same Cheats as SMBX 1.3, with the addition of some alternative codes. All codes with a 'y' (for example "moneytree") have a counterpart where it is replaced by 'z' ("moneztree") for QWERTZ-compatibility.

Building the Game
To build the game, follow one of the following guides from the GitHub page:


 * Building on Windows
 * Building on Linux or xBSD
 * Building on macOS
 * Building on Haiku
 * Building on Emscripten

For a build intended to be shared, install the ninja-build dependency, and replace the following line:

cmake -G Ninja -DCMAKE_BUILD_TYPE=Debug ..

With:

cmake -G Ninja -DCMAKE_BUILD_TYPE=MinSizeRel -DUSE_SYSTEM_SDL2=OFF -DUSE_SYSTEM_LIBS=OFF -DUSE_STATIC_LIBC=ON -DPGE_SHARED_SDLMIXER=OFF ..

After following the final steps of the guide, create a  with the following content:

[Main] force-portable = true

And place it along with the executable in the same folder as the assets.

Custom Default Sets
Currently, TheXTech doesn't support individual "graphics" folders for episodes like SMBX2 does. In order to make episodes with their own SMBX sets like "Yoshi's Archipelago" or "Super Talking Time Bros." work, they need to be patched by taking the following steps :


 * Copy the  folder from SMBX 1.3 assets (or Adventures of Demo assets).
 * Download sounds.ini and music.ini and place them in the set's root folder.
 * Copy a TheXTech executable as well as thextech.ini from above and place them in the set's root folder.
 * Use the PGE Maintainer from the newest PGE Laboratory build to convert the GIFs in the graphics folder to PNGs.

Alternatively, the contents of the graphics subfolders may all be placed in the episode's folder. However, this will increase loading times, so it is only worthwhile on a fast PC with a SSD. If you choose this method, the set's music folder, the sounds folder, music.ini and sounds.ini need to be moved to the episode's folder as well. A conversion of the GIFs is not necessary.

Planned Features

 * Improving Controller Support and allowing multiple key bindings. Until then, antimicro or xboxdrv can be used as workarounds.
 * Making the Purple Yoshi's Ground Pound be usable by other Yoshis with a yellow shell.
 * Copying and erasing savefiles within the title screen.

Links

 * An official forum post
 * A first announcement
 * A video showcase