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

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

511. 分享:图集资源做位图文本的工具类(知道fontclip组件的可以略过了,之前一直没注意到这个组件) [ 42%]

...据实际情况修改。有需要的可以参考下/* * 位图字体; */ class BPFont extends Laya.Sprite { // 文本内容 private _text: string; // 水平排列方式 private _align: string; // 资源前缀 private resFix: string; // 间距 private _padding: number; // 位图集合 private chars: ...

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

512. ProtocolBuffer通信 · LayaAir3.3 · 引擎文档 · LAYABOX [ 42%]

...前文件 import * as protobuf from "./libs/protobuf/protobuf"; const { regClass } = Laya; @regClass() export class ProtobufDemo extends Laya.Script { onEnable() { console.log("Game start"); } } 2.2 Protobuf示例脚本 引入了protobuf模块就可以直接在项目中使用了,这里我们写了...

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

513. 写了个边缘光的自定义shader,有很多问题,帮忙看一下 [ 41%]

...tomMaterial.__super.call(this); this.setShaderName("CustomShader"); } Laya.class(CustomMaterial, "CustomMaterial", Laya.BaseMaterial); CustomMaterial.DIFFUSETEXTURE = 1; CustomMaterial.prototype.getDiffuseTexture = function () { return this._getTexture(CustomMaterial.DIFFUSETEXTURE); } CustomMateria...

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

514. laya.d3.core.MeshTerrainSprite3D [ 41%]

API DocumentationAll Packages | All Classes | Index | Frames No Frames MeshTerrainSprite3DProperties | Methods | Events | Constants Packagelaya.d3.coreClasspublic class MeshTerrainSprite3DInheritanceMeshTerrainSprite3D MeshSprite3D RenderableSprite3D Sprite3D ComponentNode Node EventDispa...

来源: laya_api 发布时间: 20170929

515. 引擎 TiledMap 居然不支持图块翻转 [ 41%]

...73741824;     const TiledMapFlipConstHalf = TiledMapFlipConst / 2;     class GridSprite extends Laya.Sprite {         constructor() {             super(...arguments);             this.relativeX = 0;             this.relativeY = 0;             this.isAloneObject = fals...

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

516. Socket能连接到服务器,客户端发请求也能收到服务端的数据,但是服务端主动推送数据,客户端就是收不到数据? [ 41%]

...Core.TipsManager; import laya.utils.Browser; /** * ... * @author */ public class Socketmanger{ private static var _I:Socketmanger; public static function get Instance():Socketmanger { if(_I==null)_I=new Socketmanger(); return _I; } private static var socket:Socket=null; private var list:Array=; publ...

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

517. SCALE_FIXED_WIDTH适配屏幕的问题 [ 41%]

...Chrome/66.0.3359.126 MQQBrowser/6.2 T     代码如下,另附上demo  class Main {         private _roomId = 0;         constructor(roomId?: number) {             this._roomId = roomId;             Laya.init(750, 1218, Laya.WebGL);             Laya.Browser.document.tit...

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

518. 项目做了一周.然后打不开了.怎么办? [ 40%]

...ron-browser/workbench.main.js:95787 [Extension Host] SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder". SLF4J: Defaulting to no-operation (NOP) logger implementation d.logExtensionHostMessage @ /E:/laya/ide/LayaAirIDE_1.7.15/resources/app/out/vs/workbench/electron-browser/workbench.mai...

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

519. APP二次开发传字符串过长问题 [ 40%]

...。但是native打包安卓APP后, ExportJavaFunction.CallBackToJS(Test.class,"test",str); 二次开发中 APP调用JS方法的时候str字符串过长有丢失,请问是否有这个问题呢?请帮忙查看下? (字符串大概只收到1000个字符左右) 原字符串(在JAVA端打印...

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

520. Laya中的宏编译要怎么用啊 [ 39%]

...gn; import flash.display.StageScaleMode; import flash.events.Event; public class Main extends Sprite { public function Main():void { if (stage) init(); else addEventListener(Event.ADDED_TO_STAGE, init); } private function init(e:Event = null):void { removeEventListener(Event.ADDED_TO_STAGE, init); t...

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