no divide by zero
parent
62ad660c08
commit
56cfd97d77
|
@ -103,7 +103,9 @@ fn alignment(
|
|||
count += 1;
|
||||
}
|
||||
|
||||
accel.0 /= count as f32;
|
||||
if count > 0 {
|
||||
accel.0 /= count as f32;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue