一 、AActor
1. 获取Actor的速度
/** Returns velocity (in cm/s (Unreal Units/second) of the rootcomponent if it is either using physics or has an associated MovementComponent */
UFUNCTION(BlueprintCallable, Category="Utilities|Transformation")
virtual FVector GetVelocity() const;
二、UGameplayStatics
1. 获取每帧的时间
/** Returns the frame delta time in seconds, adjusted by time dilation. */
UFUNCTION(BlueprintPure, Category = "Utilities|Time", meta = (WorldContext="WorldContextObject"))
static float GetWorldDeltaSeconds(const UObject* WorldContextObject);
本文介绍在Unreal引擎中如何使用AActor类获取Actor的速度(单位:cm/s),以及利用UGameplayStatics类获取每帧的时间(秒),调整时间膨胀后的帧间隔时间。这些功能对于游戏开发中的物理模拟和动画控制至关重要。
309

被折叠的 条评论
为什么被折叠?



