Commit Graph

704 Commits

Author SHA1 Message Date
MangosArentLiterature
a5386ddc77 Change /login to use a "prompt" based system
This commit changes /login to no longer take command arguments. Instead, upon sending /login, you will enter an interactive "prompt", where your next OOC message will be interpreted as your login attempt (and will not be shown to other users). This prevents a typo from accidentally broadcasting your credentials to the entire area.

- Changes /login to take no command arguments, /login now sets a client state "is_logging_in".
- pktOocChat will now intercept a client's OOC message if they have this client state, and will interpret that as a moderator login.
- Adds the helper function loginAttempt() for handling moderator logins.
2021-04-26 16:29:56 -05:00
Cerapter
3aeff2d72d Merge remote-tracking branch 'refs/remotes/scatter/master' 2021-04-26 21:23:51 +02:00
Cerapter
f5cc137b40 Rename lib to core.
On Linux, the resulting shared library would have been called `liblib`, which is just dumb.
2021-04-26 21:14:25 +02:00
Cerapter
8d384d7d85 Relocate test output to bin/.
The executables couldn't be run without the libraries next to them.
2021-04-26 21:12:13 +02:00
scatterflower
aba007a5fc fix /bans 2021-04-26 02:43:38 -05:00
scatterflower
3403d45676 add auth skip 2021-04-26 02:19:19 -05:00
scatterflower
51ea6d996d fix incorrect sql statement, and add config switch to skip authentication for testing 2021-04-26 02:16:56 -05:00
MangosArentLiterature
e75b80aaae Add modcall webhook support
This is the worst code I have ever contributed to this project. This commit is the result of several days of attempting to decipher Qt's documentation. This is the best I can write. Qt has broken me. God help us all.

- Allows sending modcalls to a discord webhook, containing the name of the sender, the area, and the reason.
- Adds configurable options to config.ini for enabling/disabling webhooks and specifying the webhook url.
2021-04-25 15:49:47 -05:00
scatterflower
e44f687030 fix crash due to empty packets 2021-04-25 12:57:02 -05:00
Marisa P
192930f180
Merge pull request #103 from Salanto/Fix-#101
Fix #101
2021-04-23 14:57:27 -05:00
Cerapter
204877e706 Update Doxygen documentation for tests
Namespaces are neat.
2021-04-23 21:03:50 +02:00
Cerapter
00e1432e2d Set up basic tests subdirectories 2021-04-23 20:52:51 +02:00
Cerapter
7a3f4edf4a Separate main from lib
This is so that tests can use the logic without having to call in main as well.
Furthermore, this way, Qt actually recognises it as a library, and makes it easier to import to tests.
2021-04-23 19:05:32 +02:00
Cerapter
b740f5a3cd Relocate akashi into a subdirectory.
Will be used to make space for tests as well.
2021-04-23 18:29:33 +02:00
Salanto
532a48cd1d Update area.cpp 2021-04-23 17:25:08 +02:00
Salanto
13d03476da Fix-#101 2021-04-23 17:24:34 +02:00
Marisa P
01d4ff9048
Merge pull request #102 from AttorneyOnline/fix/utf8
Update all QSettings instances to use UTF-8 to prevent problems with Cyrillic characters
2021-04-23 00:35:49 -05:00
scatterflower
5f07cbeff7 version bump 2021-04-23 00:32:44 -05:00
in1tiate
87fe5c214d Update all QSettings instances to use UTF-8 2021-04-22 20:02:18 -05:00
Marisa P
3e490252be
Merge pull request #100 from Salanto/Fix-Woopsie2
Fix Server Crash when deleting statements during recording
2021-04-21 05:51:49 -05:00
Marisa P
d344ebe63a
Merge pull request #99 from AttorneyOnline/packet-size-limit
Add a size limit to packets and a configurable maximum character limit for messages.
2021-04-21 05:51:11 -05:00
MangosArentLiterature
e56fc07713 Revert "Merge branch 'master' into master"
This reverts commit 1b7c53bc01, reversing
changes made to f6a52f7378.
2021-04-20 19:34:22 -05:00
MangosArentLiterature
1b7c53bc01
Merge branch 'master' into master 2021-04-20 19:32:36 -05:00
Salanto
5e05326537 Fix Server Crash when deleting statements during recording 2021-04-20 23:09:16 +02:00
MangosArentLiterature
2f69b51280 Limit the amount of data the server will read
Set a hard limit on 30KB that the server is willing to read, over two sequential reads. If the client sends more than 30KB combined, the server will disconnect the client.
2021-04-20 11:51:22 -05:00
MangosArentLiterature
9c3cd12202 Add a size limit to packets and a configurable maximum character limit for messages
- Limits packets to under 16KB
- Adds a configurable option to config.ini for setting the maximum amount of characters in an IC/OOC message
- Limits the size of OOC names to 30 chars
   - The client already limits this, but this is an added precaution.
