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);