Some tweaks, and support minY in cast rules