大约有 377 项符合查询结果, 库内数据总量为 31,580 项。 (搜索耗时: 0.0146 秒)
Laya_社区(160) Laya3.0_api(70) Laya2.0_api(62) laya_api(59) Laya_示例(9) Laya2.0_文档(8) Laya2.0_示例(7) Laya3.0_文档(2)
...来自: 可以了 this.tiledMap.createMap("res/tiled/green.json", new Rectangle(0, 0, 1120, 860), new Handler(this, this.completeHandler),null,new Point(1120,860)); 最后那个参数new Point(1120,860),其实是地图的分块渲染的大小,默认是450,450,所以把我的地图分成3次...
来源: Laya_社区 发布时间: 20180321
... _OnMapCreate() { console.log("map create ..."); } var viewRect = new Laya.Rectangle(0, 0, Laya.stage.width, Laya.stage.height); var tMap = new Laya.TiledMap(); tMap.createMap("res/isometric_grass_and_water.json", viewRect, Laya.Handler.create(this, this._OnMapCreate), null, new Laya.Point(2 * 64, 2...
来源: Laya_社区 发布时间: 20190102
...ureCmd 用texture填充。 Graphics getBounds(realSize:Boolean = false):Rectangle 获取位置及宽高信息矩阵(比较耗CPU,频繁使用会造成卡顿,尽量少用)。 Graphics loadImage(url:String, x:Number = 0, y:Number = 0, width:Number = 0, height:Number = 0, complete:Function = ...
来源: Laya2.0_api 发布时间: 20190513
...色 Returns FillTextureCmd | null getBounds getBounds(realSize?: boolean): Rectangle Defined in laya/display/Graphics.ts:201 获取位置及宽高信息矩阵(比较耗CPU,频繁使用会造成卡顿,尽量少用)。 Parameters Default value realSize: boolean = false (可选)使用图片的...
来源: Laya3.0_api 发布时间: 20231115
...哪有计算 对象真是的大小了,明明 内部被赋值过一个 Rectangle 后就一直没变过 附件 : --> 2017-11-09 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 5 个回复 ymsdandan 赞同来自: 因为你...
来源: Laya_社区 发布时间: 20171109
... this.aniBody.play(0, loopPlay, key); var bound: Laya.Rectangle = this.aniBody.getBounds(); this.aniBody.pivot(bound.width / 2, bound.height / 2); if (direction < 0) { this.aniBody.scaleX = -1; } else { t...
来源: Laya_社区 发布时间: 20170615
...is.map=new Laya.TiledMap(); this.map.createMap("res/map/map.json",new Laya.Rectangle(0,0,Laya.Browser.width,Laya.Browser.height), Laya.Handler.create(this,this.onLoaded));报错的地方为:laya.tiledmap.js第178行: var tImageArray=relativePath.split("/");调试显示relativePath为undefined。...
来源: Laya_社区 发布时间: 20161224
...iledMap.createMap("tiledMap/orthogonal-test-movelayer.json", new Rectangle(0, 0, Laya.stage.width, Laya.stage.height), Handler.create(this,onLoadedMap)); } private var sp:Sprite; private function onLoadedMap():void { var mapLayer:MapLayer=tiledMap.getLayerByIndex(2); sp=new Sprite(); sp.gr...
来源: Laya_社区 发布时间: 20170525
...LoadState.eLoadMap; this._mTiledMap.createMap(conf.fileName + ".json", new Rectangle(0, 0, Browser.width, Browser.height), Handler.create(this, this.onCompleteHandler)); } /** * 销毁当前地图 */ public destroy():void{ if (this._mTiledMap) this._mTiledMap.destroy(); if (this._mLevelConf) this._m...
来源: Laya_社区 发布时间: 20180529
... createOption: any = { isStatic: false, }; this.matterBody = Matter.Bodies.rectangle(this.x, this.y, this.width, this.height, createOption); Matter.World.add(GameMain.instance.engine.world, this.matterBody); this.matterBody.layaSprite = this; Matter.Events.on(GameMain.instance.engine, 'beforeUpdate'...
来源: Laya_社区 发布时间: 20180530