Comments (5)
Scene3D是继承自Node的,所以,Scene3D和其他的场景中的节点(比如Sprite3D)没有什么区别,都是一个Node.其次你可以看一下SceneLoad1这个示例,加载的是一个场景文件.ls。在完成加载执行的函数。
sceneLoadFinished(scene){
Laya.stage.addChild(scene);
let camera = scene.getChildByName("Camera");
camera.addComponent(CameraMoveScript);
}
很显然Scene3D是作为Stage的子节点加载到Stage中的。
from layaair-demo.
我是初始化的typescript3D项目,然后照着SceneLoad1写,但会提示property 'Scene3D' does not exist on type typeof 'Laya',是否需要添加其他运行库
from layaair-demo.
我像这么写是可以的——
var scene = Laya.Scene.load("LayaScene_Laya3D01/Laya3D01.ls");
Laya.stage.addChild(scene);
但如果这么写——
Laya.Scene3D.load("LayaScene_Laya3D01/Laya3D01.ls", Laya.Handler.create(null, function (scene) {
Laya.stage.addChild(scene);
}));
就提示没有Scene3D这个属性
from layaair-demo.
首先Laya.Scene.load是加载2D场景的,Laya.Scene3D.load是加载3D场景的。其次你可以看一下我的截图 ,没有显示你所描述的问题。
你可能是用的老版本的IDE我用的是最新的 ,所以 咱们之间可能存在差异,你可以下载一个最新的ide玩玩。
from layaair-demo.
你动画设置怎么设置的、我的导出来后获取不到weapon挂点,你的角色源文件有么
from layaair-demo.
Related Issues (4)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from layaair-demo.