Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CreateDefaultSubobject,这种组件创建在lua里怎么做呢? #36

Closed
ZuoEr opened this issue Nov 16, 2018 · 2 comments
Closed

CreateDefaultSubobject,这种组件创建在lua里怎么做呢? #36

ZuoEr opened this issue Nov 16, 2018 · 2 comments

Comments

@ZuoEr
Copy link

ZuoEr commented Nov 16, 2018

No description provided.

@pangweiwei
Copy link
Collaborator

不支持泛型方法,作为变通,你可以自己到处一个函数接受const char* type作为输入,然后
if(type=="USceneComponent")
return CreateDefaultSubobject( TEXT( "SceneComponent" ) );
else if(type==...)
类似这样的写法。

@ZuoEr
Copy link
Author

ZuoEr commented Nov 19, 2018

那就是目前如果要在lua里面创建Component的话必须要在C++里面先写一个方法,然后lua去调用吗?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants