Jump to content

Create Geometry at Runtime (In Lua)

Recommended Posts

Is it possible to create geometry in a script at runtime?

I'm looking to convert a voxel engine (Minecraft terrain) I made in Unity3d to Leadwerks,

but I don't know what can and can't be done in Lua.

I need to be able to create a mesh using polygons (not just creating cubes).

Can this be done? and if so, how?

Share this post

Link to post

I'm getting a script error with the surface:UpdateAABB(). I've also tried surface:Update() and surface:Update(true) but I get the error: "attempt to call method 'Update' (a nil value)'. and It doesn't update the colour of the model. Any ideas?

Share this post

Link to post

You are right. The command is not exposed to Lua. Let me fix that tomorrow...if you switch to the beta branch on Steam you can get the update right away.

Share this post

Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...