Monkey see, monkey do.
A shotgun blast, or even a well-aimed rifle bullet, has greater range and is much more devastating to continued operation of the drone than a stick.
The chimpanzee was putting up the best defense he had at his disposal. First, recognizing this intruder as a threat, then acting upon that threat. This seems to be a lesson that many have already forgotten in this world.