大约有 4,034 项符合查询结果, 库内数据总量为 30,903 项。 (搜索耗时: 0.0164 秒)
Laya_社区(3264) Laya2.0_文档(296) Laya_示例(141) Laya2.0_示例(117) Laya3.0_文档(107) Laya3.0_api(94) Laya2.0_api(9) laya_api(6)
...来自: Laya.init(500,400,Laya.WebGL);createText();function createText(){this.txt = new Laya.Text();this.txt.overflow = Laya.Text.SCROLL;this.txt.text = "Layabox是HTML5引擎技术提供商与优秀的游戏发行商,面向AS/JS/TS开发者提供HTML5开发技术方案!\n" ;this.txt.size(200,10...
来源: Laya_社区 发布时间: 20180125
...坐标就全乱了 以下是源码里对于舞台位置的实现: if (this._alignH==="left")this.offset.x=0; else if (this._alignH==="right")this.offset.x=screenWidth-realWidth; else this.offset.x=(screenWidth-realWidth)*0.5 / pixelRatio; if (this....
来源: Laya_社区 发布时间: 20191127
...a.Byte; constructor() { //初始化引擎 Laya.init(600, 400, Laya.WebGL); this.byte = new Laya.Byte(); //这里我们采用小端 this.byte.endian = Laya.Byte.LITTLE_ENDIAN; this.socket = new Laya.Socket(); //这里我们采用小端 this.socket.endian = Laya.Byte.LITTLE_ENDIAN; //建立连接 this...
来源: Laya2.0_文档 发布时间: 20210714
...; Laya.stage.bgColor = "#232628"; Laya.loader.load(apePath, Handler.create(this, createApe)); })(); function createApe() { // 添加一只猩猩 ape = new Sprite(); ape.loadImage(apePath); var texture = Laya.loader.getRes(apePath); ape.pivot(texture.width / 2, texture.height / 2); ape.pos(Laya.stage...
来源: Laya_示例 发布时间: 20250223
...n setup() { createApe(); createTimerLine(); Laya.stage.on( Event.KEY_DOWN, this, this.keyDown); } function createApe() { target = new Sprite(); target.loadImage("../../res/apes/monkey2.png"); Laya.stage.addChild(target); target.pivot(55, 72); target.pos(100,100); } function createTimerLine() { timeL...
来源: Laya_示例 发布时间: 20250223
...createDom(); initMap(); createInfoText(); var successHandler = new Handler(this, updatePosition); var errorHandler = new Handler(this, onError); // 使用高精度位置 Geolocation.enableHighAccuracy = true; Geolocation.watchPosition(successHandler, errorHandler); // 绑定作用域 convertToBaiduC...
来源: Laya_示例 发布时间: 20250223
... l13273866189 赞同来自: // 下落 _proto_.moveDownBall = function(){ this.ball.x -= this.vx; this.ball.y += this.vy; console.log("111111"); this.vy *= 0.99; this.vy += 0.25; console.log("222222"); if (this.ball.y + this.vy >= this.img1 ||this.ball.y + this.vy <= 0) { this.vy = -this.vy; co...
来源: Laya_社区 发布时间: 20171108
...e.ALIGN_CENTER; Laya.stage.alignV = Laya.Stage.ALIGN_MIDDLE; } onEnable(){ this.playerUnit = []; this.enemyUnit = []; this.playerUnit.push(new Laya.Animation()); this.enemyUnit.push(new Laya.Animation()); this.loadUnit(); } loadUnit(){ for(let i of this.playerUnit ){ i.loadAtlas("./character/m1...
来源: Laya_社区 发布时间: 20200910
bundle.js里为什么有些是_this,有些是this 编译后,自定义的this.mySprite对象,在bundle.js文件里会出现 _this.mySprite 和 this.mySprite 两种,后者报错 附件 : --> 2018-11-30 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: ...
来源: Laya_社区 发布时间: 20181130
...后发现在Skeleton::_update方法中的以下语句:var tGraphics; if (this._aniMode == 0) { tGraphics = this._templet.getGrahicsDataWithCache(this._aniClipIndex, this._clipIndex) || this._createGraphics(); if (tGraphics && this.graphics != tGraphics) { this.graphics = tGraphics; } }决...
来源: Laya_社区 发布时间: 20200109