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

大约有 10 项符合查询结果, 库内数据总量为 30,778 项。 (搜索耗时: 0.0053 秒)

1. UI-Tree [ 100%]

...发更高效。(function() { var Box = Laya.Box; var Clip = Laya.Clip; var Label = Laya.Label; var Utils = Laya.Utils; // 此类对应的json对象: // {"child": [{"type": "Clip", "props": {"x": "13", "y": "0", "left": "12", "height": "24", "name": "selectBox", "skin": "ui/clip_selectBox.png", "ri...

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

2. 射线检测-选取物体 [ 90%]

...Physics.rayCastAll(ray, _outHitAllInfo, 30, 0); } (function loadUI() { var label = new Laya.Label(); label.text = "点击选取的几何体"; label.pos(Laya.Browser.clientWidth / 2.5, 100); label.fontSize = 50; label.color = "#40FF40"; Laya.stage.addChild(label); //鼠标事件 Laya.stage.on(Laya.Ev...

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

3. 射线检测-放置物体 [ 86%]

... Laya.Physics.rayCast(ray, _outHitInfo, 30, 0); } (function loadUI() { var label = new Laya.Label(); label.text = "点击放置"; label.pos(Laya.Browser.clientWidth / 2.5, 100); label.fontSize = 50; label.color = "#40FF40"; Laya.stage.addChild(label); var _position = new Laya.Vector3(0, 0, 0); var _...

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

4. 射线检测-点击行走 [ 84%]

... Laya.Physics.rayCast(ray, _outHitInfo, 30, 0); } (function loadUI() { var label = new Laya.Label(); label.text = "点击放置"; label.pos(Laya.Browser.clientWidth / 2.5, 100); label.fontSize = 50; label.color = "#40FF40"; Laya.stage.addChild(label); var _offset = new Laya.Vector3(0, 0.25, 0); var ...

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

5. UI-Clip [ 83%]

...teController() { controller = new Button(buttonSkin, "暂停"); controller.labelBold = true; controller.labelColors = "#FFFFFF,#FFFFFF,#FFFFFF,#FFFFFF"; controller.size(84, 30); controller.on('click', this, onClipSwitchState); controller.x = (Laya.stage.width - controller.width) / 2; controller.y = ...

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

6. 缓动-缓动函数演示 [ 81%]

...目开发更高效。(function() { // 项渲染器 var Box = Laya.Box; var Label = Laya.Label; function ListItemRender() { var label = null; ListItemRender.__super.call(this); this.size(100, 20); label = new Label(); label.fontSize = 12; label.color = "#FFFFFF"; this.addChild(label); this.setLabel =...

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

7. 缓动-时间线 [ 78%]

...t(55, 72); target.pos(100,100); } function createTimerLine() { timeLine.addLabel("turnRight",0).to(target,{x:450, y:100, scaleX:0.5, scaleY:0.5},2000,null,0) .addLabel("turnDown",0).to(target,{x:450, y:300, scaleX:0.2, scaleY:1, alpha:1},2000,null,0) .addLabel("turnLeft",0).to(target,{x:100, y:300, ...

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

8. UI-Tab [ 77%]

...n onSkinLoaded() { var tabA = createTab(skins[0]); tabA.pos(40, 120); tabA.labelColors = "#000000,#d3d3d3,#333333"; var tabB = createTab(skins[1]); tabB.pos(40, 220); tabB.labelColors = "#FFFFFF,#8FB299,#FFFFFF"; } function createTab(skin) { var tab = new Tab(); tab.skin = skin; tab.labelBold = true...

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

9. UI-CheckBox [ 76%]

...够切换标签 if (i == 0) { cb.y += 20; cb.on("change", this, this.updateLabel, [cb]); this.updateLabel(cb); } } } } private createCheckBox(skin: string): CheckBox { var cb: CheckBox = new CheckBox(skin); Laya.stage.addChild(cb); cb.labelColors = "white"; cb.labelSize = 20; cb.labelFont = "Microso...

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

10. UI-RadioGroup [ 75%]

... = new RadioGroup(); rg.skin = skin; rg.space = 70; rg.direction = "v"; rg.labels = "Item1, Item2, Item3"; rg.labelColors = "#787878,#d3d3d3,#FFFFFF"; rg.labelSize = 20; rg.labelBold = true; rg.labelPadding = "5,0,0,5"; rg.selectHandler = new Handler(this, this.onSelectChange); Laya.stage.addChild(r...

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