Array of a custom Enum as output for an interface function

Hi there,

My goal is to use an array of a custom enum (types) as ouput for an interface function.

However, when I try to do this the engine gives me the following message:

Error Message:

BlueprintEditorCompileResults:Error: Error Default value ‘’ for Types is invalid: ‘’’ is not a valid enumerant of ‘’’

My enum is coded in c++ like this:

UENUM(BlueprintType)

enum MyType
{
TP_Float UMETA(DisplayName = “Float”),
TP_Int UMETA(DisplayName = “Int”),
TP_String UMETA(DisplayName = “String”),
TP_Bool UMETA(DisplayName = “Bool”),
};

The setupt of the interface function:

12163-enum+array+error.jpg

Engine

Im working in UE 4.2.1

Trial and error

I did also test it with an enum which I created in the editor (content browser → misc → enumeration), got the same result.

Hi ,

Thank you for bringing this to our attention. I tested this in 4.2.1 and was easily able to see the behavior that you described. I also tried doing this in our latest internal build of the Engine, and the issue did not occur there. It looks like a fix for this issue has already been put in place and will be available in a future version of the Engine, though I am not sure exactly which version will contain the fix.

Have a great day!