Search Unity

Nullable types for AppParams

Discussion in 'Unity Simulation' started by wightwhale, Dec 10, 2021.

Thread Status:
Not open for further replies.
  1. wightwhale

    wightwhale

    Joined:
    Jul 28, 2011
    Posts:
    397
    Hello,
    I'm wondering if it's possible for me to use nullable types in the AppParams.cs file.

    public float? sensorSizeX = null;
    public float? sensorSizeY = null;

    When using these it doesn't appear to load the data from file but works when I remove the question mark. However it would be best if I could use the nullable type.
    Thanks!
     
Thread Status:
Not open for further replies.