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

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

71. 要做一个方形倒计时,请问该怎么实现,不知道该怎么做 [ 66%]

...eturn; } this.graphics.drawPie(pos,pos,r,START+(360 - value), 270 , COLOR ,null,0); } private function ef():void { if( TheGame.GetServerTime() > endTime ){ this.stop(); return; } var now:int = ( endTime - TheGame.GetServerTime() )/cdTime * 360; this.set360(now); } public function play(time:int,st...

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

72. 限制模型旋转角度 [ 66%]

...?是场景? fool_tiger • 2018-05-29 17:08 sphere.transform.parent 为null Laya_Aaron • 2018-05-29 16:33 不要动欧拉角。会 出问题。

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

73. UI-ProgressBar [ 66%]

...ndler.create(this, onLoadComplete)); } private function onLoadComplete(e:*=null):void { progressBar = new ProgressBar("../../../../res/ui/progressBar.png"); progressBar.width = 400; progressBar.x = (Laya.stage.width - progressBar.width ) / 2; progressBar.y = Laya.stage.height / 2; progressBar.sizeGr...

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

74. 射线检测-碰撞器混合 [ 66%]

...ent.MOUSE_UP, this, this.drawCollider); } private onKeyDown(e:Laya.Event = null):void { if (e.keyCode == Laya.Keyboard.UP) this.layaMonkey.transform.translate(this._tempUnitX1); else if (e.keyCode == Laya.Keyboard.DOWN) this.layaMonkey.transform.translate(this._tempUnitX2); else if (e.keyCode == Lay...

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

75. 灯光-点光 [ 66%]

...ar animator = aniSprite3d.getComponentByType(Laya.Animator); animator.play(null, 1.0, 75, 110); }); var _position = new Laya.Vector3(); var _quaternion = new Laya.Quaternion(); Laya.timer.frameLoop(1, null, function () { Laya.Quaternion.createFromYawPitchRoll(0.025, 0, 0, _quaternion); Laya.Vector3....

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

76. 材质-BlinnPhong-反射贴图 [ 65%]

..., 0, 0, -0.7071067); teapot2.meshFilter.sharedMesh.once(Laya.Event.LOADED, null, function (): void { var material: Laya.BlinnPhongMaterial = teapot2.meshRender.material as Laya.BlinnPhongMaterial; //反射贴图 material.reflectTexture = textureCube; }); Laya.timer.frameLoop(1, this, function (): vo...

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

77. 【简单跑酷--JS版】---Lv.5 玩家踩地板 [ 65%]

.../** * 地板类 */ function Floor(){ //背景贴图纹理 this.bgTexture = null; //最大右边距离 this.maxRight = 0; //判断是否超过右边最大距离了 this.isOutComplete = false; //背景 this.bg = null; //背景右边补丁 this.rightBg = null; Floor.__super.call(this); } //事件名称...

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

78. UI-ProgressBar [ 65%]

...ndler.create(this, onLoadComplete)); } private function onLoadComplete(e:*=null):void { progressBar = new ProgressBar("../../res/ui/progressBar.png"); progressBar.width = 400; progressBar.x = (Laya.stage.width - progressBar.width ) / 2; progressBar.y = Laya.stage.height / 2; progressBar.sizeGrid = "...

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

79. 区块地图-PerspectiveWall [ 65%]

...ive_walls.json", new Rectangle(0, 0, Laya.stage.width, Laya.stage.height), null); } })();module laya { import Stage = Laya.Stage; import TiledMap = Laya.TiledMap; import Rectangle = Laya.Rectangle; import Browser = Laya.Browser; import WebGL = Laya.WebGL; export class TiledMap_PerspectiveWall { priv...

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

80. 鼠标交互-自定义事件 [ 65%]

...vent.CLICK, this, onSpriteClick); } private function onSpriteClick(e:Event=null):void { var randomAngle:int = Math.random() * 180; //发送自定义事件 sp.event(ROTATE, [randomAngle]); } // 触发自定义的rotate事件 private function onRotate(newAngle:int):void { Tween.to(sp, {"rotation" : ne...

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