After completing [Plunder in the Sunken Ship], the ship will rise to the surface and in its place will be a vent with a stream of water at the bottom of the deep end. The star is located in that vent and normally, you shouldn’t be able to swim to it due to the strong current. The preferred method of obtaining this star involves you waiting until you unlock the [Metal Cap], which is located in the basement of the castle. However, if you mastered the faster swimming, then it is possible to get this star without needing the Metal Cap.
Metal Cap Method
The intended way to get this star is via Mario donning the Metal Cap, which is located in [Hazy Maze Cave] in the basement of the castle. Once you unlock it, return to the stage and you will find those green blocks have been filled in. What the Metal Cap does, if it isn’t obvious, is make Mario metal and allows him to sink to the bottom of the water. There are three Metal Cap boxes in Jolly Roger Bay, one of which is near the start. This isn’t ideal, since it’s pretty far from the star. There’s also one in the underwater cave, which might also be too far.
The third one is by the button that creates blocks that help get you onboard the ship. This is likely the ideal Metal Cap box to get, as you can simply long jump into the deep end and slowly descend into the jet stream, nabbing the star.
Although it was mentioned earlier that normal swimming won’t get you the star, if you have mastered the faster swimming, then it is possible to nab this star. Remember that it takes a rhythm to get this technique down, as randomly mashing the button will just get you a normal swim. So, you first need to practice getting that rhythm down before attempting this star with this method. Once you feel like you have it down, head to the deep end and approach the star from above. If doing things right, you should notice Mario getting closer to the star. If you’re having trouble, don’t forget to surface to regain your health.