The GetFloat
method retrieves a floating-point value associated with a specified key from the metadata. If the key does not exist, it returns a default value provided by the caller.
The GetFloat
method retrieves a floating-point value associated with a specified key from the metadata. If the key does not exist, it returns a default value provided by the caller.
To use the GetFloat
method, you need to have an instance of the Editor.MetaData
class. Call the method with the key name you want to retrieve and a default value that will be returned if the key is not found.
// Example usage of GetFloat method Editor.MetaData metaData = new Editor.MetaData(); float value = metaData.GetFloat("gravity", 9.81f); // 'value' will be 9.81 if the key "gravity" does not exist in the metadata.