Skip to content

How to spawn meshes in lua #227

@aurreland

Description

@aurreland

So i'm trying to spawn levels using lua script, but i can't seem to find a way to spawn meshes (i'm trying to spawn simple shapes like Sphere for an aim trainer), so im also wondering how to add a material.
How i am supposed to spawn them, should i use some function in world: or should i make an APIProvider ?
Could you please give me an example of how this should work.
I tried getting Assets<Mesh> ressource, putting a Sphere in a Mesh3d component, and i also tried making an APIProvider but i didn't managed to expose a function to lua.

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions