I followed your instructions to the the letter and the 9 is not changing on my MyInt default and it shows the variables but not replacing the defaults update i change after began play:
My code in the .h file is:
public:
// Called every frame
virtual void Tick(float DeltaTime) override;
UPROPERTY(EditAnywhere)
int32 MyInt = 99;
UPROPERTY(EditAnywhere)
bool MyBool = true;
UPROPERTY(EditAnywhere)
float Myfloat = 5.99;
};
My code for the cpp file is:
// Called when the game starts or when spawned
void AMovingPlatform::BeginPlay()
{
Super::BeginPlay();
MyInt = 9;
}
// Called every frame
void AMovingPlatform::Tick(float DeltaTime)
{
Super::Tick(DeltaTime);
}