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

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

251. layabox 只支持一个灯光? [ 95%]

...一个灯光? //加载上料闪光 private addLoadCCDLight() { //聚光灯 this.loadCCDlight = this.scene.addChild(new Laya.SpotLight()) as Laya.SpotLight; this.loadCCDlight.color = new Laya.Vector3(1, 1, 1); this.loadCCDlight.transform.position = new Laya.Vector3(-1, 1.2, 0.0); this.loadCCDlight.di...

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

252. 颜色滤镜 差值变化 [ 95%]

...olorFilter = null; private _persent: number = 0; protected constructor() { this.targets = new Array<Laya.Sprite>(); } /** * 实例 */ public static getInstance(): ColorTool { if (ColorTool.instance == null) { ColorTool.instance = new ColorTool(); } return ColorTool.instance; }  /** * 添加...

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

253. 创建[HTMLDivElement]时遇到错误(手动实例一次本组件可定位错误) [ 95%]

...览: 2158 关注: 4 人 1569295620用户 • 2019-11-19 10:08 代码写。 this.contentDiv = new Laya.HTMLDivElement(); this.contentT.parent.addChild(this.contentDiv); this.contentDiv.x = this.contentT.x; this.contentDiv.y = this.contentT.y; this.contentDiv.width = this.contentT.width; this.contentD...

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

254. 其他引擎的Demo-Example_04 [ 95%]

...leMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Stat.show(); this.createText(); this.start(); } start() { const Sprite = Laya.Sprite; for (var i = 0; i w) { stars[i].x = stars[i].x - w; } else if (stars[i].x h) { stars[i].y = stars[i].y - h; } else if (stars[i].y = []; private w:number...

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

255. _calculateCacheRect函数有bug [ 95%]

...ps laya1应该也有这个问题。)    reset() {             this.releaseContext();             this.releaseFilterCache();             this.cacheAs = "none";             this.enableCanvasRender = false;             this.userSetCache = "none";             thi...

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

256. UI-ProgressBar [ 95%]

...s/ui/progressBar.png", "../../res/ui/progressBar$bar.png"], Handler.create(this, onLoadComplete)); })(); function onLoadComplete() { progressBar = new ProgressBar("../../res/ui/progressBar.png"); progressBar.width = 400; progressBar.x = (Laya.stage.width - progressBar.width) / 2; progressBar.y = Lay...

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

257. 为什么会出现报错 ani not found:ufo1_down [ 95%]

... var Game = (function(){ (function Game(){ // 子弹发射偏移位置表 this.bulletPos = [[0],[-15,15],[-30,0,30],[-45,-15,15,45]]; // 关卡等级 this.level = 0; // 升级等级所需要的成绩数量 this.levelUpScore = 0; // 积分成绩 this.score = 0; // 子弹级别 this.bulletLevel = 0; ...

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

258. 如何将原生iframe嵌入某个节点,像addChild那样嵌入 [ 95%]

...点,像addChild那样嵌入 HallView.prototype.OnClickOneGou=function(){ this.frame=Laya.Browser.document.createElement("iframe"); this.frame.width=this.con.width; this.frame.height=850; this.frame.style.margin="0"; this.frame.style.padding="0"; this.frame.style.left="0"; this.frame.style.top="50p...

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

259. viewportPointToRay产生的射线始终有偏差,是为什么? [ 95%]

...r2(Laya.stage.mouseX, Laya.stage.mouseY); camera.viewportPointToRay(point, this._ray);然后发现ray构造出来的位置始终不对,我沿着ray的方向放了一组3D物体,和从屏幕点击下去的位置始终有一定偏差~ 请教一下有哪些可能可以排查这个问题? 2018-02-...

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

260. 如何使用3D场景2D人物进行混合开发(JavaScript-3D基础(JS)-LayaAir3D之高级应用) [ 95%]

...ory=3d&group=Advance&name=Secne3DPlayer2D)) ```typescript //变换位置 this._position.x = Math.sin(this.scaleDelta += 0.01) * 2; this._position.z = Math.cos(this.scaleDelta += 0.01) * 2; //修改球的位置 this.sphere.transform.position = this._position; //计算位置 this._camera.viewport.pr...

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