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

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

21. UI-Clip [ 94%]

...n); bg.size(224, 302); bg.pos(Laya.stage.width - bg.width >> 1, Laya.stage.height - bg.height >> 1); Laya.stage.addChild(bg); } function createTimerAnimation() { counter = new Clip(clipSkin, 10, 1); counter.autoPlay = true; counter.interval = 1000; counter.x = (Laya.stage.width - counter.width) / 2 ...

来源: Laya_示例 发布时间: 20251130

22. 为何我的stage.height不能随着实际窗口自动改变呢? [ 94%]

为何我的stage.height不能随着实际窗口自动改变呢? 这导致我的UI设置bottom属性无效,请问是怎么回事呢   谢谢     static width:number=450;     static height:number=1000;     static scaleMode:string="fixedwidth";     static screenMode:string="...

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

23. UI布局计算bug [ 94%]

...x,分别取名m_Child_1跟m_Child_2,其中m_Child_1设置width为720,height为1280,m_Child_2设置布局参数为:left、right、top、bottom均为0,目的是初始化后m_Child_2的宽高为720*1280。 接下来是bug描述:布局属性在初始化时,使用父控件的私有宽度_...

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

24. 性能测试-虫子(慎入) [ 94%]

...pBounds; var maggotTexture; (function() { Laya.init(Browser.width, Browser.height, WebGL); Laya.stage.bgColor = "#000000"; Stat.show(); wrapBounds = new Rectangle(-padding, -padding, Laya.stage.width + padding * 2, Laya.stage.height + padding * 2); Laya.loader.load(texturePath, Handler.create(this, ...

来源: Laya_示例 发布时间: 20251130

25. 请问graphics.drawTexture(texture)中如何增加一个matrix,只显示图中的一个圆形区域 [ 94%]

...; } } miniMap.src=url;     function circle_image(img, oldImgWidth, oldImgHeight) { var width, height, canvas, contex, circle; if (img.width > img.height) { width = img.height; height = img.height; } else { width = img.width; height = img.width; } canvas = document.createElement('canvas'); if (!...

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

26. UI-Clip [ 94%]

...n); bg.size(224, 302); bg.pos(Laya.stage.width - bg.width >> 1, Laya.stage.height - bg.height >> 1); Laya.stage.addChild(bg); } createTimerAnimation() { const Clip = Laya.Clip; this.counter = new Clip(clipSkin, 10, 1); Laya.stage.addChild(this.counter); this.counter.autoPlay = true; this.counter.int...

来源: Laya2.0_示例 发布时间: 20251130

27. fixed_height时不居中 [ 94%]

fixed_height时不居中 我使用fixed_height + 居中对齐,为何在layaair调试器那里看到的是不居中的呢?   初始化代码如下: constructor() {     Laya.init(640, 1136, Laya.WebGL);     Laya.stage.scaleMode = Laya.Stage.SCALE_FIXED_HEIGHT;     Laya.stage.screenMode = L...

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

28. stage.height获取高度有bug吗 [ 93%]

stage.height获取高度有bug吗 本人初学者,代码也很简单,如上图 红框部分是想实现startupView与stage底对其 但是,在微信里浏览时发现,每次效果都不一样,有时候能达到目的,有时候却不能 研究一番后,发现:每次获取到的stage....

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

29. 性能测试-虫子(慎入) [ 93%]

...// 不支持WebGL时自动切换至Canvas Laya.init(Browser.width, Browser.height, WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Stat.show(); wrapBounds = new Rectangle(-padding, -pa...

来源: Laya2.0_示例 发布时间: 20251130

30. 问一下Sprite的width,height是不是不pivotX,pivotY无关 [ 93%]

问一下Sprite的width,height是不是不pivotX,pivotY无关 如题,我如何指定一个pivotX,pivotY居中的图片的width和height缩小后不偏移 就是说我现在有张图片pivotX,pivotY是居中的 我想让他的width和height的点击范围变小,可以变小后,监听区域就...

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