Trapped inside the castle walls

"Trapped inside the castle walls" is the first variant of a recurring phrase in Super Mario 64 and Super Mario 64 DS that has caused some confusion. Due to the ambiguity of the phrase, players have interpreted the nature of this entrapment in various ways.

Instances
This is a list of instances and variants of the phrase that Super Mario Wiki has noted as of the time of writing.

Toad near main entrance
In Super Mario 64, a Toad by the main entrance to the Mushroom Castle says:

"The Princess...and I...and, well, everybody...we're all trapped inside the castle walls. Bowser has stolen the castle's Stars, and he's using their power to create his own world in the paintings and walls."

In Super Mario 64 DS, this Toad has different dialogue for each of the playable characters. Respectively, they tell Yoshi, Luigi, and Wario:

"Bowser has locked Princess Toadstool and all of us inside the walls. He stole our Power Stars, and is using their magic to create an evil land of monsters in the castle walls and paintings."

"Princess Toadstool is still trapped inside the walls."

"Princess Toadstool is still trapped in the walls."

Sign near The Princess's Secret Slide
According to Super Mario Wiki, Princess Peach's sign, hanging in the room with the entrance to The Princess's Secret Slide, contains the following information. However, it seems to have different text in Super Mario 64, suggesting that this could have been rewritten for Super Mario 64 DS and not noted as such.

"He [Bowser] stole the castle's Power Stars and disappeared into the walls along with us! Retrieve all of the Power Stars from the walls and the paintings in the castle."

Toad near Jolly Roger Bay
In Super Mario 64 DS, a Toad in the room with the Jolly Roger Bay painting tells Mario:

"Being imprisoned in these walls can drive a fungus crazy. When I really start to freak out, I think to myself, 'Well, I'm going to be here for a while, so I might as well stare at the fish. They are oddly hypnotic.' Then I actually start to like being captured............Aaaguugh! IT'S MADNESS! I've got to snap out of this! You have to free us before we're all completely brainwashed! ...But for now, why don't you gaze at the fish with me. You look tense. Come relax."

Although they don't mention being trapped to Luigi, they do expand upon their situation:

"Sometimes when I'm staring at the fish, I think I wouldn't mind staying here forever. It helps me forget about my horrible fate."

Toad near Hazy Maze Cave
A Toad near the entrance to Hazy Maze Cave gives the player character a Power Star when spoken to. Their dialogue is phrased slightly differently depending on whether this Power Star has been collected.

"Oh boy, it’s not looking good for Peach. She’s still trapped somewhere in the walls. Please Mario, you have to help her! Did you know that there are enemy worlds inside the walls? Yup. It’s true. Bowser’s troops are there, too."

"Speaking of lost, Princess Peach is still stuck in the walls somewhere. Please help, Mario! Oh, you know there are secret worlds in the walls as well as in the paintings, right?"

Bowser
When engaged in Bowser in the Fire Sea, Bowser says:

"Now, return those Stars! I stole them first and my troops in the walls need them!"

Before the final boss battle in Bowser in the Sky, he then says:

"Your friends are all trapped in the walls... And you'll never see the princess again!"

Trapped in the rooms
Some fans have interpreted "inside the walls" as a synecdoche for the normally accessible rooms in the castle.

TV Tropes' [//tvtropes.org/pmwiki/pmwiki.php/Headscratchers/SuperMario64 Headscratchers page] for the game has questioned how this can be considered entrapment if the front door isn't locked. If this is the intent, Super Mario 64 DS has partially addressed it by locking said door. However, the player is intended to unlock it to get inside, before they have the chance to read any of the aforementioned dialogue, despite the fact that the Toads would then be able to leave.

Sealed within the walls
As Toads are found standing next to the castle walls, and Princess Peach appears from a stained glass window at the end of the game, some fans believe that they are meant to be sealed behind and between the physical walls so that they cannot escape to seek help.

One theory included on the popular Super Mario 64 iceberg meme, "Peach is behind the stained glass window", compares the texture and depth of the window as seen from outside the castle, to those as it is seen from the foyer. The theory concludes that they are two separate windows at least 20 feet apart, and that Peach is physically held within an empty space between them.

The way Peach gradually fades in during the ending cutscene, allegedly representing her passing through the front window, can be applied to the transparency effect on the Toads. Some fans claim that this is the Toads magically projecting themselves through the wall to talk to Mario. It could otherwise be the Toads being presented to the player and not to the in-game Mario.

A major limitation of this theory is that Mario collides with Toads like other NPCs, suggesting that they are physically present in their visual locations within the rooms. However, the collision might have been left intact for the Toads so that Mario would not clip through them, which would also destroy the concept of them being opposite the walls from Mario.

Another contradiction is that Toads are presented as standing next to walls on the near side. This may have been due to development limitations on the Nintendo 64, but was not corrected for the Nintendo DS remake. In Super Mario Galaxy, released three years after Super Mario 64 DS, Mario is able and intended to [//www.suppermariobroth.com/post/142568437485/at-the-beginning-of-good-egg-galaxy-in-super-mario read a signpost through a wall]. This technique could be combined with with z-indexing to have the Toads fade in front of the wall while standing behind it.

Trapped in the painting worlds
It is possible that some of the castle's inhabitants are trapped in the painting worlds. This is supported by Peach seemingly being trapped in the stained glass window, which is comparable to a painting but could be lumped in with the similarly functioning walls (like the entrances to Shifting Sand Land and Snowman's Land) in dialogue.

However, all of the Toads are found at the castle proper, contradicting this theory. Some instances of the phrase also refer to the paintings and walls separately.

Additionally countering the theory, Bowser states that Mario's friends are all trapped. This does not seem accurate to this theory, as no familiar characters but the Ukkikis appear in the painting worlds. Although Bowser could still be referring to the friendly characters that Mario would likely have met in the painting worlds, they seem to be native to their respective courses. Throwback Galaxy in Super Mario Galaxy 2 would retroactively confirm that the Bob-omb Buddies live on Whomp's Fortress and were never trapped in relation to the castle.

Held hostage
It is possible that Bowser's troops have held the inhabitants of the castle hostage. Although the castle proper is mostly devoid of enemies, there are the Boos found in the courtyard and the hallway to it.

Turned into bricks
The Super Mario Bros. instruction manual states that the Mushroom People, residents of the Mushroom Kingdom and presumably an early name for Toads, "were turned into mere stones, bricks and even field horse-hair plants". While this description has several fan interpretations in its original context, some players have applied it to Super Mario 64, speculating that Bowser turned the Toads back into building materials for the walls in the Mushroom Castle.

Magically sealed
Whether the characters are trapped in the rooms or the walls, it has been theorized that Bowser's magic has made them unable to leave.

In Peach's case, she may be sealed within a painting world that was created through the stained glass window.

The Toads are presumably released when Mario defeats Bowser and collects the Jumbo Star in Bowser in the Sky, hence why they are seen outdoors in the ending cutscene after Peach appears from the stained glass window.