Merge pull request #16321 from JFonS/master
Fix gizmo solid box mesh being added twice
This commit is contained in:
commit
6179770700
1 changed files with 0 additions and 9 deletions
|
@ -308,15 +308,6 @@ void EditorSpatialGizmo::add_solid_box(Ref<Material> &p_material, Vector3 p_size
|
||||||
m->add_surface_from_arrays(cubem.surface_get_primitive_type(0), cubem.surface_get_arrays(0));
|
m->add_surface_from_arrays(cubem.surface_get_primitive_type(0), cubem.surface_get_arrays(0));
|
||||||
m->surface_set_material(0, p_material);
|
m->surface_set_material(0, p_material);
|
||||||
add_mesh(m);
|
add_mesh(m);
|
||||||
|
|
||||||
Instance ins;
|
|
||||||
ins.mesh = m;
|
|
||||||
if (valid) {
|
|
||||||
ins.create_instance(spatial_node);
|
|
||||||
VS::get_singleton()->instance_set_transform(ins.instance, spatial_node->get_global_transform());
|
|
||||||
}
|
|
||||||
|
|
||||||
instances.push_back(ins);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void EditorSpatialGizmo::set_spatial_node(Spatial *p_node) {
|
void EditorSpatialGizmo::set_spatial_node(Spatial *p_node) {
|
||||||
|
|
Loading…
Reference in a new issue