no divide by zero

main
Zynh Ludwig 2024-09-03 16:05:42 -07:00
parent 62ad660c08
commit 56cfd97d77
1 changed files with 3 additions and 1 deletions

View File

@ -103,7 +103,9 @@ fn alignment(
count += 1;
}
accel.0 /= count as f32;
if count > 0 {
accel.0 /= count as f32;
}
});
}