Home - HDR-Development/smashline GitHub Wiki
Welcome to the Smashline Wiki
What is smashline
Smashline is a script/code replacement framework for Super Smash Bros. Ultimate™. It is the latest in a chain of script replacement frameworks starting back with SaltySD -> skyline-acmd -> lua_replace -> smashline (v1).
Smashline powers the most popular Smash Ultimate mods, including HewDraw Remix (HDR), The WuBor Patch, and Ultimate S.
Sidenote, why is it called "smashline"?
My predecessor to smashline was called "lua_replace", and had a few limitations but ultimately it was very similar. While developing lua_replace, I had thought of a modding tool that would place a CLI on the switch screen using custom rendered graphics, and since it's a command line for smash, I wanted to call it smashline.
Of course that never manifested, and probably for good reason, as it would have been written in C++ and simply not maintainable.
What can smashline do?
Smashline enables code-mods (hereafter called plugins) to replace/add "scripts" for fighters and their weapons (items are currently not supported).
That probably leaves you with the question "What are scripts?". Previous iterations in the Smash series had their scripts saved in formats that were either opaque and needed an editor (think Crazy Hand for Melee) or as a dedicated interpreted format (think MSC for Smash 4). Smash Ultimate ditched these formats for Lua, which likely comes with better support for Nintendo as more recent Nintendo games have used Lua as well.
However, using Lua is a double-edged sword. Item ACMD (Animation Command, what controls hitboxes) is stored as an asset as compiled Lua bytecode, and after some RE efforts done early in the games lifetime we were able to edit and replace the Lua, which is great! The downside is that Lua is very widely supported, and as such the SSBU developers were able to transpile the Lua bytecode for fighters/weapons into normal C++ -- in order to modify fighter/weapon code in any capacity you need plugins/code mods.
That's where smashline comes in, it enables the replacing of these ACMD scripts (and status scripts -- more on those later) without needing to know where in code they are located and without needing to manage your own function hooks, for example:
Agent::new("mario")
.game_acmd("game_attacks4", mario_fsmash, Priority::Default)
.effect_acmd("effect_attacks4", mario_fsmash_effect, Priority::Default)
.install();
So long as mario_fsmash
and mario_fsmash_effect
are both the correct type of function, smashline handles replacing everything for you.
What can't smashline do?
- Add new characters
- Add new costume slots (see ARCropolis for that)
- Your taxes
In reality, there are more nuanced aspects of character code editing that Smashline is incapable of doing because it's highly specialized and doesn't have a place in a general purpose code-replacement library like this. Projects that extend functionality of Smashline in niche/specific ways include the three big overhaul mods linked at the top of this page, which are all open source and you should consider checking out their code if you wish to learn more.