mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
remove unwrap TODO
This commit is contained in:
parent
19b90d078a
commit
62a598c59b
@ -51,8 +51,10 @@ fn main() -> Result {
|
||||
|
||||
for x in aabb.min.x..aabb.max.x {
|
||||
for y in aabb.min.y..aabb.max.y {
|
||||
// TODO: remove unwrap
|
||||
let col = canvas.col(Vec2::new(x, y)).unwrap().get_info();
|
||||
let col = canvas
|
||||
.col(Vec2::new(x, y))
|
||||
.map(|col| col.get_info())
|
||||
.unwrap_or_default();
|
||||
for z in aabb.min.z..aabb.max.z {
|
||||
let pos = Vec3::new(x, y, z);
|
||||
|
||||
|
@ -1259,7 +1259,7 @@ impl ColumnSample<'_> {
|
||||
|
||||
// For a version of ColumnSample that can easily be moved around. Feel free to
|
||||
// add non reference fields as needed.
|
||||
#[derive(Clone)]
|
||||
#[derive(Clone, Default)]
|
||||
pub struct ColInfo {
|
||||
pub alt: f32,
|
||||
pub basement: f32,
|
||||
|
Loading…
Reference in New Issue
Block a user