added max patches