💾 Archived View for appl.garden › play › tis-100.gmi captured on 2023-11-04 at 11:18:15. Gemini links have been rewritten to link to archived content

View Raw

More Information

➡️ Next capture (2024-03-21)

-=-=-=-=-=-=-

TIS-100

https://zachtronics.com/tis-100/

What is this game?

TIS-100 is an open-ended programming game by Zachtronics, the creators of SpaceChem and Infinifactory, in which you rewrite corrupted code segments to repair the TIS-100 and unlock its secrets. It's the assembly language programming game you never asked for!

This seems to be one of Zach's lesser known titles, but I haven't played any of his puzzle games before (I did play their visual novel Eliza though). I'm a programmer, but I am very much intimidated by assembly language and low-level programming in general, so tinkering with it in video-game form seemed like a fun idea.

Did I enjoy playing it?

I become totally addicted.

Right off the bat, the game is very unique in having a very spartan UI, no sound or music, just the fictional computer's screen. It does not even have an in-game tutorial, instead supplying a PDF manual, which you are encouraged to physically print out. I did not print it out, but the idea was very adorable. I just looked at the PDF on another workspace, but because the TIS-100 is actually an extremely simple machine, and the manual is only a few pages of large-size text, eventually I didn't even need it.

The TIS-100 supports only 16 different instructions, with only a few memory registers. The instruction set is extremely simple even compared to the well-known 8-bit computers of the past, it pretty much only allows for reading and storing variables, adding, subtracting, comparing numbers, and jumping to different instructions. So, not even multiplication is supported - multipying two numbers is in fact one of the puzzles that you have to solve yourself.

But, what is very unique about the TIS-100 is that it's not just a basic 8-bit computer, it is a /multi-core/ 8-bit computer. Each core can only store two numbers and a few basic instructions, but the data gets passed back and forth between adjacent cores running in parallel, and that is how complex operations are done.

I'm really excited about this game so I'm just gonna share some of the puzzles and their solutions. Here's a simple solution for one of the earlier puzzles:

Read values from IN.A and IN.B; Read a value from IN.S; Write IN.A to OUT when IN.S = -1; Write IN.B to OUT when IN.S = 1; Write IN.A + IN.B to OUT when IN.S = 0

Here the "core" at the top center reads the value from IN.S, then it does either a "Jump if Less than Zero" or a "Jump if Greater than Zero" depending on the value. This jumps to different sets of instructions which will either 1) add the A and B values read from the left and right cores, or 2) read a value from one side and discard the other side.

When you complete a puzzle, you are shown a stats screen comparing your program's performance against some other solutions. You don't get any special rewards by being on top of the leaderboard, other than feeling good about yourself. But we wanna feel good about ourselves, so let's write a more optimal solution:

Same puzzle as before.

Here we take advantage of multi-core computation by using a separate core for number addition, and two other cores for filtering. The two "filter" cores read values from IN.S, then read from IN.A and IN.B respectively, and depending on the value from IN.S, they either pass on the value from A and B, or set it to zero. So if we only want to output B, then we just set A = 0, and then A + B = B. This solution has higher performance and puts us close to the top of the board.

Here are some more challenging puzzles! This is just me showing off now, I won't explain too much about how they work. Partly because these programs are hard to explain, and partly because it's been 2 months since I wrote these, so I kinda forgot how some of them actually work.

Here the task is to draw a specific pattern on the screen, by sending special codes to the IMAGE port. Showing off two different solutions, one of which is almost twice as slow.

The second-hardest puzzle in the game: sorting a sequence of numbers!

(This is not required to complete the game.) This is basically selection sort, a simple algorithm in concept, but extremely difficult in implementation, due to the limitations of the hardware. Took me days to write this. I see I wrote an instruction labelled "0W0" but I have no clue what it does.

Selection sort

Drawing numbers on the screen!

This is the Sandbox mode, and is also not required for progress. A similar puzzle exists in the main section of the game, but that one is much easier and only requires 2x2 pixel symbols, which don't resemble numbers or letters at all. Here I really wanted to draw in a proper 5x3 pixel font, but could not figure out how to do fit enough memory to draw these vertically (the TIS-100 is more suited to drawing detailed lines than detailed columns), so I cheated by drawing them horizontally. Just, rotate your monitor if you're gonna use this as a terminal!

That previous program can draw (almost) arbitrary 5x3 pixel fonts, so here I repurposed it to draw text instead, and the "0" button is now a specebar.

(Technically I did not have enough memory to store 10 separate symbols, so the 'E' and 'B' characters share some of their code.)

Anyway, I absolutely adored this little game, you can push it quite far, but also you are not required to beat all the previously mentioned challenges to complete it, and it is suitable for people with no programming experience. *9/10*, pretty much my only complaint is that the UI is a bit too minimalist and I would have prefered having some in-game music or something. It could maybe use some more tutorials, but personally I didn't need them since I as a programmer already understood the basics.

The game doesn't resemble typical software development at all, so don't expect to be 100% educational, but still, for less than 5 bucks, this is a solid investment.

Yay for having another code repository for my GitHub profile.

Oh, I forgot that there's kind of a stroryline going on about how the TIS-100 is actually [REDACTED]. It's a nice bonus, though the game would've been fine without it.

Playing it on Linux, or low-spec hardware?

The game has a native Linux port, and, while it is written in Unity, it is extremely lightweight, and could probably run on 20+ year old hardware with no issues. Though the processing speed might not be that great on some of the later puzzles if you run this on a Pentium 4 or something. You can probably find some high-performance compilers or interpreters for TIS-100, or even make one yourself!

Game finished 2023-07-20 - 47h

gardenapple - 2023-10-23

Linux and low-spec-ish gaming