大约有 243 项符合查询结果, 库内数据总量为 30,935 项。 (搜索耗时: 0.0044 秒)
...创建完毕,此方法只执行一次 */ onAwake(): void { this.sprite.loadImage("atlas/comp/image.png"); //纹理:图片路径 this.sprite.pos(Laya.stage.width >> 1, Laya.stage.height >> 1); //位置:屏幕中心 this.sprite.x = Laya.stage.width/2; //x、y分别设置位置 this.s...
来源: Laya3.0_文档 发布时间: 20250103
...e drawTextures drawTriangles fillBorderText fillText fillTexture getBounds loadImage removeCmd restore rotate save scale strokeText transform translate create recycle Constructors constructor new GraphicsAni(): GraphicsAni Inherited from Graphics.constructor Defined in laya/display/Graphics.ts:54 Re...
来源: Laya3.0_api 发布时间: 20231115
...(box); //创建背景1 bg1 = new Sprite(); //加载并显示背景图1 bg1.loadImage("res/background.png"); //把背景1添加到容器 box box.addChild(bg1); //创建背景2 bg2 = new Sprite(); //加载并显示背景图2 bg2.loadImage("res/background.png"); //设置背景图2的坐标 bg2.pos(0, -...
来源: Laya_社区 发布时间: 20160810
...mer.frameLoop(1,this,myLoop) })(); function showApe() { // 方法1:使用loadImage加载背景1 var bg1 = new Sprite(); bg1.loadImage("war/bc.png"); Laya.stage.addChild(bg1); //加载背景2 var bg2 = new Sprite(); bg2.loadImage("war/bc.png"); //更改背景2 放在背景1的上面 bg2.pos(0,85...
来源: Laya_社区 发布时间: 20191017
...e drawTextures drawTriangles fillBorderText fillText fillTexture getBounds loadImage removeCmd restore rotate save scale setState strokeText transform translate Constructors constructor new AutoBitmap(): AutoBitmap Inherited from Graphics.constructor Defined in laya/display/Graphics.ts:54 Returns Au...
来源: Laya3.0_api 发布时间: 20231115
...e drawTextures drawTriangles fillBorderText fillText fillTexture getBounds loadImage removeCmd restore rotate save scale strokeText transform translate Constructors constructor new Graphics(): Graphics Defined in laya/display/Graphics.ts:54 Returns Graphics Accessors cmds get cmds(): any[] set cmds(...
来源: Laya3.0_api 发布时间: 20231115
...背景1 this.bg1 = new Laya.Sprite(); //加载并显示背景图 this.bg1.loadImage("war/bc.png"); //把背景1放在容器中 this.addChild(this.bg1); //创建游戏背景2 this.bg2 = new Laya.Sprite(); //加载并显示背景图 this.bg2.loadImage("war/bc.png"); //更改背景2,放在背景1的...
来源: Laya_社区 发布时间: 20191018
...画的播放实质就是定时切换Graphics对象。 使用set source、loadImages(...)、loadAtlas(...)、loadAnimation(...)方法可以创建动画模版。使用play(...)可以播放指定动画。 Public Properties Hide Inherited Public Properties Show Inherited Public Properties PropertyDefin...
来源: laya_api 发布时间: 20170929
...背景1 this.bg1 = new Laya.Sprite(); //加载并显示背景图 this.bg1.loadImage("ui/BG/play-bg.png", 0, 0, 720, 5120); //把背景图显示在容器内 this.addChild(this.bg1); //创建背景2 this.bg2 = new Laya.Sprite(); //加载并显示背景图 this.bg2.loadImage("ui/BG/play-bg.png", 0, 0, ...
来源: Laya_社区 发布时间: 20181105
...(比较耗CPU,频繁使用会造成卡顿,尽量少用)。 Graphics loadImage(url:String, x:Number = 0, y:Number = 0, width:Number = 0, height:Number = 0, complete:Function = null):void 加载并显示一个图片。 Graphics restore():void 返回之前保存过的路径状态和属性。 ...
来源: laya_api 发布时间: 20170929