Commit graph

12421 commits

Author SHA1 Message Date
bors[bot] daef3d6c98
Merge #3694
3694: Fix automapper crash (fixes #3675) r=Learath2 a=def-

Thanks to bojidar-bg for the way to fix, verified locally

<!-- What is the motivation for the changes of this pull request -->

## Checklist

- [x] Tested the change ingame
- [ ] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: def <dennis@felsin9.de>
2021-03-20 16:31:58 +00:00
Kyle Bradley 23c36e637f Reverted test config 2021-03-20 18:09:43 +02:00
Kyle Bradley decaeb8934 PR feedback:
- Changed names of variables
- Changed config descriptions
- Fix for perma timeout
2021-03-20 18:08:54 +02:00
bors[bot] 73be12c39c
Merge #3724
3724: Actually check all tees. Fixes #3697 r=heinrich5991 a=Learath2

<!-- What is the motivation for the changes of this pull request -->
Seems this was broken since the beginning, I wonder how we missed this one :)


## Checklist

- [ ] Tested the change ingame
- [ ] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [x] Considered possible null pointers and out of bounds array indexing
- [x] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: Learath2 <learath2@gmail.com>
2021-03-20 16:03:47 +00:00
Learath2 a3dd47d7e8 Actually check all tees. Fixes #3697 2021-03-20 15:45:11 +01:00
bors[bot] e668039407
Merge #3719
3719: Banned for life -> Banned r=heinrich5991 a=def-

Since we mostly use them for limited global bans

<!-- What is the motivation for the changes of this pull request -->

## Checklist

- [ ] Tested the change ingame
- [ ] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: def <dennis@felsin9.de>
2021-03-19 17:24:00 +00:00
def ae34e2df6f Banned for life -> Banned
Since we mostly use them for limited global bans
2021-03-19 15:02:28 +01:00
def ac6ae40806 No negative count in server browser
With "Count playery only" and "Filter connecting players" both activated
2021-03-19 11:46:02 +01:00
bors[bot] b35e8f880c
Merge #3715
3715: Add dummy_reset and remove +resetdummy r=def- a=ardadem

<!-- What is the motivation for the changes of this pull request -->

It's works now for both on console/cfg and as bind. Also tried to fix annoying dummy hammer issue when reset dummy

## Checklist

- [X] Tested the change ingame
- [ ] Provided screenshots if it is a visual change
- [X] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: Arda Demir <ddmirarda@gmail.com>
2021-03-19 08:18:01 +00:00
bors[bot] 689a72c0ed
Merge #3717
3717: Editor: only externalize images with vanilla names r=def- a=Patiga

<!-- What is the motivation for the changes of this pull request -->
All external images should be vanilla images, since other images can't be loaded by other clients.
Also:
- all external images should be allowed to be embedded (for example for 0.7 compatibility)
- only embedded vanilla images should be allowed to become embedded again

This change focuses on enforcing those basic rules. Vanilla images are identified using only their name, this method was used to sort images into embedded/external upon adding them.

The only real change is that the editor will now only allow making an image external if it has a vanilla name.

The motivation of this change are:
- a few times I was sent maps I couldn't load properly because the mapper accidentally made some images external
- there are some DDNet maps with external images that are not vanilla images

## Checklist

