[英]How to log FVector in unreal engine
FVector ActorLocation = GetActorLocation();
UE_LOG(LogTemp, Log, TEXT("Actor location: %f"), ActorLocation);
您不能直接記錄FVector
。 您需要將其轉換為FString
,然后使用%s
(不是%f
),最后使用operator*
進行取消引用。
這應該工作
UE_LOG(LogTemp, Log, TEXT("Actor location: %s"), *ActorLocation.ToString());
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.