Commit Graph

1044 Commits

Author SHA1 Message Date
Annika
b590d3c907
Add /noreply command (#6953)
This command should never be used by users.

This is for scripting, like buttons, like:

    <button name="send" value="/nofeedback /ionext">

so they don't spam your PMs.
2020-07-10 22:01:15 -07:00
Guangcong Luo
9fe5a0e063 Improve "Message can't be blank" error
It was previously a popup, but there's no need for that anymore. An
`errorReply` is much friendlier.
2020-07-10 05:06:02 -07:00
asgdf
2136c34e8e
Fix trustuser commands (#6988) 2020-07-09 23:30:47 -07:00
Mia
6690cfb037
Fix pollqueue page crash (#6986) 2020-07-09 22:19:43 -07:00
TheMezStrikes
a719c5f7e3
Trim !show image comment (#6987) 2020-07-09 16:08:51 -07:00
Annika
db4bb7b46f
Roomevents: Delete events fully (#6984) 2020-07-09 05:00:43 -07:00
Annika
2c24650cf7
Daily spotlight: Fix regex to allow whitespace (#6985) 2020-07-09 05:00:22 -07:00
Annika
573eb439f8
Datasearch: Don't use Object.keys() in /ds monotype (#6982) 2020-07-08 15:39:46 -07:00
Annika
c2f4e524b8
Datasearch: Support /ds monotype without a type (#6981) 2020-07-08 15:12:40 -07:00
Kris Johnson
127a04b19e
Make improvements to the UNO game (#6980) 2020-07-08 15:12:14 -07:00
Guangcong Luo
faab60a618 Unify command logging code
Global punishments like /lock will notify Staff, and admin commands
like /updateserver will log to Staff, but this has been done ad-hoc
in the past.

To handle these cases, this commit introduces new chat-context
functions:

- `this.addGlobalModAction`,
- `this.privateGlobalModAction`
- `this.stafflog`

Other updates:

- the issue where Staff notifications didn't show up until someone talks
  has been fixed
- `privateModAction`s in Staff will now be visible in the scrollback
  log
- a bunch of commands that should notify Staff but didn't now do
- some typos in modlogs have been fixed
2020-07-07 18:51:29 -07:00
Guangcong Luo
d6de3ce6eb Fix typo in HTML scripted button validator 2020-07-07 21:27:04 -04:00
Annika
d2a61a2b9d
Daily spotlights: Add queue management commands (#6974) 2020-07-07 16:14:50 -07:00
Kirk Scheibelhut
2691b91062
Fix tour challenges (#6972) 2020-07-06 22:58:12 -07:00
ZestOfLife
a594f0b816
Mafia: Make CS indication more obvious for hosts (#6684) 2020-07-07 14:01:33 +09:30
Kirk Scheibelhut
eea2196280
Server side changes to support persistent user settings and privacy changes (#6947)
NOTE: This is changes the semantics of `hidenext`/`ionext` from
applying to the next created *battle* to applying to the next
created *search*/*challenge*.
2020-07-06 21:18:38 -07:00
Annika
d42e17b7ff
Trivia: Changes to the random category selector (#6971) 2020-07-06 21:16:57 -07:00
Guangcong Luo
9879d29cb8 /makechatroom no longer defaults to public 2020-07-06 17:12:01 -07:00
Kris Johnson
1a9d0611a6
Add quality-of-life fixes for Pet Mods (#6968) 2020-07-06 16:44:09 -07:00
Kris Johnson
4043f6e118
Fix bugs from recent restrictions update (#6967) 2020-07-06 15:54:14 -07:00
Guangcong Luo
c124720885
Support throwing error messages (#6946)
The idea is that throwing `ErrorMessage` will replace needing to pass
`context` variables around (which make it hard to unit test a lot of
chat functions).

I recognize the drawback is that it makes it harder to tell where
chat commands might return from. This might be somewhat alleviated by
a convention such as prefixing everything with `check`

    this.checkBroadcastable();

    this.checkCan('lock');

I honestly didn't like the old approach of `if (!this.can(...)) return`,
though. It didn't seem very obvious which commands would show error
messages and which needed you to write your own error messages. I think
the new system would at least be clearer about that.

We can also consider things such as some sort of sigil, such as:

    !this.checkCan('lock');

There's no other reason to use `!` at the beginning of a line, so I
think this is reasonably unambiguous, although it might take some
time to learn. Also we'd have to screw with eslint.

Another alternative is something all-caps?

    this.CHECK_can('lock');

In the end, I still think `this.checkCan('lock')` would be enough, and
I still think it's already an improvement in many ways.
2020-07-06 14:07:02 -07:00
Guangcong Luo
8b3a3e47cf global is no longer a RoomID 2020-07-06 14:06:00 -07:00
whales
6d3cf8a972 Remove unnecessary room requirements from some commands 2020-07-07 00:54:50 +09:30
Spandan Punwatkar
fa5b90cba3
Add /showevo (#6957)
Co-authored-by: Kris Johnson <11083252+KrisXV@users.noreply.github.com>
2020-07-06 10:53:10 +04:00
Mia
4997a47314
Commands: Allow the room parameter to be null (#6948)
Co-authored-by: Guangcong Luo <guangcongluo@gmail.com>
2020-07-05 14:25:09 -07:00
Kirk Scheibelhut
bbfcd7ae25 Remove 'inappropriate status' from reports
Staff suggest this is never used for the correct reasons and is more
trouble than its worth
2020-07-04 18:14:10 -07:00
Guangcong Luo
d7ba455e2b Update permissions
Permissions have gotten out-of-date, so this commit syncs them.
Default permissions are now matched with Main, in particular including
the new & rank as admin (removing the old Leader rank and ~ symbol).

Relevant changes:
- Admin (~) and Leader (&) have been merged into Admin (&)
- The 'ban' permission was split into 'globalban' and 'ban'
- The 'broadcast' permission was renamed 'show' (going forward,
  "broadcast" should only refer to the big red/blue/green
  announcement bars.)
- Bots no longer have global moderation abilities, making it
  easier to give untrustworthy bots the "bot" rank.
2020-07-03 17:32:49 -04:00
Annika
26150aab1b
Fix bug in /renameroom (#6952) 2020-07-03 11:48:25 -07:00
Annika
61e0a2e9e4
Chatlog: Fix grammar in error message (#6951) 2020-07-03 10:47:08 -07:00
Guangcong Luo
f16849eda3 Support addModAction/privateModAction in PMs 2020-07-03 01:18:17 -04:00
Guangcong Luo
26615490f7 Merge BasicChatRoom and BasicRoom
They were only ever kept separate because of GlobalRoom. It might be
useful to support rooms that aren't ChatRooms, but we've been chucking
properties into either BasicChatRoom or BasicRoom essentially at
random, so I think it makes sense to wait until we actually have a
use-case for a non-Chat room before carefully deciding which properties
belong where.
2020-07-02 18:54:02 -07:00
Guangcong Luo
bdb0b0ff72 Refactor Net use in YouTube plugin 2020-07-02 17:14:24 -07:00
urkerab
ea30e9d48d
Don't sort player array in-place when scoring round robin tournaments (#6945) 2020-07-02 15:46:55 -07:00
Guangcong Luo
ba1730900f Support comments in /roomintro etc 2020-07-02 14:34:53 -04:00
Guangcong Luo
46c9afa2f3
"Remove" the global room (#6885)
I couldn't completely remove the global room in one commit, but this
solves basically every problem with it by making it no longer a `Room`.

In particular, this means:

- It's no longer of type `Room`
- It's no longer in the `Rooms.rooms` table
- Its class name is now `GlobalRoomState` rather than `GlobalRoom`
- It no longer tracks its own user list (online user count is now
  provided by `Users.onlineCount`)
- It's no longer a socket channel (there's new syntax for "send this
  message to every user")
2020-07-02 11:31:34 -07:00
Guangcong Luo
d20a4a9918 Remove unnecessary update in /requestshow 2020-07-01 16:37:36 -07:00
Kris Johnson
7010e0286f
Add OMotM and RoA Spotlight for July 2020 (#6936) 2020-07-01 12:59:10 +04:00
Mia
5d72fe2f74
Fix /viewapprovals (#6935) 2020-06-30 23:17:24 -07:00
Mia
75f9937aad
Info: Support viewing current media requests and hiding media (#6907) 2020-06-30 15:59:52 -07:00
Mia
857d5c648e
Youtube: Allow drivers to use /youtube update (#6933) 2020-06-30 12:11:09 -07:00
Austin Couturier
25c185c010
Fix /tour forcepublic to prevent /hiddenroom (#6932) 2020-06-30 12:09:30 -07:00
Austin Couturier
f08bc21f26
Add an option to force public replays for room tournaments (#6927) 2020-06-29 19:21:21 -07:00
Annika
f017398ffc
Trivia: Automatically join a game when answering (#6923) 2020-06-28 12:03:05 -07:00
Annika
4b02342806
Datasearch: Support 'monotype' parameter in /ds (#6922)
also piggybacked a fix for /as in here
2020-06-28 05:17:00 -07:00
fart
8503a6de1f
Correct commands in poll queue help (#6916) 2020-06-25 12:43:04 +04:00
TheMezStrikes
b1247e7892
Fix multiple bugs in events (#6913) 2020-06-24 14:52:31 -07:00
TheMezStrikes
815d5c5a0a
/changeuhtml should send /uhtmlchange not /uhtml (#6912) 2020-06-24 05:32:25 -07:00
TheMezStrikes
a3c0d69b3c
Add /st as /servertime alias (#6911) 2020-06-24 05:31:07 -07:00
Annika
a578ec99c6
Trivia: Fix bug in /trivia history (#6906) 2020-06-22 22:35:02 -07:00
Lusamine
41ece9d418
Update datacenters & ip-tools (#6903) 2020-06-22 07:18:40 -07:00