I have a tick function firing in the editor:
void ASolarPanelArray::Tick(float DeltaTime)
{
Super::Tick(DeltaTime);
if (LastPanelAngle != PanelAngle)
Rotate(PanelAngle);
LastPanelAngle = PanelAngle;
}
void ASolarPanelArray::Rotate(float Angle)
{
GEngine->AddOnScreenDebugMessage(-1, 5.f, FColor::Red, TEXT("Rotate"));
for (auto i = 0; i < Panels->GetInstanceCount(); i++)
{
float Roll = Angle + (Random.FRandRange(-PanelRandomAngle, PanelRandomAngle));
FTransform Tfm;
Panels->GetInstanceTransform(i, Tfm);
FVector Rotation = Tfm.GetRotation().Euler();
Rotation.X = Roll;
FTransform Tfm2 = FTransform(FQuat::MakeFromEuler(Rotation), Tfm.GetLocation(), Tfm.GetScale3D());
Panels->UpdateInstanceTransform(i, Tfm2);
}
}
Where PanelAngle is animated in the sequencer. This doesn’t have any affect whatsoever on the instance transforms, although it does print “Rotate”, even though Rotate is being called (I’ve verified that). When fired from PostEditChangeProperty, it does what it should however. Am I missing something or is this a bug of some kind? Can I send my project to Epic to check it out?