static StackObject *Ctor_0(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj)
        {
            CSHotFix.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject *__ret = ILIntepreter.Minus(__esp, 0);

            var result_of_this_method = new UnityEngine.U2D.SpriteAtlas();

            return(ILIntepreter.PushObject(__ret, __mStack, result_of_this_method));
        }
예제 #2
0
 public Sprite GetSprite(string atlasName, string spriteName)
 {
     UnityEngine.U2D.SpriteAtlas atlas = AddResource(string.Format("Atlas/{0}", atlasName)) as UnityEngine.U2D.SpriteAtlas;
     if (atlas == null)
     {
         return(null);
     }
     return(atlas.GetSprite(spriteName));
 }
        SpineSpriteAtlasAsset FindSpineSpriteAtlasAsset(UnityEngine.U2D.SpriteAtlas spriteAtlasAsset)
        {
            string path = AssetDatabase.GetAssetPath(spriteAtlasAsset).Replace(".spriteatlas", AssetUtility.SpriteAtlasSuffix + ".asset");

            if (System.IO.File.Exists(path))
            {
                return(AssetDatabase.LoadAssetAtPath <SpineSpriteAtlasAsset>(path));
            }
            return(null);
        }
        void GenerateAssetsFromSpriteAtlas(UnityEngine.U2D.SpriteAtlas spriteAtlasAsset)
        {
            AssetUtility.IngestSpriteAtlas(spriteAtlasAsset, null);
            string texturePath;

            if (AssetUtility.GeneratePngFromSpriteAtlas(spriteAtlasAsset, out texturePath))
            {
                Debug.Log(string.Format("Generated SpriteAtlas texture '{0}'", texturePath), spriteAtlasAsset);
            }
        }
        static StackObject *get_tag_1(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj)
        {
            CSHotFix.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject *ptr_of_this_method;
            StackObject *__ret = ILIntepreter.Minus(__esp, 1);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
            UnityEngine.U2D.SpriteAtlas instance_of_this_method = (UnityEngine.U2D.SpriteAtlas) typeof(UnityEngine.U2D.SpriteAtlas).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            var result_of_this_method = instance_of_this_method.tag;

            return(ILIntepreter.PushObject(__ret, __mStack, result_of_this_method));
        }
        static StackObject *get_isVariant_0(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj)
        {
            CSHotFix.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject *ptr_of_this_method;
            StackObject *__ret = ILIntepreter.Minus(__esp, 1);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
            UnityEngine.U2D.SpriteAtlas instance_of_this_method = (UnityEngine.U2D.SpriteAtlas) typeof(UnityEngine.U2D.SpriteAtlas).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            var result_of_this_method = instance_of_this_method.isVariant;

            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value      = result_of_this_method ? 1 : 0;
            return(__ret + 1);
        }
        static StackObject *GetSprite_0(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj)
        {
            ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject *ptr_of_this_method;
            StackObject *__ret = ILIntepreter.Minus(__esp, 2);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
            System.String @name = (System.String) typeof(System.String).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
            UnityEngine.U2D.SpriteAtlas instance_of_this_method = (UnityEngine.U2D.SpriteAtlas) typeof(UnityEngine.U2D.SpriteAtlas).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            var result_of_this_method = instance_of_this_method.GetSprite(@name);

            return(ILIntepreter.PushObject(__ret, __mStack, result_of_this_method));
        }
예제 #8
0
        static StackObject *Invoke_0(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj)
        {
            ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject *ptr_of_this_method;
            StackObject *__ret = ILIntepreter.Minus(__esp, 2);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
            UnityEngine.U2D.SpriteAtlas @obj = (UnityEngine.U2D.SpriteAtlas) typeof(UnityEngine.U2D.SpriteAtlas).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack), (CLR.Utils.Extensions.TypeFlags) 0);
            __intp.Free(ptr_of_this_method);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
            System.Action <UnityEngine.U2D.SpriteAtlas> instance_of_this_method = (System.Action <UnityEngine.U2D.SpriteAtlas>) typeof(System.Action <UnityEngine.U2D.SpriteAtlas>).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack), (CLR.Utils.Extensions.TypeFlags) 8);
            __intp.Free(ptr_of_this_method);

            instance_of_this_method.Invoke(@obj);

            return(__ret);
        }
예제 #9
0
        static StackObject *SetResult_5(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj)
        {
            ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject *ptr_of_this_method;
            StackObject *__ret = ILIntepreter.Minus(__esp, 2);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
            UnityEngine.U2D.SpriteAtlas @ret = (UnityEngine.U2D.SpriteAtlas) typeof(UnityEngine.U2D.SpriteAtlas).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack), (CLR.Utils.Extensions.TypeFlags) 0);
            __intp.Free(ptr_of_this_method);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
            ptr_of_this_method = ILIntepreter.GetObjectAndResolveReference(ptr_of_this_method);
            ET.ETAsyncTaskMethodBuilder <UnityEngine.U2D.SpriteAtlas> instance_of_this_method = (ET.ETAsyncTaskMethodBuilder <UnityEngine.U2D.SpriteAtlas>) typeof(ET.ETAsyncTaskMethodBuilder <UnityEngine.U2D.SpriteAtlas>).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack), (CLR.Utils.Extensions.TypeFlags) 16);

            instance_of_this_method.SetResult(@ret);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
            WriteBackInstance(__domain, ptr_of_this_method, __mStack, ref instance_of_this_method);

            __intp.Free(ptr_of_this_method);
            return(__ret);
        }
        static StackObject *GetSprites_6(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj)
        {
            CSHotFix.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain;
            StackObject *ptr_of_this_method;
            StackObject *__ret = ILIntepreter.Minus(__esp, 3);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 1);
            System.String @name = (System.String) typeof(System.String).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 2);
            UnityEngine.Sprite[] @sprites = (UnityEngine.Sprite[]) typeof(UnityEngine.Sprite[]).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            ptr_of_this_method = ILIntepreter.Minus(__esp, 3);
            UnityEngine.U2D.SpriteAtlas instance_of_this_method = (UnityEngine.U2D.SpriteAtlas) typeof(UnityEngine.U2D.SpriteAtlas).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack));
            __intp.Free(ptr_of_this_method);

            var result_of_this_method = instance_of_this_method.GetSprites(@sprites, @name);

            __ret->ObjectType = ObjectTypes.Integer;
            __ret->Value      = result_of_this_method;
            return(__ret + 1);
        }