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

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

1041. sprite.mask的疑问 [ 50%]

...         Laya.timer.once(1000, this, this.a)     }      private a ()     {         let a:Sprite = Laya.stage.getChildAt(0).getChildAt(0).getChildByName("A") as Sprite;         let b:Sprite = Laya.stage.getChildAt(0).getChildAt(0).getChildByName("B") ...

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

1042. 发布app(android)后,按后退键显示有问题 [ 50%]

...页面调用的数据。正常的应用是不需要调用此方法的。 private void Hook() { if(!isExit) { isExit = true; Toast.makeText(this, "在按一次退出程序", Toast.LENGTH_SHORT).show(); new Timer().schedule(new TimerTask() { @Override public void run() { // TODO Auto-generated method ...

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

1043. ts项目加载version.json失败 [ 50%]

...rsion.enable("version.json", Laya.Handler.create(this, this.beginLoad)); } private beginLoad(): void { console.debug("aaaaaaaaaaaaaaaaa"); var img = new Laya.Sprite(); img.loadImage("res/test.jpg"); Laya.stage.addChild(img); } } new GameMain(); 调试的时候可以显示出来 res/test.jpg,但是...

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

1044. 我竟然被射线检测这个小功能给难了一天了 [ 50%]

...oid {     Laya.stage.on(Laya.Event.MOUSE_DOWN,this,this.onMouseDownCb) } private onMouseDownCb(e:Laya.Event):void{ console.log("点击屏幕") // console.log("相机位置",this.camera.) this.camera.viewportPointToRay(new Laya.Vector2(Laya.stage.mouseX,Laya.stage.mouseY),this.ray) if(this.physics....

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

1045. scaleMode设为full时怎么pc浏览器跟平板上效果不一样? [ 50%]

...loader.load("assets/bg.jpg", Handler.create(this, loadCompleteHandler)); } private function loadCompleteHandler():void { var bg:Image = new Image("assets/bg.jpg"); Laya.stage.addChild(bg); }这张图在三星平板上可以完整显示出来,为什么在电脑上显示不完整呢。图分辨率...

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

1046. LayaNative端使用.ttf字体 [ 50%]

....loader.load("hu.ttf",Handler.create(this,onLoaded),null,Loader.BUFFER); } private function onLoaded():void { var arr:ArrayBuffer=Laya.loader.getRes("hu.ttf"); if(Browser.window.conch) { Browser.window.conch.setFontFaceFromBuffer("hu",arr); } var text:Text=new Text(); text.font="hu"; text.fontSize=5...

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

1047. 本地双击html如何打开laya项目? [ 50%]

...ublic class HttpServer implements Runnable { static HttpServer httpServer; private static final String TAG = "HttpServer"; /** * 服务器端的socket */ ServerSocket server; /** * 服务器监听的端口号 */ public static final int PORT = 8080; // public static HttpServer getInstance(){ // if(ht...

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

1048. AS3与JS混合编码(ActionScript-2D进阶篇(AS3)-扩展模块) [ 50%]

...下: ```java package { import laya.utils.Browser; public class JSDemo { private var name:String = "Game"; public function JSDemo() { //初始化引擎 Laya.init(0, 0); //定义一个命名空间的属性为app; Browser.window.app = this; } public static function getGameName():String { return "my...

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

1049. Camera.viewportToRay中origin与direction相等问题 [ 50%]

...46 我好像猜到是什么问题了,是不是因为我干了这件蠢事: private _ray: Laya.Ray = new Laya.Ray(Laya.Vector3.ZERO, Laya.Vector3.ZERO); 顺带还改了Laya.Vector3.ZERO的值?

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

1050. iPhone6 ios 8.3系统 最新的QQ 锁屏再解锁 游戏闪退 [ 50%]

...ILITY_CHANGE); });     public static var isStopLoop:Boolean = false; /**@private */ public function _loop():Boolean { if(!isStopLoop) { render(Render.context, 0, 0); } return true; }   2017-10-11 0 1 分享 微博 QZONE 微信 为什么被折叠? 0 个回复被折叠 要回复问题请先登录 ...

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