大约有 8 项符合查询结果, 库内数据总量为 30,778 项。 (搜索耗时: 0.0023 秒)
...var textureUrl = (flag = !flag) ? texture1 : texture2; // 更换纹理 ape.graphics.clear(); var texture = Laya.loader.getRes(textureUrl); ape.graphics.drawTexture(texture, 0, 0); // 设置交互区域 ape.size(texture.width, texture.height); } })();module laya { import Sprite = Laya.Sprite; import ...
来源: Laya_示例 发布时间: 20241118
...a.loader.getRes("../../res/apes/monkey2.png"); var ape = new Sprite(); ape.graphics.drawTexture(t, 0, 0); Laya.stage.addChild(ape); ape.pos(200, 0); })); } })();module laya { import Sprite = Laya.Sprite; import Stage = Laya.Stage; import Texture = Laya.Texture; import Browser = Laya.Browser; import ...
来源: Laya_示例 发布时间: 20241118
...1, dragWidthLimit, dragHeightLimit); //画出拖动限制区域 Laya.stage.graphics.drawRect( dragRegion.x, dragRegion.y, dragRegion.width, dragRegion.height, null, "#FFFFFF", 2); } function onStartDrag(e) { //鼠标按下开始拖拽(设置了拖动区域和超界弹回的滑动效果) ape.startDra...
来源: Laya_示例 发布时间: 20241118
...is.aniFly); //创建按钮 this.btn = new Sprite().size(205, 55); this.btn.graphics.drawRect(0, 0, this.btn.width, this.btn.height, "#057AFB"); this.txt = new Text(); this.txt.text = "销毁"; this.txt.pos(75, 15); this.txt.fontSize = 25; this.txt.color = "#FF0000"; this.btn.addChild(this.txt); this...
来源: Laya_示例 发布时间: 20241118
...ore.material.BaseMaterial; import laya.d3.core.scene.Scene; import laya.d3.graphics.VertexElementUsage; import laya.d3.math.Vector3; import laya.d3.resource.Texture2D; import laya.d3.resource.models.CapsuleMesh; import laya.d3.resource.models.Mesh; import laya.d3.resource.models.SphereMesh; import l...
来源: Laya_示例 发布时间: 20241118
....material.TerrainMaterial; import laya.d3.core.scene.Scene; import laya.d3.graphics.VertexElementUsage; import laya.d3.math.Vector2; import laya.d3.math.Vector3; import laya.d3.math.Vector4; import laya.d3.resource.Texture2D; import laya.d3.resource.models.CapsuleMesh; import laya.d3.resource.models...
来源: Laya_示例 发布时间: 20241118
...3.core.render.RenderState; import laya.d3.core.scene.Scene; import laya.d3.graphics.IndexBuffer3D; import laya.d3.graphics.VertexBuffer3D; import laya.d3.math.Quaternion; import laya.d3.math.Vector3; import laya.d3.math.Vector4; import laya.d3.resource.Texture2D; import laya.d3.resource.models.BoxMe...
来源: Laya_示例 发布时间: 20241118
...ort laya.d3.core.Sprite3D; import laya.d3.core.scene.Scene; import laya.d3.graphics.VertexElementUsage; import laya.d3.math.Quaternion; import laya.d3.math.Vector3; import laya.d3.resource.Texture2D; import laya.d3.resource.models.CapsuleMesh; import laya.d3.resource.models.Mesh; import laya.d3.reso...
来源: Laya_示例 发布时间: 20241118