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

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

1. 分享,扩展Laya.Text组件实现简单的富文本 [ 100%]

...m visibleLineCount */ renderText(begin, visibleLineCount) { var graphics = this.graphics; graphics.clear(true); var ctxFont = (this.italic ? "italic " : "") + (this.bold ? "bold " : "") + this.fontSize + "px " + (Browser.onIPhone ? (laya.display.Text._fontFamilyMap[this.font] || this.font) : this.fo...

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

2. list ,增加item ,我想在末尾增加,但是每次都给我翻倍的增加,如何解决 [ 99%]

...次都给我翻倍的增加,如何解决 _proto.room_xinxi=function(){ this.roombg=new Laya.Image($mj.Curr_Game_ImagePath + "hall/room_bg.png"); this.roombg.pos(50,150); this.addChild(this.roombg); var button = new Sprite(); button.loadImage($mj.Curr_Game_ImagePath + "hall/room_jiesan.png"); butto...

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

3. 【LIST无法拖动】参照官方实例做的 [ 99%]

...selectEnable = true;         list.selectHandler = new Handler(thisthis.onSelect);         list.renderHandler = new Handler(thisthis.updateItem);                  // 设置数据项为对应图片的路径         var data: Array<String>...

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

4. 加载.lh文件 运行后黑屏 无法显示 [ 98%]

...ctor3 = new Laya.Vector3(0, 1, 0);     constructor() {         this._upVector3 = new Laya.Vector3(0, 1, 0);         Laya3D.init(0, 0); Laya.stage.scaleMode = Laya.Stage.SCALE_FULL; Laya.stage.screenMode = Laya.Stage.SCREEN_NONE;         Laya.Stat.show();     //var res...

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

5. (实现手指控制模型的缩放旋转)触控可以识别 但是导入的模型没有根据触控反应 [ 98%]

...or3(0, 1, 0); constructor(){         Laya.alertGlobalError = true; this._upVector3 = new Laya.Vector3(0, 1, 0); //初始化引擎         Laya3D.init(0, 0);         Laya.stage.scaleMode = Laya.Stage.SCALE_FULL;         Laya.stage.screenMode = Laya.Stage.SCREEN_NONE; ...

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

6. Laya多点触控是有开关吗 为什么多点触控没有任何反应 [ 98%]

...     Laya.stage.screenMode = Laya.Stage.SCREEN_NONE;         this.upVector3 = new Laya.Vector3(0, 1, 0);         //预加载所有资源         let resource = ["Export/LayaScene_JJF/Conventional/JJF.lh"];         Laya.loader.create(resource, Laya.Handler.create(...

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

7. timer.loop里面修改Text.text在微信小程序上用iPhone打开出现闪屏 [ 96%]

...改Text.text在微信小程序上用iPhone打开出现闪屏 如题,  this.myTest = new Laya.Text() this.myTest.pos(0, 0) this.myTest.size(100, 100) this.myTest.fontSize = 13 this.myTest.color = "#ffffff" this.myTest.align = "center" this.addChild(this.myTest) this.timer.loop(10, this, this.timer...

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

8. SVG渐变精灵的扩展脚本继承了多个精灵, 在safari环境下重叠了渲染 [ 96%]

...向, 求大大指点, 感激   附上渐变SVG文字的代码:   /** * this class is a extension of texts with gradient color  */ var effect; (function (effect) {     var GradientText = (function (_super) {         const style = {             DEFAULT: "default",             VERT...

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

9. http无响应 [ 96%]

...ar LoginView = (function (_super) { function LoginView() { LoginView.super(this); //调用父类构造函数 this.dlg; } function connect() { var hr = new Laya.HttpRequest(); hr.once(Event.PROGRESS, this, onHttpRequestProgress); hr.once(Event.COMPLETE, this, onHttpRequestComplete); hr.once(Event.ERR...

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

10. 分享个用美术资源做位图文本的方法。。。 [ 95%]

...序入口 class GameMain{ constructor() { Laya.init(600,400); var that = this; Laya.loader.load([{"url":"res/playerKpiFont.json","type":Laya.Loader.JSON}, {"url":"res/playerKpiFont.png","type":Laya.Loader.IMAGE}],new Laya.Handler(that,function(){ var jsonData = Laya.loader.getRes("res/playerKpiFont....

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