Commit graph

126 commits

Author SHA1 Message Date
Zwelf 13c80fdc56 Thread safe saving of score 2020-06-15 11:14:15 +02:00
Zwelf 031ac52320 Thread safe /save 2020-06-15 11:14:15 +02:00
Zwelf 9add354367 Use Template for SqlResult 2020-06-15 11:14:15 +02:00
Zwelf 8a22cce031 Start of sql refractor
* Use atomic integer in thread count for thread safety
2020-06-15 10:59:46 +02:00
bors[bot] 92fc95d742
Merge #2202
2202: Send DDNet version early in the connection process r=Learath2 a=heinrich5991

This gets rid of the problem that we don't know whether we should send
full snapshots to clients because they haven't told us about them being
DDNet yet.

Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2020-05-27 17:49:31 +00:00
def e1849ad1bb Implement /practice for teams
As discussed on Discord today, can be enabled inside of teams on the fly
during each run on any server. Finishes don't count. I haven't tested
save/load yet, would do that live on the server if this can be merged.
2020-05-27 17:33:26 +02:00
heinrich5991 0d7872c79e Send DDNet version early in the connection process
This gets rid of the problem that we don't know whether we should send
full snapshots to clients because they haven't told us about them being
DDNet yet.
2020-05-22 17:58:41 +02:00
Learath 547f751bf3 Mark players as afk initially. Fix #1797 2019-10-13 17:13:03 +02:00
d3fault 10e06f919e respawn is now instant, but rate limited to 3 sec unless player clicks mouse1 2019-06-07 02:44:19 -07:00
fokkonaut e471d4796e Remove the unused Skinstealaction 2019-06-04 17:23:29 +02:00
trml 3f9d30af0f Sync weapon input with other inputs 2019-01-29 20:58:25 +01:00
Dennis Felsing f83a9be610 Sneaky code (TODO: Also mark 708?) 2018-12-17 14:55:58 +01:00
Dennis Felsing 5c18d6c481 Remove /modhelp (fixes #1401) 2018-12-12 10:05:44 +01:00
heinrich5991 8d04e7e5e1 Share libcurl resources across requests
Use the libcurl-share interface to share DNS cache and connections
between different requests.

If compiled with OpenSSL, libcurl can only be safely used from multiple
threads for OpenSSL >= 1.1.0, but this problem is not newly introduced
by this commit: According to libcurl-thread(3):

>OpenSSL <= 1.0.2 the user must set callbacks.
>
>https://www.openssl.org/docs/man1.0.2/crypto/threads.html#DESCRIPTION
>
>https://curl.haxx.se/libcurl/c/opensslthreadlock.html
2018-07-11 20:17:21 +02:00
bors[bot] ebb9481857 Merge #1157 #1160
1157: Add a way to call for external moderator help r=Learath2 a=heinrich5991

This is done by HTTP POSTing to a location specified by
`sv_modhelp_url`. We also provide a `src/modhelp/server.py` which can
use theses POSTs to forward them to Discord servers.

The POST contains a JSON object payload, with the keys `"port"` which
contains the server port, `"player_id"` which contains the calling
player's client ID, `"player_name"` which contains the calling player's
nick and `"message"` which is the user-specified message.

Make JSON-escaping function public, add tests and fix bugs uncovered by
these tests.

Supersedes #1129.

1160: Fix warning about incompatible function pointers r=Learath2 a=heinrich5991

This comes at the cost of one allocation per started thread. This should
be okay because we're about to invoke a syscall anyway.

Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2018-06-24 14:12:48 +00:00
heinrich5991 57e26450b2 Unify spelling of Modhelp
Since the command name is `/modhelp` it should be written `Modhelp` in
camel case.
2018-06-24 11:03:18 +02:00
heinrich5991 36694d3852 Add a way to call for external moderator help
This is done by HTTP POSTing to a location specified by
`sv_modhelp_url`. We also provide a `src/modhelp/server.py` which can
use theses POSTs to forward them to Discord servers.

The POST contains a JSON object payload, with the keys `"port"` which
contains the server port, `"player_id"` which contains the calling
player's client ID, `"player_name"` which contains the calling player's
nick and `"message"` which is the user-specified message.

Make JSON-escaping function public, add tests and fix bugs uncovered by
these tests.

Supersedes #1129.
2018-06-19 23:27:35 +02:00
heinrich5991 c739aef60e Some style fixes 2018-06-19 14:28:53 +02:00
Dennis Felsing f8a00ad8af
Merge pull request #1000 from Ryozuki/pr_modhelp_chat_cmd
Add /modhelp chat command
2018-04-03 10:21:01 +02:00
ChillerDragon 052e67c541 Add broadcast importance (fixes #669) 2018-03-07 17:22:41 +01:00
heinrich5991 a744fe53a2 Remove CPlayer::m_Authed
This can't get out of sync now.
2018-01-27 23:13:17 +01:00
Ryozuki 79fedff12d add /modhelp chat command 2018-01-21 01:32:55 +01:00
Ryozuki d6eb604718 add rcon moderate mode 2018-01-05 15:23:08 +01:00
def 03fa475b5e Implement /pause [name] and /spec [name] 2017-09-18 19:12:01 +02:00
ChillerDragon 727b9f84b6 fixed scoreboard update for slow racers (less hacky) (#765)
* fixed scoreboard update for slow racers (less hacky)

* Fix some style issues
2017-07-05 23:01:57 +02:00
Dennis Felsing 278b17b460 Merge pull request #721 from Learath2/dd_pr_pause
Rework the pause system
2017-05-14 11:55:09 +02:00
Learath2 c1a4a95d61 Add ratelimiting and config options for invite 2017-04-24 14:04:50 +02:00
Learath 95690a1cf7 Reimplement sv_pause_frequency 2017-04-09 01:16:48 +02:00
Learath 5626259b27 Rework pause. Fixes force_pause 2017-04-09 00:20:41 +02:00
necropotame b6548aa8cf Fix wrong code convension, add enum for timer display type 2017-02-28 07:31:24 +01:00
heinrich5991 80ea4c8590 Disallow usage of semicolons in chat commands
This prevents player name exploits due to tab completion of nicknames
that could result in unwanted commands being executed.

Print a deprecation message that is supposed to be removed in the
future.
2017-01-03 14:01:51 +01:00
heinrich5991 c08206dd96 Don't show player HUD during /pause for vanilla clients 2016-09-20 21:40:40 +02:00
H-M-H e39829ef7c killer of locked team will get strong hook on respawn 2016-03-04 22:55:12 +01:00
H-M-H 42a68636b5 tweaked respawndelay a bit 2016-02-02 21:14:46 +01:00
H-M-H cb1c63c652 Merge pull request #410 from heinrich5991/pr_ddnet_join_vote_delay
Add sv_join_vote_delay
2016-01-29 12:58:05 +01:00
def 0a49428e21 Veto considers time on server not in current race 2016-01-27 02:14:46 +01:00
heinrich5991 384668928b Add sv_join_vote_delay
This is a new delay that specifies how many seconds you have to wait
before making your first vote. In case the server was only recently
filled (e.g. by a map change or if people start joining an empty
server), this delay is disabled (in the first case, because it's normal
to join after a map change, in the second case because you might have
joined the empty server to vote for a different map).
2016-01-19 23:52:28 +01:00
def 6e8ada1ac8 Fix whitespaces a bit 2015-07-09 02:12:35 +02:00
def 87ebb2f03e Defer character kill from thread to prevent race conditions 2014-12-07 03:42:43 +01:00
def 93d0f43a6a Broadcast about DDNet client delayed a bit (fixes #72) 2014-11-25 20:33:21 +01:00
east 630fd4fa07 sending vote options balanced 2014-10-26 19:39:42 +01:00
def 6333583141 Display message about DDNet client to players not using it 2014-10-12 11:33:36 +02:00
def 741cf8f8c7 Cleanup & Halloween event 2014-09-18 12:14:00 +02:00
def 2980bd77e8 Add /specteam 2014-08-09 19:53:38 +02:00
def f859f350ca Kind of working with timeout code 2014-08-09 17:25:29 +02:00
def 4af575654b Kind of working 2014-08-09 14:50:51 +02:00
def 145f0434f5 Add /save by the glorious HMH 2014-07-26 14:46:31 +02:00
HMH f2c8134bd2 send correct tunings to spectators 2014-03-23 17:10:49 +01:00
def 0e15c22639 More sensitive afk detection 2014-02-21 18:27:00 +01:00
def 823a04333a Add /showall 2014-02-02 19:56:10 +01:00