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

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

51. 请问graphics.drawTexture(texture)中如何增加一个matrix,只显示图中的一个圆形区域 [ 87%]

...圆形区域 我可以另外建一个圆形比如 var mapMask = new Laya.Sprite(); mapMask.size(100,100); mapMask.pos(50,50); mapMask.graphics.drawCircle(0, 0, 50, "#000000") 我这么获得mapMask的matrix,然后放进graphics.drawTexture中呢? 不要说直接用mask,因为微信小游戏不...

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

52. DOM元素-表单输入 [ 87%]

...ge.SCREEN_HORIZONTAL; Laya.stage.bgColor = "#FFFFFF"; this.form = new Laya.Sprite(); this.form.size(250,120); this.form.pos((Laya.stage.width - this.form.width) / 2, (Laya.stage.height - this.form.height) / 2); Laya.stage.addChild(this.form); this.rowHeight = 30; this.rowSpacing = 10; var rowHeightD...

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

53. TileMap 设置了Scale 进行缩放后,width、height 怎么取过来还是原来的大小? [ 87%]

...已经被锁定, 无法添加新回复 发起人 jerreychen 相关问题 sprite旋转以后,但是原来碰撞检测rect没有旋转 matter中layasprite怎么改变图片大小? Texture图片能否进行翻转? 如何设置Sprite的宽高和点击区域? 使用钢体设置防穿后仍有几...

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

54. DOM元素-表单输入 [ 87%]

...e = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#fff"; this.form = new Laya.Sprite(); this.form.size(250,120); this.form.pos((Laya.stage.width - this.form.width) / 2, (Laya.stage.height - this.form.height) / 2); Laya.stage.addChild(this.form); this.rowHeight = 30; this.rowSpacing = 10; let rowHeightD...

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

55. DOM元素-视频 [ 87%]

...ine", true); // 设置画布上的对齐参照物 let reference = new Laya.Sprite(); Laya.stage.addChild(reference); reference.pos(100, 100); reference.size(600, 400); reference.graphics.drawRect(0, 0, reference.width, reference.height, "#CCCCCC"); // 每次舞台尺寸变更时,都会调用Utils....

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

56. Sprite-旋转缩放 [ 87%]

...TypeScript三种开发语言、LayaAirIDE让项目开发更高效。class Sprite_RoateAndScale { constructor() { const Browser = Laya.Browser, WebGL = Laya.WebGL, Stage = Laya.Stage; // 不支持WebGL时自动切换至Canvas Laya.init(Browser.clientWidth, Browser.clientHeight, WebGL); Laya.stage.ali...

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

57. Sprite-新手引导 [ 87%]

...种开发语言、LayaAirIDE让项目开发更高效。(function() { var Sprite = Laya.Sprite; var Stage = Laya.Stage; var HitArea = Laya.HitArea; var WebGL = Laya.WebGL; var red; var guideContainer; var tipContainer; var guideSteps = [ { x: 151, y: 575, radius: 150, tip: "../../res/guide/help6.png"...

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

58. 计时器-延迟执行 [ 87%]

...n(Event.CLICK, this, this.onDecreaseAlpha2); } createButton(label) { const Sprite = Laya.Sprite; let w = 300, h = 60; let button = new Sprite(); Laya.stage.addChild(button); button.graphics.drawRect(0, 0, w, h, "#FF7F50"); button.size(w, h); button.graphics.fillText(label, w / 2, 17, "20px simHei", ...

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

59. Sprite-新手引导 [ 87%]

...er, maskArea, interactionArea, hitArea, tipContainer, guideStep = 0; class Sprite_Guide { constructor() { const WebGL = Laya.WebGL, Stage = Laya.Stage; // 不支持WebGL时自动切换至Canvas Laya.init(1285, 727, WebGL); Laya.stage.alignV = Stage.ALIGN_MIDDLE; Laya.stage.alignH = Stage.ALIGN_CENTE...

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

60. 这种进度条怎么实现? [ 86%]

...18-08-17 0 0 分享 微博 QZONE 微信 Barry Allen 赞同来自:  import Sprite = Laya.Sprite export default class Test extends Sprite{ public DEF_SIZE: number = 200 public CIRCLE_WIDTH: number = 20 public $circleSprite: Sprite = new Sprite() public startY: number = -90 constructor() { super() thi...

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