- Limits the length of shownames to 30 chars
- Implements shownames_allowed for areas, for toggling whether shownames are allowed for messages in that area
2021-04-19 19:44:46 -05:00
Marisa P
f6a52f7378
Merge pull request #97 from Salanto/Woopsie
Wopsie
2021-04-19 16:03:55 -05:00
Salanto
4e81eeb64f Wopsie 2021-04-19 23:01:50 +02:00
Marisa P
c13438587b
Merge pull request #95 from Salanto/fix-#94
Force UTF-8
2021-04-19 14:33:55 -05:00
Salanto
5dad3c11c6 Force UTF-8 2021-04-19 15:06:11 +02:00
MangosArentLiterature
5da651bfde Add a link to source code to /about 2021-04-19 04:31:06 -05:00
Marisa P
c9e97b34d7
Merge pull request #93 from AttorneyOnline/multiclient-limit
Multiclient limit
2021-04-19 02:16:08 -05:00
scatterflower
e252ed04e9 make it configurable 2021-04-19 02:09:24 -05:00
scatterflower
e8a99eb35a implement multiclient limit 2021-04-19 01:54:22 -05:00
Marisa P
0454ac114c
Merge pull request #88 from AttorneyOnline/messaging-commands
Add /charcurse and /uncharcurse
2021-04-18 21:23:35 -05:00
Marisa P
80ac3cc94c
Merge pull request #92 from AttorneyOnline/dice-roller-and-togglemusic
Refactor AOClient::diceThrower() and add /togglemusic
2021-04-18 21:23:13 -05:00
MangosArentLiterature
fcce8d9699 Document charcurse_list, fix /charcurse 2021-04-18 20:50:44 -05:00
MangosArentLiterature
8933ec2809 Clean up documentation, remove RollType
- Cleans up documentation for cmdRoll cmdRollP and diceThrower()
- Removes the obsolete enum RollType
2021-04-18 20:30:11 -05:00
MangosArentLiterature
75fe0a86f1 Merge branch 'master' into dice-roller-and-togglemusic 2021-04-18 20:22:57 -05:00
MangosArentLiterature
cf1e1cfc95 Add /togglemusic
- Adds /togglemusic to toggle whether music can be played in an area. CM's can still play music.
- Add toggle_music option to area.ini to set the default value in an area. Default value is set to true.
- Also fixes a missing period in the documentation for force_immediate. Because I noticed it.
2021-04-18 20:21:17 -05:00
MangosArentLiterature
a32cc0e27f Refactor AOClient::diceThrower() 2021-04-18 19:56:03 -05:00
scatterflower
5d1094c12d fix messed up merge conflict resolution 2021-04-18 19:44:34 -05:00
Marisa P
647c3cb398
Merge branch 'master' into messaging-commands 2021-04-18 19:41:56 -05:00
Marisa P
ad1429ac03
Merge pull request #89 from Salanto/Add-/a-and-/s
Add /a and /s
2021-04-18 19:28:30 -05:00
Marisa P
a0919d8824
Merge pull request #91 from AttorneyOnline/banids2
Expose ban ids to /bans and BD
2021-04-18 19:28:12 -05:00
scatterflower
21d7ade720 go back to comma separated 2021-04-18 19:26:37 -05:00
scatterflower
4f6706ae94 fix a few small bugs 2021-04-18 19:18:52 -05:00
scatterflower
08ba6ef278 change curse list to int list, marked unavailable chars as taken 2021-04-18 18:57:33 -05:00
in1tiate
7ae4f95e12 expose ban ids to /bans and BD 2021-04-18 18:49:06 -05:00
Salanto
40552b1602 Add /a and /s 2021-04-19 00:48:51 +02:00