大约有 96 项符合查询结果, 库内数据总量为 30,778 项。 (搜索耗时: 0.0036 秒)
... rotationInfo:RotationInfo):void { info.text = "alpha:" + Math.floor(rotationInfo.alpha) + '\n' + "beta :" + Math.floor(rotationInfo.beta) + '\n' + "gamma:" + Math.floor(rotationInfo.gamma); } ``` ## 2、加速计 `Accelerator`类定期发送设备的运动传感器检...
来源: Laya2.0_文档 发布时间: 20210714
...stage.mouseX, Laya.stage.mouseY, p); layer.getScreenPositionByTilePos(Math.floor(p.x), Math.floor(p.y), p); sprite.pos(p.x, p.y); } function mapLoaded() { layer = tiledMap.getLayerByIndex(0); var radiusX = 32; var radiusY = Math.tan(180 / Math.PI * 30) * radiusX; var color = "#FF7F50"; sprite = new ...
来源: Laya_示例 发布时间: 20241117
... rotationInfo: Laya.RotationInfo): void { this.info.text = "alpha:" + Math.floor(rotationInfo.alpha) + '\n' + "beta :" + Math.floor(rotationInfo.beta) + '\n' + "gamma:" + Math.floor(rotationInfo.gamma); } } new Gyroscope_Sample(); 2、加速计 Accelerator类定期发送设备的运动传感器...
来源: Laya3.0_文档 发布时间: 20230303
...地图坐标得到屏幕坐标 this.layer.getScreenPositionByTilePos(Math.floor(p.x), Math.floor(p.y), p); this.sprite.pos(p.x, p.y); } mapLoaded() { this.layer = this.tiledMap.getLayerByIndex(0); var radiusX = 32; var radiusY = Math.tan(180 / Math.PI * 30) * radiusX; // 14.37 var color = "#FF7F50";...
来源: Laya2.0_示例 发布时间: 20241117
... rotationInfo: Laya.RotationInfo): void { this.info.text = "alpha:" + Math.floor(rotationInfo.alpha) + '\n' + "beta :" + Math.floor(rotationInfo.beta) + '\n' + "gamma:" + Math.floor(rotationInfo.gamma); } } new Gyroscope_Sample(); ``` ## 2、加速计 `Accelerator`类定期发送设备的运动...
来源: Laya2.0_文档 发布时间: 20210715
...c.y - CacheStyle.CANVAS_EXTEND_EDGE; tRec.x = Math.floor(tRec.x + x) - x; tRec.y = Math.floor(tRec.y + y) - y; tRec.width = Math.floor(tRec.width); tRec.height = Math.floor(tRec.height); ...
来源: Laya_社区 发布时间: 20210615
...ap.ORIENTATION_STAGGERED: tileX = Math.floor(tileX); tileY = Math.floor(tileY); screenPos.x = tileX * this._map.tileWidth + (tileY & 1) * this._tileWidthHalf; ...
来源: Laya_社区 发布时间: 20220627
... result = { r: -1, g: -1, b: -1 }; result.b = color % 256; result.g = Math.floor((color / 256)) % 256; result.r = Math.floor((color / 256) / 256); return result; } let result = spliceColor(color); let lastResult = spliceColor(lastColor); let colorMatrix = [ 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, ...
来源: Laya_社区 发布时间: 20180930
...ge.mouseY, p); this.layer.getScreenPositionByTilePos(Math.floor(p.x), Math.floor(p.y), p); this.sprite.pos(p.x, p.y); } private mapLoaded(): void { this.layer = this.tiledMap.getLayerByIndex(0); var radiusX...
来源: Laya_社区 发布时间: 20201230
...void { this.view.box_mark.graphics.drawPie(216, 216, 216, -90, (-90 + Math.floor(percent * 360)), "#ff0000"); //画进度 let point: { x: number, y: number, hudu: number } = this.cal(216, 216, 205, Math.abs(Math.floor(percent * 360) ) - 90); //现在是顺时针,如果逆时针旋转 Math.abs(Math...
来源: Laya_社区 发布时间: 20190629