October 2016
Intermediate to advanced
452 pages
9h 47m
English
Enums are commonly used in C++ as flags or inputs to switch statements. However, what if you want to pass an enum value to or from C++ from a Blueprint? Alternatively, if you want to use a switch statement in Blueprint that uses an enum from C++, how do you let the Blueprint editor know that your enum should be accessible within the editor? This recipe shows you how to make enums visible in Blueprint.
StaticMeshActor class called Tree using the editor.UENUM(BlueprintType)
enum TreeType
{
Tree_Poplar,
Tree_Spruce,
Tree_Eucalyptus,
Tree_Redwood
};UPROPERTY in the Tree class:UPROPERTY(BlueprintReadWrite) ...
Read now
Unlock full access