大约有 2,121 项符合查询结果, 库内数据总量为 31,560 项。 (搜索耗时: 0.0061 秒)
分享一个自己做的游戏公告功能,跑马灯效果 import View = Laya.View import Image = Laya.Image import HTMLDivElement = Laya.HTMLDivElement import Sprite = Laya.Sprite import Box = Laya.Box /** 公告栏 */ export default class Notice extends View { /** 滚动区域 */ hornBox: Box /...
来源: Laya_社区 发布时间: 20180314
...啊 请问2.0的版本开始,我用ts编写的相关内容,都要使用import和export吗? 预设怎么在代码中使用 微信小程序—未找到入口 app.json 文件,或者文件读取失败,请检查后重新编译。 layaAir TS项目如何引用protoBuf库? ide 2.4 layaair2-cmd ...
来源: Laya_社区 发布时间: 20200817
... 不会自动引入 npm install --save @types/autobahn 你需要手动 import 很难受的时 连提示也不会有 但是如果你引用了 就会有提示 具体为什么会这样 我不太清楚,也许是官方在index.html 中使用js库 不希望你在代码中如下情况 import { Con...
来源: Laya_社区 发布时间: 20180805
Laya.timer.loop() 报错 Cannot read property 'loop' of null import { Image } from "laya/ui/Image"; // import { List } from "laya/ui/List"; import { Laya } from "laya"; export default class test_move extends Image{ // /** @prop {name:move_img, tips:"用来移动的箭头", type:Image} */ // public ...
来源: Laya_社区 发布时间: 20200203
...R: this.timeLine.resume(); break; } } } new Tween_TimeLine();module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; import Event = Laya.Event; import Keyboard = Laya.Keyboard; import TimeLine = Laya.TimeLine; import WebGL = Laya.WebGL; export class Tween_TimeLine { private target:Spri...
来源: Laya2.0_示例 发布时间: 20251130
...自己需要的图片。 **示例代码:** ```javascript module laya { import Stage = Laya.Stage; import Image = Laya.Image; import WebGL = Laya.WebGL; export class UI_Image { constructor() { // 不支持WebGL时自动切换至Canvas Laya.init(550, 400, WebGL); Laya.stage.alignV = Stage.ALIGN_MIDD...
来源: Laya2.0_文档 发布时间: 20210714
...urces版本, 可以拿去用, 会不会引起其他副作用, 还不确定 import Resource = Laya.Resource; import RenderTexture = Laya.RenderTexture; export default function destroyUnusedResourcesHack() { // @ts-ignore let idResourcesMap = Resource._idResourcesMap; for (let k in idResourcesMap) { l...
来源: Laya_社区 发布时间: 20190621
..._MOVE, this, this.onMouseMove); } } new Interaction_Rotate();module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; import Event = Laya.Event; import Browser = Laya.Browser; import WebGL = Laya.WebGL; export class Interaction_Rotate { private sp: Sprite; private preRadian: number = 0;...
来源: Laya2.0_示例 发布时间: 20251130
...{ this.label.text = value; } } new Tween_EaseFunctionsDemo();module laya { import Input = Laya.Input; import Sprite = Laya.Sprite; import Stage = Laya.Stage; import Text = Laya.Text; import Event = Laya.Event; import List = Laya.List; import Browser = Laya.Browser; import Ease = Laya.Ease; import Ha...
来源: Laya2.0_示例 发布时间: 20251130
...s, there is also encodeDelimited and decodeDelimited. } })();module laya { import Loader = Laya.Loader; import Browser = Laya.Browser; import Handler = Laya.Handler; export class Network_ProtocolBuffer { private ProtoBuf:any = Browser.window.protobuf; constructor() { Laya.init(550, 400); this.ProtoB...
来源: Laya_示例 发布时间: 20251130