What does/can python do?

I was looking into purchasing a pixhawk and other equipment for creating my own uav with a group of friends. We were looking heavly into the use of the mission planner software, but because we don’t have any hardware yet we can’t actually experiment to much with the software. I did however notice that you could use python scripts in mission planner and was a little confused by a lack of documentaion.
When you use python scripts, is the script your mission, and you have to hardcode everything that you want to happen? Or is the script somthng that you can run when the UAV reaches a waypoint? What can these python scripts do?
All help is appreciated!