Flick 'em Up!
When a cowboy enters a building with loot, does the duel resolve before he picks up the loot?
Most likely yes. The duel is fought first, the winner flicks the loser out, and then the winner may pick up loot in the building. The rulebook does not say this directly.