mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Use made_valid instead of min/max
This commit is contained in:
parent
165065725e
commit
ad0396d9f4
@ -1325,14 +1325,13 @@ fn handle_build_area_add(
|
||||
);
|
||||
return;
|
||||
}
|
||||
let bb_id = ecs
|
||||
.write_resource::<BuildAreas>()
|
||||
.deref_mut()
|
||||
.areas
|
||||
.insert(Aabb {
|
||||
min: Vec3::new(xlo.min(xhi), ylo.min(yhi), zlo.min(zhi)),
|
||||
max: Vec3::new(xhi.max(xlo), yhi.max(ylo), zhi.max(zlo)),
|
||||
});
|
||||
let bb_id = ecs.write_resource::<BuildAreas>().deref_mut().areas.insert(
|
||||
Aabb {
|
||||
min: Vec3::new(xlo, ylo, zlo),
|
||||
max: Vec3::new(xhi, yhi, zhi),
|
||||
}
|
||||
.made_valid(),
|
||||
);
|
||||
ecs.write_resource::<BuildAreas>()
|
||||
.deref_mut()
|
||||
.area_names
|
||||
|
Loading…
Reference in New Issue
Block a user