Flooding in a New Zealand city has claimed three lives.