In WWII, anti-aircraft guns were used to shoot down planes.
Tips
register
Strongly vulgar in its slang meaning — avoid in any polite, professional, or mixed-company setting. The literal sense ('shoot down a plane') is fine and unambiguous in military or historical context.
mistakes
Don't translate 打飞机 literally as 'hit a plane' in a casual conversation — native speakers will hear the slang reading first. If you mean shooting down a plane, use 击落飞机 (jīluò fēijī) to be safe.