summaryrefslogtreecommitdiff
path: root/client/src/window.rs
diff options
context:
space:
mode:
authormetamuffin <metamuffin@disroot.org>2025-01-27 16:05:48 +0100
committermetamuffin <metamuffin@disroot.org>2025-01-27 16:05:48 +0100
commitf5caf8f9643c2e7d10afb4a83f980b1e8659eae7 (patch)
tree0f7ac93653b1e70f3eb865fd2bbd9bc227c3ec3f /client/src/window.rs
parentc121d94f0b27bc04ffbdca55cd0939c1401d5a2e (diff)
downloadweareserver-f5caf8f9643c2e7d10afb4a83f980b1e8659eae7.tar
weareserver-f5caf8f9643c2e7d10afb4a83f980b1e8659eae7.tar.bz2
weareserver-f5caf8f9643c2e7d10afb4a83f980b1e8659eae7.tar.zst
faster cursor centering
Diffstat (limited to 'client/src/window.rs')
-rw-r--r--client/src/window.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/client/src/window.rs b/client/src/window.rs
index 665aa01..919d05e 100644
--- a/client/src/window.rs
+++ b/client/src/window.rs
@@ -73,10 +73,10 @@ impl ApplicationHandler for WindowState {
sta.renderer.surface_configuration.height as f32,
);
let center = size / 2.;
- let dt = 0.008_f32;
+ let dt = 0.03_f32;
let h = center + (sta.input_state.cursor_pos - center) * (-dt).exp();
sta.input_state.cursor_pos = h;
- let center = center.distance(sta.input_state.cursor_pos) < 5.;
+ let center = center.distance(sta.input_state.cursor_pos) < 10.;
if self.center != center {
self.center = center;
win.set_cursor(if center {