FairyGUI.GMovieClip.ConstructFromResource C# (CSharp) Method

ConstructFromResource() public method

public ConstructFromResource ( ) : void
return void
        public override void ConstructFromResource()
        {
            sourceWidth = packageItem.width;
            sourceHeight = packageItem.height;
            initWidth = sourceWidth;
            initHeight = sourceHeight;

            _content.interval = packageItem.interval;
            _content.swing = packageItem.swing;
            _content.repeatDelay = packageItem.repeatDelay;
            _content.SetData(packageItem.texture, packageItem.frames, new Rect(0, 0, sourceWidth, sourceHeight));

            SetSize(sourceWidth, sourceHeight);
        }

Usage Example

示例#1
0
 static int ConstructFromResource(IntPtr L)
 {
     try
     {
         ToLua.CheckArgsCount(L, 1);
         FairyGUI.GMovieClip obj = (FairyGUI.GMovieClip)ToLua.CheckObject <FairyGUI.GMovieClip>(L, 1);
         obj.ConstructFromResource();
         return(0);
     }
     catch (Exception e)
     {
         return(LuaDLL.toluaL_exception(L, e));
     }
 }
All Usage Examples Of FairyGUI.GMovieClip::ConstructFromResource