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

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

331. 如何自定义Shader(TypeScript-3D基础(TS)-LayaAir3D之Shader) [ 49%]

...BaseMaterial变更为Material。 ```typescript export class CustomMaterial extends Laya.Material { constructor() { super(); //设置本材质使用的shader名字 this.setShaderName("CustomShader"); } } ``` #### 4.使用自定义材质 ​ 在使用自定义材质之前,一定要记得初始化自...

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

332. LayaBox HelloWorld实战 [ 49%]

...话框,对话框里面展示 Hello World!export default class HelloWorld extends Laya.Scene { constructor() { super(); HelloWorld.instance = this; } onBtnShowClick(){ var dialog = new Laya.Dialog(); dialog.width=300; dialog.height=600; //var bg = new Laya.Image('comp/img_bg.png'); //dialog.addChil...

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

333. ScrollRect设置会引起其他的UI资源无法正在显示 [ 49%]

...ge; import laya.utils.Handler; import ui.TestViewUI; public class TestView extends TestViewUI { private var PATH_LEN:Number = 120.0; private var speed:Number = 15; private var _path:Sprite = new Sprite(); private var arr:Array = []; public function TestView() { super(); _path.pivot(0,0); _path.pos(a...

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

334. swf转成H5资源显示超出原有范围 [ 49%]

...Context;     import flash.system.Capabilities;     public class Main extends Sprite     {         public function Main():void         {             if (stage) init();             else addEventListener(Event.ADDED_TO_STAGE, init);         }          ...

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

335. 动效问题,没有 ui.TestPUI,官方文档是错的,几年了至今无解答 [ 49%]

...Laya.Scene; var REG = Laya.ClassUtils.regClass; export class kick_effectUI extends EffectAnimation { //然后又改成Laya.EffectAnimation constructor(){ super(); this.ani1=null; this.effectData =ui.kick_effectUI.uiView;; } } kick_effectUI.uiView={"type":"View","props":{},"compId":2,"child":[{"type"...

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

336. List 组件做的手风琴Demo [ 49%]

...listArr[0].refresh()         }     /** * 创建BOX */ class Item extends Laya.Box{     public static WID:number =100;     public static HEI:number =30;     constructor(){         super()         this.size(Item.WID,Item.HEI);         var img1 =new Laya.Im...

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

337. List翻页效果 [ 49%]

...fo"; import { ui } from "../ui/layaMaxUI"; export default class RuleDialog extends ui.scene.RuleDialogUI { private m_index: number = -1; private m_downValue: number = -1; constructor() { super(); this.list_rule.hScrollBarSkin = ""; this.list_rule.renderHandler = new Laya.Handler(this, this.updateIte...

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

338. 仿照laya官方demo做了一个视频播放的UI,为啥在微信里不能用? [ 49%]

...下:   /**Created by the LayaAirIDE*/ module view { export class Guide extends ui.GuideUI { constructor() { super(); // 创建Video元素 let videoElmt: any = Laya.Browser.createElement("video"); Laya.Browser.document.body.appendChild(videoElmt); // 设置Video元素地样式和属性 videoElmt.s...

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

339. UI-Tree [ 49%]

..."Box", "props": {"name": "render", "right": "0", "left": "0"}}; class Item extends Box { constructor() { super(); this.right = 0; this.left = 0; var selectBox: Clip = new Clip("../../res/ui/tree/clip_selectBox.png", 1, 2); selectBox.name = "selectBox";//设置 selectBox 的name 为“selectBox”时...

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

340. Laya3D 中如何解决3D模型上添加文本的问题,类似Unity中的3DText [ 49%]

... 关注: 5 人 大大大懒猫 • 2018-09-10 10:39 export class ShopTitle extends Laya.Script{ public title: string; constructor(){ super(); } public _initialize(owner: Laya.Sprite3D): void { super._initialize(owner); var sprite3D = this.owner as Laya.MeshSprite3D; var sprite3DMat = new Laya.Standa...

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