Fix coordinate extraction