One example of opportunity cost I encountered while playing the Mario Brothers emulator was when I had to choose between going for a power-up (like a Super Mushroom) or jumping over a group of enemies.
In this situation, I decided to go for the power-up to increase my abilities. The opportunity cost of this choice was the risk of losing a life by running into enemies that I could have avoided had I chosen to jump over them instead. Essentially, I gave up the safety of bypassing the enemies for the potential advantage of enhanced power from the item.