Commit Graph

1028 Commits

Author SHA1 Message Date
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
Annika
bc2aec5c82 Roomevents: Support event categories (#6820) 2020-06-21 21:46:11 -07:00
asgdf
2a570291e1 Remove incorrect host classification (#6893)
A large portion of the IPs with that hostname are static broadband connections.
2020-06-21 19:22:22 -04:00
Guangcong Luo
6af875af8b Improve RoomPermission/GlobalPermission checks
Global permissions can no longer be used as room permissions. Instead,
the two are entirely separate lists, with only a few permissions in
both lists.
2020-06-21 03:53:06 -07:00
Guangcong Luo
ee6e43b552 Strongly type RoomPermission and GlobalPermission
`user-groups.ts` now tracks the list of possible values for
`RoomPermission` and `GlobalPermission` in a const.
2020-06-21 01:43:27 -07:00
Mia
f9e79220dd Polls: Support queuing (#6595) 2020-06-20 23:56:04 -07:00
Guangcong Luo
214aef6df6 Strongly type Rooms.global.settingsList 2020-06-20 21:45:02 -07:00
Nixola
00d0647dec Prevent empty string from being added to banwords (#6887)
Filter out empty strings from the `banword add` and `banword delete`
arguments. Added a check in `banword add` for an empty array of
arguments.
2020-06-20 20:50:53 -07:00
urkerab
273eb928cf Show status immunities in /weak output (#6889) 2020-06-20 20:49:50 -07:00
Mia
f306ed069f Youtube: Fix crash (#6891)
Ensure video data exists in the response
2020-06-20 20:47:55 -07:00
Mia
a888c10bb6 Youtube: Don't crash if key isn't configured (#6848) 2020-06-20 20:16:07 -07:00
Annika
128d36aa0b Trivia: Add /trivia history command (#6880) 2020-06-19 22:43:10 -07:00
Peach
6c517b5562 Roomsettings: Fix language, modjoin, button formatting (#6879) 2020-06-19 17:36:37 -07:00
Guangcong Luo
20336fdfa0 Refactor /requestshow 2020-06-18 23:47:39 -07:00
Mia
501f773204 Improve /requestshow (#6868) 2020-06-18 23:43:41 -07:00
Mia
d2b255b934 /eval: Log in dev room and broadcast (#6871)
Co-authored-by: Guangcong Luo <guangcongluo@gmail.com>
2020-06-18 23:28:15 -07:00
Mia
f8b95ce9a0 Rooms: Save creation time for all rooms (#6845) 2020-06-18 19:45:30 -07:00