You do NOT need an Xbox Live Gold subscription to play the Slam Dunk Contest or 3-Point Shootout in NBA 2K13.
Note: Xbox Live Silver (Free) allows store access, downloads, and party chat. Gold is only for matchmaking multiplayer. Since 2K13 servers are long retired, online modes are non-functional regardless.