The flameskull did my group in as well. I'm actually kinda pleased with how it played out. Initially, they (all L4) came in and went up the left to the bugbear barracks. After a decent fight, they immediately decided to rip open the barricaded door, and began travelling down the hall in a loose line. The lead character got to see the foundry, with several undead rising and a giant floating skull limned in green flames. Cue fireball down the tunnel (only 2 squares as that is far as flameskull could see from 15' elevation).
The 28 pts of damage rolled knocked out the fighter (who failed his save) and the wizard (who made it), and seriously wounded the rogue and cleric. The cleric dragged the fighter back into the room on his turn, and the rogue (just after in initiative), retreated and slammed the door. Some quick heals had the group back on their feat, and they re-barricaded the door and made a strategic retreat back to the cave at the front.
After a nights rest outside, they crept back in with a new found wariness and dread of the flaming skull. Eventually, they end up in a pitched battle in the ghoul room. Things are tight, but some well-timed Shatters and Thunderwaves turns things their way. Early on, before the ghouls attacked, when the raised area to the right was mentioned the rogue suggested "be careful that might head back to the skull". Anyway, during the fight, the wizard decided to Misty Step out, and rather than go back down the tunnel he decided to pop up top of the eastern rise for some reason. I decided that this (combined with the Shatters and Thunderwaves and general mayhem of shouting and fighting) would draw the attention of Signor Flameskull meandering down the tunnel to have a look. Not having a group together to target, he began with a flaming sphere, causing the party to begin fleeing in havoc. For some reason, the mage fled along the north wall to the west, while the fighter decided to charge up the stairs at the bad guy and the other two fled out the south (the cleric dragging the rogue who had went down to the last of the ghouls). The probably could have survived with just the fighter dead at that point, but as soon as the cleric had patched up the rogue, they rush back in for a last ditch effort with magic missiles and what not. They are sad to see the missiles absorbed by the glowing shield, and the rogue realizes that even with dash he is 5' short of being able to reach the floating flameskull with Tasha's Laughter (he is a Trickster). Meanwhile, the party (minus slow ass dwarven cleric) is now nicely grouped together near the center of the room. I was trying to think of any reason the skull wouldn't fireball them, and couldn't. Cue
https://www.youtube.com/watch?v=hCeIIcPAwv8.