Beispiel #1
0
        public void regDirect(string url, spriteTexture tex)
        {
            if (this.mapInfo.ContainsKey(url))
            //var item = this.mapInfo[url];
            //if (item != Script.Undefined)
            {
                throw new Exception("you can't reg the same name"); //ness
            }
            var item = new texutreMgrItem();                        //ness

            this.mapInfo[url] = item;
            item.url          = url;
            item.tex          = tex;
        }
Beispiel #2
0
        public void reg(string url, string urladd, textureformat format, bool mipmap, bool linear)
        {
            //重复注册处理
            if (this.mapInfo.ContainsKey(url))
            //var item = this.mapInfo[url];
            //if (item != Script.Undefined)
            {
                throw new Exception("you can't reg the same name"); //ness
            }
            var item = new texutreMgrItem();                        //ness

            this.mapInfo[url] = item;
            item.url          = url;
            item.urladd       = urladd;
            item.format       = format;
            item.mipmap       = mipmap;
            item.linear       = linear;
        }