Allow PlatformHelper.Current to be set externally, only when the property hasn't been set yet.
As discussed, being able to set this allows for BepInEx to manually set the platform without needing to execute the static constructor, which can cause issues on some Unity versions.
The property has a lock to prevent writes once the property has been read by anything, to prevent any inconsistencies arising from two different values being read during later execution.
Allow PlatformHelper.Current to be set externally, only when the property hasn't been set yet.
As discussed, being able to set this allows for BepInEx to manually set the platform without needing to execute the static constructor, which can cause issues on some Unity versions.
The property has a lock to prevent writes once the property has been read by anything, to prevent any inconsistencies arising from two different values being read during later execution.