I’m trying to add a new custom parameter of double type.
From documentation:
Note: Parameter values must be one of the following primitive types: string, int, long, float, double or bool. This restriction is enforced by the SetParameter(…) methods provided by the Event base class.
However, when I try adding it there is no double type option. (No long type as well)
The data types mentioned in the documentation refer to the SDK’s accepted parameter types in the Unity Editor or game, while the actual storage types may differ on the platform. A Double parameter will map to a Float.
For your case:
If you’re collecting data with decimals points, you should create a Float parameter.
If you’re collecting data without a decimal point, you should create a Integer parameter.
I think the documentation is a bit confusing. For me, as a developer, double cannot be stored as float (8b vs 4b). If you dig deeper into the documentation and look at the Snowflake SQL dialect, it suggests that the parameter type name is more of a category rather than the exact data type.