That’s actually the approach I take with my dog and it’s worked very well. I read about it somewhere (most likely the interwebs) that when someone you are training (either an animal or human) acts out, you simply pull them aside and (if I recall correctly) you just sit there until they calm down usually around 30 seconds. If it’s a child, you will ask them “Do you know why I made you come over here?” And usually The child or pet knows that what they were doing when you stopped them was not right because you called them over and while they might mess up again with it, after a few times they will not do the bad act anymore. It was really fascinating to read. I’ve used the technique with my doghter and it’s worked well.