It is entirely possible for a PHP script to get fancy when checking email, but this requires that you have a script which can talk to a mail server -- probably via POP or IMAP, depending on the server.
The trick here is that email is a rather unstructured data format and different mail clients and servers can behave quite differently. You should most definitely try and use some existing code library to talk to the server and parse out the attachments for you. It would be a pain in the rear to try and rewrite a MIME-complaint mail client in PHP and someone has probably already done it for you.
I would start by looking at the source code of your plugin to see how it gets access to the mailbox. Then try checking out the built-in PHP mail libraries or perhaps search the PEAR package repository for IMAP or POP. I imagine the easiest way would be to take your current plugin and try to expand it.