Wow! I'm interested in this script, I thought that optimal water distribution was NP-complete!
I managed impossible without selling anything, but it was soooo difficult to optimize water distribution every turn to grab that one extra influence or two each time.