add maxLength to chat input field
make void a tiny bit faster again
This commit is contained in:
parent
e6ebc08e26
commit
f01db742af
|
@ -109,6 +109,7 @@ const Chat = ({
|
||||||
value={inputMessage}
|
value={inputMessage}
|
||||||
onChange={(e) => setInputMessage(e.target.value)}
|
onChange={(e) => setInputMessage(e.target.value)}
|
||||||
ref={inputRef}
|
ref={inputRef}
|
||||||
|
maxLength="200"
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="Chat here"
|
placeholder="Chat here"
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -43,7 +43,7 @@ class Void extends WebSocketEvents {
|
||||||
const area = TARGET_RADIUS ** 2 * Math.PI;
|
const area = TARGET_RADIUS ** 2 * Math.PI;
|
||||||
const online = webSockets.onlineCounter;
|
const online = webSockets.onlineCounter;
|
||||||
// require an average of 0.25 px / min / user
|
// require an average of 0.25 px / min / user
|
||||||
const requiredSpeed = Math.floor(online / 10);
|
const requiredSpeed = Math.floor(online / 6);
|
||||||
const ppm = Math.ceil(area / EVENT_DURATION_MIN + requiredSpeed);
|
const ppm = Math.ceil(area / EVENT_DURATION_MIN + requiredSpeed);
|
||||||
// timeout between pixels
|
// timeout between pixels
|
||||||
this.msTimeout = 60 * 1000 / ppm;
|
this.msTimeout = 60 * 1000 / ppm;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user