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

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

171. 3D中摄像机绕物体旋转该如何实现? [ 83%]

...age.on(Laya.Event.MOUSE_WHEEL, this, this.mouseWheel) } onUpdate(): void { if (Laya.Browser.onMobile) { this.AroundByMobileInput(); } else { this.AroundByMouseInput(); } if (!this.canRotation_X) this.targetAngles.y = 0; if (!this.canRotation_Y) this.targetAngles.x = 0; //Lerp. this.CurrentAngles = t...

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

172. 微信浏览器里横屏home键方向 [ 83%]

...竖屏             canvasDegree = 0;             if (rotation) {                 if (_screenMode === SCREEN_HORIZONTAL) {                     mat.rotate(Math.PI / 2);                     mat.translate(screenHeight / pixe...

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

173. 输入设备-贪吃蛇(重力感应) [ 83%]

... segments.length; i Laya.stage.width) targetPosition.x = Laya.stage.width; if (targetPosition.y Laya.stage.height) targetPosition.y = Laya.stage.height; } checkEatFood() { let food; for (let i = foods.length - 1; i >= 0; i--) { food = foods[i]; if (food.hitTestPoint(targetPosition.x, targetPosition....

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

174. 官方案例里摄像机绕物体旋转脚本的问题 [ 83%]

...age.on(Laya.Event.MOUSE_WHEEL, this, this.mouseWheel) } onUpdate(): void { if (Laya.Browser.onMobile) { this.AroundByMobileInput(); } else { this.AroundByMouseInput(); } if (!this.canRotation_X) this.targetAngles.y = 0; if (!this.canRotation_Y) this.targetAngles.x = 0; //Lerp. this.CurrentAngles = t...

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

175. 分享:List相关(Item增删功能) [ 83%]

...vate function onMouse(e:Event,index:int):void { //鼠标单击事件触发 if(e.type == Event.CLICK) {//如果点中的是checkBox组件 if((e.target) is CheckBox) { var tempObj:Object = arr[index];//记录当前条目所包含组件的数据信息(避免后续删除条目后数据结构显示错误...

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

176. Clip组件Bug:Play方法无法结束循环 [ 83%]

...有插件开发,修改源码会有问题): export default class GifView extends Laya.Clip {     /**      *开始帧位置      *      * @private      * @memberof GifView      */     private frameIndex = 0;     /**      *结束帧位置   ...

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

177. Uncaught 无法实例class PhysicsCollider extends PhysicsTriggerComponent [ 83%]

... var flags = bt.btCollisionObject_getCollisionFlags(btColObj);         if (this.owner.isStatic) {             if ((flags & PhysicsComponent.COLLISIONFLAGS_KINEMATIC_OBJECT) > 0)                 flags = flags ^ PhysicsComponent.COLLISIONFLAGS_KINEMATIC_OBJECT;           ...

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

178. LayaFlash:求ByteArray.jas ->readMultiByte对gb2312的实现翻译 [ 83%]

...(length:int, charSet:String):String          {             if(charSet=="UNICODE" || charSet=="unicode")             {                 return readUnicode(length);             }             if(charSet=="GB2312" || charSet=="gb2312")         ...

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

179. 飞机大战js源码中判断语句问题 [ 83%]

...的显示区域 480*852,则将背景1的y轴坐标,向上移动 852*2. if (bg1.y + box.y >= 852) { bg1.y -= 852 * 2; } //当背景2向下移动出游戏的显示区域 480*852,则将背景2的y轴坐标,向上移动 852*2. if (bg2.y + box.y >= 852) { bg2.y -= 852 * 2; } } })()这是飞机...

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

180. 微信关系链:LayaAir引擎针对开发数据域使用图集支持介绍 [ 83%]

...息监听**/ public function init():void { //接收主域透传的数据 if(MiniAdpter.isZiYu && MiniAdpter.isPosMsgYu) { __JS__('wx').onMessage(function(message:Object):void{ trace(message); if(message['isLoad'] == "filedata") { MiniFileMgr.ziyuFileData[message.url] = message.data;//文本...

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