• 首页
  • 动态
  • 案例
  • 引擎社区
  • API
  • 文档
  • 示例
  • 引擎下载

大约有 278 项符合查询结果, 库内数据总量为 30,897 项。 (搜索耗时: 0.0042 秒)

241. 鼠标交互-拖动 [ 51%]

....Browser; import Handler = Laya.Handler; import WebGL = Laya.WebGL; export class Interaction_Drag { private ApePath: string = "../../res/apes/monkey2.png"; private ape: Sprite; private dragRegion: Rectangle; constructor() { // 不支持WebGL时自动切换至Canvas Laya.init(Browser.clientWidth, Bro...

来源: Laya_示例 发布时间: 20250219

242. 物体随着鼠标滑动旋转脚本 [ 51%]

...    this.mainCameraAnimation = null;     this.scene = null; } Laya.class(ObjectRotate, "ObjectRotate", Laya.Script);  //这是什么意思有什么作用 ObjectRotate.prototype._initialize = function (owner) {     var _this = this;     ObjectRotate.__super.prototype._initialize.call...

来源: Laya_社区 发布时间: 20170810

243. 【官网代码】加载dom音频报错,怎么回事? [ 50%]

....net.HttpRequest;import laya.net.Loader;import laya.utils.Browser; public class Main{private var AudioContext:Object;private var audioContext:Object;private var analyser:Object;private var audioBufferSourceNode:Object;public function Main(){Laya.init(500,500);AudioContext =Browser.window.AudioConte...

来源: Laya_社区 发布时间: 20181023

244. runTime使用(ActionScript-IDE篇(AS3)-组件化开发相关) [ 50%]

...laya.utils.Tween; /** *ImageRunTime逻辑类 * @author mengjia * */ public class ImageRunTime extends Image { //缩放时间100毫秒 public var scaleTime:int = 100; public function ImageRunTime() { //设置组件的中心点 this.anchorX = this.anchorY = 0.5; //添加鼠标按下事件侦听。按...

来源: Laya2.0_文档 发布时间: 20210714

245. 3D变换 · LayaAir3.3 · 引擎文档 · LAYABOX [ 50%]

...x、y和z方向上分别移动距离1,示例代码如下: const { regClass, property } = Laya; @regClass() export class NewScript extends Laya.Script { @property({ type: Laya.Sprite3D }) public cube: Laya.Sprite3D; // 平移距离 private translate: Laya.Vector3 = new Laya.Vector3(1, 1, 1); cons...

来源: Laya3.0_文档 发布时间: 20240910

246. 实体组件系统 · LayaAir3.3 · 引擎文档 · LAYABOX [ 49%]

...事件方法三、组件在IDE的暴露方式3.1 组件脚本的识别@regClass()3.2 组件属性的识别@property()3.3 IDE中执行生命周期方法@runInEditor3.4 @classInfo()四、代码中使用属性4.1 节点类型方式4.2 组件类型的使用4.3 Prefab类型属性实体组件系统(ECS...

来源: Laya3.0_文档 发布时间: 20250103

247. 动画-旧版骨骼动画 [ 49%]

....utils.Stat; import common.CameraMoveScript; /** * ... * @author */ public class SkinAnimation_Old { private var zombie:Sprite3D; private var changeActionButton:Button; private var curStateIndex:int = 0; private var skinAniUrl:Array = [ "../../../../res/threeDimen/skinModel/Zombie/old/Assets/Zombie/...

来源: Laya_示例 发布时间: 20250219

248. 区块地图-滚动地图 [ 48%]

...= Laya.Handler; import Stat = Laya.Stat; import WebGL = Laya.WebGL; export class TiledMap_SimpleDemo { private tiledMap: TiledMap; private mLastMouseX: number = 0; private mLastMouseY: number = 0; private mX: number = 0; private mY: number = 0; constructor() { // 不支持WebGL时自动切换至Canv...

来源: Laya_示例 发布时间: 20250219

249. List翻页效果 [ 48%]

..."../data/ConfigInfo"; import { ui } from "../ui/layaMaxUI"; export default class RuleDialog extends ui.scene.RuleDialogUI { private m_index: number = -1; private m_downValue: number = -1; constructor() { super(); this.list_rule.hScrollBarSkin = ""; this.list_rule.renderHandler = new Laya.Handler(thi...

来源: Laya_社区 发布时间: 20171202

250. List翻页效果怎么实现 [ 48%]

..."../data/ConfigInfo"; import { ui } from "../ui/layaMaxUI"; export default class RuleDialog extends ui.scene.RuleDialogUI { private m_index: number = -1; private m_downValue: number = -1; constructor() { super(); this.list_rule.hScrollBarSkin = ""; this.list_rule.renderHandler = new Laya.Handler(thi...

来源: Laya_社区 发布时间: 20181112