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

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

581. 绘制三角形、多边形及根据数据绘制图案(TypeScript-LayaAir基础篇(TS)-矢量图) [ 74%]

...      this.sp = new Sprite();             Laya.stage.addChild(this.sp);             //画三角形             this.sp.graphics.drawPoly(30, 28, [0, 100, 50, 0, 100, 100], "#ffff00");            }     } } new laya.Sprite_DrawShapes(...

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

582. 动画播放完后,怎么知道?Animation.play() [ 74%]

...s.feijiBody=new Laya.Animation(); //把飞机的身体添加到容器 this.addChild(this.feijiBody); //播放动画 this.feijiBody.play(0,false,this.feijiName);播放结束后 出个提示框,alert("播放结束"); 怎么写 2018-01-19 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找...

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

583. 获取Sprite位置问题 [ 74%]

...reateFrames(["res/war/hero_fly1.png","res/war/hero_fly2.png"],"fly"); this.addChild(this.body); this.body.play(0,true,"fly"); //获取动画大小区域 var bound:Laya.Rectangle = this.body.getBounds();  //this.pos(100,0); console.log(-bound.width/2 + " --- "+ -bound.height/2); }  onPlayComplete()...

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

584. LayaAir2.6.0版阴影系统如何使用,请教请教! [ 74%]

...光: //添加方向光         this.m_light = this.m_scene3D.addChild(new Laya.DirectionLight()) as Laya.DirectionLight;         this.m_light.color = new Laya.Vector3(0.8, 0.8, 0.8);         this.m_light.transform.worldMatrix.setForward(new Laya.Vector3(1, -1, ...

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

585. 新人求教!!! [ 74%]

...    this.img = new Laya.Sprite();    //添加到舞台    Laya.stage.addChild(this.img);    //显示初始化绘制的图片    this.switchImg();    //侦听switchImg中图片区域的点击事件,触发后执行switchImg切换纹理绘制    this.img.on("click",this,this.switchImg);...

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

586. 3D寻路 · LayaAir3.0文档 · LAYABOX [ 74%]

...nish(): void { //初始化3D场景 this.scene = (<Scene3D>Laya.stage.addChild(Loader.createNodes("res/threeDimen/scene/TerrainScene/XunLongShi.ls"))); //根据场景中方块生成路径点 this.initPath(this.scene); //获取可行走区域模型 var meshSprite3D: MeshSprite3D = (<MeshSprit...

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

587. webgl 下当对象子显示对象存在panel且panel有子集时,旋转此显示对象会导致此显示对象的同级对象消失!(1.7.10beta) [ 74%]

...omp():void{ var parent:ui.ParentViewUI = new ui.ParentViewUI(); Laya.stage.addChild(parent); //当注释掉设置rotaion的代码则没有问题,否则会导致显示异常,其他child消失 parent.child_1.rotation = Math.random() * 180; } } class ChildView extends ui.ChildViewUI{ constructor(){ s...

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

588. Clip属性详解(JavaScript-IDE篇(JS)-IDE组件属性详解) [ 74%]

...age.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 - 35; counter.y = (Laya.stage.height ...

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

589. wx.getFileSystemManager is not a function [ 74%]

...eError: tex.once is not a function 官方视频教程中飞机大战 "this.addChild is not a function" 打地鼠发布成微信小游戏后提示gameThirdScriptError this.preinitialize is not a function "this.moles[this.index].show is not a function" api readFile success callback function undefined ...

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

590. 精灵添加名称 [ 74%]

...3");         sp.on(Event.CLICK,this, onsp);         Laya.stage.addChild(sp);   }   private function onsp(e:Event){              console.log("监听到按钮"+e.target);              console.log((e.target.getChildAt(0) as Sprite).name);              console.log(e.t...

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