The shift in global weather patterns threatens to worsen floods and heat waves that were already intensifying because of climate change.