If I have a skeletal Mesh component named GunMesh with Blueprint Editable properties.
//In Header
UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = Mesh)
USkeletalMeshComponent* GunMesh;
GunMesh = CreateDefaultSubobject<USkeletalMeshComponent>(TEXT("GunMesh"));
If I make a mistake and set the parameter of CreateDefaultSubobject as the same text as the first object.
UPROPERTY(VisibleAnywhere, BlueprintReadWrite, Category = Mesh)
USkeletalMeshComponent* OtherGunMesh;
OtherGunMesh= CreateDefaultSubobject<USkeletalMeshComponent>(TEXT("GunMesh"));
This will un-recoverably break the blueprint permissions of both “GunMesh” and “OtherGunMesh” for any blueprints that extending either actor c++ class. To fix this it will require a new blueprint child to be created or to re-parent the current blueprint to another class, then back to the intended class. Pressing reload in the asset actions does not work.
While this is a product of incorrect use it happens quite frequently do to newer employees re-using colder code and missing this critical line.
Any way around this that does not involve making a new blueprint?