It will find total playcounts of every track in your last.fm history, check if it is higher than the value in the database (for all tracks of that title/artist - even if multiples) and updates it if so.
It will also update the last played times for all tracks with a newer last played on last.fm than in your MM database.
Get it from: http://psykar.com/scripts
Direct link: http://psykar.com/script-files/LastFmImport-3.3.mmip
It's been extensively tested now, but if you run into issues, sending me the log file would be a great help! %appdata%\MediaMonkey\Scripts\LastFmImport\Log.txt
Notes:
- Does *not* update MM's internal play histories. Feel free to use other scripts to fix this up (unlikely to be added as a feature here) http://www.mediamonkey.com/forum/viewto ... =2&t=31809
The tree needs cleaning up but figured I'd shove it up anyway given I'm now distributing an exe so you can look at the source code. It's compiled with pyinstaller.
Version history is here:
https://github.com/Psykar/MM-LastFmImpo ... its/master
It will find total playcounts of every track in your last.fm history, check if it is higher than the value in the database (for all tracks of that title/artist - even if multiples) and updates it if so.
It will also update the last played times for all tracks with a newer last played on last.fm than in your MM database.
Useful if you lose your play counts, or you have a portable player (such as iPhone) which will scrobble tracks to last.fm OK, but won't update playcounts in MM.
A log file is created automatically containing all tracks which were updated in a tab delimited file in your %appdata%/mediamonkey/lastfmimport directory.
A first run over a database can a few hours, but interrupting the script is safe, and running it later will pickup where it left off.
To speed it up somewhat, turn *OFF* autorate accurate, otherwise every track updated will need to be written too as the script processes.
======
My first real scripting attempt for MM, thanks to:
Teknojnky - author of last.fmnode - for code for various functions, hacked a LOT.
Trixmoto - for mmip packaging of normal scripts, had me stumped for a while there

======================================================
Download:
http://psykar.com/scripts/
======================================================
I VERY STRONGLY recommend a database backup before you try this.
ToDo:
- Fuzzy matching