Quantcast
Channel: Questions in topic: "skinned mesh renderer"
Viewing all articles
Browse latest Browse all 192

Substract mesh from Skinned Mesh Renderer

$
0
0
Hi there Uniteers, I am in need of your help. In the process of optimizing our game performance, we have decided to look into combining all skinned mesh renderers into a single skinned mesh renderer containing all the other Skinned Mesh Renderer. By using the script provided by duhprey and modified by Marble on the Unity Community forum, I managed to combine all our skinned mesh renderers into one: [Forum post about combining skinned mesh renderers][1] But combining all Skinned Mesh Renderers into one arises a problem. When attempting to disable a single "Character" (such as, when an enemy has been slain), it is not possible to disable the renderer, because all the other meshes will also get disabled, because they are all attached to one single Skinned Mesh Renderer. So my big question is then: How can I disable a "Character" from a combined skinned mesh renderer? I have two ideas: 1: When combining the skin mesh renderer, I will leave a copy of the original skin mesh renderer on the GameObject (Of course disabled). Whenever the GameObject is destroyed, I'll take the copy of the original skin mesh renderer, extract the mesh data, and substract it from the main Skinned Mesh Renderer, but: - I don't know how to do this, and I can't seem to find enough information to assist me. Any tips and tricks on how to proceed with this? - During such mesh manipulation runtime, is that to heavy? 2: Another solution would be to simply just move the GameObject out of sight (Underneath the terrain) but: - This approach seems very dirty - Would eventually lead into problems. So, I am in doubt on how to proceed, and assistance would be appreciated. [1]: http://forum.unity3d.com/threads/123649-Script-to-combine-Animated-Mesh-and-Textures

Viewing all articles
Browse latest Browse all 192

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>