大约有 517 项符合查询结果, 库内数据总量为 30,778 项。 (搜索耗时: 0.0037 秒)
...age.bgColor = "#232628"; Laya.loader.load(aniConfPath, Laya.Handler.create(this, this.createAnimation), null, Laya.Loader.ATLAS); } createAnimation() { const Animation = Laya.Animation; let ani = new Animation(); Laya.stage.addChild(ani); ani.loadAtlas(aniConfPath); // 加载图集动画 ani.interva...
来源: Laya2.0_示例 发布时间: 20241117
...ture Laya.stage.loadImage("res/pixi/laserBG.jpg"); Laya.stage.frameLoop(1, this, this.animate); } animate() { const Sprite = Laya.Sprite, Point = Laya.Point; let laser; if (tick > frequency) { tick = 0; // iterate through the dudes and update the positions laser = new Sprite(); laser.loadImage("res/...
来源: Laya2.0_示例 发布时间: 20241117
...leMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Stat.show(); this.setup(); } setup() { const Event = Laya.Event; let vGap = 100; this.button1 = this.createButton("点我3秒之后 alpha - 0.5"); this.button1.x = (Laya.stage.width - this.button1.width) / 2; this.button1.y = (Laya.stage....
来源: Laya2.0_示例 发布时间: 20241117
...g", "../../res/ui/vscroll$up.png"); Laya.loader.load(skins, Handler.create(this, onSkinLoadComplete)); })(); function onSkinLoadComplete() { placeHScroller(); placeVScroller(); } function placeHScroller() { var hs = new HScrollBar(); hs.skin = "../../res/ui/hscroll.png"; hs.width = 300; hs.pos(50, 1...
来源: Laya_示例 发布时间: 20241117
...件? parent加载了child1,child2,child3, parent.on(Event.MOUSE_DOWN, this, function(){ trace("parent被点击了!"); }); 其中child1,child2,child3都是load图片的Sprite,为何parent(它也是个Sprite)识别不到鼠标事件? 2017-03-12 添加评论 免费帖 --> 分享 ...
来源: Laya_社区 发布时间: 20170312
...ya.stage.bgColor = "#232628"; Laya.loader.load(assets, Laya.Handler.create(this, this.ShowContent)); } ShowContent() { const FontClip = Laya.FontClip; var clipnum= new FontClip(assets[0]); var fontClip = new FontClip(assets[1]); var TestFontClip = new FontClip(assets[1]); var TestClipNum = new FontC...
来源: Laya2.0_示例 发布时间: 20241117
..."#232628"; Laya.loader.load([buttonSkin, clipSkin, bgSkin], Handler.create(this, this.onSkinLoaded)); } onSkinLoaded() { this.showBg(); this.createTimerAnimation(); this.showTotalSeconds(); this.createController(); } showBg() { const Image = Laya.Image; let bg = new Image(bgSkin); bg.size(224, 302);...
来源: Laya2.0_示例 发布时间: 20241117
...leMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Stat.show(); this.setup(); } setup() { const Event = Laya.Event; this.createSprite(); Laya.stage.on(Event.MOUSE_UP, this, this.onMouseUp); Laya.stage.on(Event.MOUSE_OUT, this, this.onMouseUp); } createSprite() { const Sprite = Laya.Sprite...
来源: Laya2.0_示例 发布时间: 20241117
...leMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; Stat.show(); this.init(); } init() { const Sprite = Laya.Sprite, Animation = Laya.Animation, Text = Laya.Text, Event = Laya.Event; // 创建背景 this.spBg = Sprite.fromImage(PathBg); Laya.stage.addChild(this.spBg); // 创建动画 this....
来源: Laya2.0_示例 发布时间: 20241117
...E; Laya.stage.alignH = Stage.ALIGN_CENTER; Laya.stage.bgColor = "#232628"; this.createMap(); } private createMap(): void { this.tiledMap = new TiledMap(); this.tiledMap.createMap("../../res/tiledMap/perspective_walls.json", new Rectangle(0, 0, Laya.stage.width, Laya.stage.height), null); } } } new l...
来源: Laya_示例 发布时间: 20241117