大约有 738 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0056 秒)
...lignH = Stage.ALIGN_CENTER; Laya.stage.alignV = Stage.ALIGN_MIDDLE; var sp:Sprite=new Sprite(); sp.graphics.drawRect(0,0,200,200,"#EEFF00"); var label:Label=new Label(); label.fontSize=60; label.text="666"; label.bold=true; label.color="#000000"; sp.addChild(label); sp.size(200,200); Laya.stage.addC...
来源: Laya_社区 发布时间: 20180403
...thographic = true; camera.orthographicVerticalSize = 5; this.effRes = Laya.Sprite3D.load(resUrl); this.effRes.on(Laya.Event.HIERARCHY_LOADED, this, function(){ this.eff1 = scene.addChild( Laya.Sprite3D.instantiate(this.effRes)); this.eff1.transform.position = new Laya.Vector3(0,0,50); this.eff1.tran...
来源: Laya_社区 发布时间: 20180503
...一个 private glow: Laya.GlowFilter = new Laya.GlowFilter; 然后给10个sprite用,当点击一个sprite时,在onclick事件中加上glow效果。但是运行就报错,都还没有点。 换个写发,给每个sprite设置滤镜时new 一个glow就可以。 debug 看到方法里面new出来...
来源: Laya_社区 发布时间: 20170403
...; rankTexture.bitmap.alwaysChange = true;//小程序使用,非常费 let sprite = new Laya.Sprite(); sprite.graphics.drawTexture(rankTexture, 0, 0, rankTexture.width, rankTexture.height); this._content.addChild(sprite); sprite.pos(40, 190);报:this.bitmap activeResource is not a function 2019-09...
来源: Laya_社区 发布时间: 20190920
...pi,报错如一楼图。添加绘图api代码如下 module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; import WebGL = Laya.WebGL; export class Sprite_DrawShapes { private sp: Sprite; constructor() { // 不支持WebGL时自动切换至Canvas Laya.MiniAdpter.init(); Laya.init(740,...
来源: Laya_社区 发布时间: 20180115
... = stateMap[e.type]); } public static function addDark(target:laya.display.Sprite, isDark:Boolean = true):void { if (isDark) { // laya.ui.UIUtils.addFilter(target, DARK); target.filters=[ new ColorFilter([0.7, 0, 0, 0, 0, 0, 0.7, 0, 0, 0, 0, 0, 0.7, 0, 0, 0, 0, 0, 1, 0])]; } else { // laya.ui.UIUtil...
来源: Laya_社区 发布时间: 20160802
用ide打包后的图片,Texture显示不出来? Sprite和Image可以显示出来,Texture报错、、、说找不到图片 代码 : Laya.loader.load([{url: "comp.json", type: Loader.ATLAS}], Handler.create(this, onLoaded)); function onLoaded(){ var aa = new Sprite(); Laya.sta...
来源: Laya_社区 发布时间: 20171226
...办法降DrawCall package { import laya.display.Node; import laya.display.Sprite; import laya.maths.Rectangle; import laya.ui.Dialog; import laya.ui.Image; import laya.utils.Handler; import ui.TestDialogUI; import ui.TestViewUI; public class TestView extends TestViewUI { private var PATH_LEN:Number ...
来源: Laya_社区 发布时间: 20171129
...ound'; window[className] = (function() { Laya.class(Class, className, Laya.Sprite); function Class() { Class.super(this); // this定义.. this.init(); } Class.prototype.init = function() { console.log(this); }; return Class; })(); } var __extends = (this && this.__extends) || function(d, b) ...
来源: Laya_社区 发布时间: 20170619
...eControlScript extends Laya.Script{ /*角色模型*/ public roleModel:Laya.Sprite3D; /*角色动画组件*/ public roleAni:Laya.Animator; /*角色当前动作*/ public currentAction:string = "stand"; /*角色动画是否完成*/ public aniComplete:Boolean = true; /*角色移动速度*/ public speed:...
来源: Laya_社区 发布时间: 20171113