Documentation index for AI agents (llms.txt) A Markdown version of every page is available: request the page's source under /docs/, follow the "alternate" link in this page's head, or start from /llms.txt.
Visual Script logo Manual

Video Player Frame Dropped#

Video / Video Player / Video Player Frame Dropped

Description#

Executes whenever the Frame Dropped event of Video Player component is invoked

Parameters#

Name Description
Source

Code#

// <auto-generated>
// This script was automatically generated using the Visual Script Transpiler.
// Do not modify. Changes to this file will be lost when updating the package.
// </auto-generated>

using System;
using UnityEngine;
using VisualScript.Icons;
using UnityEngine.Video;

namespace VisualScript.Runtime
{
    [Title("Video Player Frame Dropped")]
    [Category("Video/Video Player/Frame Dropped")]
    [Description("Executes whenever the Frame Dropped event of Video Player component is invoked")]
    
    [Image(typeof(IconVideo), ColorTheme.Type.Blue)]
    [Keywords("Movie, Film")]
    
    [Parameter("Source")]
    
    [Serializable]
    public class GenTriggerVideoPlayer_FrameDropped : TriggerSourceComponentBase<VideoPlayer>
    {
        
        public GenTriggerVideoPlayer_FrameDropped() : base(new GenTypeGameObject_VideoPlayer())
        { }
        
        protected override string GetTitle(GameObject source)
        {
            string member = TextUtils.ThemeAsKeyword("Frame Dropped");
            return $"{this.SourceName} {member}";
        }
        
        protected override void OnSourceChanged(VideoPlayer previousSource, VideoPlayer newSource)
        {
            if (previousSource != null)
            {
                previousSource.frameDropped -= this.Run;
            }
            
            if (newSource != null)
            {
                newSource.frameDropped += this.Run;
            }
        }
        
        private void Run(VideoPlayer value1)
        {
            using Args args = Args.Get(
                this.Component,
                this.m_CurrentSource
            );
            
            this.Run(args);
        }
    }
}

Visual Script logoVisual Script © Catsoft Works 2026. All rights reserved.