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

大约有 1,232 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0054 秒)

121. 音频-播放演示 [ 92%]

...L = Laya.WebGL; export class Sound_SimpleDemo { //声明一个信息文本 private txtInfo: Text; constructor() { // 不支持WebGL时自动切换至Canvas Laya.init(Browser.clientWidth, Browser.clientHeight, WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Lay...

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

122. 屏幕适配-屏幕适配 [ 92%]

...mport WebGL = Laya.WebGL; export class SmartScale_T { //所有适配模式 private modes: Array = ["noscale", "exactfit", "showall", "noborder", "full", "fixedwidth", "fixedheight"]; //当前适配模式索引 private index: number = 0; //全局文本信息 private txt: Text; constructor() { // 不...

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

123. 3D寻路 · LayaAir3.0文档 · LAYABOX [ 92%]

...色值放到数组中 /** * 通过图片数据计算得到AStart网格 */ private createGridFromAStarMap(texture): any { var textureWidth = texture.width; var textureHeight = texture.height; var pixelsInfo = texture.getPixels(); var aStarArr = []; var index = 0; for (var w = 0; w < textureWidth; ...

来源: Laya3.0_文档 发布时间: 20230303

124. 音频-播放演示 [ 92%]

...L = Laya.WebGL; export class Sound_SimpleDemo { //声明一个信息文本 private txtInfo: Text; constructor() { // 不支持WebGL时自动切换至Canvas Laya.init(Browser.clientWidth, Browser.clientHeight, WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTER; Lay...

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

125. 屏幕适配-屏幕适配 [ 92%]

...mport WebGL = Laya.WebGL; export class SmartScale_T { //所有适配模式 private modes: Array = ["noscale", "exactfit", "showall", "noborder", "full", "fixedwidth", "fixedheight"]; //当前适配模式索引 private index: number = 0; //全局文本信息 private txt: Text; constructor() { // 不...

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

126. UI-Input [ 92%]

...this.skins, Handler.create(this, this.onLoadComplete));//加载资源。 } private onLoadComplete(): void { for (var i: number = 0; i < this.skins.length; ++i) { var input: TextInput = this.createInput(this.skins[i]); input.prompt = 'Type:'; input.x = (Laya.stage.width - input.width) / 2; input.y = ...

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

127. socket.sent [ 92%]

...制的源码 openHandler 和 receiveHandler 没有响应  class Game { private socket: Laya.Socket; private byte: Laya.Byte; constructor() { //初始化引擎 //Laya.init(600, 400, Laya.WebGL); Laya.init(600,400); Laya.stage.scaleMode = Laya.Stage.SCALE_SHOWALL; Laya.stage.screenMode = Laya.Stage...

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

128. UI-Input [ 92%]

...this.skins, Handler.create(this, this.onLoadComplete));//加载资源。 } private onLoadComplete(): void { for (var i: number = 0; i < this.skins.length; ++i) { var input: TextInput = this.createInput(this.skins[i]); input.prompt = 'Type:'; input.x = (Laya.stage.width - input.width) / 2; input.y = ...

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

129. [LayaAirIDE3]xcode切入切出声音不播放 [ 92%]

...this, this.onBlur); Laya.stage.on(Laya.Event.FOCUS, this, this.onFocus);  private onBlur() {         // 暂停所有需要停止的逻辑         console.log("onBlur");         SoundManager.Instance.pauseBGM();         // // 部分机型包内不生效         SoundManager.Insta...

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

130. LAYABOX游戏实时语音之APP版本 [ 92%]

...on; /** * Created by Administrator on 2017/7/19. */ public class YIMMain { private final String TAG = "MarketTest"; private final static String strAppKey = "123132123";//你申请的App Key private final static String strSecrect = "1231312312312312312312";//你申请的App Secret private static Stri...

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