State and local governments may see their credit ratings drop if they don't prepare for global warming.