Treasure in the Ocean Cave

Treasure in the Ocean Cave (referred to as Treasure of the Ocean Cave in Super Mario 64) is the third mission of Jolly Roger Bay in Super Mario 64 and its remake, Super Mario 64 DS. The mission's objective is to collect the treasure hidden by The Cap'n.

Layout
The third Power Star is found inside the pirate's cavern, which can only be reached by swimming through an underwater tunnel near the bottom of the bay. The cavern is outside of the water, and at its entrance is a sign that threatens anyone who enters with "certain disaster." Inside are large pillars that fall in the player's direction, potentially crushing them. In Super Mario 64, Mario can grab a Metal Cap that makes him impervious to the pillars' damage, and in Super Mario 64 DS, the player can grab a Power Flower that gives them benefits as well (with Mario being able to float above the pillars, Luigi turning invisible and passing through the pillars, and Wario turning metal and being invulnerable to the pillars). Past the pillars are some chests and a sign that was left by The Cap'n. The sign tells the player that The Cap'n has hidden a treasure, and the chests must be opened in a specific order in order to obtain it. If a chest is opened in the wrong order, the player gets shocked with a weak bolt. Once all four chests are opened in the correct order (back, left, right, then front), the final chest releases a Power Star that the player is free to obtain.