大约有 49 项符合查询结果, 库内数据总量为 30,903 项。 (搜索耗时: 0.0039 秒)
...rawLine(fromX: number, fromY: number, toX: number, toY: number, lineColor: string, lineWidth: number = 1): DrawLineCmd { return this.addCmd(DrawLineCmd.create(fromX, fromY, toX, toY, lineColor, lineWidth)); } 代码示例: let sp = new Laya.Sprite(); //画直线 sp.graphics.drawLine(10, 58, 146, 5...
来源: Laya3.0_文档 发布时间: 20240910
...aya.stage.graphics.drawRect( 0, 0, phoenixWidth, phoenixHeight, getHexColorString()); } function getHexColorString() { bgColorChannels.r = Math.floor(bgColorChannels.r); // 绿色通道使用0 bgColorChannels.g = 0; //obj.g = Math.floor(obj.g); bgColorChannels.b = Math.floor(bgColorChannels.b); var ...
来源: Laya_示例 发布时间: 20250223
...tage.graphics.drawRect( 0, 0, phoenixWidth, phoenixHeight, this.getHexColorString()); } getHexColorString() { bgColorChannels.r = Math.floor(bgColorChannels.r); // 绿色通道使用0 bgColorChannels.g = 0; //obj.g = Math.floor(obj.g); bgColorChannels.b = Math.floor(bgColorChannels.b); var r = bgCol...
来源: Laya2.0_示例 发布时间: 20250223
....chatBox.innerHTML = ""; gRoomView.chatBox.height = 1; } public SysSay(txt:string):void { this.AddChat(0, "法官", txt); } public PlayerSay(msg:any):void { this.AddChat(msg['from_client_seatsno'], msg['from_client_name'], msg['content']); } private AddChat(seat:number, name:string, txt:string) { le...
来源: Laya_社区 发布时间: 20170911
....chatBox.innerHTML = ""; gRoomView.chatBox.height = 1; } public SysSay(txt:string):void { this.AddChat(0, "法官", txt); } public PlayerSay(msg:any):void { this.AddChat(msg['from_client_seatsno'], msg['from_client_name'], msg['content']); } private AddChat(seat:number, name:string, txt:string) { le...
来源: Laya_社区 发布时间: 20170911
...NE 微信 风信子 赞同来自: private createAnimation(images: Array<string>): Laya.Animation { this.animation = new Laya.Animation(); this.ui.addChild(this.animation); this.animation.loadImages(images); this.animation.interval = 70; this.animation.play(0); return this.animation } 我不...
来源: Laya_社区 发布时间: 20190325
...声音进行控制,以及获取声音信息。 */ static playSound(url: string, loops?: number, soundClass?: any, startTime?: number) { return new Promise((resolve, reject) => { let soundChannel: Laya.SoundChannel = Laya.SoundManager.playSound(url, loops, Laya.Handler.create(this, () => { re...
来源: Laya_社区 发布时间: 20180124
...ebGL; import Stat = Laya.Stat; export class Animation_SWF{ private SWFPath:string = "h5/res/Map11.swf"; private MCWidth:number = 760; private MCHeight:number = 650; constructor(){ // 不支持WebGL时自动切换至Canvas Laya.init(760,650, WebGL); Laya.stage.frameRate = Stage.FRAME_SLOW; ...
来源: Laya_社区 发布时间: 20171103
...esh: Mesh, texture: Texture2D, minHeight: number, maxHeight: number, name: string = null): MeshTerrainSprite3D { var meshTerrainSprite3D: MeshTerrainSprite3D = new MeshTerrainSprite3D(mesh, null, name); meshTerrainSprite3D._initCreateFromMeshHeightMap(texture, minHeight, maxHeight); return meshTerra...
来源: Laya3.0_文档 发布时间: 20230303
... // 程序入口 class GameMain { private btn: Laya.Button; private skin: string = 'images/button.png'; constructor() { Laya.init(200, 300); Laya.loader.load(this.skin, Laya.Handler.create(this, () => { this.btn = this.createBtn(this.skin); this.btn.on(Laya.Event.CLICK, this, this.onClick); })); ...
来源: Laya_社区 发布时间: 20170511