From 4bc23eabc41fadd911e4b779ab8e71e63800cfc1 Mon Sep 17 00:00:00 2001 From: flashwave Date: Thu, 29 Feb 2024 21:58:01 +0000 Subject: [PATCH] Made it say Ready~ --- src/mami.js/main.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/mami.js/main.js b/src/mami.js/main.js index 5d66d60..f07380a 100644 --- a/src/mami.js/main.js +++ b/src/mami.js/main.js @@ -418,7 +418,7 @@ window.Umi = { UI: {}, Protocol: { SockChat: { Protocol: {} } } }; const pingIndicator = new MamiPingIndicator; const pingToggle = Umi.UI.Toggles.Add('ping', { click: () => alert(pingToggle.title), - }, 'Ready!'); + }, 'Ready~'); pingToggle.appendChild(pingIndicator.getElement()); console.log(pingIndicator); @@ -623,8 +623,8 @@ window.Umi = { UI: {}, Protocol: { SockChat: { Protocol: {} } } }; if(dumpEvents) console.log('ping:recv', recv); let strength = 3; - if(recv.diff > 1000) --strength; - if(recv.diff > 250) --strength; + if(recv.diff >= 1000) --strength; + if(recv.diff >= 250) --strength; pingToggle.title = `${recv.diff.toLocaleString()}ms`; pingIndicator.setStrength(strength);