Code with types for patches and landscape