I didn't look it up but I would think if a dead twig is on the ground and u are taking a practice swing (not in a hazard) And u hit the dead twig and it bounces into your ball that u replace ur ball as close as possible to original spot and continue without penalty.
If same scenario happens but ur practice swing breaks a twig off a tree then hirs ur ball...u incur a one stroke penalty for breaking the twig off then get to replace ur ball
Just an educated guess from experience of getting stroked for something similar in a tournament