Error: BaseColor was deprecated on iOS 15
bobbygeo opened this issue · comments
Describe the bug
I am getting an error in the FocusEntity Colored swift file for
var modelMaterial = UnlitMaterial(color: .clear)
modelMaterial.baseColor = endColor
With the error baseColor was deprecated on iOS 15, use Color instead. When changing to color I get the following error:
Cannot assign value of type 'MaterialColorParameter' to type 'UnlitMaterial.BaseColor' (aka
'PhvsicallvBasedMaterial.BaseColor')
To Reproduce
Steps to reproduce the behavior:
- It happens when you open the project in Swift Playgrounds on iPad
Environment:
- iPadOS 15.2
- iPad Pro (11-inch) (3rd generation)
- Swift Playgrounds 4.0
Hi @bobbygeo, I was sneaking this into a PR that's currently in draft (#29) last month.
The problem I'm having is that it's completely changed, then the minimum version for this package is bumped to iOS 15, and if it's wrapped with an if #available
then it still complains that it is deprecated.
I'll work on getting that patch added early in the new year, but it seems that the warning will persist unless it's set to minimum version iOS 15.