Make FloatingOriginSettings::new pub (#3)

Closes #2
This commit is contained in:
Aevyrie 2023-05-08 13:46:41 -07:00 committed by GitHub
parent a1a395290e
commit 1a1f7ebc39
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -183,7 +183,9 @@ pub struct FloatingOriginSettings {
}
impl FloatingOriginSettings {
fn new(grid_edge_length: f32, switching_threshold: f32) -> Self {
/// Construct a new [`FloatingOriginSettings`] struct. This cannot be updated after the plugin
/// is built.
pub fn new(grid_edge_length: f32, switching_threshold: f32) -> Self {
Self {
grid_edge_length,
maximum_distance_from_origin: grid_edge_length / 2.0 + switching_threshold,