From the Super Mario Wiki
Rotten Mushrooms are purple, skull shaped mushrooms that appear in Super Mario Maker 2. They replace 1-Up Mushrooms when the night mode is activated, but only for the Ground course theme. Unlike most mushrooms, Rotten Mushrooms actively pursue the player, even jumping up ledges up to two blocks high to get to them. However, if they are under the Super Star's effects, Rotten Mushrooms will evade them. Touching a Rotten Mushroom powers down the player, similar to a Poison Mushroom, making it a hazardous obstacle. Their skull-like design and role as an "evil" counterpart to "good" mushrooms makes them comparable to Poison Mushrooms, Zombie Shrooms, and Ghoul Shrooms. The Super Mario World version of the Rotten Mushroom resembles Bowser's fireball rain from said game.
While Rotten Mushrooms can only be placed in Overworld night areas, they can be brought into other themes if Yoshi grabs one with his tongue and travels through a warp pipe to a non-Overworld night area. They display unique behaviors in other themes, despite the fact that they cannot be placed in them outright.
As Yoshi is only featured in the Super Mario World and New Super Mario Bros. U game styles, they cannot be seen outside of Overworld night courses in the Super Mario Bros. and Super Mario Bros. 3 game styles.
Names in other languages