I still have this bug in 4.11.2
Scratch that fix, didn’t work for long… weird
I managed a temp fix
In Engine\Source\Runtime\CoreUObject\Private\UObject\UObjectGlobals.cpp line 2708
UObject* ClassDefaults = bCopyTransientsFromClassDefaults ? DefaultsClass->GetDefaultObject() : NULL;
Change to
UObject* ClassDefaults = DefaultsClass->GetDefaultObject();
Unreal seems to think that the variable is transient even when it’s not.
In this line of code (2724) ClassDefaults is NULL causing the variable i.e. float to be set to 0.0
P->CopyCompleteValue_InContainer(Obj, ClassDefaults);
Well my fix works for me, but I would be cautious to implement it in other projects (not to break anything).
P.S. My variable that keeps being zeroed is ACharacter(UE4 Class) → C++CustomCharClass → BlueprintChar → float