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

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

3961. 如何为灯光添加阴影(ActionScript-3D基础(AS3)-LayaAir3D之灯光) [ 44%]

... ....... // A sphere cast/receive shadow. var sphereSprite: MeshSprite3D = this.addPBRSphere(PrimitiveMesh.createSphere(0.1), new Vector3(0, 0.2, 0.5), scene); sphereSprite.meshRenderer.castShadow = true; sphereSprite.meshRenderer.receiveShadow = true; ``` 然后来看下效果。 ![](img/1.png)(图...

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

3962. Dialog 第一次打开总是出现在窗口右下角,这是为啥,再打开就正常剧中了? [ 44%]

...default class SettingDialog extends Laya.Dialog { constructor() { super(); this.loadScene('assets/scenes/dialogs/SettingDialog.scene'); } }{ "x":0, "type":"Dialog", "selectedBox":2, "selecteID":3, "searchKey":"Dialog", "props":{"width":1624,"sceneColor":"#000000","runtime":"script/view/dialogs/Setti...

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

3963. 关于位图字体的valign属性问题 [ 44%]

...0); mBitmap=new BitmapFont(); mBitmap.loadFont("date/data.fnt",new Handler(this,onLoadedFnt)); } private function onLoadedFnt():void { // TODO Auto Generated method stub Text.registerBitmapFont(mFontName,mBitmap); var text:Text=new Text(); text.pos(300,200); text.size(200,80); text.pivotY=text.heigh...

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

3964. 使用webgl之后toDataUrl返回黑色的图像 [ 44%]

...L); Stat.show(); Laya.stage.bgColor = "#ffcccc"; Laya.stage.on(Event.CLICK,this,onClick); sp= new Sprite(); sp.name='base'; sp.loadImage("logo.png"); Laya.stage.addChild(sp); } private function onClick():void { var htmlsss:String=(Laya.stage.getChildAt(0) as Sprite).drawToCanvas(100,100,0,0).getCanv...

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

3965. 含有List的Scene移除后List的item未移除,性能面板的Sprite一直增长 [ 44%]

...22-10-19 15:01 重写了createView; 将super.createView 替换为 let that=this; Laya.SceneUtils.createComp(a, that, that); that.hitTestPrior = true; 就会移除了,不知道会不会出其他问题T.T wxid_mq3mt1b4zxfq22 • 2022-10-20 16:55 十分感谢,这就下载2.13.2去学习。期待3.0...

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

3966. 微信小游戏wxmin图片加载有点问题 [ 44%]

...le.log(123120, ape) // Laya.loader.load('res/mao.jpg', Laya.Handler.create(this, function (){ // var t = Laya.loader.getRes('res/mao.jpg') // console.log(t) // var a = new Laya.Sprite() // a.graphics.drawTexture(t, 0,0) // a.scaleX = 0.3 // a.scaleY = 0.4 // a.pos(0,300) // Laya.stage.addChild(a) //...

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

3967. Laya3d球星添加了刚体,但是碰撞无法触发onTriggerEnter的问题,120元有偿悬赏解答 [ 44%]

... QZONE 微信 159*****332 赞同来自: 看着像刚提睡着了 设置 this.m_rig.sleepLinearVelocity = 0;试试 2020-07-28 0 1 分享 微博 QZONE 微信 shiyang 赞同来自: 两个isKinematic=true的刚体不触发碰撞 2020-07-28 0 3 分享 微博 QZONE 微信 ParadiseKiss 赞同来自: 有...

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

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

...景位置的更新,实现背景滚动效果。 Laya.timer.frameLoop(1, this, onLoop); })() /** * 在onLoop函数内,更新box容器的位置。 */ function onLoop() { //设置背景容器由上向下移动 1px box.y += 1; //当背景1向下移动出游戏的显示区域 480*852,则将背景1...

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

3969. 竖屏游戏实现背景缩放铺满全屏,UI相对高度等比较缩放,UI位置始终按照竖屏比例显示在屏幕中间 [ 44%]

...少,Laya.stage.scaleMode使用哪种模式,Laya.stage.on(Event.RESIZE, this, onResize);如何处理比例问题? 2018-03-13 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 2 个回复 Monica - 知识达人 赞同来自: ...

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

3970. 我在Layasample主类中,检测键盘按下并输出一切正常,可是放到其他类里面则能检测到按键按下,却一直输出undefined [ 44%]

...on (_super) {     function GameStart() {         GameStart.super(this);         Laya.stage.on(Laya.Event.KEY_DOWN,LayaSample,Test);     }     function Test(e){         console.log(e.keycode);             }   按下按键后一直输出undefined,在入口类...

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