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

大约有 323 项符合查询结果, 库内数据总量为 30,724 项。 (搜索耗时: 0.0049 秒)

101. LayaNative 2.8.0 加载的TTF字体不生效,附复现工程。 [ 69%]

...", Laya.Handler.create(this, (success) => {             console.log("2.8.0 字体加载是否成功:", success);             Laya.Text.defaultFont = "OPPOSANS-H";         }), null, Laya.Loader.TTF) 附件 : --> laya复现工程_2.6_.0和2_.8_.0_.zip 相...

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

102. 我二进制资源load之后,为什么通过getRes获取不到。 [ 69%]

...ndler.create(this, this.onProcess), null, 1, false); } onComplete(e,a,b) { console.log('资源加载完成!!',e,a,b); var cfg = Laya.Loader.getRes("config/data.txt"); console.log('cfg===',cfg, Laya.Loader.groupMap); } 2018-08-16 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到...

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

103. Laya2.2.0,官方demo,Iphone Xs Max 14.0 锁屏小游戏卡死 [ 69%]

...> { this.event(AppEvent.onShow, res); this.appStatus = AppEvent.onShow; console.log(this.appStatus, '---------'); Laya.stage.renderingEnabled = true//恢复渲染 Laya.updateTimer.resume() //恢复onUpdate Laya.timer.resume(); //恢复时间 Laya.timer.scale = 1; }) window['wx'].onHide(() => {...

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

104. laya3.0中jszip使用异常 [ 69%]

...         (zipData: JSZip) => {                         console.log(zipData.files);                         for (let i in zipData.files) {                             console.log(`key=${i},value=${zipData.files[i]}`);                         } ...

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

105. rigidBody.applyForce 物体不会移动 [ 69%]

....MeshSprite3D = building.getChildByName( "fence15" ) as Laya.MeshSprite3D; console.log("-----"); console.log(building); console.log("-----"); console.log(moveArea); } private playRun(): void { this.animator.play("Running"); this.animator.speed = 1.0; } private playIdle(): void { this.animator.play("...

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

106. 加载预制体json,返回值不统一 [ 68%]

...n", Laya.Handler.create(this, function (obj) {             console.log('hero',obj);         }), null, Laya.Loader.PREFAB);         Laya.loader.create("prefab/WeiTiao.json", Laya.Handler.create(this, function (obj) {             console.log('WeiTiao',...

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

107. 怎么才能像HTML5中那样直接操作Canvas [ 68%]

...10, 150, 150,"red"); ctx.fillText("texttt",100,100,"","#ffffff","center"); console.log("draw complete"); 2017-05-02 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 1 个回复 cuixueying 赞同来自: LayaAir也是基于canvas...

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

108. Laya下的图片上传示例(完整版) [ 68%]

...y):void { if(file.files.length>0) { if(20*1024<file.files[0].size) { console.log("图片大小不能超过20kb!") }else{ fileReader.readAsDataURL(file.files[0]); //转换图片格式为字符编码 } } }; fileReader.onload = function(e):void { if(Laya.Browser.window.FileReader.DONE == fileRead...

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

109. 使用外部引擎播放layaair制作的.ani [ 68%]

...; //播放Animation动画 tl.play(); tl.on(Event.COMPLETE, this, () => {console.log('end')}); } 2018-08-23 0 2 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 要回复问题请先登录 发起人 zyx 相关问题 看了其他引擎才发现 LAYA 真的太太太太好用了!...

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

110. matter中有没有类似于unity中的OnCollision碰撞检测函数呀,用js怎么写 [ 68%]

...', this.onCollision);   2.碰撞检测 private onCollision(event): void { console.log("碰撞了..");  var home = _gamePage._mainPage._playPage;  for(var i = 0; i < event.pairs.length; i++) {  var pair = event.pairs[i];  if(!(pair.bodyA.label === 'gun' || pair.bodyB.label == "gun")) continue...

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