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

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

1. 设置滤镜(JavaScript-LayaAir基础篇(JS)-位图) [ 100%]

...= new Sprite(); apeshadow.loadImage(apePath); ape.pos(100,50); apeGlow.pos(250,50); apeshadow.pos(400,50); Laya.stage.addChild(ape); Laya.stage.addChild(apeGlow); Laya.stage.addChild(apeshadow); } function filterGlow() { //创建一个发光滤镜 var glowFilter = new GlowFilter("#ffff00", 10, 0, 0)...

来源: Laya2.0_文档 发布时间: 20210714

2. 设置滤镜(TypeScript-LayaAir基础篇(TS)-位图) [ 97%]

...); this.ape.pos(100,50); this.apeGlow = this.createApe(); this.apeGlow.pos(250,50); this.apeShadow = this.createApe(); this.apeShadow.pos(400,50); this.GlowFilter(); this.ShadowFilter(); } private createApe(): Sprite { var ape = new Sprite(); ape.loadImage(this.apePath); Laya.stage.addChild(ape); re...

来源: Laya2.0_文档 发布时间: 20210715

3. 位图字体的制作与使用(JavaScript-LayaAir基础篇(JS)-文本) [ 75%]

...(); txt.text = "asdfghjk"; //设置宽度,高度自动匹配 txt.width = 250; //自动换行 txt.wordWrap = true; txt.align = "center"; txt.color = "ff00ff"; //使用我们注册的字体 txt.font = mFontName; txt.fontSize = 50; txt.leading = 5; Laya.stage.addChild(txt); } ``` ### **Text 类中相...

来源: Laya2.0_文档 发布时间: 20201114

4. 位图字体的制作与使用(ActionScript-LayaAir基础篇(AS3)-文本) [ 72%]

...txt.text = "这是测试"; //设置宽度,高度自动匹配 txt.width = 250; //自动换行 txt.wordWrap = true; txt.align = "center"; //使用我们注册的字体 txt.font = this.mFontName; txt.fontSize = 50; txt.leading = 5; Laya.stage.addChild(txt); } } } ``` ### **Text 类中相关接口:*...

来源: Laya2.0_文档 发布时间: 20201114