大约有 32 项符合查询结果, 库内数据总量为 30,778 项。 (搜索耗时: 0.0024 秒)
...BG.jpg"); Laya.stage.frameLoop(1, this, this.animate); } animate() { const Sprite = Laya.Sprite, Point = Laya.Point; let laser; if (tick > frequency) { tick = 0; // iterate through the dudes and update the positions laser = new Sprite(); laser.loadImage("res/pixi/laser0" + ((type % 5) + 1) + ".png")...
来源: Laya2.0_示例 发布时间: 20241117
...TypeScript三种开发语言、LayaAirIDE让项目开发更高效。class Sprite_Container { constructor() { const Browser = Laya.Browser, WebGL = Laya.WebGL, Stage = Laya.Stage; // 不支持WebGL时自动切换至Canvas Laya.init(Browser.clientWidth, Browser.clientHeight, WebGL); Laya.stage.alignV ...
来源: Laya2.0_示例 发布时间: 20241117
...TypeScript三种开发语言、LayaAirIDE让项目开发更高效。class Sprite_NodeControl { constructor() { const Browser = Laya.Browser, WebGL = Laya.WebGL, Stage = Laya.Stage; // 不支持WebGL时自动切换至Canvas Laya.init(Browser.clientWidth, Browser.clientHeight, WebGL); Laya.stage.align...
来源: Laya2.0_示例 发布时间: 20241117
...ctionList(); this.createDurationCrontroller(); } createCharacter() { const Sprite = Laya.Sprite; character = new Sprite(); Laya.stage.addChild(character); character.loadImage("res/cartoonCharacters/1.png"); character.pos(100, 50); } createEaseFunctionList() { const List = Laya.List, Handler = Laya.H...
来源: Laya2.0_示例 发布时间: 20241117
...TypeScript三种开发语言、LayaAirIDE让项目开发更高效。class Sprite_Pivot { constructor() { const Browser = Laya.Browser, WebGL = Laya.WebGL, Stage = Laya.Stage; // 不支持WebGL时自动切换至Canvas Laya.init(Browser.clientWidth, Browser.clientHeight, WebGL); Laya.stage.alignV = St...
来源: Laya2.0_示例 发布时间: 20241117
...Laya.stage.bgColor = "#232628"; Stat.show(); this.init(); } init() { const Sprite = Laya.Sprite, Animation = Laya.Animation, Text = Laya.Text, Event = Laya.Event; // 创建背景 this.spBg = Sprite.fromImage(PathBg); Laya.stage.addChild(this.spBg); // 创建动画 this.aniFly = new Animation(); this...
来源: Laya2.0_示例 发布时间: 20241117
...stage.on(Event.MOUSE_DOWN, this, this.onDown); } createCoralRect() { const Sprite = Laya.Sprite, Event = Laya.Event; let coralRect = new Sprite(); coralRect.graphics.drawRect(0, 0, Laya.stage.width, Laya.stage.height / 2, "#FF7F50"); //设置名称 coralRect.name = "珊瑚色容器"; coralRect.size(...
来源: Laya2.0_示例 发布时间: 20241117
...s.Construct(); this.eventListener(); } Construct() { let ground = new Laya.Sprite(); Laya.Laya.stage.addChild(ground); let rigidbody = new Laya.RigidBody(); rigidbody.type = "static"; ground.addComponentIntance(rigidbody); let chainCollider = ground.addComponent(Laya.ChainCollider); chainCollider.po...
来源: Laya2.0_示例 发布时间: 20241117
...e = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#fff"; this.form = new Laya.Sprite(); this.form.size(250,120); this.form.pos((Laya.stage.width - this.form.width) / 2, (Laya.stage.height - this.form.height) / 2); Laya.stage.addChild(this.form); this.rowHeight = 30; this.rowSpacing = 10; let rowHeightD...
来源: Laya2.0_示例 发布时间: 20241117
...nge); } // 方位指示器指向当前所朝方位 createCompass() { const Sprite = Laya.Sprite; compassImg = new Sprite(); Laya.stage.addChild(compassImg); compassImg.loadImage(compassImgPath); compassImg.pivot(compassImg.width / 2, compassImg.height / 2); compassImg.pos(Laya.stage.width / 2, 400);...
来源: Laya2.0_示例 发布时间: 20241117