大约有 40 项符合查询结果, 库内数据总量为 31,722 项。 (搜索耗时: 0.0125 秒)
...先回顾一下前文中创建MaterialInstancePropertyBlock的代码: ```typescript //创建材质instance属性块 this.materialBlock= new MaterialInstancePropertyBlock(); ``` 在前文使用drawMeshInstance的时候,MaterialInstancePropertyBlock类用来描述instance自定义属性,比如...
来源: Laya2.0_文档 发布时间: 20210714
...emo2/?language=ch&category=3d&group=Resource&name=GarbageCollection)) ```typescript function(e:Laya.Event):void { this._castType++; this._castType %= 2; switch (this._castType) { case 0: (e.target as Button).label = "释放显存"; this.loadScene(); break; case 1: (e.target as Button).label = "加...
来源: Laya2.0_文档 发布时间: 20210715
# 引擎常见问题Frequently Asked Questions ### 1,引擎的四种发布模式的区别 **内嵌模式**:内嵌模式会把编辑器的UI内容生成一个场景类代码文件,代码脚本里包含IDE创建的UI场景的信息,在小游戏和轻游戏还没有问世的时候,不用考虑j...
来源: Laya2.0_文档 发布时间: 20210714
# F9!项目设置介绍 > 本篇采用LayaAirIDE 2.0.1 bate 截图,如有不同,请下载最新的LayaAirIDE,以最新版本IDE为准。 ## 概述 快捷键F9,是LayaIDE最常用,也最不可或缺的功能,熟悉Laya的开发者都知道F9的重要性,而这一点早在1.0就已...
来源: Laya2.0_文档 发布时间: 20210715
...事件派发的功能。我们写个简单的例子来看下用法: ```typescript class LayaSample { constructor() { //初始化引擎 Laya.init(1136, 640); var xhr: Laya.HttpRequest = new Laya.HttpRequest(); xhr.http.timeout = 10000;//设置超时时间; xhr.once(Laya.Event.COMPLETE, this, this...
来源: Laya2.0_文档 发布时间: 20210715
...用和显示这个img。我们新建个项目。代码如下所示: ```typescript class LayaUISample { constructor() { //初始化引擎 Laya.init(600, 400); Laya.stage.bgColor = "#ffcccc"; var data: string = "data:image/svg+xml," + '' + '' + '' + 'I like ' + '' + 'cheese' + '' + '' + ''; var sp: ...
来源: Laya2.0_文档 发布时间: 20210715
##版本管理的功能介绍  关于版本管理,最开始是采用链接后加随机数的方式来管理,但是微信等环境下,缓存问题很严重,随机数方式并不能有效解决缓存问题,还是会出现因更新版本导致页面混乱等现象...
来源: Laya2.0_文档 发布时间: 20210715
...emo2/?language=ch&category=3d&group=Resource&name=GarbageCollection)) ```typescript function(e:Event):void { _castType++; _castType %= 2; switch (_castType) { case 0: (e.target as Button).label = "释放显存"; loadScene(); break; case 1: (e.target as Button).label = "加载场景"; if (_scene)//...
来源: Laya2.0_文档 发布时间: 20210715
# 关于声音 在LayaNative中,声音分为背景音乐、音效两种模式。 ## 1.背景音乐 在LayaNative中背景音乐只支持mp3格式,同时只能播放一个背景音乐。 ## 2.音效 在项目中,音效都是高频发事件,为了确保运行效率,LayaNative使用openAL播...
来源: Laya2.0_文档 发布时间: 20210715
...emo2/?language=ch&category=3d&group=Resource&name=GarbageCollection)) ```typescript function(e:Event) { this._castType++; this._castType %= 2; switch (this._castType) { case 0: (e.target as Button).label = "释放显存"; this.loadScene(); break; case 1: (e.target as Button).label = "加载场景"...
来源: Laya2.0_文档 发布时间: 20210715