Merge branch 'sceneanim_null_check_fix' of https://github.com/GoaLitiuM/FlaxEngine into GoaLitiuM-sceneanim_null_check_fix

This commit is contained in:
Wojtek Figat
2023-10-01 12:12:21 +02:00
20 changed files with 45 additions and 38 deletions

View File

@@ -33,7 +33,7 @@ namespace FlaxEditor.GUI.Timeline
/// </summary>
public SceneAnimationPlayer Player
{
get => _player;
get => _player != null ? _player : null;
set
{
if (_player == value)
@@ -268,7 +268,7 @@ namespace FlaxEditor.GUI.Timeline
/// <inheritdoc />
public override void OnSeek(int frame)
{
if (_player?.Animation)
if (_player != null && _player.Animation)
{
_player.Animation.WaitForLoaded();
_player.Time = frame / _player.Animation.FramesPerSecond;