With the rapid advancement of drone technology and the growing applications in the field of drone engineering, the demand for precise and efficient path planning in complex and dynamic environments has become increasingly important. Traditional algorithms struggle with complex terrain, obstacles, and weather changes, often falling into local optima. This study introduces an Improved Crown Porcupine Optimizer (ICPO) for drone path planning, which enables drones to better avoid obstacles, optimize flight paths, and reduce energy consumption. Inspired by porcupines' defense mechanisms, a visuo-auditory synergy perspective is adopted, improving early convergence by balancing visual and auditory defenses. The study also employs a good point set population initialization strategy to enhance diversity and eliminates the traditional population reduction mechanism. To avoid local optima in later stages, a novel periodic retreat strategy inspired by porcupines' precise defenses is introduced for better position updates. Analysis on the IEEE CEC2022 test set shows that ICPO almost reaches the optimal value, demonstrating robustness and stability. In complex mountainous terrain, ICPO achieved optimal values of 778.1775 and 954.0118; in urban terrain, 366.2789 and 910.1682 and ranked first among the compared algorithms, proving its effectiveness and reliability in drone delivery path planning. Looking ahead, the ICPO will provide greater efficiency and safety for drone path planning in navigating complex environments.