Specific performance is an equity remedy, following the maxim that "“who comes into equity must come with clean hands.” Means if you want specific performance, you could not contribute in any way to the breaking down of the contract.
As for buyer breaching the contract, usually the contract says the seller take the EMD and the seller agent could go after buyer for lost commission.