- [x] Tested the change ingame
- [ ] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [x] Considered possible null pointers and out of bounds array indexing
- [x] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: Patiga <dev@patiga.eu>
2021-03-19 08:04:04 +00:00
Patiga 55117fcfaa Externalize only images with vanilla names 2021-03-19 01:06:37 +01:00
Kyle Bradley 6c9cbee41c Merge branch 'feature-swap' of https://github.com/houseme-kyle/ddnet into feature-swap 2021-03-17 21:23:52 +02:00
Kyle Bradley a68b28fc14 Further tests and edge cases dealt with 2021-03-17 21:23:41 +02:00
def 61b3a7c554 Fix clang-format
By using clang-format-10 from AUR clang-format-static package
2021-03-17 20:19:35 +01:00
Kyle Bradley 2d4834ffcf Edge case for player state when changing team 2021-03-17 20:51:52 +02:00
houseme-kyle e11345807f
Merge pull request #5 from ddnet/master
Merge
2021-03-17 19:07:18 +02:00
Arda Demir 2aefdf2a5e Add dummy_reset and remove +resetdummy 2021-03-17 18:09:39 +03:00
Kyle Bradley 1a35e3be12 Removed comments and added variable reset 2021-03-17 00:48:24 +02:00
Kyle Bradley 73aea2426b Style fixes 2021-03-17 00:33:48 +02:00
Kyle Bradley 4afe62a596 Updated to include penalty, cooldown and timeout 2021-03-17 00:31:16 +02:00
bors[bot] af935dcb47
Merge #3713
3713: Retry hdiutil create if it fails (fixes #3711) r=heinrich5991 a=def-

<!-- What is the motivation for the changes of this pull request -->

## Checklist

- [ ] Tested the change ingame
- [ ] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: def <dennis@felsin9.de>
2021-03-16 17:15:18 +00:00
def 8fc1fe3811 Retry hdiutil create if it fails (fixes #3711) 2021-03-16 17:56:36 +01:00
def a4bb2f8764 Switch back to using a stable sort
so that for example demos stay sorted the same way when sorting by demo
markers and removing a demo, otherwise they get totally reordered every
time.

as reported by Shyzo
2021-03-15 23:36:25 +01:00
bors[bot] 34e523e5e4
Merge #3708
3708: Updates to /top and /rank r=def- a=houseme-kyle

**/top**
Updated /top to always show the global 5. Also, show the region's top 3 if no local users are represented.

- The same information from the previous /top5 is displayed keeping consistency. Extra information is displayed only when relevant. 
- Regional top will be displayed even less often now that it takes the top 5 entries into consideration - before it was the top 3. 
![image](https://user-images.githubusercontent.com/25198124/111163123-7f7e1700-85a5-11eb-9ed5-815882b18db5.png)
![image](https://user-images.githubusercontent.com/25198124/111163145-87d65200-85a5-11eb-9502-c8aaabcdc22d.png)

**/rank**
Suggestions were made to update the format of /rank. The one with the most consensus was the below.
![rank](https://user-images.githubusercontent.com/25198124/111163322-af2d1f00-85a5-11eb-9f56-5503c3af3649.JPG)

## Checklist
- [x] Tested the change ingame
- [x] Provided screenshots if it is a visual change
- [x] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: houseme-kyle <kyle@houseme.co.za>
Co-authored-by: Kyle Bradley <kyle@house.me>
2021-03-15 13:50:07 +00:00
Kyle Bradley 0b6da7ece1 Applied community feedback.
- Always show global /top5
2021-03-15 15:38:53 +02:00
houseme-kyle 570bb541d3
Merge pull request #4 from ddnet/master
Merge
2021-03-15 15:12:01 +02:00
def 9f58b0f608 Set search field active when opening vote menu ingame
As suggested by RafaelFF
2021-03-14 19:57:23 +01:00
bors[bot] 30d3aedc19
Merge #3701
3701: Center tees in more places r=def- a=Jupeyy

tee settings
scoreboard
spectator board

## Checklist

- [x] Tested the change ingame
- [ ] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2021-03-12 22:04:26 +00:00
Jupeyy 331ee9aa56 Center tees in more places 2021-03-12 21:23:29 +01:00
def 5350f98e8d Fix automapper crash (fixes #3675)
Thanks to bojidar-bg for the way to fix, verified locally
2021-03-11 20:31:45 +01:00
bors[bot] 9b17e52d5b
Merge #3693
3693: Rank not sending r=def- a=houseme-kyle

- Fixes the message for loop not sending all messages
- Still calls SpamProtection method for each message to count towards users spam chat score
*** If the above isn't relevant, then the spam check can move outside the for loop
- Tested with normal and a muted user

![image](https://user-images.githubusercontent.com/25198124/110751526-a3132b80-824c-11eb-9a9a-6ac507bb87b4.png)
![image](https://user-images.githubusercontent.com/25198124/110751829-14eb7500-824d-11eb-9f23-3aca11af428b.png)

## Checklist

- [x] Tested the change ingame
- [x] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: houseme-kyle <kyle@houseme.co.za>
Co-authored-by: Kyle Bradley <kyle@house.me>
2021-03-11 07:58:51 +00:00
Kyle Bradley 6ed2b2277d Added break on primary message while still processing subsequent 2021-03-11 09:20:26 +02:00
houseme-kyle 877bd9afbd
Merge pull request #3 from ddnet/master
Merge
2021-03-11 08:48:56 +02:00
bors[bot] 5e4f5f15b7
Merge #3692
3692: Don't bypass the anti-spam system r=def- a=heinrich5991

Quick-fix for
https://github.com/ddnet/ddnet/pull/3669#issuecomment-794805243.

Probably breaks that feature a bit.

<!-- What is the motivation for the changes of this pull request -->

## Checklist

- [ ] Tested the change ingame
- [ ] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2021-03-10 22:05:19 +00:00
heinrich5991 f694dd68e9 Don't bypass the anti-spam system
Quick-fix for
https://github.com/ddnet/ddnet/pull/3669#issuecomment-794805243.

Probably breaks that feature a bit.
2021-03-10 21:50:56 +01:00
bors[bot] 46864c0e08
Merge #3683 #3684
3683: More colors from components in console r=heinrich5991 a=Jupeyy


![screenshot_2021-03-08_01-18-23](https://user-images.githubusercontent.com/6654924/110260454-9d97b600-7fac-11eb-9437-e5b31c9146ab.png)

dunno how to trigger that echo chat, but rest looks fine i think

## Checklist

- [x] Tested the change ingame
- [x] Provided screenshots if it is a visual change
- [x] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


3684: Increase max ban duration from 1 month to 1 year r=heinrich5991 a=def-

to show ban message more accurately when player gets globally banned

<!-- What is the motivation for the changes of this pull request -->

## Checklist

- [ ] Tested the change ingame
- [ ] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: Jupeyy <jupjopjap@gmail.com>
Co-authored-by: def <dennis@felsin9.de>
2021-03-09 21:41:23 +00:00
bors[bot] 01dd157995
Merge #3687
3687: Free Client.m_PersistentData r=heinrich5991 a=def-

Caused by https://github.com/ddnet/ddnet/pull/3605

Found by ASAN:
```
==11628==ERROR: LeakSanitizer: detected memory leaks

Direct leak of 64 byte(s) in 64 object(s) allocated from:
    #0 0x4f36b3 in __interceptor_malloc (/home/teeworlds/servers/DDNet-Server-asan+0x4f36b3)
    #1 0x5536a7 in CServer::Run() /home/teeworlds/src/master/src/engine/server/server.cpp:2362:31
    #2 0x562408 in main /home/teeworlds/src/master/src/engine/server/server.cpp:3594:21
    #3 0x7f6ee56d209a in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x2409a)
```
<!-- What is the motivation for the changes of this pull request -->

## Checklist

- [ ] Tested the change ingame
- [ ] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: def <dennis@felsin9.de>
2021-03-09 21:30:49 +00:00
bors[bot] d721e8ff2d
Merge #3690
3690: Update to /top feature r=def- a=houseme-kyle

Feedback from the community. It will hide the local ranks if there are any duplicates so the larger communities, who were previously disadvantaged by the change aren't anymore. 

Added an extra rank to the global list seeing that it is still smaller than the combined

![image](https://user-images.githubusercontent.com/25198124/110504260-a8b22980-8105-11eb-9d76-21cf5b7672cc.png)

![image](https://user-images.githubusercontent.com/25198124/110504302-b23b9180-8105-11eb-947a-2de2c3f1851a.png)

## Checklist

- [x] Tested the change ingame
- [x] Provided screenshots if it is a visual change
- [x] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: houseme-kyle <kyle@houseme.co.za>
Co-authored-by: Kyle Bradley <kyle@house.me>
2021-03-09 18:13:18 +00:00
Kyle Bradley c79f874c54 Removd unusual characters and added a base dash to mirror previous implementation 2021-03-09 18:41:48 +02:00
Kyle Bradley 0a183673c5 Hide local when there are duplicates 2021-03-09 18:27:25 +02:00
houseme-kyle 25bb82c3bd
Merge pull request #2 from ddnet/master
Merged Master
2021-03-09 17:39:48 +02:00
def 5261764fb0 Free Client.m_PersistentData
Caused by https://github.com/ddnet/ddnet/pull/3605

Found by ASAN:

==11628==ERROR: LeakSanitizer: detected memory leaks

Direct leak of 64 byte(s) in 64 object(s) allocated from:
    #0 0x4f36b3 in __interceptor_malloc (/home/teeworlds/servers/DDNet-Server-asan+0x4f36b3)
    #1 0x5536a7 in CServer::Run() /home/teeworlds/src/master/src/engine/server/server.cpp:2362:31
    #2 0x562408 in main /home/teeworlds/src/master/src/engine/server/server.cpp:3594:21
    #3 0x7f6ee56d209a in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x2409a)
2021-03-09 11:44:20 +01:00
bors[bot] e2cb24b7d9
Merge #3669
3669: Local ranking info viewable in-game r=def- a=houseme-kyle

The feature is based on the issue below:
https://github.com/ddnet/ddnet/issues/3655

The main concern was the impact it would have if we had to double our ranking/point commands to support it. I took the feedback into account and combined the info into one command. The PR is in draft as I don't want to implement it for the remaining commands before getting thoughts on the approach taken.

**Feature**
Display local stats alongside global while using the same commands

**Implementation**
- /rank, /top5 etc to display their local position alongside global. 
- Top 5 changed to top 3 due to space limitations
- Message limit increased by 1
- Don't show "requested by" when the request was made by the same individual

**Reason for feature**
- Foster growth in the smaller communities as they compete amongst each other in their own leaderboard
- The names become more relevant to all communities as they can better relate to the names displayed 

**TODO**
~- Tested with production sqlite data but not MySQL storage~
~- Expand concept to other relevant ranking commands~

(Example of NovaShock who is the top player in South Africa)
![image](https://user-images.githubusercontent.com/25198124/109824890-f03a4080-7c41-11eb-84dc-ad319cb98f1e.png)
![image](https://user-images.githubusercontent.com/25198124/109824910-f6302180-7c41-11eb-9013-f3254c08f068.png)

## Checklist

- [x] Tested the change ingame
- [x] Provided screenshots if it is a visual change
- [x] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: houseme-kyle <kyle@houseme.co.za>
Co-authored-by: Kyle Bradley <kyle@house.me>
Co-authored-by: = <=>
2021-03-08 22:51:05 +00:00
Jupeyy af2e19c4e7 Add color for non chat(binds, ghost, client, demo) 2021-03-08 18:39:25 +01:00
def 271ab5f9de Increase max ban duration from 1 month to 1 year
to show ban message more accurately when player gets globally banned
2021-03-08 18:15:00 +01:00
Kyle Bradley b1e200df88 Formatted player.cpp using ClangFormat 2021-03-08 15:56:20 +02:00
Kyle Bradley 8957005f48 Kept rank spam protection 2021-03-08 15:33:26 +02:00
Kyle Bradley ecf70319fc Fixed formatting issues 2021-03-08 14:53:35 +02:00
Jupeyy 853e00ed15 More colors from chat in console 2021-03-08 01:20:28 +01:00
bors[bot] 75e9b20e45
Merge #3680
3680: Fix legacy serverinfo with reserved slots and num_players > 15 (fixes #3678) r=heinrich5991 a=def-

<!-- What is the motivation for the changes of this pull request -->

## Checklist

- [ ] Tested the change ingame
- [ ] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [ ] Written a unit test if it works standalone, system.c especially
- [ ] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [ ] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


Co-authored-by: def <dennis@felsin9.de>
2021-03-07 23:49:17 +00:00