i am trying to export meshes in game into blender, but i have 3000 meshes to export, i want to export them all as a seperate mesh, how can i achieve this?
if u right click a mesh u can press to export but i can see that it would be daunting for 3000 meshes the best approach would be a plugin as i believe they can trigger exports
1 Like
Maybe …
local AssetService = game:GetService("AssetService")
local assetIds = {123456, 789012, ...}
local exportDirectory = "MeshExports"
for _, assetId in ipairs(assetIds) do
local success, meshId = pcall(function()
return AssetService:CreatePlaceInPlayerInventoryAsync(assetId)
end)
if success then
local success, mesh = pcall(function()
return AssetService:CreatePlaceInSetAsync({meshId})
end)
if success and #mesh > 0 then
local exportPath = exportDirectory .. "/" .. assetId .. ".fbx"
mesh[1]:ExportMesh(exportPath)
mesh[1]:Destroy()
end
end
end
This is from an old post … didn’t test anything.
{123456, 789012, …} “…” means more added.
Prob just as fast to click them one at a time. Over updating this
this is a good idea, but i cant find where the mesh is saved on my computer after i run it in the command bar
Oh, don’t look like I set that. Was to be exportDirectory. You’ll have to set that up.
workspace.MeshExports
Not even sure if this will work. Kind of tossed it together with the ideal from a post I seen here.
(that never did work)