Nobody knows for sure. Generally karma follows intention. However karma is not an object. So even karma has no fixed identity that we would call good or bad.
The Blessed One said:
"What is the All? Simply the eye & forms, ear & sounds, nose & aromas, tongue & flavors, body & tactile sensations, intellect & ideas. This, monks, is called the All. Anyone who would say, 'Repudiating this All, I will describe another,' if questioned on what exactly might be the grounds for his statement, would be unable to explain, and furthermore, would be put to grief. Why? Because it lies beyond range." Sabba Sutta.