do

local CBFP_oldUAA0310 = UAA0310

UAA0310 = Class(CBFP_oldUAA0310) {
    OnKilled = function(self, instigator, type, overkillRatio)
        CBFP_oldUAA0310.OnKilled(self, instigator, type, overkillRatio)
        # added by brute51 - fix for current unit being build not being destroyed when the CZAR dies [170]
        if self.UnitBeingBuilt and not self.UnitBeingBuilt:BeenDestroyed() and self.UnitBeingBuilt:GetFractionComplete() != 1 then
            self.UnitBeingBuilt:Destroy()
        end
    end,
}

TypeClass = UAA0310

end