• 首页
  • 动态
  • 案例
  • 引擎社区
  • API
  • 文档
  • 示例
  • 引擎下载

大约有 395 项符合查询结果, 库内数据总量为 31,722 项。 (搜索耗时: 0.0060 秒)

321. laya中js 如何实现Sprite类继承 [ 60%]

...oleMap = new Laya.Sprite(); 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 () { Ro...

来源: Laya_社区 发布时间: 20181012

322. 我创建了 一个 dialogUI,怎么在页面中打开? [ 60%]

...面中打开? this.wrong=new ui.wrongUI; this.wrong.width=300; this.wrong.height=200; this.wrong.x=50; this.wrong.y=100; this.doworkui.addChild(this.wrong); doworkui是我的一个UI,我要在这个面中打开一个对话框. wrongUI是我创建的 对话框 我现在这个对话框是可以初始...

来源: Laya_社区 发布时间: 20171027

323. Laya.loader.load(xx) 当地址""的时候,会报错。 [ 60%]

...                 tex = new Texture2D(data.width, data.height, 1, false, false);                     tex.wrapModeU = exports.WarpMode.Clamp;                     tex.wrapModeV = exports.WarpMode.Clamp;                 ...

来源: Laya_社区 发布时间: 20201130

324. var text = new Laya.Text();为什么text.pivot(200,200);不起作用 [ 59%]

...);不起作用 var text = new Laya.Text(); text.pivot(text.width / 2, text.height / 2); text.pivot(200,200); console.log(text.pivotX, text.pivotY); 打印显示都是0 2018-03-22 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交...

来源: Laya_社区 发布时间: 20180322

325. 关于UI编辑器的小建议 [ 59%]

...绝对定位,一种是相对定位 绝对定位时,可以使用width,height,x,y 相对定位时,在某些情况下不是很好用 比如说,我有一个按钮,宽高是固定的,100*100,这时我相对于上级的坐标希望是相对位置,right=0,top=0,表示右上角对...

来源: Laya_社区 发布时间: 20170217

326. LayaFlash下如何进行项目适配? [ 59%]

...度 1、通过Laya提供的方法Laya.window.innerWidth和Laya.window.innerHeight //[IF-JS]方法的使用请参考:LayaFlash宏编译//转换成h5项目后获取浏览器的宽度 //[IF-JS]sourceWidth = Laya.window.innerWidth; //转换成h5项目后获取浏览器的高度 //[IF-JS]sourceHeight =...

来源: Laya_社区 发布时间: 20151028

327. 为啥 增加 Text ,drawcall 暴增 ?????????????? [ 59%]

...ish.scoreItem.width/2; fish.scoreItem.y = fish.getBox().y - fish.scoreItem.height; this.scoreBox.addChild(fish.scoreItem); fish.scoreGold = new Laya.Image(); fish.scoreGold.skin = "assets/ui_imgs/icon_00312.png"; fish.scoreGold.x = fish.scoreItem.x; fish.scoreGold.y = fish.scoreItem.y; fish.scoreGol...

来源: Laya_社区 发布时间: 20180517

328. 开放数据域组件 · LayaAir3.4 · 引擎文档 · LAYABOX [ 59%]

...开放数据域的样式和布局 let style = { container: { width: 400, height: 200, backgroundColor: "#ffffff", justifyContent: "center", alignItems: "center", }, testText: { color: "#ffffff", width: "100%", height: "100%", lineHeight: 200, fontSize: 40, textAlign: "center", }, // 文字的最终...

来源: Laya3.0_文档 发布时间: 20251010

329. 加速器是不是不支持input:file [ 59%]

...iv class="upload-wrap" id="upload" style="left: 0px; top: 0px; width: 0px; height: 0px; display: none;">     <input type="file" class="upload-pic" id="upFile" accept="image/jpeg,image/png" value="upload Img">     <span class="upload-text"></span> </div>   我在html...

来源: Laya_社区 发布时间: 20170116

330. 请问下laya.ui.Component下面的anchorX和anchorY的作用,好像显示有问题? [ 59%]

...对象的正中心,那么pivotX=显示对象.width/2,pivotY=显示对象.height/2,anchor是用百分比的形式来设置的,值为0-1,那么用anchor设置就是anchorX=0.5,anchorY=0.5,两者选其一设置即可! 2017-04-12 0 0 分享 微博 QZONE 微信 为什么被折叠? 0 个回...

来源: Laya_社区 发布时间: 20170412