Config.quietconsole is a new (intentionally undocumented) config
setting to decrease the amount of non-error messages PS outputs
to the console.
It's useful because of some upcoming improvements to other PS
console output, and this will make those easier to sift through,
but it's undocumented because only a huge server (namely, Main)
will actually have enough activity to need it.
'Confirmed' is a new pseudo-usergroup, halfway between autoconfirmed
and voice. It grants immunity to locks and works similarly to
autoconfirm status, except it's only granted by being globalvoice+,
roomdriver+, or manually confirmed.
The .forceRenamed flag was used to make sure /frt couldn't
accidentally grant console access. /frt had a lot of security
issues and was removed a long time ago, which renders this
part of the code obsolete.
Username roombans could be bypassed by joining the room before
merging into the banned user.
This removes connections from a room if they're merging into a user
roombanned in that room. It's done rather crudely because midway
through a merge, the user and connection objects are in an
inconsistent state.
Reverse DNS can't always find a host for certain common IP
ranges (generally cell networks), so we're going to fill in
a fake host in that case, to make rangebans and the like
easier.
This plugs an exploit where users could start laddering and
change name to be matched with users at a different Elo rating
than the one they play with.
There is no reason to allow them, while doing so allows some race conditions where the first connection of a player joining a battle room doesn't receive their request.
Seperated /privateroom command into /privateroom and /hiddenroom. In
hidden rooms, mostly set by battle players, global staff maintain their
ranks within the room, but the rank is not kept in secret/private rooms
(only set by users who can create chat rooms).
Created command /whoare to allow global staff to see the hidden rooms a
user is in.
A mismatch between the key in `room.users` and the userid arised due to the fact that users had their `userid` property updated before getting disconnected from the server.
- `user.locked` would be equal to the id the user had when the rename has performed, rather than the autolocked userid.
- `lockedIps`'s property values would be sometimes wrong in a similar way due to a missing change in 47e90226.
Both of these issues are hereby fixed.
Generalized the BattleRoom constructor function (and the functions that
call it) to pass an arbitrary `options` object instead of a boolean for
`rated` only. Also, removed mention of `parent` or `parentid` in the
constructor and functions because it's no longer needed or used.
Added support to the BattleRoom constructor to let it process tournaments
properly. Now, instead of having the tournament forcefully override the
BattleRoom.win function, the BattleRoom itself can handle the callback for
when a tournament participant wins the battle.
Added a check for tournament battles to prevent users who aren't part of
that specific tournament battle from entering the battle.