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

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

521. 在Unity中设置动画事件(TypeScript-3D基础(TS)-LayaAir3D之Animator动画) [ 60%]

...Scene_AnimationEvent/Conventional/layaScene.ls", Laya.Handler.create(this, function(scene) { Laya.stage.addChild(scene); //获取cube对象 var cube = scene.getChildByName("Cube") as Laya.Sprite3D; //添加组件(脚本) var _script = cube.addComponent(SceneScript) as SceneScript; //label用于显...

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

522. 嵌入字体 · LayaAir3.4 · 引擎文档 · LAYABOX [ 60%]

...续通过注册时传入的字体名称“layabox”使用关联字体。 function registerFont() { var assetFontData = conch.readFileFromAsset('font/layabox.ttf', 'raw'); if (assetFontData) { if (conch.registerFont("layabox", assetFontData)) { log('字体注册成功'); } else { log('字体注册...

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

523. 关于as版的Animation.createFrames()不能工作? [ 60%]

...lass LayaUISample { protected var text:Text; protected var aaa:AAA; public function LayaUISample() { Laya.init(1540, 990); Laya.Stat.show(); Laya.loader.load("res/atlas/war.json", Laya.Handler.create(this, this.onLoaded), null, Laya.Loader.ATLAS); Laya.loader.on(Event.ERROR, this, onError); } protec...

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

524. ToolTip鼠标悬停的使用 [ 60%]

...悬浮提示框 private var _tip:TipManager;//实例化TipManager public function ToolTipDemo() { Laya.init(Browser.width,Browser.height); Laya.stage.bgColor="#eeffcc"; Laya.loader.load("res/atlas/comp.json",Handler.create(this,onLoaded),null,Loader.ATLAS); } private function onLoaded():void { this....

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

525. Sprite graphics的显示比例问题 [ 60%]

Sprite graphics的显示比例问题 function createCharacter(skin) { var character = new Laya.Sprite(); character.loadImage(skin, 0, 0, 200, 200, Laya.Handler.create(this, function () {console.log('KO!~'); })); character.graphics.drawLine(0, 200, 200, 0, "#ff0000", 1); character.graphics.drawLine(...

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

526. 物理碰撞器(TypeScript-3D基础(TS)-LayaAir3D之物理系统) [ 60%]

...xture2D.load("res/threeDimen/Physics/grass.png", Laya.Handler.create(this, function(tex:Laya.Texture2D) { planeMat.albedoTexture = tex; })); //设置纹理平铺和偏移 planeMat.tilingOffset = new Laya.Vector4(10, 10, 0, 0); //设置材质 plane.meshRenderer.material = planeMat; //平面添加物...

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

527. 物理碰撞器(ActionScript-3D基础(AS3)-LayaAir3D之物理系统) [ 60%]

...); Texture2D.load("res/threeDimen/Physics/grass.png", Handler.create(null, function(tex:Texture2D):void { planeMat.albedoTexture = tex; })); //设置纹理平铺和偏移 planeMat.tilingOffset = new Vector4(10, 10, 0, 0); //设置材质 plane.meshRenderer.material = planeMat; //平面添加物理碰...

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

528. Unlit材质详解(TypeScript-3D基础(TS)-模型材质详解) [ 60%]

...xture2D.load("res/threeDimen/texture/earth.png", Laya.Handler.create(this, function(texture) { //设置反照率贴图 material2.albedoTexture = texture; })); earth2.meshRenderer.material = material2; ``` ![](img/1.png)(图1)

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

529. Unlit材质详解(JavaScript-3D基础(JS)-模型材质详解) [ 60%]

...xture2D.load("res/threeDimen/texture/earth.png", Laya.Handler.create(this, function(texture){ //设置反照率贴图 material2.albedoTexture = texture; })); earth2.meshRenderer.material = material2; ``` ![](img/1.png)(图1)

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

530. Effect材质详解(JavaScript-3D基础(JS)-模型材质详解) [ 60%]

...xture2D.load("res/threeDimen/texture/earth.png", Laya.Handler.create(this, function(texture) { //设置纹理 material.texture = texture; })); earth.meshRenderer.material = material; ``` ![](img/1.gif)(图1)

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