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

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

131. 最新版本绘制100x100个sprite ios不能显示 [ 64%]

...t; this.MapColNum; j++){ var box = new laya.display.Sprite(); box.graphics.drawRect(0, 0, 30, 30, null, "#e6e4ef", 1); box.x = i * 30; box.y = j * 30; boxSp.addChild(box); } } boxSp.cacheAs = "bitmap"; this.addChild(boxSp); } boxSp.cacheAs = "bitmap"; 如果去掉这句话可以显示 是内部设...

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

132. 写消消乐游戏, 如何在tiledMap格子中添加精灵? [ 64%]

...p/map.json",viewRect);  // 精灵 var sp = new Laya.Sprite(); sp.graphics.drawRect(0, 0, 100, 100, "#FF0000", "#0000FF", 1) sp.zOrder = 1000;   请问这里如何把精灵添加到地图中? 看文档没看明白啊, 其他回答仿写都无效果. 2018-07-21 添加评论 免费帖 --> 分享 微...

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

133. matterjs渲染laya的ui [ 64%]

...0, 200, 80, 80); var layaSprite:Sprite = new Sprite(); layaSprite.graphics.drawRect( -40, -40, 80, 80, "#ffff00"); boxA.layaSprite = layaSprite;   2018-05-14 0 2 分享 微博 QZONE 微信 liudong95 赞同来自: 您好,如果我想旋转,缩放这个layaSprite要怎么做呢  直接设置这...

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

134. 分享:销毁龙骨动画! [ 64%]

...= 40; var button:Sprite = new Sprite(); button.size(w, h); button.graphics.drawRect(0, 0, w, h, "#FF7F50"); button.graphics.fillText(label, w / 2 , 8, "25px SimHei", "#FFFFFF", "center"); Laya.stage.addChild(button); return button; } private function parseComplete(fac:Templet):void { //创建模式...

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

135. 打包APK运行,drag拖动出现问题;color="#0"程序直接崩溃 [ 64%]

...    var _mDown:Sprite=new Sprite();             _mTop.graphics.drawRect(0,0,1,1,"#0");     3.叠加效果 BlendMode.ADD,apk中无效   4.MouseManager.as 运行 时报错,“ touchemoves is undefined”                case "touchmove":                      va...

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

136. 关于js继承类class的参数问题 [ 63%]

...m.__super.call(this);//初始化父类      *         this.graphics.drawRect(0, 0, 100, 20, "#ff0000");      *         var label = new laya.ui.Label();//创建一个 Label 类的实例对象 label 。      *         label.text = "100000";//设置 label 的文本内容。     ...

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

137. hitTestPoint对象父容器rotation旋转之后检测不了碰撞 [ 63%]

...tor() { super(); var _fish: Laya.Sprite = new Laya.Sprite() _fish.graphics.drawRect(this.are.x, this.are.y, this.are.width, this.are.height, "#00ff00"); _fish.x = 300 _fish.y = 200 this.addChild(_fish); Laya.timer.loop(100, this, function () { console.log(_fish.x, _fish.y, _fish.width, _fish.height,...

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

138. 为什么 Event 事件触发不了? [ 63%]

...:  var Block = new Sprite(); Laya.stage.addChild(Block); Block.graphics.drawRect(300, 200, 50, 50, "#000"); Block.pos(300, 100); Block.on(Event.MOUSE_DOWN, this, function() {     console.log(1); });   点击无效,但我给用 Laya.stage.on(Event.MOUSE_DOWN); 是有效的   什么原因了...

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

139. 精灵自动消失 [ 63%]

...个精灵或在box 组件在场景中为什么会消失 this.sp.graphics.drawRect(10, 166, 166, 90, "#ffff00"); 附件 : --> test.zip 2021-12-02 添加评论 免费帖 --> 分享 微博 QZONE 微信 没有找到相关结果 已邀请: 与内容相关的链接 提交 2 个回复 Layabox商务 赞同...

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

140. destination-out 叠加模式问题 [ 63%]

...ntainer); maskArea = new Sprite(); maskArea.alpha = 0.3; maskArea.graphics.drawRect(0, 0, Laya.stage.width, Laya.stage.height, "#0ef604"); guideContainer.addChild(maskArea); //EventManager.add(MyEvent.PLAYER_MOVE,this,playerMoveFun); playerMoveFun(); //EventManager.add(MyEvent.MYRESIZE,thi...

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