12
\$\begingroup\$

Introduction

Baba Is You is a puzzle game. In this game, a level is a grid that consists of objects and texts, and the objective of the level is to, if there are texts BABA IS YOU and FLAG IS WIN, navigate Baba (a white cat-like creature) to a flag.

The fuss is, there are so many variety of possible texts. WALL IS STOP, ROCK IS PUSH, WATER IS SINK, LAVA IS HOT, KEKE IS MOVE, KEY IS OPEN, DOOR IS SHUT, and so many more.

What's much more crazy is, the player can modify these rules in-game! All texts can be pushed to modify the rules. For example, if there was a text BABA IS YOU and Baba pushed one of the words to break the text, now the rule BABA IS YOU is gone and the player cannot control Baba anymore. For another example, if there was a text BABA IS YOU and Baba replaced BABA to WALL, now the new rule WALL IS YOU applies and the player has control on wall(s) instead.

This game is known to be Turing-complete. But would that mean that this game can participate as a language for challenges in this site? Let's look:

Input method

The game uses arrow keys to move objects that IS YOU. It's also possible for them to "wait" by the player pressing the space key.

But as like the standards of this site, input methods must be flexible. Another method of input would include, for example, specifying a combination of in-game aspects as a codepage of input.

Output method

Beating the level may count as halting, but this game has no standard notion of an "output".

As like the standards of this site, output methods must also be flexible. Specifying a combination of in-game aspects as a codepage of output would suffice.

Scoring

This game doesn't have a notion of "score". The size of the bounding box of the level would count as the score, though.

Meta Question

What I'm concerning is that, the input/output method might become too flexible. I cannot imagine how crazy an answer in Baba Is You would be. Is this "language" really suitable for this site?

\$\endgroup\$
5
  • \$\begingroup\$ Size of the bounding box is a terrible metric for scoring. You can stack pieces so its possible to store unlimited information within any given region. It's also not clear if this bounding box creates limits on the input and intermediate memory use of the game, both of which I think would be undesirable as they are not really the program. \$\endgroup\$
    – Wheat Wizard Mod
    Dec 13, 2021 at 10:38
  • 3
    \$\begingroup\$ @WheatWizard Actually, there's a few hard-limits on stacking. For example, stacking a 7th item A onto a stack of 6 items A will delete the 7th. Additionally, you can only stack up to 3 items on the same tile in the editor, so the initial state of the program can't even reach the 6 stack limit. I still agree that it isn't a good scoring metric, however, since, as you said, the bounding box is not the program. It'd be like scoring other 2d langs based on the bounding box after padding. \$\endgroup\$ Dec 13, 2021 at 18:29
  • \$\begingroup\$ P.S. Apparently Baba is a sheep, which also explains the name - it's similar to "Baa Baa", the sound that sheeps make. Source: it was mentioned in one of the livestreams on the Youtube channel "Cracking the Cryptic". It might have been the game's author that said it in the chat (he visited from time to time), but I don't know. \$\endgroup\$
    – Vilx-
    Dec 19, 2021 at 16:08
  • \$\begingroup\$ @Vilx- it is not canonical or relevant that baba is a sheep \$\endgroup\$ Dec 21, 2021 at 4:25
  • 1
    \$\begingroup\$ @thejonymyster - It's not canonical? I was under the impression that it was. Perhaps I'm wrong. Anyways, that's why it's a comment - it's just a fun fact, not really relevant to anything. \$\endgroup\$
    – Vilx-
    Dec 21, 2021 at 5:51

2 Answers 2

14
\$\begingroup\$

First off, I think that programming and doing code golf in Baba Is You is a fun idea. It's a very programmatic game and I would like to see it on this site.

However the game doesn't have a clear input, output or score. You have pointed this out. I don't think that it is a good idea to add to the ever expanding meta cruft with special rules about Baba Is You. We don't need more special cases and weirdness.

Baba Is You should follow the same pre-existing rules as every everyone else. So as far as I am concerned the answer is: "No, Baba Is You does not belong here..."

