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

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

681. 分享一个Shader版的CoolDown实现 [ 56%]

... public static shader: coolDownShader = new coolDownShader();         constructor() {             var vs: string = " \             attribute vec2 position; \             attribute vec2 texcoord; \             attribute vec4 color; \             uniform vec2 size; \ ...

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

682. List属性详解(TypeScript-IDE篇(TS)-IDE组件属性详解) [ 56%]

... Handler = Laya.Handler; import WebGL = Laya.WebGL; export class UI_List { constructor() { // 不支持WebGL时自动切换至Canvas Laya.init(800, 600, WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgCo...

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

683. 加载UI不成功,项目源码已经上传 [ 56%]

... wudi199553 • 2017-11-13 19:48 class TestUI extends ui.test.TestPageUI { constructor() { super(); } } Laya.init(600, 400); Laya.stage.bgColor = "#FFFFF00"; this.onLoaded(); function onLoaded(): void { var testUI: TestUI = new TestUI(); Laya.stage.addChild(testUI); } 这是加载ui的代...

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

684. 获取Sprite位置问题 [ 56%]

...置问题 class Plant extends Laya.Sprite { public body :Laya.Animation; constructor(){ super(); this.body = new Laya.Animation(); Laya.Animation.createFrames(["res/war/hero_fly1.png","res/war/hero_fly2.png"],"fly"); this.addChild(this.body); this.body.play(0,true,"fly"); //获取动画大小区域 ...

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

685. laya如何用audio播放音频? [ 56%]

laya如何用audio播放音频? private elentAutio: HTMLAudioElement; constructor(){     super();     this.btn_play.on(Laya.Event.CLICK, this, this.onPlay);     this.elentAutio = <HTMLAudioElement>document.createElement('audio');     this.elentAutio.src="res/10.mp3"; } onPlay():void...

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

686. fixed_height时不居中 [ 56%]

...air调试器那里看到的是不居中的呢?   初始化代码如下: constructor() {     Laya.init(640, 1136, Laya.WebGL);     Laya.stage.scaleMode = Laya.Stage.SCALE_FIXED_HEIGHT;     Laya.stage.screenMode = Laya.Stage.SCREEN_VERTICAL;     Laya.stage.alignH = Laya.Stage.ALIGN_CENTER; ...

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

687. 区块地图-滚动地图 [ 56%]

...let mLastMouseX = 0, mLastMouseY = 0, mX, mY; class TiledMap_ScrollMap { constructor() { const Browser = Laya.Browser, WebGL = Laya.WebGL, Stage = Laya.Stage, Event = Laya.Event, Stat = Laya.Stat; // 不支持WebGL时自动切换至Canvas Laya.init(Browser.width, Browser.height, WebGL); Laya.stage.a...

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

688. "Utils3D:unidentified class type in (.lh) file." [ 56%]

...caught Can not find class 错误 发布微信小游戏运行错误,Class constructor xx cannot be invoked without 'new' 关于js继承类class的参数问题 Uncaught Can not find class laya.html.dom.HTMLDivElement class导出问题 问题状态 最新活动: 2018-04-03 23:00 浏览: 757 关注: 2...

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

689. laya.d3.core.Vector3Keyframe [ 56%]

...perty public var outTangent:Vector3valueproperty public var value:Vector3Constructor DetailVector3Keyframe()Constructorpublic function Vector3Keyframe() 创建一个 Vector3Keyframe 实例。 Method DetailcloneTo()methodoverride public function cloneTo(dest:*):void 克隆。 Parameters dest:* — ...

来源: Laya2.0_api 发布时间: 20190513

690. 鼠标脚本(JavaScript-3D基础(JS)-LayaAir3D之鼠标交互) [ 56%]

...*: ```typescript export default class MouseScript extends Laya.Script3D{ constructor(){super();} //物体必须拥有碰撞组件(Collider) //当被鼠标点击 onMouseDown(e){ //console.log("点击到了我box",owner.name); //从父容器销毁我自己 this.owner.removeSelf(); } } ``` > **...

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