大约有 1,769 项符合查询结果, 库内数据总量为 31,625 项。 (搜索耗时: 0.0168 秒)
Laya_社区(1396) Laya2.0_文档(82) Laya3.0_api(68) Laya2.0_api(57) Laya3.0_文档(54) laya_api(53) Laya_示例(32) Laya2.0_示例(27)
...),null,Loader.ATLAS); } private function onLoadedSource():void { roleAni = new Animation(); playActions(); } 2、你打包图集的时候,.json文件的prefix键是没有值的,这个是因为你直接针对散图所在文件夹进行打包了,你需要在资源文件夹的外层再套一...
来源: Laya_社区 发布时间: 20170821
...擎 Laya.init(1136, 640); Laya.stage.bgColor = "#ffffff"; var sp : Label = new Label("hello world"); //sp.fontSize = 55; sp.pos(100, 100) ; //sp.color = "#000000"; Laya.stage.addChild(sp); } } } chrome 下查看源代码 <html> <head> <meta charset='utf-8'/> <title>www.layabo...
来源: Laya_社区 发布时间: 20170711
...rl: string, loops?: number, soundClass?: any, startTime?: number) { return new Promise((resolve, reject) => { let soundChannel: Laya.SoundChannel = Laya.SoundManager.playSound(url, loops, Laya.Handler.create(this, () => { resolve(soundChannel); }), soundClass, startTime); }); } 我使用Promis...
来源: Laya_社区 发布时间: 20180124
... } private _checkInput(input: Laya.TextInput) { let sp_icon: Laya.Sprite = new Laya.Sprite(); // 判定是否有两个子对象 if (input.numChildren == 2) { input.removeChildAt(1); } // 输入框为空则插入错误图标 if (input.text.trim().length == 0) { input.changeText(""); sp_icon.texture =...
来源: Laya_社区 发布时间: 20200410
...20 0 3 分享 微博 QZONE 微信 hujian0318 赞同来自: var sp:Sprite = new Sprite(); sp.graphics.drawRect(0, 0, 100, 100, "#ffff00"); Laya.stage.addChild(sp); sp.x = 50; trace(sp.x); // 输出50 sp.cacheAs = "bitmap"; sp.staticCache = true; sp.x = 100; trace(sp.x); // 输出100,且编译出来...
来源: Laya_社区 发布时间: 20171120
... 要回复问题请先登录 发起人 你海哥 相关问题 两个对象new了一个相同的对象,调用第一个的一个方法,走进了第二方法里 请问LayaAir中如何使图片以圆形的方式显示? 安装layaAirIDE2 ,跟着官网敲hello world 例子,为什么不显示? ...
来源: Laya_社区 发布时间: 20220824
...8-08-16 15:18 请问下这段代码有什么问题? let s: Laya.Sprite = new Laya.Sprite(); s.graphics.drawRect(10, 10, 580, 470, "#000000"); s.pos(0,0); console.log("=mask container=>>", s.width, s.height)//打印出是0,0 this.scrollContainer.mask = s;//scrollContainer...
来源: Laya_社区 发布时间: 20180720
...vas(100, 100, 0, 0);//把精灵绘制到canvas上面 var texture:Texture = new Texture(htmlCanvas);//使用htmlCanvas创建Texture var sp:Sprite = new Sprite().pos(0, 200);//创建精灵并把它放倒200位置 sp.graphics.drawTexture(texture);//把截图绘制到精灵上 Laya.stage.addChild(sp);//...
来源: laya_api 发布时间: 20170929
...vas(100, 100, 0, 0);//把精灵绘制到canvas上面 var texture:Texture = new Texture(htmlCanvas);//使用htmlCanvas创建Texture var sp:Sprite = new Sprite().pos(0, 200);//创建精灵并把它放倒200位置 sp.graphics.drawTexture(texture);//把截图绘制到精灵上 Laya.stage.addChild(sp);//...
来源: laya_api 发布时间: 20170929
...ing): Laya.Label { const STROKE_WIDTH: number = 4; var label: Laya.Label = new Label(); label.font = "Microsoft YaHei"; label.text = "SAMPLE DEMO"; label.fontSize = 30; label.color = color; if (strokeColor) { label.stroke = STROKE_WIDTH; label.strokeColor = strokeColor; } this.owner.addChild(label);...
来源: Laya3.0_文档 发布时间: 20251010