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

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

101. 骨骼动画-藤蔓 [ 97%]

.../spineRes5/vine.sk"; mFactory = new Templet(); mFactory.on(Event.COMPLETE, this, parseComplete); mFactory.on(Event.ERROR, this, onError); mFactory.loadAni(mAniPath); } function onError() { console.log("error"); } function parseComplete() { //创建模式为1,可以启用换装 mArmature = mFactory...

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

102. 高级应用-寻路导航 [ 97%]

...发语言、LayaAirIDE让项目开发更高效。Laya3D.init(0, 0, true); this._position = new Laya.Vector3(0, 0, 0); this._upVector3 = new Laya.Vector3(0, 1, 0); this._tarPosition = new Laya.Vector3(0, 0, 0); this._finalPosition = new Laya.Vector3(0, 0, 0); this._quaternion = new Laya.Quaternion();...

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

103. SVG渐变精灵的扩展脚本继承了多个精灵, 在safari环境下重叠了渲染 [ 97%]

...向, 求大大指点, 感激   附上渐变SVG文字的代码:   /** * this class is a extension of texts with gradient color  */ var effect; (function (effect) {     var GradientText = (function (_super) {         const style = {             DEFAULT: "default",             VERT...

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

104. 富文本过程中我遇到的问题以及解决方法(超链接换行以及无法接收超链接鼠标事件以及br或者 标签会崩溃报错的问题) [ 97%]

...者  标签崩溃问题 解决方法 HTMLElemen类中      var words = this._getWords();             if (words == null && (!this._children || this._children.length == 0))                 return false;             if (words) {                 for (var i = 0, n ...

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

105. 使用IDE制作的动画在pc模拟器播放OK在手机端不显示 [ 97%]

...的动画在pc模拟器播放OK在手机端不显示 loaded : function(){ this.loader = Laya.loader; this.loader.retryNum = 0;//无加载重试 this.urls = ['imgdebris/imgdebris.atlas','imgdebris/p1_slj.png',]; // this.loader.load(this.urls[0], Laya.Handler.create(this, this.onAssetloaded)); this.lo...

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

106. 输入设备-指南针 [ 97%]

...ignV = Stage.ALIGN_MIDDLE; Laya.loader.load(compassImgPath, Handler.create(this, init)); })(); function init() { // 创建罗盘 createCompass(); // 创建方位指示器 createDirectionIndicator(); // 画出其他UI drawUI(); // 创建显示角度的文本 createDegreesText(); Gyroscope.instance.on...

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

107. 分享一下自己的屏幕适配方案 [ 97%]

...ight:number; ImgX:number; ImgY:number; Img:Laya.Image =new Laya.Image(); this.nWidth =this.bg.width; //背景图宽 this.nHeight =this.bg.height;//背景图的高 this.Img.x =0; this.Img.y =0; this.Img.url ="../game/1.png"; Laya.stage.addChild(this.Img); //获取图片初始x y轴坐标 this.ImgX=...

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

108. 骨骼动画-橡胶人 [ 97%]

...es4/stretchyman.sk"; mFactory = new Templet(); mFactory.on(Event.COMPLETE, this, parseComplete); mFactory.on(Event.ERROR, this, onError); mFactory.loadAni(mAniPath); } function onError() { console.log("error"); } function parseComplete() { //创建模式为1,可以启用换装 mArmature = mFactory...

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

109. Sprite-切换纹理 [ 97%]

...aya.stage.scaleMode = Stage.SCALE_SHOWALL; Laya.stage.bgColor = "#232628"; this.flag = true; Laya.loader.load([monkey1Str, monkey2Str], Laya.Handler.create(this, this.onAssetsLoaded)); } onAssetsLoaded() { monkey1Res = Laya.loader.getRes(monkey1Str), monkey2Res = Laya.loader.getRes(monkey2Str); this...

来源: Laya2.0_示例 发布时间: 20241001

110. 性能测试-骨骼 [ 97%]

...e: Loader.IMAGE }, { url: mAniPath, type: Loader.BUFFER }], Handler.create(this, this.onAssetsLoaded)); } onAssetsLoaded() { const Loader = Laya.Loader, Templet = Laya.Templet, Event = Laya.Event; let tTexture = Loader.getRes(mTexturePath); let arraybuffer = Loader.getRes(mAniPath); mFactory = new T...

来源: Laya2.0_示例 发布时间: 20241001