大约有 1,557 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0065 秒)
... new Laya.Box() bgWrapper.zOrder = 0 let bg = new Laya.Sprite(); bgWrapper.addChild(bg) Laya.stage.addChild(bgWrapper) bgWrapper.x = 375 bgWrapper.y = 667 bg.loadImage("../res/image/interface/intro_bg.png",0,0,1500,1500); bg.pivot(750,750) bg.alpha = 1 bg.rotation = 20 2018-05-19 1 0 分享 微博 Q...
来源: Laya_社区 发布时间: 20180519
... sp.loadImage("logo.png"); Laya.stage.addChild(sp); } private function onClick():void { //HTMLCanvas 是 Html Canvas 的代理类,封装了 Canvas 的属性和方法。。请不要直...
来源: Laya_社区 发布时间: 20170424
...Button=new Laya.Button(); btn.label="AAAAAA"; btn.pos(200,200); Laya.stage.addChild(btn); btn.on(Laya.Event.CLICK,this,()=>{console.log("click button");}); 请问 这样监听不到button的点击事件吗?如果我创建一个ui.view a a.on 也监听不到吗 2017-11-28 添加评论 免...
来源: Laya_社区 发布时间: 20171128
... txt = new Laya.Text(); txt.text = "abcde"; txt.fontSize = 100; Laya.stage.addChild(txt); txt = new Laya.Text(); txt.text = "我们是最好的"; txt.fontSize = 50; txt.x = 0; txt.y = 300; txt.scale(2,2); Laya.stage.addChild(txt);在laya2.0版本里,上面第二个文字显示不齐, log里提...
来源: Laya_社区 发布时间: 20181119
...te(); this.RoleMap.size(Laya.stage.width, Laya.stage.height/2); Laya.stage.addChild(this.RoleMap); this.RoleMap.addChild(this.Role); this.Role.pivot(16,24);// 图片32x48 this.Role.pos(100, 200); Role.js基础代码: var Role = ( function ( _super ) { function Role () { Role._super.call(this); ...
来源: Laya_社区 发布时间: 20181012
...omp():void{ var parent:ui.ParentViewUI = new ui.ParentViewUI(); Laya.stage.addChild(parent); //当注释掉设置rotaion的代码则没有问题,否则会导致显示异常,其他child消失 parent.child_1.rotation = Math.random() * 180; } } class ChildView extends ui.ChildViewUI{ constructor(){ s...
来源: Laya_社区 发布时间: 20170829
...init(550,400); var sp:Image=new Image(); sp.loadImage("2.png"); Laya.stage.addChild(sp); var text:Text=new Text(); text.fontSize=40; text.color="#FF00FF"; text.text="哈哈哈哈哈哈哈哈哈哈哈哈哈哈"; text.font="hu" text.pos(600,600); Laya.stage.addChild(text); Laya.timer.once(1000,this,on...
来源: Laya_社区 发布时间: 20160514
...idth /2 ,tx.height / 2); tx.align="center"; tx.valign="middle"; Laya.stage.addChild(tx); } })() 2017-11-15 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 1 个回复 Monica - 知识达人 赞同来自: 修改后的代码...
来源: Laya_社区 发布时间: 20171115
...ke(): void { let sprite = new Laya.Sprite(); // 添加到舞台 Laya.stage.addChild(sprite); } 3.2 显示图片 图片的显示是游戏开发的基础,Sprite类中用于显示图片是 Sprite.loadImage 和 Sprite.texture。 3.2.1 loadImage /** * <p>加载并显示一个图片。相当于加...
来源: Laya3.0_文档 发布时间: 20251010
...HTML = "<img src='res/test1.png'/>"; html.pos(150, 100); Laya.stage.addChild(img); Laya.stage.addChild(html); 按照这个顺序,图片test1.png加载不出来 2018-12-19 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提...
来源: Laya_社区 发布时间: 20181219