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

大约有 617 项符合查询结果, 库内数据总量为 30,723 项。 (搜索耗时: 0.0057 秒)

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

...pos(50,150); this.addChild(this.roombg); var button = new Sprite(); button.loadImage($mj.Curr_Game_ImagePath + "hall/room_jiesan.png"); button.pos(300, 0); this.roombg.addChild(button); button.on(Event.MOUSE_DOWN, this, function (e) { list.addItem(1); }); function Item() { Item.__super.call(this); t...

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

92. 关于Pivot和Mask联合使用时的显示问题再次提交 [ 75%]

...ion setup()     {         var bg = new Sprite();         bg.loadImage("../../res/bg2.png");         Laya.stage.addChild(bg);         bg2 = new Sprite();         bg2.loadImage("../../res/bg2.png");         Laya.stage.addChild(bg2);         bg2.scale(3, 3);...

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

93. 滤镜-模糊滤镜 [ 75%]

...his, createApe)); })(); function createApe() { var ape = new Sprite(); ape.loadImage(apePath); ape.x = (Laya.stage.width - ape.width) / 2; ape.y = (Laya.stage.height - ape.height) / 2; Laya.stage.addChild(ape); applayFilter(ape); } function applayFilter(ape) { var blurFilter = new BlurFilter(); blur...

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

94. Sprite-旋转缩放 [ 75%]

...232628"; createApe(); })(); function createApe() { ape = new Sprite(); ape.loadImage("../../res/apes/monkey2.png"); Laya.stage.addChild(ape); ape.pivot(55, 72); ape.x = Laya.stage.width / 2; ape.y = Laya.stage.height / 2; Laya.timer.frameLoop(1, this, animate); } function animate(e) { ape.rotation +...

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

95. Sprite用graphics绘制图形后,mouse_over触发scale显示有问题 [ 75%]

...w(); } private _initView():void { let sprite:Sprite = new Sprite(); sprite.loadImage("res/scene/1001/layer1/qiang.jpg", 100, 100, 100, 100); this.addChild(sprite); sprite = new Sprite(); sprite.graphics.drawCircle(100, 500, 50, "#0000ff"); //sprite.graphics.scale(2, 2); this.addChild(sprite); sprite...

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

96. 精灵 · LayaAir3.0文档 · LAYABOX [ 75%]

...创建完毕,此方法只执行一次 */ onAwake(): void { this.sprite.loadImage("atlas/comp/image.png"); //纹理:图片路径 this.sprite.pos(Laya.stage.width >> 1, Laya.stage.height >> 1); //位置:屏幕中心 this.sprite.x = Laya.stage.width/2; //x、y分别设置位置 this.s...

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

97. 点击事件面积太大 [ 74%]

...3good 1、如果你要改变go的位置,直接用pos方法,别直接在loadImage中修改 2、loadImage中的位置,是纹理logo.png相对于父级go的位置,所以虽然可见的图片不大,但是go的宽高是很大的 3、scale与width、height是相对独立互补影响的,如果...

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

98. Sprite-旋转缩放 [ 74%]

...() { this.ape = new Laya.Sprite(); Laya.stage.addChild(this.ape); this.ape.loadImage("res/apes/monkey2.png"); this.ape.pivot(55, 72); // this.ape.pos( Laya.stage.width / 2, Laya.stage.height / 2); this.ape.x = Laya.stage.width / 2; this.ape.y = Laya.stage.height / 2; this.scaleDelta = 0; Laya.timer....

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

99. 求助。layabox 加载url 图片 [ 74%]

...ayabox 加载url 图片 //(使用本地文件)这个是好使的 //ape.loadImage("../../laya/assets/monkey/monkey0.png"); //此url是用node.js 搭的用浏览器测试能看到图片。好使。 //下面代码不好使。请大家帮看看。我是小白,初学者,见谅。 var img_url:Stri...

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

100. 调用图集中小图片失败 [ 74%]

调用图集中小图片失败 var sp:Sprite=new Sprite(); sp.loadImage("img/btnbg2.png"); Laya.stage.addChild(sp); var sp1:Sprite=new Sprite(); sp1.loadImage("system/twoP.png"); Laya.stage.addChild(sp1); img图集中的小图可以调用到,system的图集调用不到,在浏览器的资源列表...

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