I’m still recieving the same ‘Lacking Capability’ error from the function. Any help?
Exactly, my complement was to render the player’s map (including meshes with their textures or PBR’s) but, Roblox preferred to limit this only to what belongs to the player, when in the same way the player can export it and upload it to their inventory. This change does not make sense and it affects me in more than 4 things that I was creating. I really expected an improvement, and even though it was there, this doesn’t make up for it, I’m disappointed and upset.
Okay, so I understand why this policy is in place. However, I have some legitimate needs for analyzing meshes made by other users. In particular, analyzing potentially malicious UGC items and layered clothing assets on avatars in a competitive game.
I want to analyze layered clothing cages to see if they substantially warp the geometry of the avatar adorning them, so I can ban bad avatars from my shooter game and still allow non-malicious uses of layered clothing to pass.
Can anything be done to meet the needs of this use case?
Similarly with 2D clothing, it is impossible to emulate Roblox’s Humanoid texture compositor in Luau unless we can load shirts and pants. Frankly, if it is loaded into our game, we should be allowed read-only access to avatar assets in games.
I’m not fan about permissions, this model is not edited and is literally made by Roblox (?), but still, says me it’s not mine :
7430070993 is the MeshId of the head.
Some other infos
making a triangle where the Y position of all 3 vertices are the same seems to make the triangle invisible. Not sure if i’m doing something wrong or if this is a bug.
this works fine.
local positions = {
Vector3.new(10, 1, 10),
Vector3.new(0, 2, 10),
Vector3.new(10, 3, 0)
}
but changing the Y position to 0 for all 3 vertices makes the triangle invisible and even makes the SpawnLocation
invisible
local positions = {
Vector3.new(10, 0, 10),
Vector3.new(0, 0, 10),
Vector3.new(10, 0, 0)
}
Adding a
HighLight
in the SpawnLocation
makes it re-appear but the triangle won’t show. You also can’t see it in the wireframe view.
full code
local AssetService = game:GetService("AssetService")
local editableMesh = AssetService:CreateEditableMesh({Size = Vector3.one})
local positions = {
Vector3.new(10, 0, 10),
Vector3.new(0, 0, 10),
Vector3.new(10, 0, 0)
}
for i = 1, 3 do
editableMesh:AddVertex(positions[i])
end
editableMesh:AddTriangle(table.unpack(editableMesh:GetVertices()))
local function computeExtents(em: EditableMesh)
local verts = em:GetVertices()
if #verts == 0 then
return Vector3.zero
end
local inf = math.huge
local min = Vector3.new(inf, inf, inf)
local max = Vector3.new(-inf, -inf, -inf)
for _, id in verts do
local v = em:GetPosition(id)
min = min:Min(v)
max = max:Max(v)
end
return max - min
end
local meshPart = editableMesh:CreateMeshPartAsync(computeExtents(editableMesh))
meshPart.Anchored = true
meshPart.Position = Vector3.new(10, 10, 10)
meshPart.Parent = workspace
TriangleIssue.rbxl (53.3 KB)
So if we have an NPC with roblox’s default animations how are we going to get the ids of it? also that might break a lot of games. But i like that because we wont have to call api every time which causes a lot of loading errors.
Having same issue. I believe this might be due to the frustum culling that is culling the original object’s bounding box rather than the editablemesh’s bounding box.
Just made some small module to make everything easier to understand for myself. So far, I’m loving this update.
Well. I already made previous complaints, but I already gave it the necessary time to try almost everything.
Good Things:
-I like the fact that I don’t have to read a table with distances of 10M (ReadPixels).
-Optimized the use of WritePixels (now writePixelsBuffer).
-They increased the number of things that can be done with tights (for the better).
Bad Things:
-You cannot upload meshes or images that do not belong to you (my color Picker, my map rendering plugin, my tree leaf movement script are no longer useful (mesh uploaded by the official Roblox account)…) .
-I don’t think I have any more bad experiences (for now).
Things that would be good to implement: I don’t know if it is possible, but adding a method like “SetFaceMaterial(FaceId, Enum.Material)” to EditableMesh would be something spectacular.
As always, good work from the Roblox team and, it must be said, that everything I mention is my experience and opinion. Thanks for reading (translated with Google Translator).
Very nice, made some conveyor mesh generator with this. Just wondering, if there stuff in the API for double sided meshes?
Just make the MeshPart doublesided.
I did manage to reduce the big performance impact this update had on me by
- setting CanCollide = false
- setting CanTouch = false
- Anchoring (as before)
- Instead of deleting mesh parts/editable meshes with each mesh change, using the same mesh part, deleting all of the faces, using the delete unused API, and then inserting the new vertices.
A few more thoughts on the API use:
- You can no longer use CollectionService with Objects. This is unfortunate because CollectionService was a great way to do animations for these things. It’s still doable off the mesh part though.
- A clear API really is needed. Best current alternative is delete faces and then delete unused vertices. Deleting the meshpart is too slow.
- The whole set extents thing… needs a rethink. If I’m programmatically making meshes, I want my meshes to be using worldspace units in 99% of the cases. Having to waste time computing extents so that meshParts can set their scale and try to rescale the mesh is just a waste of processing time. And what happens when I change those vertices later anyways?
The current thread cannot write ‘DoubleSided’ (lacking capability Plugin) ? I’m just setting the property double sided of the mesh to true. Is there any other way around this?
Hmm, the old way was to Clone an existing MeshPart that already had the DoubleSided set… But now we have to make the MeshPart with CreateMeshPartAsync.
I think one way that might work is have a MeshPart in your storage with DoubleSided set. Clone it, then use MeshPart:ApplyMesh() to apply a Mesh that you’ve created with CreateMeshPartAsync(). It’s obvious a backwards way of doing things though.
No way, that’s an actual function? (Edit: Thanks)
Hi, may i know if theres a specific reason why vertices dont retain their indice order from the imported file? I’m using .fbx file format and looking to use editable meshes to create blend shapes (which require ordered vertices), however, from testing i have noticed that indices are mixed up (i’ve made sure to triangulate the mesh in blender before exporting too.)
Blendshapes are extremely useful in many cases, for example a more dynamic character editor which can be used to sculpt intricate facial features and have a wider-range of body-types. So i hope there will be/is a way to use these as it is a game-changing feature and opens up many more opportunities to devs.
I was told in a previous post that this should already be possible wasnt given an explanation as to how. Also, are there plans on supporting blend-shapes natively - it seems quite expensive to be calculating vertex positions on meshes with multiple blendshapes layered over & calling this update every frame when working with intensity sliders, etc.
why does mine just return Expected Object, got nil. Note that the Object must not inherit from Instance.
it isnt even empty i think i draw pixels and everything
I dont care about these updates, my game has the whole world and the terrain requires editable meshes, PLEASE can i have some sort of ETA like i need it to release
I’m even surprised there isn’t any support for SpecialMeshes. Hope that we should see support for it soon!