... But

There is a neat solution which I think will make everyone happy. If you want to do code-golf in Baba Is You, write a programming language that works like Baba Is You.

This neatly solves all the issues here since once you've made a programming language it can compete with no special rules. The input and output are whatever you define them to be for the programming language. The score is simply the size of file on disc. The limitations put in place by the game on, for example bounding box size, can be removed without hassle. We don't have to wonder or worry about player movement.

And if someone doesn't like the way it's handled and wants to do it their own way they don't have to go to meta and hash out new rules, creating more cruft. They can fork the interpreter and change it, or write their own from scratch.

Another big bonus is that you don't need to own the game to check the validity of someone else's answer, or to suggest a golf.

Once you've written this you can always include pictures and animations of the game demonstrating how your code runs.

\$\endgroup\$
4
  • \$\begingroup\$ Yeah, this is definitely one good option. And a similar thing has been done for TIS-100. \$\endgroup\$
    – Bubbler
    Dec 13, 2021 at 14:33
  • \$\begingroup\$ @Bubbler can you link that? both because it is relevant and because i'm curious \$\endgroup\$ Dec 15, 2021 at 23:42
  • 1
    \$\begingroup\$ @thejonymyster TIS, and the same user answered some challenges with it (example). \$\endgroup\$
    – Bubbler
    Dec 15, 2021 at 23:51
  • \$\begingroup\$ @Bubbler Thanks :) \$\endgroup\$ Dec 16, 2021 at 0:05
3
\$\begingroup\$

Yes, but I/O and scoring need to be defined properly

Disclaimer: I haven't played Baba Is You.

A TCness proof by simulating Rule 110 gives a concrete description of a "program", and how it should be set up and run. The initial setup of this program consists of a bunch of rules, followed by a single row of Rocks, which encodes a binary pattern and acts as the "input" of the Rule 110 program. Also, once the program starts, user interaction is not allowed.

(Related Hacker News thread is also possibly worth looking.)

Using it as a model, I propose the following rules for Baba Is You:

  • A "program" is a representation of the initial configuration of the stage, which contains the necessary rules and other objects as needed.
  • The 2D grid is assumed to be infinite in all four directions.
  • The input is represented as a single row of Rocks encoding the binary pattern of the input data, and is to be set up at a specific place designated by the answer body. Unary or other data can be also used.
  • The output (for non-decision-problem) is represented as a single row of Rocks encoding the binary pattern of the output data, formed at a specific place designated by the answer body.
  • Once the program starts, user interaction is simply not allowed. The linked post shows a way to enforce that by including certain additional rules, but I don't think it is necessary.
  • Scoring is done by encoding the initial state (minus the input row) of the program in a text file and counting bytes, just like how we score textual 2D languages. If the objects do not overlap and there are 255 or fewer distinct objects in the entire game (it is an if because I haven't played it), one could propose a codepage to encode the program using 1 byte per cell. (Remember, newline, which is strictly necessary for 2D languages, is 1 byte.) Otherwise, some more work has to be done...
\$\endgroup\$
3
  • \$\begingroup\$ I/O format should be more flexible than "a single row of Rocks". Especially because objects and texts can stack on the same position. \$\endgroup\$ Dec 13, 2021 at 8:42
  • 3
    \$\begingroup\$ (Also haven't played) It seems as though Game of Life is a good model for rules around Baba Is You, as the overall "structure" appears to be very similar. I believe they mostly agree with the rules listed here, but differ in a few areas \$\endgroup\$ Dec 13, 2021 at 10:27
  • 3
    \$\begingroup\$ I want to point out, that although the author doesn't mention it, that TC proof needs an infinite (not unbounded but infinite) bounding box, and needs an infinite number of rocks to be present at the same time. This is because rule 110 is proven TC on a specific repeating background pattern. In the non-generalized game Baba Is You none of this can be done. \$\endgroup\$
    – Wheat Wizard Mod
    Dec 13, 2021 at 10:35

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .