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

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

81. UI-Dialog [ 93%]

...a.Button; let dialog = new Dialog(); let bg = new Image(assets[0]); dialog.addChild(bg); let button = new Button(assets[1]); button.name = Dialog.CLOSE; button.pos(DIALOG_WIDTH - CLOSE_BTN_WIDTH - CLOSE_BTN_PADDING, CLOSE_BTN_PADDING); dialog.addChild(button); dialog.dragArea = "0,0," + DIALOG_WIDTH...

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

82. js继承模式 [ 93%]

...is.img = []; this.init(); } Class.prototype.init = function() { Laya.stage.addChild(this); this.bg(); Laya.timer.frameLoop(1, this, this.loop); }; Class.prototype.bg = function() { for (var i = 0; i < 2; i++) { this.img[i] = new Laya.Image('background.png'); this.addChild(this.img[i]); } this.img...

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

83. UI-Slider [ 93%]

...ler = Laya.Handler; let hs = new HSlider("res/ui/hslider.png"); Laya.stage.addChild(hs); hs.width = 300; hs.pos(50, 170); hs.min = 0; hs.max = 100; hs.value = 50; hs.tick = 1; hs.changeHandler = new Handler(this, this.onChange); } placeVSlider() { const VSlider = Laya.VSlider, Handler = Laya.Handler...

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

84. [LayaAirIDE3]2d相机打包后问题 [ 93%]

...) {         const graphics = new Laya.Sprite();         this.owner.addChild(graphics);         this.addBoundaryLabels();     }      private addBoundaryLabels() {         const minXLabel = new Laya.Text();         minXLabel.text = `minX: ${this.playerScript.mapMinX}`;     ...

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

85. list 下 生成图片模糊 [ 93%]

...if (!root) { root = new Sprite(); root.pos(0, 0); root.name = "root"; cell.addChild(root); } 。。。。。 生成的 图片 从一个场景中回来在生成 他的 子物体 Sprite 在切换场景再回来 在生成 如此多次 自后 我的 list 内部 数量比较多但大部分都是重复,...

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

86. UI-Dialog [ 93%]

...plete() { var dialog = new Dialog(); var bg = new Image(assets[0]); dialog.addChild(bg); var button = new Button(assets[1]); button.name = Dialog.CLOSE; button.pos(DIALOG_WIDTH - CLOSE_BTN_WIDTH - CLOSE_BTN_PADDING, CLOSE_BTN_PADDING); dialog.addChild(button); dialog.dragArea = "0,0," + DIALOG_WIDTH...

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

87. 文本-字符限制 [ 93%]

...teLabel(text) { const Text = Laya.Text; let label = new Text(); Laya.stage.addChild(label); label.text = text; label.color = "white"; label.fontSize = 20; return label; } createInput() { const Input = Laya.Input; let input = new Input(); Laya.stage.addChild(input); input.size(200, 30); input.borderC...

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

88. 3D模型怎么删除?没回切换页面原来的模型都还在? [ 93%]

... 2.新建了个场景添加到B页面 this.scene = new Laya.Scene(); this.addChild(this.scene); 3.新建模型,并且添加B页面的3D场景中 var map: Laya.Sprite3D = Laya.Sprite3D.load("cj/cj.lh"); this.scene.addChild(map);   4.切换页面 private playGame(): void { Laya.stage.removeChild(this...

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

89. 动画挂点(TypeScript-3D基础(TS)-LayaAir3D之Animator动画) [ 92%]

...ntional/SceneMonkey.ls",Laya.Handler.create(this,function(res){ Laya.stage.addChild(res); //用于挂点的精灵 var box = new Laya.MeshSprite3D(Laya.PrimitiveMesh.createBox(1,1,1)); var material = new Laya.BlinnPhongMaterial(); Laya.Texture2D.load("res/layabox.png", Laya.Handler.create(this, funct...

来源: Laya2.0_文档 发布时间: 20210715

90. 动画挂点(JavaScript-3D基础(JS)-LayaAir3D之Animator动画) [ 92%]

...ntional/SceneMonkey.ls",Laya.Handler.create(this,function(res){ Laya.stage.addChild(res); //用于挂点的精灵 var box = new Laya.MeshSprite3D(Laya.PrimitiveMesh.createBox(1,1,1)); var material = new Laya.BlinnPhongMaterial(); Laya.Texture2D.load("res/layabox.png", Laya.Handler.create(this, funct...

来源: Laya2.0_文档 发布时间: 20210714