Summary
If you remove a mesh component from an entity and then add a new mesh component the old mesh component is still shown.
I believe the issue is with removing the old mesh component because even if you remove it, it is still visible which then prevents you from adding a new mesh.
Please select what you are reporting on:
Verse
What Type of Bug are you experiencing?
Verse
Steps to Reproduce
-
Spawn a new entity in the world (I used a prefab with one entity and mesh component as the only components)
-
Remove the old mesh component (you will still be able to see it)
-
Add a new mesh component (nothing happens)
if: MeshComp:= Entity.GetComponent[mesh_component] then: Entity.SetGlobalTransform(XForm) MeshComp.RemoveFromEntity() if. Entity.GetComponent[mesh_component] then Print("This shouldn't print") NewMeshComp:=Meshes.mTemp_Box{Entity:=Entity} Entity.AddComponent(NewMeshComp) if. Entity.GetComponent[mesh_component] then Print("It has a mesh again")
Expected Result
The old mesh should disappear and the new mesh should be shown
Observed Result
The old mesh is still showing
Platform(s)
All