Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void UOpenDoor::Open_Door()
- {
- // Find the owning actor:
- AActor* Owner = GetOwner();
- // Create a rotator:
- FString oldAngle = "old angle = " + Owner->GetActorRotation().Roll.ToString();
- UE_LOG(LogTemp, Warning, TEXT(oldAngle));
- FRotator NewRotation = FRotator(0.0f, Owner->GetActorRotation().Roll + OpenAngle, 0.0f);
- // Set the door rotation:
- Owner->SetActorRotation(NewRotation);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement