- I stole the power-detecting script from this thread on the autohotkey forums.
- I added some code which it plays a noise if the charger is unplugged or plugged in.
- It somehow takes up on average 4% of my CPU, and I think that's a bit excessive for what should be a system process. Probably has to do with the fact that it's on a loop.