大约有 51 项符合查询结果, 库内数据总量为 30,786 项。 (搜索耗时: 0.0023 秒)
...r; import laya.webgl.WebGL; public class UI_Button { private const COLUMNS:int = 2; private const BUTTON_WIDTH:int = 147; private const BUTTON_HEIGHT:int = 165 / 3; private const HORIZONTAL_SPACING:int = 200; private const VERTICAL_SPACING:int = 100; private var xOffset:int; private var yOffset:int;...
来源: Laya2.0_示例 发布时间: 20241124
...port laya.webgl.WebGL; public class UI_CheckBox { private const COL_AMOUNT:int = 2; private const ROW_AMOUNT:int = 3; private const HORIZONTAL_SPACING:int = 200; private const VERTICAL_SPACING:int = 100; private const X_OFFSET:int = 100; private const Y_OFFSET:int = 50; private var skins:Array; publ...
来源: Laya2.0_示例 发布时间: 20241124
....webgl.WebGL; public class PerformanceTest_Cartoon { private var colAmount:int = 100; private var extraSpace:int = 50; private var moveSpeed:int = 2; private var rotateSpeed:int = 2; private var characterGroup:Array; public function PerformanceTest_Cartoon() { // 不支持WebGL时自动切换至Canv...
来源: Laya2.0_示例 发布时间: 20241124
...游戏开始时有一个食物 this.produceFood(); } initSnake() { const Point = Laya.Point; for (let i = 0; i 0) { let prevSeg = segments[segments.length - 1]; seg.rotation = prevSeg.rotation; let point = seg.getPinPosition(); seg.x = prevSeg.x - point.x; seg.y = prevSeg.y - point.y; } segments.pus...
来源: Laya2.0_示例 发布时间: 20241124
...er; import laya.webgl.WebGL; public class UI_Input { private const SPACING:int = 100; private const INPUT_WIDTH:int = 300; private const INPUT_HEIGHT:int = 50; private const Y_OFFSET:int = 50; private var skins:Array; public function UI_Input() { // 不支持WebGL时自动切换至Canvas Laya.init(8...
来源: Laya2.0_示例 发布时间: 20241124
...mport laya.webgl.WebGL; public class UI_RadioGroup { private const SPACING:int = 150; private const X_OFFSET:int = 200; private const Y_OFFSET:int = 200; private var skins:Array; public function UI_RadioGroup() { // 不支持WebGL时自动切换至Canvas Laya.init(800, 600, WebGL); Laya.stage.alignV...
来源: Laya2.0_示例 发布时间: 20241124
...gth / 2; let buttonPosition, beginPosition, endPosition; let button; class Interaction_Swipe { constructor() { const Browser = Laya.Browser, WebGL = Laya.WebGL, Stage = Laya.Stage, Stat = Laya.Stat, Handler = Laya.Handler; // 不支持WebGL时自动切换至Canvas Laya.init(Browser.clientWidth, Brow...
来源: Laya2.0_示例 发布时间: 20241124
...// 设置数据项为对应图片的路径 var data:Array = []; for (var i:int = 0; i < 10; ++i) { data.push("../../res/ui/listskins/1.jpg"); data.push("../../res/ui/listskins/2.jpg"); data.push("../../res/ui/listskins/3.jpg"); data.push("../../res/ui/listskins/4.jpg"); data.push("../../res/ui/lists...
来源: Laya2.0_示例 发布时间: 20241124
...; for (var i: number = 0, len: number = demoString.length; i > 1; var endY:int = Laya.stage.height / 2 - 50; var demoString:String = "LayaBox"; for (var i:int = 0, len:int = demoString.length; i < len; ++i) { var letterText:Text = createLetter(demoString.charAt(i)); letterText.x = w / len * i + offs...
来源: Laya2.0_示例 发布时间: 20241124
...port laya.webgl.WebGL; public class UI_Dialog { private const DIALOG_WIDTH:int = 220; private const DIALOG_HEIGHT:int = 275; private const CLOSE_BTN_WIDTH:int = 43; private const CLOSE_BTN_PADDING:int = 5; private var assets:Array; public function UI_Dialog() { // 不支持WebGL时自动切换至Can...
来源: Laya2.0_示例 发布时间: 20241124