Hack 'n' Slash

Hack 'n' Slash

Not enough ratings
Prevent messy timelines by manually saving checkpoints
By Sparkette
I've always wanted to go crazy experimenting in Hack 'N Slash, but what's always stopped me is how the timeline interface quickly becomes very hard to navigate, complicating it further every time I change rooms, even within the library. This will show you how to modify one of the game's Lua files (I haven't figured out how to do this from a Steam Workshop mod yet) to tie the behavior of the checkpoint-saving mechanism to two artifacts whose values aren't changed very frequently, in a manner that shouldn't get in your way.
   
Award
Favorite
Favorited
Unfavorite
Introduction
It's obvious that the developers of Hack 'N Slash were hoping people would keep playing long after beating the game, experimenting with the various hacking tools in the game to see what they could do. I've been doing that, and my timeline became basically impossible to follow, much like the image on the left. If you've done the same, I'd bet yours looks quite similar. Wouldn't it be nice if the game provided a manual save function so that you could prevent this from happening, and you could feel free to change rooms or browse the library without it causing your timeline to become harder and harder to navigate the more you play? This guide will show you how to basically add a feature like that. It's pretty hackish, in that it doesn't add any new menus or anything to do it, but rather extends the function of two unrelated artifacts, but it'll get the job done just fine.

Keep in mind that if your timeline is already messed up like mine, this won't let you delete sections to clean it up. You'll have to start a new save to fix that, unfortunately. Thankfully, however, it really doesn't take that long to get to the point where you have access to the bombs and the library once you already know how to solve all the puzzles. Furthermore, the next section will describe a trick to significantly cut back on the time it will take to get to this point in the game. If you already have a save file at that point with an easily-readable timeline, you can skip this next section.
Speeding through a new save
So let's say you do have to start a new file. Don't worry, this won't take nearly as long as it did the first time you played. For one thing, as I mentioned before, you know the solutions to all the puzzles (provided you remember them.) But there's also a way to sequence break very early on, and get the bombs and access to the library before you even visit the dungeon! You don't even really have to go to the dungeon, but it's recommended so you can get the hat, and anything else in the dungeon you want to mess with, like Ida and Halcyon.

But remember, you'll have access to the algorithm rooms now, and that means you can get the debug keys artifact! This will let you get through the dungeon super-fast once you get the hat INFO_OPACITY artifact, and you can skip all the puzzles. You can get ENABLE_DEBUG_KEYS by going to the chest in SpookyPath with the algorithm plaque next to it, and changing the '>' in "50000000 > days" to a '<'. Then a chest will appear next to the outhouse where you exit the dungeon, containing the artifact. The debug keys artifact will actually become important for this hack later on, so you should get it even if you don't plan to actually use the debug keys.

All you have to do is go to the Infinite Woods as soon as you get to the point where you can go there, and take the correct path, which is left, up, up, left, left, down, down, right, right, up. (Thanks, SmashManiac!)[www.doublefine.com] This will let you skip to act 4, where you can complete a few puzzles and get the bombs.

Of course, since the puzzles here are designed with the expectation that you have the hat (which you don't), some of them are annoying or impossible to solve without it unless you already remember the solution or have a lucky guess. So here are the solutions for those puzzles in case you don't remember—let me know if I missed any:

  • First puzzle after meeting Isis: change ADD from 1 to 2
  • "ran".."dom": change "ran" to "free"
  • "impossible": change MUL from 0 to 1
  • pushable rocks with "he pl": push the rocks one tile forward into the shaded areas, and swap the "1" and "3" constants in the code (so they're "3" and "1" respectively)
Editing the code
First, right-click Hack 'n' Slash in Steam, and select Properties. Go to the "Local Files" tab, and then click "Browse Local Files...". From there, go to Data, Scripts, and open UniverseState.lua in a text editor (like Notepad.) Now look for the line that says "function UniverseState:addCheckpoint (tag)". Immediately below that line, paste in the following code:

if g_hack.primaryHost.ENABLE_DEBUG_BUTTONS then if not g_hack.primaryHost.queenSpriteGaveHearts then return else g_hack.primaryHost.queenSpriteGaveHearts = false end end

It should look like this:



Now save and start up the game!
Using the hack!
This hack takes effect once ENABLE_DEBUG_BUTTONS is set to TRUE. My reasoning for this is that you aren't really going to be doing enough experimenting to mess up your timeline too much before you get that artifact, and once you have it there's really no reason to set it back to FALSE. Once ENABLE_DEBUG_BUTTONS is TRUE, no further checkpoints will be saved. To manually save a checkpoint, get out your queenSpriteGaveHearts artifact (it's in the chest in SpookyPath with the two turtles walking back and forth, but you almost certainly know that by now!) and set it to TRUE. With queenSpriteGaveHearts set to TRUE, change levels. It will save a single checkpoint, and set queenSpriteGaveHearts back to FALSE to prevent further checkpoints from being saved.

Now you can experiment all you want, and only add to your timeline when you do something you think is actually worth saving!

Finally, just for fun, here's what the modified code looks like in the game's disassembler.