大约有 4,103 项符合查询结果, 库内数据总量为 31,629 项。 (搜索耗时: 0.0071 秒)
Laya_社区(3324) Laya2.0_文档(296) Laya_示例(141) Laya2.0_示例(117) Laya3.0_文档(116) Laya3.0_api(94) Laya2.0_api(9) laya_api(6)
...位置, 这个可以用道具点击事件的阻止事件冒泡来解决 this.on(Laya.Event.MOUSE_DOWN, this, function (e) { e.stopPropagation();//阻止冒泡 console.log('@_@' + e.stageX, e.stageY); }); 另外,能分享一下,你的导弹是怎么做的吗?谢谢 2017-09-19 0 1 分享 微...
来源: Laya_社区 发布时间: 20170902
...; Laya.stage.bgColor = "#232628"; Laya.loader.load(ApePath, Handler.create(this, setup)); })(); function setup() { normalizeApe(); makeRedApe(); grayingApe(); } function normalizeApe() { var originalApe = createApe(); apeTexture = Laya.loader.getRes(ApePath); originalApe.x = (Laya.stage.width - apeT...
来源: Laya2.0_文档 发布时间: 20210714
...;& _selected) return; if(e.type==Event.MOUSE_DOWN){ QuickUtils.addDark(this,true); }else{ QuickUtils.addDark(this,false); } if (e.type === Event.CLICK) { toggle && (selected = !_selected); _clickHandler && _clickHandler.run(); return; } !_selected && (state = stateMap[e.t...
来源: Laya_社区 发布时间: 20160802
...个回复 Yangcy 赞同来自: Laya.loader.load("abc.json", Handler.create(this, onAssetLoadedSound), Handler.create(this, progressHandler), Loader.SOUND); 第一次加载出来: [list=none] [*]0: {column: "0", duration: "0", mode: "点", time: "3076"}[/*] [*]1: {column: "0", duratio...
来源: Laya_社区 发布时间: 20181122
...t; "use strict"; var test = {}; test.text = new laya.display.Text(); // in this line is error , so you can't defined class before "Laya.init" Laya.init(800,600); //test.text = new laya.display.Text(); // in this line is right test.text.text = "dsafdsdsada"; test.text.color = "#ff0000"; Laya.stage.ad...
来源: Laya_社区 发布时间: 20170302
...r_yao1yao=(function(){ function Controller_yao1yao(model){ /*__JS__ */var _this=this; /*__JS__ */_model=model; /*__JS__ */var SHAKE_THRESHOLD=100; /*__JS__ */var last_update=0; /*__JS__ */var x=y=z=last_x=last_y=last_z=0;; /*__JS__ */var canShake=1; /*__JS__ */if (window.DeviceMotionEvent){window.ad...
来源: Laya_社区 发布时间: 20160110
...32628"; Laya.loader.load("../../res/bg2.png", Handler.create(this, setup)); })(); function setup() { var bg = new Sprite(); bg.loadImage("../../res/bg2.png"); Laya.stage.addChild(bg); bg2 = new Sprite(); ...
来源: Laya_社区 发布时间: 20170826
...为黑色 txt.color = '#ffffff'; this.addChild(txt); var v:View = new View(); v.graphics.drawCircle(50, 50, 100, "#000000"); v.pos(100, 100); this.addCh...
来源: Laya_社区 发布时间: 20170725
... number = 0; @property( { type : Number } ) get weight() : number { return this._weight; } //如果没有 Setter,则 weight 为只读属性 set weight(value: number) { this._weight = value; } } 2.3 是否序列化保存 serializable 通过装饰器定义为组件属性后,默认状态下,属...
来源: Laya3.0_文档 发布时间: 20251010
...去舞台焦点(切出游戏)的处理 Laya.stage.on(Laya.Event.BLUR, this, () => { _sound.stop(); }); //获得舞台焦点(切回游戏)的处理 Laya.stage.on(Laya.Event.FOCUS, this, () => { _sound.play(0); }); …… Copyright ©Layabox 2025 all right reserved,powered by LayaAir E...
来源: Laya3.0_文档 发布时间: 20251010