大约有 771 项符合查询结果, 库内数据总量为 31,722 项。 (搜索耗时: 0.0082 秒)
matter中layasprite怎么改变图片大小? var roleOptions: any = {mass:1, restitution:0.8, layaSprite: sprite}; var role: any = Matter.Bodies.rectangle(180, 450, 334, 522, roleOptions); 代码类似这样的:sprite是我传入的图片,要怎么改变这张图片的大小? 2018-08-...
来源: Laya_社区 发布时间: 20180827
...{ constructor() { //初始化引擎 Laya.init(1136,640); var sp = new Laya.Sprite(); var xhr = new Laya.HttpRequest(); xhr.once(Laya.Event.COMPLETE,this,this.completeHandler); xhr.once(Laya.Event.ERROR,this,this.errorHandler); xhr.send("res/a.png","","get","arraybuffer"); } private completeHandler(d...
来源: Laya2.0_文档 发布时间: 20210714
...oLoaded),null,true,true); } function showProgress() { progressBar=new Laya.Sprite(); progressBar.loadImage("comp/BG1.jpg",50,300); progressBar.width=300; progressBar.sizeGrid="5,5,5,5"; progressBar.changeHandler=new Handler(this,onChange); //当progressBar的value值改变时触发 Laya.stage.addChi...
来源: Laya_社区 发布时间: 20170701
...同来自: 亲,我想问问你最后怎么解决的,我是在同一个sprite多次截图,发现截出来的图会有叠加情况 2018-01-25 0 0 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 要回复问题请先登录 发起人 leoganliang 相关问题 发起问题须知...
来源: Laya_社区 发布时间: 20170407
为什么hitTestPoint始终是false? class TestUI extends Laya.Sprite { private s:Laya.Sprite = new Laya.Sprite(); constructor() { super(); var img:Laya.Image = new Laya.Image("comp/bg.png"); this.s.addChild(img); this.addChild(this.s); Laya.stage.on(Laya.Event.CLICK, this, this.hitPoint); } priv...
来源: Laya_社区 发布时间: 20170319
sprite加载图片,如果设置其高固定,宽等比? $pic.loadImage(_pic, 14, 192, 0, 0, Handler.create(this, function(){ $pic.height = 246; $pic.scaleX = $pic.scaleY; trace("$pic.width:" + $pic.width); })); 这样处理后,图片高度还是100%,并不是246啊 2017-0...
来源: Laya_社区 发布时间: 20170503
...这个问题要怎么改啊? appPic.as package { import laya.display.Sprite; import laya.resource.Texture; import laya.ui.Image; import laya.utils.Handler; public class addPic { private var picUrl:String; private var pic:Sprite; private var picX:int; private var picY:int; public function addPic...
来源: Laya_社区 发布时间: 20170522
... export class NewScript extends Laya.Script { //declare owner : Laya.Sprite3D; @property(String) public text: string = ""; @property(Laya.Image) public image: Laya.Image = null; constructor() { super(); } } 附件 : --> 2023-04-12 添加评...
来源: Laya_社区 发布时间: 20230412
...: boolean = false Inherited from Text._ownGraphics Defined in laya/display/Sprite.ts:252 _scene _scene: Node Inherited from Node._scene Defined in laya/display/Node.ts:641 _scene3D _scene3D: any Inherited from Scene._scene3D Defined in laya/display/Scene.ts:28 _skinBaseUrl _skinBaseUrl: string Inher...
来源: Laya3.0_api 发布时间: 20231115
...ght:"+height); var tex = new BK.Texture(buff,width,height); var sp =new BK.Sprite(200,200,tex,0,1,1,1); BK.Director.root.addChild(sp); }else if(openID == openID2){ ... } } BK.MQQ.Account.getHead(openID1, callback); BK.MQQ.Account.getHead(openID2, callback); ========================================...
来源: Laya_社区 发布时间: 20180417