Commit graph

2497 commits

Author SHA1 Message Date
fokkonaut ac588f324c Fix crashbug on set_team_ddr -1 2019-08-04 23:38:08 +02:00
Ryozuki e112cf6791
add paused and spec to explayerflags 2019-08-02 18:16:58 +02:00
def 99b814342c Add a few contributors 2019-08-01 18:36:21 +02:00
Learath 9061f03174 Move the afk flag up front 2019-07-29 14:46:29 +03:00
bors[bot] dc41bb9649 Merge #1821
1821: Add afk marks r=def- a=ardadem

This is final state  (and most minimalist to not create mess) of my previous pull request. I didn't reopen it because it's contains changed unnecessary commits.

If someone will become afk, mark will be spawn next to tee's name.
![2019-07-13-13:59:20-screenshot](https://user-images.githubusercontent.com/13207692/61170739-8c4b9b80-a576-11e9-9d87-4c4b2f93941b.png)


Co-authored-by: Arda <ddmirarda@gmail.com>
2019-07-26 08:58:20 +00:00
Arda fb2cb4db26 move afk state inside to player flags 2019-07-26 11:48:15 +03:00
bors[bot] cd8994147c Merge #1842
1842: [WIP] Fix timer r=heinrich5991 a=Learath2

I'm really unsure about this one.

DEPENDS on #1839 

Co-authored-by: Learath <learath2@gmail.com>
2019-07-19 22:23:22 +00:00
bors[bot] 2f23b5c29a Merge #1839
1839: Set m_Race. Fix #1806 r=heinrich5991 a=Learath2

@heinrich5991 apparently you forgot to set `CGameInfo::m_Race` 🙂 

Co-authored-by: Learath <learath2@gmail.com>
2019-07-19 09:31:04 +00:00
Learath b1ed78d58d Add new flag, Fix #1807 2019-07-19 12:28:08 +03:00
Learath 78ac5ce030 Send the flag from the server 2019-07-19 11:21:32 +03:00
Learath 02f5723321 Force spawn order of teams. Fix #1828 2019-07-18 18:35:51 +03:00
bors[bot] a2e40ca4b3 Merge #1803
1803: Fix double pause due to spec r=def- a=fokkonaut

If a player is in /spec (sv_pausable 1 required) and would then use /pause, the tee would respawn, but the player would still be in /pause instead of playing again.
With this, the player will resume completely

Co-authored-by: fokkonaut <35420825+fokkonaut@users.noreply.github.com>
2019-07-15 07:55:48 +00:00
bors[bot] d3c6f1b54f Merge #1823
1823: Fix 'several players were found' on /rank r=heinrich5991 a=fokkonaut

If no player was found, it should say 'x is not ranked', instead it says 'Several players were found', that is because if the result is -1, it will say that. With the default result being -2, it can no longer say that, instead it will say that the player is not ranked.

Co-authored-by: fokkonaut <35420825+fokkonaut@users.noreply.github.com>
2019-07-14 11:23:55 +00:00
fokkonaut fabdc73087 Fix 'several players were found' on /rank 2019-07-14 11:31:58 +02:00
Arda f1454dbb7a Share afk state of players to client 2019-07-13 12:25:24 +03:00
ChillerDragon 6172a9dca0 Use the float type explicitly 2019-07-08 23:08:42 +02:00
bors[bot] b50e7ee674 Merge #1802
1802: Prediction fixes r=def- a=trml

I believe this fixes #1671 (uninitialized variables).

Some other things: Use new ddnetchar fields in prediction, small fix for prediction of moving pickups, fix the freeze end tick in ddnetcharacter (will add it to the client later)

Also adds a setting for choosing between new/old antiping for grenade like suggested in #1683 (cl_antiping_gunfire 0 to disable).

Co-authored-by: trml <trml@users.noreply.github.com>
2019-07-04 12:59:52 +00:00
fokkonaut 0cb13ccec1 Fix double pause due to spec 2019-07-01 01:17:32 +02:00
trml 82a47210eb Fix freeze end tick in ddnetchar 2019-07-01 00:50:50 +02:00
def 6d19963933 Remove unused variables 2019-06-25 23:07:32 +02:00
def f7e642bbbe Fix race condition in /map (untested) 2019-06-25 21:03:20 +02:00
heinrich5991 f31e081bd4 Remove all checking for the gametype in the game
OK, maybe not actually remove because it is kept for fallback when the
new method isn't available.

The whole gametype parsing business had the same downsides as user agent
parsing on the web, hence I removed it while keeping behavior the same.

This allows servers to explicitly opt in or out of certain bug
workarounds and other client behavior. This increases the complexity of
different configurations that are available in the client (which is a
bad thing).
2019-06-14 00:28:59 +02:00
Learath efbc05c9a8 No need for <algorithm> 2019-06-13 23:24:06 +02:00
trml fbf5edfdcb Set and send solo status on servers with sv_solo_server and sv_team 3 2019-06-13 17:23:23 +02:00
Dennis Felsing 617d123024
Merge pull request #1778 from d3fault/instant-respawn
respawn is now instant, but rate limited to 3 sec unless player clicks mouse1
2019-06-11 18:04:52 +02:00
Dennis Felsing bbb1b2cdef
Merge pull request #1733 from Learath2/dd_pr_colorsigned
Store colors unsigned
2019-06-11 12:26:28 +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
fokkonaut 75e13550c2 Convert to int 2019-06-03 11:57:46 +02:00
fokkonaut 078e88bc8f Cleanup CPlayer Snap 2019-06-03 11:35:18 +02:00
fokkonaut af7fd12341 Remove m_Weapon parameter from CProjectile 2019-06-02 22:04:11 +02:00
bors[bot] 1578a33628 Merge #1760
1760: Fix freeze projectiles only hit one tee (Fixes #1759) r=def- a=fokkonaut



Co-authored-by: fokkonaut <35420825+fokkonaut@users.noreply.github.com>
2019-05-31 11:59:15 +00:00
bors[bot] 647bbcc259 Merge #1732
1732: Implement ISDDNET and Time Score cleanly r=def- a=Learath2

This is an attempt at implementing the two things in a cleaner way.

Deprecated #1320 
Willfix #1622  soon(tm)

Co-authored-by: Learath <learath2@gmail.com>
Co-authored-by: Learath2 <learath2@gmail.com>
2019-05-31 10:12:10 +00:00
fokkonaut 85cbe99422 Fix wrong character team check 2019-05-30 14:14:47 +02:00
fokkonaut 61a6518f0d remove spaces 2019-05-29 16:30:44 +02:00
fokkonaut bbbdd89e64 Fix freeze projectiles only hit one tee (Fixes #1759) 2019-05-29 16:28:38 +02:00
fokkonaut 14c7bf550a
fixed typo 2019-05-26 22:47:02 +02:00
Learath2 c98978c9d6 Implement timescore using a netobj 2019-05-21 10:26:33 +02:00
Learath c2a774275f Move AuthInfo into DDNetPlayer 2019-05-21 10:25:15 +02:00
heinrich5991 096c87bd1d Hack around the race condition in random maps selection
Revert this "once we get proper SQL code"™.
2019-05-20 00:12:59 +02:00
Learath 0d39eb128d Use unsigned integers for colors 2019-05-15 18:05:19 +02:00
Dennis Felsing 7ba1cae5f6
Merge pull request #1699 from trml/pr_extend_ddnetchar
Add some more fields to ddnetcharacter
2019-05-05 20:11:10 +02:00
trml 09401a83ec Add strong/weak id to ddnetcharacter 2019-05-02 00:34:20 +02:00
trml ae57b7f205 Add more fields to ddnetcharacter 2019-05-02 00:34:03 +02:00
Learath 57f58cc9c7 Refactoring mishap 2019-05-01 22:57:14 +03:00
Learath 689c7b29be Don't check dnsbl when alone 2019-05-01 14:54:51 +03:00
bors[bot] a2f44299e0 Merge #1678
1678: Handle colors in console r=def- a=Learath2

DEPENDS: #1654 

A better way to fix #1581 possibly deprecates #1597 

Co-authored-by: Learath <learath2@gmail.com>
2019-04-30 19:39:56 +00:00
bors[bot] 70b3f1db21 Merge #1675
1675: Remove unused vanilla code (closed #1658) r=def- a=ChillerDragon

Removed vanilla code from gamecontext and gamecontroller. I didn't search for the code all over the place I just remember seing it there a lot. Also removed some empty lines. Wanted to do this for a long time :)

thought there is an reason it is there. But we have git and the vanilla repo so I don't see any point keeping it there.

Co-authored-by: ChillerDragon <chillerdragon@gmail.com>
2019-04-29 07:24:01 +00:00
bors[bot] a5096c4de0 Merge #1663
1663: Use freeze end tick instead of a flag. Fix #1659 r=def- a=Learath2

I used -1 for deep frozen, and 0 for not frozen. Not really sure if this is the best way.

Co-authored-by: Learath <learath2@gmail.com>
2019-04-27 08:53:38 +00:00
Learath 93d14a1eca Inconvenience for windows 2019-04-26 22:36:49 +03:00
Learath 93265dbb9c Please MSVC 2019-04-25 21:09:32 +03:00
Learath 0f781df1dd Try handling colors in console 2019-04-25 14:48:53 +03:00
ChillerDragon ad7a2cdef2 Remove unused vanilla code (closed #1658) 2019-04-24 22:36:47 +02:00
Learath 24408e6f3c Oops 2019-04-24 19:12:46 +03:00
Ryozuki 42a5d7a9c1 fix conflicts 2019-04-23 20:42:07 +02:00
Dennis Felsing dc1e638fb9
Merge pull request #1664 from Learath2/dd_pr_solofix
Fix solo bug
2019-04-23 20:03:58 +02:00
bors[bot] 526af034dd Merge #1620
1620: Rewrite of prediction code, with additional prediction (updated) r=def- a=trml

This is a reworked attempt at a rewrite of the prediction code (#464), to allow for more client side prediction. It doesn't fix the duplication of server code, but the client code should otherwise be cleaner. This includes separating prediction code out of gamecore/gameclient, and a refactor of the rendering of predicted characters.

There is also prediction for some new things, and some other changes:
- prediction of laser, shotgun, ninja, fng hammer, pickups and ddrace tiles (freeze/unfreeze tiles with cl_predict_freeze)
- laser and bullets are rendered when you fire them and bullets don't go through walls (when both cl_antiping_grenade and cl_antiping_weapons are enabled)
- antiping for flags
- prediction of dummy input
- an additional smoothing option that attempts to make antiping less jumpy (cl_antiping_smooth)

Co-authored-by: trml <trml@users.noreply.github.com>
Co-authored-by: trml <trml@noreply.github.com>
2019-04-23 17:11:21 +00:00
Learath 5d4461981a Fix solo bug 2019-04-23 19:46:51 +03:00
Learath 67668d7fb2 Use freeze end tick instead of a flag. Fix #1659 2019-04-23 18:57:26 +03:00
bors[bot] 34542e64b5 Merge #1655
1655: Add delete projectiles on death settings r=def- a=12pm

Need this for a map fix and doesn't hurt to have for grenades too I guess. Defaults are still the same

Co-authored-by: 12pm <30786226+12pm@users.noreply.github.com>
2019-04-23 14:43:23 +00:00
12pm a83e3e0d9a Add delete projectiles on death settings 2019-04-21 20:17:41 +02:00
trml 0b3f3b03b5 Rewrite of prediction code, with additional prediction 2019-04-21 16:12:20 +02:00
Ryozuki 7d4fdb3322
update the core server-side 2019-04-21 15:16:28 +02:00
Ryozuki 6bfdad9771
fix super and solo 2019-04-21 14:57:45 +02:00
Ryozuki eaef31d4a0
fix wording and add/fix no col and no hook 2019-04-19 11:59:09 +02:00
Ryozuki 0f3411f8fa
fix wording 2019-04-19 11:46:54 +02:00
Ryozuki f37f8a8268
add all character flags to ddnetnetwork character 2019-04-19 11:17:28 +02:00
bors[bot] bbf485a9ac Merge #1628
1628: Make client know about other solo players, fixes #258 r=heinrich5991 a=Ryozuki

When another player is in solo and you are not, you could notice a weird collision and also the hook moving a little towards the solo player. This as been fixed.

It also applies m_ClShowOthersAlpha to other players whenever you are on solo or others are.

It uses the protocol extension thingy.

fixes #258 

Co-authored-by: Ryozuki <ryo@ryozuki.xyz>
Co-authored-by: Learath <learath2@gmail.com>
2019-04-18 23:03:52 +00:00
12pm 997e01bf31 Fix mute typo 2019-04-18 20:54:22 +02:00
Learath d6bfef2cc0 Use a NetObj instead of a system message 2019-04-17 23:47:32 +02:00
Dennis Felsing 6e74d9d728 remove debugging 2019-04-17 14:12:35 +02:00
Dennis Felsing b425495f45 Fix draggers 2019-04-17 12:58:53 +02:00
def 9dddb290dd File score: Implement negative top5 (fixes #1631) 2019-04-15 18:55:33 +02:00
Dennis Felsing aad18ebb86
Merge pull request #1624 from ChillerDragon/pr_refactor_mute
Refactor mute and vote mute code
2019-04-13 17:52:55 +02:00
ChillerDragon deaab4bb4b Add functions instead of goto 2019-04-12 19:50:02 +02:00
Ryozuki c686ceea53
Merge branch 'master' into pr_fix_solo 2019-04-12 16:34:43 +02:00
Ryozuki 3556830b9a
fix solo prediction 2019-04-12 16:29:13 +02:00
Ryozuki 7e43120b6e
make the client aware of other players solo status 2019-04-12 16:16:21 +02:00
bors[bot] 826a7781ae Merge #1621
1621: Actually enable -Wuseless-cast r=heinrich5991 a=def-

It's not supported in C and we only checked using a C compiler.

Co-authored-by: Dennis Felsing <dennis@felsin9.de>
2019-04-12 00:08:19 +00:00
ChillerDragon a6d00973e1 Refactor mute and vote mute code 2019-04-11 20:10:04 +02:00
Dennis Felsing cde07b420b Implement changes suggested by -Wuseless-cast
But don't enable it yet because I'm not sure what the best way is.
2019-04-11 19:54:43 +02:00
bors[bot] cde3781184 Merge #1616
1616: Minor CFileScore improvements r=heinrich5991 a=def-

It's written using STL strings and files intead of using system. Didn't change any of that because of the risk of breaking something unintentionally.

Co-authored-by: def <dennis@felsin9.de>
2019-04-11 09:41:01 +00:00
def 0a286b1d94 File score: report file opening errors 2019-04-11 08:15:14 +02:00
fokkonaut 15658b3b10
removed brackets 2019-04-10 22:13:10 +02:00
def 279d6e60ca No duplicate () on rank 2019-04-10 22:05:44 +02:00
fokkonaut b92607eb7d
fix no score when joining when using file based score 2019-04-10 21:40:31 +02:00
Dennis Felsing ed34dcfec5
Merge pull request #1602 from def-/pr-explain-tiles
Explain game tiles and entities in editor (fixes #1600)
2019-04-10 17:38:22 +02:00
bors[bot] b05b268a6a Merge #1598 #1601 #1605 #1606 #1607 #1609
1598: Fix home/end keys in console r=heinrich5991 a=def-



1601: 2 more tries to force DB to respond in UTF8 (fixes #1599) r=heinrich5991 a=def-



1605: Fix memory leak in draggers r=heinrich5991 a=def-



1606: Always initialize m_InfosLoaded r=heinrich5991 a=def-

otherwise it's uninitialized and then read, found by valgrind --tool=memcheck

1607: Enable a few more GCC warnings r=heinrich5991 a=def-



1609: Fix C90 compatibility on Windows r=heinrich5991 a=def-



Co-authored-by: def <dennis@felsin9.de>
2019-04-09 22:09:18 +00:00
def 708019c675 Grammar fix: Catched -> Caught 2019-04-08 21:54:33 +02:00
def 173b43d487 Fix memory leak in draggers 2019-04-08 21:54:12 +02:00
12pm 7b95d38bf3 Fix crash when draggers don't have a number 2019-04-08 21:47:22 +02:00
def eda16acbca Explain game tiles and entities in editor (fixes #1600)
- Explanations by Lady Saavik taken from https://ddnet.tw/explain/
- CCW/CW were mixed up in enum names, fixed
- Make sure that the texts fits, otherwise reduce font size
- Still need explanations for Portal tiles
2019-04-08 19:39:56 +02:00
Ryozuki be708d0498
a mess 2019-04-07 21:18:43 +02:00
Ryozuki 813c24bf29
add m_IsSolo and fix hook col 2019-04-07 18:58:49 +02:00
bors[bot] 4931d00201 Merge #1589
1589: Remove some code duplication in CSaveTee::LoadString r=def- a=def-

by using a switch-case with fallthroughs, seems like the perfect use case.

Co-authored-by: def <dennis@felsin9.de>
2019-04-07 12:01:59 +00:00
bors[bot] 5d9d0d7d35 Merge #1587
1587: Small fixxings r=heinrich5991 a=ChillerDragon



Co-authored-by: ChillerDragon <chillerdragon@gmail.com>
2019-04-06 21:08:40 +00:00
def e27679ebcc Remove some code duplication in CSaveTee::LoadString
by using a switch-case with fallthroughs
2019-04-06 20:28:47 +02:00
Ryozuki 52b58c3d5b
final fix 2019-04-06 18:38:25 +02:00
Ryozuki 69fd7f1767
fix and add gameuuid 2019-04-06 18:37:25 +02:00
Ryozuki fb398ebcbf
better this way 2019-04-06 18:19:56 +02:00
Ryozuki beeda4d7bb
fix warnings 2019-04-06 18:18:46 +02:00
Ryozuki b92b2f1878
save telegun on /save 2019-04-06 18:13:11 +02:00
ChillerDragon 905204781b Cleanup if nesting 2019-04-06 17:22:15 +02:00
12pm a7ef921e3f Add playerflags, dnsbl, and ips for non-admins in status 2019-04-03 15:07:05 +02:00
def ef0e685496 Make timestamp consistent in scores
The motivation is to have the exact same timestamp for every member
finishing in a team and the team rank as well. This makes the database
more consistent and tooling easier.
2019-04-02 20:18:40 +02:00
Dennis Felsing 2dd78b6568 Command completion for /times, /points and /top5points
Still not implemented for file based servers of course
2019-03-29 14:39:48 +01:00
Dennis Felsing d12ad9d05f
Merge pull request #1548 from def-/pr-vote-mute
Remove vote mute after it expired (fixes #1544)
2019-03-28 23:38:45 +01:00
def 09412f43f7 Remove vote mute after it expired (fixes #1544) 2019-03-28 23:35:51 +01:00
def c489fb61be After a char was killed stop processing further tiles 2019-03-28 23:29:34 +01:00
12pm 34c99f5944 Don't enforce own votes when moderating
It's counterintuitive, and hence way too risky
2019-03-21 02:57:22 +01:00
Dennis Felsing 1add4a0819 Only print team join message when not in team already (fixes #1524) 2019-03-20 14:01:32 +01:00
def 1e4890c499 More error checking in system.c (fixes #1317) 2019-03-19 23:16:29 +01:00
Ryozuki 6ed3276d20
fix formatting 2019-03-19 20:32:01 +01:00
Ryozuki e00e9f126a
add vote_mutes 2019-03-19 20:25:21 +01:00
Ryozuki 43a1990e5d
ConVoteUnMute -> ConVoteUnmute 2019-03-19 20:18:11 +01:00
Ryozuki d469654629
add vote_unmute and display on chat 2019-03-19 20:07:33 +01:00
12pm 679628c4eb Exclude current map on random map votes 2019-03-18 15:10:27 +01:00
bors[bot] d8e8a21a30 Merge #1469
1469: Don't use strtok. Close #1468 r=heinrich5991 a=Learath2

^

Co-authored-by: Learath <learath2@gmail.com>
2019-03-11 11:56:26 +00:00
bors[bot] 26dc51a272 Merge #1466
1466: Add colors for authed players. Deprecates #1299 r=def- a=Learath2

Not sure if a snap item is the best idea for this but it should help with not sending the data more then needed and keeping it properly updated. The colors aren't great now but we can fix that easily.

![image](https://user-images.githubusercontent.com/490500/53680889-607bf780-3cf2-11e9-84a0-579160e9e170.png)


Co-authored-by: Learath <learath2@gmail.com>
2019-03-06 13:44:28 +00:00
Learath c4af290df5 Don't use strtok. Close #1468 2019-03-05 12:46:29 +03:00
Learath 548e9969b2 Add colors for authed players. Deprecates #1299 2019-03-02 13:50:33 +03:00
def afa1e8adc5 Uninvite kicked/spectated players from team (fixed #1464) 2019-03-01 22:11:00 +01:00
def 887d1c8401 Simplify some server messages 2019-02-27 19:46:01 +01:00
bors[bot] dfa16e37ba Merge #1462
1462: Remove empty else branch r=def- a=ChillerDragon



Co-authored-by: ChillerDragon <chillerdragon@gmail.com>
2019-02-25 19:21:04 +00:00
ChillerDragon a34d9633ad Remove empty else branch 2019-02-25 20:16:05 +01:00
def 21a938d983 Update credits 2019-02-15 11:10:44 +01:00
def 374529b452 Update credits 2019-02-15 10:59:34 +01:00
Dennis Felsing 6f3d261b73
Merge pull request #1441 from trml/pr_sync_weapon_input
Sync weapon input with other input
2019-02-14 10:27:52 +01:00
Dennis Felsing 698a3f1c5a
Merge pull request #1443 from ChillerDragon/AutobanKnownBots
Add autoban depending on client version
2019-02-13 12:04:51 +01:00
trml b9f301018f Remove nesting 2019-02-11 22:25:51 +01:00
Learath 109983da21 Remove use of strtok 2019-02-11 18:53:30 +01:00
Learath 0086452757 Use str_in_list, generalize further 2019-02-11 18:52:40 +01:00
bors[bot] ea6f76b383 Merge #1438 #1447 #1448
1438: Add man pages with asciidoc r=def- a=Ryozuki

Fixes #1240 

I added a simple script to generate the man pages.

To edit the man pages in the future, you must edit the `.adoc` files and then run generate.sh

You need asciidoc package to generate the manpages.

`sudo apt install asciidoc`

http://asciidoc.org/

Writing plain troff is a pain in the ass.

1447: Allow vote-kicking players with same auth level r=def- a=12pm

This is meant to help with dealing with trolls on test server since everyone can log into rcon there.
Shouldn't cause any problems anywhere else, I think.

1448: Require sv_vote_kick_min only on team 0 kick votes r=def- a=12pm



Co-authored-by: Ryozuki <ryo@ryozuki.xyz>
Co-authored-by: 12pm <30786226+12pm@users.noreply.github.com>
2019-02-10 10:23:08 +00:00
12pm f2cbb9d87d Make teleporting to where you look at convenient 2019-02-09 19:32:45 +01:00
12pm 1cf73b3eec Abort votes only if auth level is higher 2019-02-08 19:43:07 +01:00
12pm 10e4fcc185 Require sv_vote_kick_min only on team 0 kick votes 2019-02-08 18:44:11 +01:00
12pm 4b1651f18c Allow vote-kicking players with same auth level 2019-02-08 16:57:39 +01:00
ChillerDragon c0157db98d Neutral kick reason 2019-02-06 14:53:22 +01:00
ChillerDragon eaf61b662d Never ban known bots 2019-02-06 14:49:41 +01:00
ChillerDragon 3f8e9613f7 Fix style 2019-02-06 13:06:28 +01:00
ChillerDragon f5b551adee Fix empty string check (ty Travis) 2019-02-04 23:33:25 +01:00
ChillerDragon 8ddb487e2b Use consisten seperators (comma not semicolons) 2019-02-04 23:12:05 +01:00
ChillerDragon 03a20d6406 Add IServer::Ban 2019-02-04 23:09:14 +01:00
ChillerDragon 867b0a66ce Fixings thanks to @Learath2 2019-02-04 22:16:09 +01:00
ChillerDragon 069b1763dd Add autoban depending on client version 2019-02-04 20:46:42 +01:00
trml 3f9d30af0f Sync weapon input with other inputs 2019-01-29 20:58:25 +01:00
12pm 3d01e59878 Fix switch_open description 2019-01-27 20:09:33 +01:00
def 22ea30a7f5 Fix crash 2019-01-10 21:11:23 +01:00
def f5e8b9d822 Fix potential inconsistencies in rank/teamrank 2019-01-10 09:32:23 +01:00
def 7f8b1ecf21 Fix saves sql insert format for file fallback 2018-12-30 00:31:29 +01:00