Commit graph

7571 commits

Author SHA1 Message Date
bors[bot] 1ac07fe797
Merge #3626
3626: Rename save/load to conform to the code style r=def- a=Zwelf

Small cleanup

## 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: Zwelf <zwelf@strct.cc>
2021-02-16 22:47:32 +00:00
def 670f318779 Don't toggle Destructive in editor when pressing ctrl-shift-d
As reported by texnonik on Discord
2021-02-16 22:26:58 +01:00
Zwelf 9daf1274a4 Rename save/load to conform to the code style 2021-02-16 18:15:50 +01:00
Zwelf c59c41bd3f Inform player while loading when save exists, but they don't belong to the team 2021-02-16 17:54:13 +01:00
Jupeyy 00e22d8d14 Fix chat refind skins 2021-02-15 15:15:21 +01:00
bors[bot] 55a8293e7e
Merge #3608
3608: Fix crash on autoban unsupported client r=heinrich5991 a=fokkonaut

I moved the check where it returns to after the join message because if a client uses the new CLIENTVER system it would just drop without even a join message, looks weird if the chat only shows a player leaving, but not joining :D

## 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: fokkonaut <35420825+fokkonaut@users.noreply.github.com>
2021-02-12 19:04:00 +00:00
bors[bot] 2b29a9a0c8
Merge #3610
3610: Fix top time not being displayed on old servers r=def- a=heinrich5991

Fix #3599.

(Forgot to check for both NETMSG_RECORD and NETMSG_RECORDLEGACY in one
place.)

## 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: heinrich5991 <heinrich5991@gmail.com>
2021-02-11 23:49:20 +00:00
heinrich5991 f199b5101f Change record message to record@netmsg.ddnet.tw
Now that I understand that the message is still in use, rename it from
`weird-record@netmsg.ddnet.tw`.
2021-02-12 00:31:51 +01:00
heinrich5991 e1448bebc7 Fix top time not being displayed on old servers
Fix #3599.

(Forgot to check for both NETMSG_RECORD and NETMSG_RECORDLEGACY in one
place.)
2021-02-11 23:33:50 +01:00
fokkonaut c79bb91b16 Fix crash on autoban unsupported client 2021-02-11 12:51:56 +01:00
def 2a87814d84 Version 15.3 2021-02-11 10:45:20 +01:00
def 28eb4b15af Remove gfx_show_warnings 2021-02-10 23:02:34 +01:00
trml e6de475a72 Don't predict other teams 2021-02-07 23:27:45 +01:00
def c28d949f0c Improve performane of /top5points query
Thanks to Learath2

Also remove negative /top5points since it makes no sense anyway
2021-02-02 00:15:56 +01:00
def 15220d4545 Fix button presses after esc after color picker usage (fixes# 3575) 2021-02-01 23:49:44 +01:00
bors[bot] ed9abba485
Merge #3586 #3587
3586: Disallow some more switch entities r=heinrich5991 a=def-

As reported by ReD

<!-- 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)


3587: Fix color picker positioning (fixes #3574) r=heinrich5991 a=def-

![screenshot-20210201@193418](https://user-images.githubusercontent.com/2335377/106502369-93256080-64c4-11eb-832f-6c2318d63e87.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
- [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: def <dennis@felsin9.de>
2021-02-01 20:49:35 +00:00
def 5e4481d9cc Fix color picker positioning (fixes #3574) 2021-02-01 19:34:41 +01:00
def 75a2ca613e Disallow some more switch entities
As reported by ReD
2021-02-01 15:01:46 +01:00
def 6f2c82c0d4 SUBSTRACT -> SUBTRACT 2021-02-01 14:55:26 +01:00
heinrich5991 18bb0ed92c Fix /pause not working
Caused by a logic error in a comparison, comparing a client ID with a
DDNet version.

Fixes #3578.
2021-02-01 00:58:09 +01:00
bors[bot] e2c7c81c55
Merge #3572
3572: Fix sizing in graphics menu r=heinrich5991 a=def-

As reported by louis
![screenshot-20210131@202748](https://user-images.githubusercontent.com/2335377/106395490-cc959780-6402-11eb-8217-77c026ce2b4f.png)

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

## 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: def <dennis@felsin9.de>
2021-01-31 22:17:25 +00:00
def f49e8b060d DDnet -> DDNet
As reported by Ravie
2021-01-31 20:29:43 +01:00
def 32f7a7979e Fix sizing in graphics menu
As reported by louis
2021-01-31 20:27:10 +01:00
bors[bot] 8be462af26
Merge #3557
3557: Log duplicate messages in console r=edg-l a=def-

As reported by fokkonaut

<!-- 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
- [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: def <dennis@felsin9.de>
2021-01-31 14:55:45 +00:00
bors[bot] 2b5723cdef
Merge #3492 #3559 #3561 #3565
3492: Support F-Client and replace non-extended extension messages r=Learath2 a=heinrich5991

This continues what #3439 started, and also replaces non-extended messages that are DDRace extensions with extended messages. The DDNet server still sends the old message to old clients and the DDNet client still understands the old messages.

Supersedes #3439.

## 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)


3559: Don't highlight us if we have no name (alternative fix for #3554) r=heinrich5991 a=def-

<!-- 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
- [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)


3561: Fix input message position in teehistorian files r=heinrich5991 a=Zwelf

Previously the message was recorded when incoming. But the time when the input should apply wasn't recorded. Now inputs are recorded right before they get applied in the game world.

And record exact tick where load/save result is returned.

## 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)


3565: Add Arabic language translation by .Yukki r=heinrich5991 a=def-

![screenshot-20210131@093216](https://user-images.githubusercontent.com/2335377/106378755-747d7780-63a7-11eb-9553-6a1898907441.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
- [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: fokkonaut <35420825+fokkonaut@users.noreply.github.com>
Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
Co-authored-by: def <dennis@felsin9.de>
Co-authored-by: Zwelf <zwelf@strct.cc>
2021-01-31 14:37:48 +00:00
Zwelf 80df59ba5a Clarify teehistorian code 2021-01-28 23:42:01 +01:00
Zwelf 04e8ce56a9 Record exact tick where load/save result is returned 2021-01-28 22:50:15 +01:00
Zwelf cd407a08a8 Fix teehistorian PLAYER_INPUT message position
Previously the message was recorded when incoming. But the time when the input
should apply wasn't recorded.
Now inputs are recorded right before they get applied in the game world.
2021-01-28 22:50:00 +01:00
Dennis Felsing 243f330e3c
Merge pull request #3550 from def-/pr-revert-freeze-rescue
Revert "rescue on freeze/dfreeze"
2021-01-28 18:53:07 +01:00
bors[bot] b08b93ee73
Merge #3556
3556: Don't highlight echo messages (fixes #3554) r=heinrich5991 a=def-

<!-- 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
- [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: def <dennis@felsin9.de>
2021-01-28 14:37:20 +00:00
def af8b306dfb Don't highlight us if we have no name 2021-01-28 15:36:30 +01:00
def 487bd18a39 Log duplicate messages in console
As reported by fokkonaut
2021-01-28 11:32:38 +01:00
def c30b596dab Don't highlight echo messages (fixes #3554) 2021-01-28 11:21:55 +01:00
def cbf5aa6e36 Reset filter: Refresh browser in DDNet/KoG tabs
so that countries/types is also updated
2021-01-27 19:24:10 +01:00
heinrich5991 43998ce41a Replace projectile hack with a new extended snapshot object
Still send the old hack to old clients, still accept the old hack from
old servers. This is so F-Client can support DDNet servers without such
hacks.
2021-01-26 20:58:42 +01:00
def f2cf038248 Revert "rescue on freeze/dfreeze"
This reverts commit 28cf3b31ba.
2021-01-26 14:44:01 +01:00
def e16dd5c1d2 HTTP Map Download: Time out faster
Since our maps2.ddnet.tw doesn't work well for players in China
2021-01-26 00:19:19 +01:00
bors[bot] a3ae016177
Merge #3531
3531: Add set_view camera position command r=heinrich5991 a=ChillerDragon

Allows to bind spectator camera positions. Can be used to write teleport binds for test server or quickly spectate specific spots of the map.

## 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
- [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: ChillerDragon <ChillerDragon@gmail.com>
2021-01-25 11:46:32 +00:00
bors[bot] aa43e329b6
Merge #3538
3538: Improve error messages when you can't join team r=heinrich5991 a=def-

<!-- 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
- [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: def <dennis@felsin9.de>
2021-01-25 11:35:39 +00:00
bors[bot] f5280919f1
Merge #3541
3541: rank/teamrank: Display how much better you are r=def- a=def-

![screenshot-20210123@231642](https://user-images.githubusercontent.com/2335377/105615509-8c666180-5dd1-11eb-94b4-a3f5d9131383.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
- [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: def <dennis@felsin9.de>
Co-authored-by: Zwelf <zwelf@strct.cc>
2021-01-24 17:34:07 +00:00
Zwelf 953ea87929 Use sql PERCENTAGE_RANK() window function 2021-01-24 16:41:43 +01:00
bors[bot] ab897f21f1
Merge #3539
3539: Inform player about possibility to keep the hook when loading r=def- a=Zwelf

Message is displayed when saving with an active hook

## 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
- [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: Zwelf <zwelf@strct.cc>
2021-01-24 14:50:43 +00:00
bors[bot] 319c382167
Merge #3343
3343: rescue on freeze/dfreeze (supersedes #3335) r=heinrich5991 a=def-

Fixed all the merges and clang-format (hopefully)

## 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: Vlad <gerdoexx@gmail.com>
2021-01-24 00:07:31 +00:00
def b28cdc933a rank/teamrank: Display how much better you are 2021-01-23 23:19:45 +01:00
ChillerDragon 9a3e8bb0a2 Add set_view camera position command 2021-01-23 17:36:35 +01:00
Zwelf a3702e8314 Inform player about possibility to keep the hook when loading
Message is displayed when saving with an active hook
2021-01-23 16:49:50 +01:00
bors[bot] a176990649
Merge #3537
3537: Fix condition for eye emote (fixes #3536) r=Learath2 a=def-

<!-- 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
- [x] 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: def <dennis@felsin9.de>
2021-01-23 14:53:00 +00:00
def d39a17933d Improve error messages when you can't join team 2021-01-23 15:52:57 +01:00
def 4eeb14d2f4 Fix condition for eye emote (fixes #3536) 2021-01-23 12:04:14 +01:00
bors[bot] 14e70506e1
Merge #3535
3535: Fix a possible race in load code  r=def- a=heinrich5991

Previously, a save could possibly be loaded twice given enough latency
discrepancy between servers. The server only verified that it deleted
*some* save with the given password, not *the* save it is trying to
load. This is fixed by also checking the SaveID column that is random
and globally unique (except for the old NULLs). Since users can't create
new saves with NULL SaveID, these pose no problem.

Also change the default UUID for saves without save ID to something
nonzero, so we can't accidentally hit it due to a bug.

## Checklist

- [x] Tested the change ingame
- [ ] Provided screenshots if it is a visual change
- [ ] Tested in combination with possibly related configuration options
- [x] 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: heinrich5991 <heinrich5991@gmail.com>
2021-01-23 10:14:32 +00:00
heinrich5991 7b0b1c4162 Fix a possible race in load code
Previously, a save could possibly be loaded twice given enough latency
discrepancy between servers. The server only verified that it deleted
*some* save with the given password, not *the* save it is trying to
load. This is fixed by also checking the SaveID column that is random
and globally unique (except for the old NULLs). Since users can't create
new saves with NULL SaveID, these pose no problem.

Also change the default UUID for saves without save ID to something
nonzero, so we can't accidentally hit it due to a bug.
2021-01-23 01:21:20 +01:00
heinrich5991 3539f2b183 Allow ParseUuid to report errors and add tests 2021-01-23 01:21:20 +01:00
def 9196a9a3d4 Fix crash on namechange (fixes #3444) 2021-01-22 19:17:21 +01:00
bors[bot] 93acedf00e
Merge #3523
3523: Handle switch number 0 r=heinrich5991 a=def-

Thanks to ReD for report

<!-- 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
- [x] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [x] 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-01-22 17:31:35 +00:00
bors[bot] 77a9f41268
Merge #3530
3530: Improve ClShowDistance a bit r=heinrich5991 a=def-

<!-- 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-01-22 17:16:37 +00:00
def 23c145d760 Improve ClShowDistance a bit 2021-01-21 17:07:07 +01:00
bors[bot] 5d927f35b6
Merge #3502
3502: Some (mostly backported) refactor r=Learath2 a=Kaffeine

Port some cleanup and refactoring from the upstream and add some custom refactoring.

Changes overview:
- Backported angle() and direction() functions (upstream commit 7735557aa5)
- Backported vector math cleanup (remove some pointless templates, refactor other functions; upstream commit bdaabc10bc)
- `ddracechat.h` (used by both client and server) moved to a shared dir next to `ddracecommands.h`
- Backport `IGameController::DoActivityCheck()`
- Backport `IGameController::DoTeamChange()`
- Backport `IGameController::OnPlayerDisconnect()`
- Refactor Emote-related code (decouple the code and hide the details in CPlayer class)
- Fix: restore default emote on the emote override ended over.
- CCharacter::HandleTiles(): Move a part of DDRace-specific code to the DDRace GameController
- Add `IGameController::GetMaskForPlayerWorldEvent()` to port classes away from direct `CGameControllerDDRace/CGameTeams` usage.

Result overview:
- CPlayer does not depend on CGameControllerDDRace nor CGameTeams anymore
- CCharacter does not depend on CGameControllerDDRace anymore

I'm not sure that `GetMaskForPlayerWorldEvent()` is a good name for that. The idea of the method is to abstract the users of `CreateExplosion`, `CreatePlayerSpawn`, `CreateDeath`, `CreateSound`, and other world events from thinking about the player team.

I checked that the client and server work (didn't do deep testing though).

## Checklist

- [x] Tested the change ingame
- Provided screenshots if it is a visual change (no visual changes)
- Tested in combination with possibly related configuration options (no related options)
- [ ] Written a unit test if it works standalone, system.c especially
- [x] 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: Alexander Akulich <akulichalexander@gmail.com>
Co-authored-by: BeaR <cinaera@web.de>
2021-01-21 10:56:38 +00:00
Zwelf 4375bc1ac6 Don't depend on table locking for savegame load/save synchronization 2021-01-20 21:42:44 +01:00
def cd8e67df66 Handle switch number 0
Thanks to ReD for report
2021-01-20 20:00:25 +01:00
Alexander Akulich c28bd693d3 CPlayer: Port to GetMaskForPlayerWorldEvent
The CPlayer class does not depend on CGameTeams anymore.
2021-01-19 22:36:23 +03:00
Alexander Akulich d2744d595a GameController: Introduce GetMaskForPlayerWorldEvent() 2021-01-19 22:36:23 +03:00
Alexander Akulich d536743dda DDRace GameController: Set Teams to CCharacter on Spawned
Since this commit, CCharacter does not directly depend on
CGameControllerDDRace anymore.
2021-01-19 22:36:22 +03:00
Alexander Akulich e0affc3f34 CCharacterCore: Join Init() methods 2021-01-19 22:36:09 +03:00
Alexander Akulich 33dc79d190 Character: Make the GameController set the Teleports info
CCharacter::HandleTiles() doesn't depend on the CGameControllerDDRace anymore.
2021-01-19 22:36:03 +03:00
trml 34d80e65c8 Don't predict input from the dummy when it is paused 2021-01-18 23:55:13 +01:00
bors[bot] 174eeab80d
Merge #3504
3504: Display median time instead of average (fixes #3399) r=heinrich5991 a=def-

Do we want average too or just median?

## 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
- [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: def <dennis@felsin9.de>
2021-01-17 16:40:50 +00:00
Alexander Akulich d5dbd94c66 CCharacter: Move Team-related tiles handling to the DDRace Controller 2021-01-16 03:20:58 +03:00
Alexander Akulich f7dfd8c9b9 CCharacter: Move start/finish tiles handling to the DDRace Controller 2021-01-16 03:20:58 +03:00
Alexander Akulich acfb541db9 DDrace GameController: Add GetPlayerTeam() 2021-01-16 03:20:58 +03:00
Alexander Akulich a14607f818 Introduce GameController::HandleCharacterTiles() 2021-01-16 03:20:58 +03:00
Alexander Akulich d924d9bf68 CCharacter: Extract ResetPickups() 2021-01-16 03:20:58 +03:00
Alexander Akulich 729262b896 GameController: Move the DDRace-specific code to the subclass
This leads to some small code duplication but let us remove the ugly casts.
2021-01-16 03:20:58 +03:00
Alexander Akulich 39938b6b2f Adjust the CGameControllerDDRace header file
- Reorder the methods as they're in the source file
- Move the member variables to the end (to later apply a special access-control)
- Mark Tick() override (we use C++11 and this is our own code)
2021-01-16 03:20:58 +03:00
Alexander Akulich cba66d96f2 CPlayer: Remove unused GameControllerDDRace include 2021-01-16 03:20:58 +03:00
Alexander Akulich 2191996254 CPlayer: Make the emote-related members private 2021-01-16 03:20:58 +03:00
Alexander Akulich 281186468f CPlayer: Correctly restore the default emote on override emote expired
We used to set EMOTE_NORMAL even on 'special' days ('events' config option).
2021-01-16 03:20:58 +03:00
Alexander Akulich f0e34c9c36 Move DefaultEmote logic into CPlayer 2021-01-16 03:20:58 +03:00
Alexander Akulich 4004fc093c CPlayer: Add missing reset for m_LastEyeEmote 2021-01-16 03:20:58 +03:00
Alexander Akulich 5a9af45f9a CPlayer: Rename EyeEmote to EyeEmoteEnabled (to be clear) 2021-01-16 03:20:58 +03:00
Alexander Akulich 2286771349 ConEyeEmote: Don't count the command if arguments not valid 2021-01-16 03:20:58 +03:00
Alexander Akulich 9197075654 Refactor the SetEmote code to remove custom CCharacter methods 2021-01-16 03:20:58 +03:00
Alexander Akulich b36a4fd8c3 Process CPlayer::m_DefEmoteReset in CPlayer 2021-01-16 03:20:58 +03:00
Alexander Akulich ecce5631ed Move Halloween emoticon to CPlayer and send it once per client
GameServer()->SendEmoticon() sends CNetMsg_Sv_Emoticon packet to everyone.

Calling SendEmoticon() from Character::Snap(ClientID) triggers as many
messages to everyone as there are active players.

Move the SendEmoticon() because it is not the Character (a world entity object)
responsibility to celebrate a day. Actually it is not CPlayer responsibility
either but CPlayer is the class where we deciding to celebrate (checking the
date) so at least let's keep the coupled stuff together.
2021-01-16 03:20:58 +03:00
Alexander Akulich 457f91ca8d CCharacter: Add GetLastAction() 2021-01-16 03:20:58 +03:00
Alexander Akulich 19234987c9 Backport IGameController::OnPlayerDisconnect() from the upstream
Upstream commit 5e4caa9b9c
2021-01-16 03:20:58 +03:00
Alexander Akulich 7512ad285b Backport IGameController::DoTeamChange from the upstream
Upstream commit 5e4caa9b9c
2021-01-16 03:20:58 +03:00
Alexander Akulich c4405c4811 GameController: Backport reorder from upstream
Upstream commit 5e4caa9b9c
2021-01-16 03:20:57 +03:00
Alexander Akulich e34f268bed Make CSaveTee and CPlayer not friends anymore 2021-01-16 03:20:57 +03:00
Alexander Akulich ffe3f110eb GameController: Extract DoActivityCheck()
Apply refactoring from the upstream.
2021-01-16 03:20:57 +03:00
Alexander Akulich 242aa63178 ddracechat.h is used by the client, so move it to src/game
where ddracecommands.h already is.
2021-01-16 03:20:57 +03:00
Alexander Akulich dfd60e6668 CGameContext: Remove ugly CGameControllerDDRace::m_Teams.Reset()
We called CGameControllerDDRace constructor on the previous line.
The CGameControllerDDRace invokes CGameTeams constructor which calls
Reset() on his own.

There is no chance how this can change anything.
2021-01-16 03:20:57 +03:00
Alexander Akulich 5d0bb4cf3c Backport vector functions cleanup from the upstream
Keep closest_point_on_line() as-is.

(commit 6b69f94dc8)
2021-01-16 03:20:57 +03:00
BeaR 9f0b0af862 Add angle<->direction conversion functions to vector math (Cleanup)
Keep angle() (ex. GetAngle()) as-is.

(cherry picked from commit 7735557aa5)
2021-01-16 03:20:57 +03:00
def 39d06c5e85 Display median time instead of average (fixes #3399) 2021-01-12 14:24:38 +01:00
def dccbf26ca0 Differentiate hook symbol 2021-01-12 10:22:39 +01:00
heinrich5991 9784726683 Replace remaining non-extended extension messages
Add backward compatibility stuff, but this allows newer clients to only
care for new messages.
2021-01-12 01:48:10 +01:00
heinrich5991 0d916e2ef6 Remove F-Client-specific messages
The PLAYERFLAG_AIM can now be set directly on DDNet servers via the 0.7
bridge and will be sent to clients identifying themselves as DDNet
clients.

Add a new extended message that mirror the old `Sv_TeamsState`.
2021-01-12 01:38:23 +01:00
fokkonaut 9940a806fa Support for F-Client 2021-01-12 01:38:23 +01:00
bors[bot] 5d45f061fa
Merge #3498
3498: Make netclipping of entities and events respect shown distance (fixes #3420) r=heinrich5991 a=def-

<!-- 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-01-11 22:21:01 +00:00
def cbda5b720a Make netclipping of entities and events respect shown distance (fixes #3420) 2021-01-11 23:11:28 +01:00
bors[bot] d0cdf23526
Merge #3493 #3497
3493: Keep showing last checkpoint after kill r=heinrich5991 a=def-

Some maps kill you quickly and you can't see how good your last run was,
for example "Buckle Up".

<!-- 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)


3497: No network clip in client prediction 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-01-11 20:21:44 +00:00
def f9aae5d53a No network clip in client prediction 2021-01-11 18:02:52 +01:00
def 9033968518 Freeview mouse moves faster when zoomed out (fixes #3459) 2021-01-11 17:54:33 +01:00
Zwelf 87d422df5a Remove unused onChangeTeamState 2021-01-11 14:29:01 +01:00
def 95e4418026 Keep showing last checkpoint after kill
Some maps kill you quickly and you can't see how good your last run was,
for example "Buckle Up".
2021-01-11 14:09:37 +01:00
bors[bot] c8b4ce9c92
Merge #3465
3465: Reset practice after team saved and got killed r=Zwelf a=def-

As reported by Polector on Discord

<!-- 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-01-11 13:09:18 +00:00
def 4520ea3bb7 Reset practice after team saved and got killed
As reported by Polector on Discord
2021-01-11 00:23:36 +01:00
bors[bot] e0d6fa4670
Merge #3476 #3484
3476: Indicate strength of hook in nameplates r=heinrich5991 a=def-

off by default, cl_nameplates_strong 1 to enable

also shown in debug mode (ctrl-shift-d)

![screenshot-20210105@142505](https://user-images.githubusercontent.com/2335377/103651612-2b7e0300-4f62-11eb-8b45-09b8b125f2a6.png)

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

## 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
- [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)


3484: Fix up/down keys in demo browser r=heinrich5991 a=def-

<!-- 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-01-10 16:57:26 +00:00
bors[bot] 6f4fb1a926
Merge #3468
3468: Improve grammar when locking team (fixes #3467) 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-01-10 16:46:08 +00:00
bors[bot] 124c4b1acf
Merge #3463
3463: Dynamically size scoreboard title r=heinrich5991 a=def-

![screenshot_2020-12-31_10-01-53](https://user-images.githubusercontent.com/2335377/103403147-80c7a800-4b4f-11eb-90d3-90d032439cf3.png)
![screenshot_2020-12-31_10-13-23](https://user-images.githubusercontent.com/2335377/103403580-ed8f7200-4b50-11eb-9798-01fd4e283405.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
- [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: def <dennis@felsin9.de>
2021-01-10 15:46:11 +00:00
Alexander Akulich c2f276cee1 Port CConfig API from the upstream (0.7.5)
The old (g_Config) API is kept to not break the stuff.

See commits:
    de5859b371
    78076761eb
2021-01-10 17:10:19 +03:00
Alexander Akulich 77b2b22dd2 Entity: Restrict the access to some (now) private members
Follow upstream commit e86a486688
2021-01-10 14:25:12 +03:00
Alexander Akulich b0db610a47 Entities: Get rid of direct m_ID access 2021-01-10 14:25:12 +03:00
Alexander Akulich 035a50dd0b Entities: Get rid of direct m_ProximityRadius access 2021-01-10 14:25:12 +03:00
Alexander Akulich b865306b56 Entity: Add API changes from the upstream
The upstream restricted access to the class member.
Keep the some protected API as public and some private API as protected
for now to avoid massive changes in a hundreds places (related to m_Pos).

See upstream commit e86a486688.
2021-01-10 14:25:12 +03:00
Alexander Akulich 476c2c60d7 Cleanup includes
See the upstream commit 24bda2faa0
2021-01-10 14:25:12 +03:00
Alexander Akulich f16937b361 gamecontext.h: Remove unused player.h include
See the upstream commit 24bda2faa0
2021-01-10 14:25:12 +03:00
Alexander Akulich 164cb9907a player.h: Remove unused character.h include
See the upstream commit 24bda2faa0
2021-01-10 14:25:12 +03:00
Alexander Akulich 8ee8351b68 Move WEAPON enum from character.h to player.h
See the upstream commit 24bda2faa0
2021-01-10 14:25:12 +03:00
Alexander Akulich dc5b9340d5 Extract allocation macros to alloc.h (mimic the upstream)
See the upstream commit 24bda2faa0
2021-01-10 14:25:12 +03:00
Alexander Akulich 80539245c8 GameContext: Extract SendMotd() and SendSettings() methods
Partial cherry-pick from upstream d8d259a166
2021-01-10 00:47:06 +03:00
def 52616a5f35 Fix unused variable warnings 2021-01-08 11:43:26 +01:00
Дядя Женя afb4ce5fc7 Revert horizontal sliders 2021-01-08 11:43:26 +01:00
Дядя Женя 7d576c41b4 H Slider 2021-01-08 11:43:26 +01:00
Дядя Женя eb796c6b5c More fixes 2021-01-08 11:43:26 +01:00
Дядя Женя 38e6878c48 Temp fixes for controls 2021-01-08 11:43:26 +01:00
Дядя Женя b8ba2b226a Sliders 2021-01-08 11:43:26 +01:00
Дядя Женя aefcbf812d Vertical sliders and lists 2021-01-08 11:43:24 +01:00
def 83b5601d62 Fix up/down keys in demo browser 2021-01-07 10:42:13 +01:00
hhh26459 ef2dd39cf5
typo in gamecontext.cpp
specators...
2021-01-06 18:16:30 +01:00
bors[bot] 4fb8798fd1
Merge #3474
3474: Fix scrollbar going out of bounce (fixes #3416) r=Learath2 a=def-

<!-- 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
- [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: def <dennis@felsin9.de>
2021-01-06 16:08:47 +00:00
def 143985a68e Indicate strength of hook in nameplates
only shown in debug mode (ctrl-shift-d)
2021-01-05 19:32:53 +01:00
bors[bot] f68e7853be
Merge #3478
3478: Fix server crash with too many items (fixes #3477) 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-01-05 18:20:24 +00:00
def 5c4fc9471a Fix server crash with too many items (fixes #3477) 2021-01-05 19:09:29 +01:00
def 088420459f Fix scrollbar going out of bounce (fixes #3416) 2021-01-04 19:16:38 +01:00
Tim Schumacher 56bfab6f1c Make dragging quads in the editor more sensitive to small mouse deltas
Closes #963
2021-01-02 13:49:16 +01:00
def 134b644d40 Improve grammar when locking team (fixes #3467) 2021-01-01 23:40:34 +01:00
def 992683c772 Dynamically size scoreboard title 2020-12-31 10:13:53 +01:00
bors[bot] 871fd94531
Merge #3448 #3449
3448: Same default map as in autoexec_server.cfg r=Jupeyy 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)


3449: Fix x of y servers r=Jupeyy a=def-

as reported by louis

<!-- 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>
2020-12-29 15:11:47 +00:00
bors[bot] b1531642cd
Merge #3458
3458: Respect possible particle size increase, of worst case rotation r=def- a=Jupeyy

Particle's achsis aligned bounding box can increase in size if the particle is rotating.
Even if the particle images are all "pretty" round and so it wouldn't matter for default particles,
its not correct and with a custom image it could break.
following #3441

Basically this:
![image](https://user-images.githubusercontent.com/6654924/103292756-be60ef80-49ee-11eb-8518-dd120d19ca17.png)


## 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>
2020-12-29 15:02:20 +00:00
Jupeyy bce1f45a2b Respect possible particle size increase, of worst case rotation 2020-12-29 15:58:05 +01:00
bors[bot] 1c750a73ff
Merge #3457
3457: Don't render fully transparent quads r=def- a=Jupeyy

@def- i mean u could test the fps diff, its quite huge
and if u really only have 50fps, others will only have 30fps xd

## 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>
2020-12-29 14:12:37 +00:00
Jupeyy 288a18fa95 Don't render fully transparent quads 2020-12-29 14:59:17 +01:00
def 78870a5fcd Version 15.2.5 2020-12-29 14:30:00 +01:00
bors[bot] 505656313c
Merge #3451
3451: Add New Year season theme by mind and use for 2 days r=Learath2 a=def-

Map reduces my FPS from 60 to 53, mind can't optimize it further.

I'd release this as 15.2.5 in 1-2 days ideally with no other new changes in.

![screenshot_2020-12-28_14-51-48](https://user-images.githubusercontent.com/2335377/103228624-83e54d00-4931-11eb-96fd-c408a353cda0.png)

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

## 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
- [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: def <dennis@felsin9.de>
2020-12-29 13:12:13 +00:00
bors[bot] 262439b5bb
Merge #3455
3455: Readd round start tick to the calculation r=def- a=Jupeyy

fixes #3454

@bretonium would you be so kind and test this quickly, if everything looks fine again? :D

## 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>
2020-12-29 11:37:53 +00:00
Jupeyy 30d089b45c Readd round start tick to the calculation 2020-12-29 03:08:28 +01:00
Zwelf 72455ed32d Fix use of uninitialized variable during /load of old saves 2020-12-28 18:02:43 +01:00
def 59f1c2cbe6 Add New Year season theme by mind and use for 2 days
Map reduces my FPS from 60 to 45, mind can't optimize it further.

I'd release this as 15.2.5 in 1-2 days ideally with no other new changes in.
2020-12-28 17:45:04 +01:00
def 5a23bc1ab1 Fix veto 2020-12-28 12:01:35 +01:00
def ff2d2f6fc4 Fix x of y servers
as reported by louis
2020-12-28 08:56:55 +01:00
def 98aec6bffc Fewer repetitions 2020-12-27 10:57:50 +01:00
def 21886f2741 Fix spacing of cl_show_ids by using figure space (U+2007) 2020-12-27 01:19:36 +01:00
def 89e2371b9b Improve some chat settings 2020-12-27 01:14:34 +01:00
def 18ccb39384 Add (un)endless_hook command
As requested by Kicker
2020-12-26 23:09:38 +01:00
Jupeyy 2ea2d67b56 Only render visible particles 2020-12-23 14:55:49 +01:00
def e981d1b477 Fix veto vote, simplified logic
Also allow IPs to change their vote when multiple players are connected,
with 1 player it always worked.

Reported by Lenah on Discord
2020-12-23 10:51:51 +01:00
Jupeyy f21687a927 remove unused chains 2020-12-22 19:25:32 +01:00
bors[bot] 440337eb5c
Merge #3384 #3437
3384: Add w as default bind for dummy hammer 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)


3437: Update .clang-tidy file to 11 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>
2020-12-22 11:40:35 +00:00
def 93a0dc3eee Add more commonly used binds
from https://forum.ddnet.tw/viewtopic.php?t=2537
2020-12-22 12:36:01 +01:00
bors[bot] 0b2eda2bd9
Merge #3434
3434: Add F-DDrace entities r=heinrich5991 a=fokkonaut



## 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: fokkonaut <35420825+fokkonaut@users.noreply.github.com>
2020-12-22 11:31:56 +00:00
bors[bot] e9b174a00f
Merge #3389
3389: Alternative alternative fix for malloc of size 0 r=def- a=heinrich5991

Has a short diff to the original code before a4f13ed4a8.
Supersedes #3353. Thanks for the idea, @timakro.

<!-- 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>
2020-12-22 11:23:40 +00:00
fokkonaut d4c4031f20 Add F-DDrace entities 2020-12-22 12:23:21 +01:00
bors[bot] e708f3a1b1
Merge #3405
3405: Keep veto right after joining dummy with lower ID (fixes #3404) 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>
2020-12-22 11:15:46 +00:00
bors[bot] 8a15bc15d5
Merge #3417 #3419 #3432
3417: Notify about vote when authed r=heinrich5991 a=def-

<!-- 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
- [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)


3419: Only assign aOldName when we need it 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)


3432: Fix localization of version/game type/ping in server details r=heinrich5991 a=def-

<!-- 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>
2020-12-22 10:55:34 +00:00
def 57b1311b4b Fix localization of version/game type/ping in server details 2020-12-21 12:17:07 +01:00
bors[bot] f190e529b6
Merge #3427
3427: Remove hardcoded zoom level r=def- a=Jupeyy

E.g. on current tournament map its really annoying to not see the whole map at once to get a feeling for the map size

## 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>
2020-12-20 22:13:17 +00:00
bors[bot] f6ef42ce0d
Merge #3430
3430: Filter invalid kill messages r=def- a=Jupeyy

Fixes #3429

Also made it a bit safer by checking what the server sends

## 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>
2020-12-20 22:02:56 +00:00
Jupeyy cedb3e0b1f Filter invalid kill messages 2020-12-20 20:25:42 +01:00
Jupeyy 56d81678bd Remove hardcoded zoom level 2020-12-20 18:32:16 +01:00
bors[bot] 8d4e1a8b1a
Merge #3425
3425: Remove redundant check for pPlayer->m_IsReady r=Jupeyy 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>
2020-12-19 11:12:43 +00:00
def bdfb8bb06e Fix dragger being shown (fixes #3414)
Still doesn't seem to work with different team and /showothers 1, but
maybe that has always been the case
2020-12-19 11:30:56 +01:00
def 7eb26c62d1 Remove redundant check for pPlayer->m_IsReady 2020-12-19 10:20:18 +01:00
def 4d3d9d7049 Only assign aOldName when we need it 2020-12-18 23:18:55 +01:00
Дядя Женя b745feec73 Format 2020-12-18 23:35:22 +03:00
Дядя Женя 2c3d24d5b3 Merge branch 'pr_color_picker' of https://github.com/Banana090/ddnet into pr_color_picker 2020-12-18 23:29:52 +03:00
Дядя Женя b57d934b69 Polish 2020-12-18 23:28:33 +03:00
def fc75e95e35 Merge branch 'master' into pr_color_picker 2020-12-18 19:13:51 +01:00
def 6586ab20bc Play highlight sound on vote too when authed 2020-12-18 18:38:12 +01:00
def 567f0aa6d4 Notify about vote when authed 2020-12-18 12:58:01 +01:00
def da6930fba5 Version 15.2.4 2020-12-16 13:28:16 +01:00
Дядя Женя 9d77b8f716 Discard unnesaccery changes 2020-12-16 07:59:45 +03:00
Дядя Женя f4b8033056 Fixes 2020-12-16 07:55:41 +03:00
bors[bot] c564d788ad
Merge #3402
3402: Move PNG loading in SkinDL to fetch thread (fixes #3398) r=Jupeyy a=def-

Sorry for the trouble, seems to work.

<!-- 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
- [x] Considered possible null pointers and out of bounds array indexing
- [x] Changed no physics that affect existing maps
- [x] 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>
2020-12-15 15:09:44 +00:00
bors[bot] 0f9f71d73c
Merge #3409
3409: Menu tabs animations r=def- a=Banana090

Cool menu tabs animations, please merge


Co-authored-by: Дядя Женя <spy090@yandex.ru>
Co-authored-by: def <dennis@felsin9.de>
2020-12-15 13:55:16 +00:00
Дядя Женя d80cdd20d4 Fix merge conflicts 2020-12-14 22:18:00 +03:00
Learath2 bd1c847300 Allow reordering in the settings editor 2020-12-14 12:06:11 +01:00
Дядя Женя ebee286f00 Another attempt to fix Lin & Mac build 2020-12-14 04:49:24 +03:00
Дядя Женя c084c9cde2 Fix Mac & Linux build 2020-12-14 04:18:04 +03:00
Дядя Женя 77f84ac831 Ready 2020-12-14 03:51:31 +03:00
def 82faad33e9 Fix clang-format 2020-12-13 19:31:37 +01:00
Дядя Женя 9b4dfc142a Merge branch 'master' into pr_color_picker
# Conflicts:
#	src/game/client/components/chat.h
#	src/game/client/components/menus_settings.cpp
2020-12-13 20:40:33 +03:00
Дядя Женя e234776de2 Merge branch 'master' into pr_animations_hud 2020-12-13 20:34:53 +03:00
def ea70c347a3 Keep veto right after joining dummy with lower ID (fixes #3404) 2020-12-13 17:58:24 +01:00
bors[bot] 483e7b2624
Merge #3403
3403: Allow resizing on Windows too r=def- a=Jupeyy

I actually wanted to fix the grabbing issue on Windows, but sadly couldn't fix it, while trying to fix it, i fixed the resizing stuff tho(tested with a vm on win10 and win7), also gfx_resizable 1 should be fine now with KDE too(couldn't reproduce that blackscreen bug anymore)

Tho I also want to share some things about the grabbing thing, maybe someone is interested in improving it:
I found out that disabling the console on windows and creating the window as fast as possible reduces the grabbing issues.
Even better was making the windows always on top so SDL doesn't call the grab when our window looses focus, while the IO stuff is blocking.
The code is really random but here are the things i tried(c881720137)



## 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>
2020-12-13 10:23:04 +00:00
Jupeyy bae42b9284 Recreate kill messages if required 2020-12-13 01:08:34 +01:00
Jupeyy cafd1a4e8f Allow windows resizing 2020-12-13 00:52:57 +01:00
def cd00c4c04b Move PNG loading in SkinDL to fetch thread (fixes #3398)
Sorry for the trouble, seems to work.
2020-12-13 00:08:46 +01:00
Zwelf 037bac8f13 Add /top5team s?i command to show all team ranks of a player 2020-12-10 13:44:11 +01:00
Zwelf b256250b7b Synchronize database thread via atomic_bool instead of use_count from shared pointer 2020-12-08 18:11:00 +01:00
def 2544c758a0 Add w as default bind for dummy hammer 2020-12-08 14:42:22 +01:00
heinrich5991 e805e42a94 Alternative alternative fix for malloc of size 0
Has a short diff to the original code before a4f13ed4a8.
Supersedes #3353. Thanks for the idea, @timakro.
2020-12-08 12:29:10 +01:00
Dennis Felsing 516c1cc599
Merge pull request #3382 from Zwelf/pr-fix-race-condition
Fix storing load/save result in main thread without incrementing usage count
2020-12-04 11:48:14 +01:00
Zwelf e15a91911e Fix storing load/save result in main thread without incrementing usage count
Resulting to race condition, since the main thread always thought that the
load/save thread already completed. Passing the shared_ptr by reference to
prevent a similar future bug to happen.

Fixes #3380
2020-12-04 11:09:21 +01:00
def b63d20a6e0 Check for m_pCharacter before accessing it (fixes #3372) 2020-12-02 11:37:55 +01:00
bors[bot] 0848df797a
Merge #3315
3315: Remove annoying "added option" logging r=heinrich5991 a=def-

Fills our logs all the time

<!-- 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>
2020-11-30 15:46:25 +00:00
def b32e421dff Remove annoying "added option" logging
Fills our logs all the time
2020-11-30 08:08:37 +01:00
bors[bot] 6eb56ffb13
Merge #3341
3341: Check finish of team after player joins spectators r=heinrich5991 a=def-

Reported by Jupeyy

<!-- 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
- [x] Considered possible null pointers and out of bounds array indexing
- [x] Changed no physics that affect existing maps
- [x] 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>
2020-11-28 20:18:37 +00:00
def 9d66c2530b Check finish of team after player joins spectators
Reported by Jupeyy
2020-11-28 20:59:51 +01:00
bors[bot] b8fca40851
Merge #3340
3340: Fix vec_base constructors & remove useless operator r=heinrich5991 a=Jupeyy

Interestingly besides it found unused variables, this also found some "logic" errors, where vectors were used in `if`.

## 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>
2020-11-28 17:06:25 +00:00
bors[bot] 80a65c6326
Merge #3358
3358: Fix prediction with global collision off tiles and tunings (fix #2510) r=def- a=trml

Tested it now, and it seems that only the hook and collision off tiles were affected by this.

## 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: trml <trml@users.noreply.github.com>
2020-11-25 22:59:17 +00:00
trml 7bfd708405 Set ddnetchar flags when collision is disabled with server tunings 2020-11-25 23:38:29 +01:00
Jupeyy c0dbd4a6f5 Fix leak, initialize UI Element Rect 2020-11-25 13:11:34 +01:00
Headshot 9b460750fa
fix typo "authroized" 2020-11-24 21:50:10 -04:00
def bb43660cd4 Fix scroll bar (fixes #3347) 2020-11-21 18:30:24 +01:00
Vlad 28cf3b31ba rescue on freeze/dfreeze 2020-11-21 10:52:43 +01:00
Jupeyy f83d528f5d Fix vector constructor impl & remove useless operator 2020-11-20 12:14:33 +01:00
def d618c8e1e1 Fix assets menu
Multiple assets would be highlighted

Bug introduced in https://github.com/ddnet/ddnet/pull/3304
2020-11-19 18:11:00 +01:00
def 0278200da8 Version 15.2.3 2020-11-19 16:17:01 +01:00
bors[bot] 797116fbfe
Merge #3316
3316: Disable ninja jetpack when player has telegun r=heinrich5991 a=def-

Required for map Taceht because of weapon tele interaction with jetpack

As requested by Cøke

## 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>
Co-authored-by: Dennis Felsing <dennis@felsin9.de>
2020-11-19 13:06:24 +00:00
Dennis Felsing 227405b645
Update src/game/server/entities/character.cpp
Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2020-11-19 10:20:13 +01:00
bors[bot] b138c4038c
Merge #3304 #3310
3304: Improve list box behaviour, make it more consistent r=heinrich5991 a=def-

Make keys work after searching in vote menu
Unify some duplicated code

## 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
- [x] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


3310: Found some more times with mins, use hours for consistency r=heinrich5991 a=def-

## 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
- [x] 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>
2020-11-18 23:43:22 +00:00
bors[bot] 38d0bf3c40
Merge #3325
3325:  Add ball effects, even for invalid projectiles r=heinrich5991 a=Jupeyy

@pure-luck-999 can you test, if this is already enough?

fixes #3323

## 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>
2020-11-18 23:35:00 +00:00
Jupeyy 2a7ba8fe30 Add ball particles, even for invalid projectiles 2020-11-18 14:48:18 +01:00
bors[bot] 078247dd3e
Merge #3327
3327: Check skin/sprite images for correctness r=def- a=Jupeyy

I hope this helps with downloading things at wrong resolution again.

Note that this commit is smaller than it seems, bcs of renaming files and moving code to it.
Also this requires new translations.

In the skin database are invalid skins too:

![screenshot_2020-11-18_07-51-02](https://user-images.githubusercontent.com/6654924/99495409-e7637e80-2972-11eb-91ec-f8bb02a80e83.png)
![screenshot_2020-11-18_07-51-05](https://user-images.githubusercontent.com/6654924/99495410-e7fc1500-2972-11eb-94b8-aedc98e8ef67.png)


## 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>
2020-11-18 12:27:47 +00:00
bors[bot] b4f8f7928f
Merge #3319
3319: Fix random map vote reason to set stars r=Learath2 a=def-

Caused by the hotfix for solo cheat

As reported by maggi323

## 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>
2020-11-18 11:49:36 +00:00
Jupeyy c989cd67f9 Check skin/sprite images for correctness 2020-11-18 07:59:15 +01:00
def f8b07f705e Version 15.2.2 2020-11-17 18:34:42 +01:00
bors[bot] 6e5d0cce6f
Merge #3321
3321: Mod by zero r=def- a=Jupeyy

<!-- 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>
2020-11-17 17:08:04 +00:00
Jupeyy 6cefbcbbf9 Mod by zero 2020-11-17 18:01:23 +01:00
def f9be02c411 Version 15.2.1: Quick autoupdate fix 2020-11-17 17:04:21 +01:00
def d65af80291 Version 15.2 2020-11-17 13:27:23 +01:00
bors[bot] 39f4e94ba2
Merge #3312
3312: DoEditBox clamp cursor position r=def- a=TsFreddie

Fix freezing with DoEditBox
Pretty small patch but seems to be working
Also removed the linewidth limit in DoEditBox to avoid multiline

fixes #3256

## 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: Freddie Wang <tsfreddiewang@gmail.com>
Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-11-17 11:19:28 +00:00
def c0b48ad89f Disable ninja jetpack when player has telegun
Required for map Taceht because of weapon tele interaction with jetpack

As requested by Cøke
2020-11-16 20:28:17 +01:00
def c3f6d89cac Fix random map vote reason to set stars
Caused by the hotfix for solo cheat

As reported by maggi323
2020-11-16 17:32:48 +01:00
Jupeyy fbf0aedfb2 Fix statboard rendering 2020-11-15 09:06:03 +01:00
Jupeyy e2be287827 numeric robustness 2020-11-15 07:40:24 +01:00
Jupeyy 51a31774f8 Don't trigger text alignment for editboxes 2020-11-15 07:15:38 +01:00
Freddie Wang d31397ade4 doeditbox 2020-11-15 13:24:18 +08:00
def cfd3f84106 Found some more times with mins, use hours for consistency 2020-11-14 00:22:21 +01:00
bors[bot] d80d1df0db
Merge #3297 #3305 #3307
3297: Fix memleak in CServer on instant shutdown r=Jupeyy a=def-

```
Direct leak of 566869 byte(s) in 1 object(s) allocated from:
    #0 0x4f28e3 in __interceptor_malloc (/home/teeworlds/servers/DDNet-Server-asan+0x4f28e3)
    #1 0x55b3c9 in CServer::LoadMap(char const*) /home/teeworlds/src/master/src/engine/server/server.cpp:2312:49
    #2 0x55bfdd in CServer::Run() /home/teeworlds/src/master/src/engine/server/server.cpp:2351:6
    #3 0x56add2 in main /home/teeworlds/src/master/src/engine/server/server.cpp:3553:21
    #4 0x7f54401cd09a in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x2409a)
```

## 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
- [x] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


3305: DemoRecorder: Only remove existing filenames r=Jupeyy a=def-

As noticed by Jupstar

## 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
- [x] Tested the change with [ASan+UBSan or valgrind's memcheck](https://github.com/ddnet/ddnet/#using-addresssanitizer--undefinedbehavioursanitizer-or-valgrinds-memcheck) (optional)


3307: Don't crash with debug mode in demo r=Jupeyy a=def-

Since character doesn't exist then. Reported by murpi

Originally introduced in https://github.com/ddnet/ddnet/pull/2578

<!-- 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>
2020-11-13 10:31:20 +00:00
bors[bot] 5602d3e9fb
Merge #3306
3306: Respect friend color in spectate mode ♥ too r=Jupeyy a=def-

As suggested by Cøke
![screenshot_2020-11-12_19-17-01](https://user-images.githubusercontent.com/2335377/98979616-d7cfda00-251b-11eb-857d-b592655ef538.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
- [x] Considered possible null pointers and out of bounds array indexing
- [x] Changed no physics that affect existing maps
- [x] 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>
2020-11-13 10:20:08 +00:00
def 81bb7e661c Improve list box behaviour, make it more consistent
Make keys work after searching in vote menu

Unify some duplicated code
2020-11-13 08:03:34 +01:00
def 0c416df935 Respect friend color in spectate mode ♥ too
As suggested by Cøke
2020-11-13 07:44:25 +01:00
def 7aa6be9e12 Don't crash with debug mode in demo
Since character doesn't exist then. Reported by murpi

Originally introduced in https://github.com/ddnet/ddnet/pull/2578
2020-11-12 22:56:50 +01:00
Jupeyy 0c231c3668 Respect outline in skin metrics 2020-11-12 08:45:10 +01:00
bors[bot] a12ec3c9a8
Merge #3279
3279: Add a script to check for variable name style violations, fix some variable names r=def- a=heinrich5991

Didn't fix all variable names because there were far too many. Ideas? At least the second commit should probably go in.

## 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>
2020-11-11 17:42:12 +00:00
Jupeyy 4d9f4da3ec Fix dragger logic 2020-11-11 05:41:42 +01:00
Jupeyy 06c2e0af50 Fix server browser columns 2020-11-09 21:24:06 +01:00
bors[bot] 8dd1cd50ed
Merge #3274
3274: Add skin metrics r=def- a=Jupeyy

Finally i had time for this.
This addresses the problem with skin sizes( yes @Banana090 I care for you :* )

Finally a way to calculate skin sizes correctly:

**new**
![image](https://user-images.githubusercontent.com/6654924/98458133-b1154a80-218d-11eb-9c80-1dccec36a250.png)

old:
![image](https://user-images.githubusercontent.com/6654924/98458263-1ddd1480-218f-11eb-9ff2-25c318e8e89a.png)

Maybe more obvious(left new, right old):
![image](https://user-images.githubusercontent.com/6654924/98458338-c5f2dd80-218f-11eb-83f0-d3020a39f1a2.png)


So we can center skins always.

Currently I only applied this to chat, but it should be used everywhere, where a skin is rendered(except the actual game skin)
- Scoreboard
- Skin selection
- and so on

@def- i'd really like to get this into this next release, because I know ppl with smaller skins will complain about the offset.
I'll test it a bit tomorrow, maybe others can test it too already.

## 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: Jupeyy <jupjopjap@gmail.com>
2020-11-09 10:44:56 +00:00
Jupeyy a9631bf9cd Fix text color change 2020-11-08 19:43:01 +01:00
heinrich5991 7663641ed2 Fix some variable name's style 2020-11-08 17:15:48 +01:00
trml 984352dd00 Only use individual character flags for collision when ddnetchar is available 2020-11-08 14:05:44 +01:00
Jupeyy df4c7a08c8 Add skin metrics 2020-11-08 10:28:47 +01:00
bors[bot] 03fbb9f423
Merge #3273
3273: Fix spawnpoints calculation r=def- a=Jupeyy

m_aNumSpawnPoints wasn't increased causing no spawn points to be loaded at all.
Also the maximum value it can have should be 64, not 64 - 1, bcs it's the upper limit, not the index.

## 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>
2020-11-08 09:09:27 +00:00
bors[bot] f6bcc3ca41
Merge #3272
3272: Fix browser wrong alignment r=def- a=Jupeyy

Must be a 1 instead of -1, caused at 74515d4b95



## 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>
2020-11-08 09:00:38 +00:00
Jupeyy 6db4323daf Fix spawnpoints calculation 2020-11-08 03:42:35 +01:00
Jupeyy 6fbb161846 Fix wrong alignment 2020-11-08 01:41:12 +01:00
bors[bot] 848bbf543d
Merge #3268
3268: Fix ScaleFontSize with too long strings r=Jupeyy a=def-

Thanks to PopCorn181 for report
![screenshot_2020-11-08_00-03-19](https://user-images.githubusercontent.com/2335377/98453118-d1c1ae00-2155-11eb-97cf-cd5a455c00d3.png)

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

## 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
- [x] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [x] 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>
2020-11-07 23:07:38 +00:00
def 7c0e2212e2 Fix ScaleFontSize with too long strings
Thanks to PopCorn181 for report
2020-11-08 00:02:35 +01:00
bors[bot] be06146c49
Merge #3252
3252: cl_chat_tee + cl_chat_background => cl_chat_old (fixes #3106) r=Jupeyy a=def-

![screenshot-20201105@131601](https://user-images.githubusercontent.com/2335377/98240075-30760480-1f69-11eb-91ab-4be84ab84aab.png)
![screenshot-20201105@131537](https://user-images.githubusercontent.com/2335377/98240077-310e9b00-1f69-11eb-8454-71d2c6612a2a.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
- [x] Considered possible null pointers and out of bounds array indexing
- [x] Changed no physics that affect existing maps
- [x] 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>
2020-11-07 21:27:19 +00:00
bors[bot] 556f64775e
Merge #3242
3242: Enable most clang-tidy bugprone-*, misc-*, performance-* checks r=Jupeyy a=def-

Fixes #3134

## 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>
2020-11-07 20:15:30 +00:00
bors[bot] 536295ec74
Merge #3266 #3267
3266: Fix chat scoreboard collision for 16:9 and disable scoreboard checks … r=def- a=Jupeyy

…for lower aspect ratios

fixes #3223

![screenshot_2020-11-07_19-04-54](https://user-images.githubusercontent.com/6654924/98448455-6d3e2900-212c-11eb-9352-730119577178.png)

![screenshot_2020-11-07_19-04-43](https://user-images.githubusercontent.com/6654924/98448454-6c0cfc00-212c-11eb-89dd-51a74e4aa8d3.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)


3267: Add czech translation by eNJi r=heinrich5991 a=def-

## 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>
2020-11-07 19:02:55 +00:00
bors[bot] 3d00ae4414
Merge #3257
3257: Add cl_showhud_timer option (requested by hussainx3) r=heinrich5991 a=def-

![screenshot-20201106@092559](https://user-images.githubusercontent.com/2335377/98343428-1a704e80-2012-11eb-8fa2-37fe734c5056.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
- [x] Considered possible null pointers and out of bounds array indexing
- [x] Changed no physics that affect existing maps
- [x] 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>
2020-11-07 18:54:32 +00:00
bors[bot] 2583343a4a
Merge #3254
3254: Warn when connecting to new server with high gametime r=heinrich5991 a=def-

as suggested by HalfNoob on Discord

<!-- 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
- [x] 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
- [x] 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>
2020-11-07 18:46:44 +00:00
bors[bot] 85c4384045
Merge #3245
3245: Don't access m_aaSpawnPoints out of bounds r=heinrich5991 a=def-

As discovered by ASAN:

```
/home/teeworlds/src/master/src/game/server/gamecontroller.cpp:142:3: runtime error: index 65 out of bounds for type 'vec2 [64]'
    #0 0x5de082 in IGameController::OnEntity(int, vector2_base<float>, int, int, int) /home/teeworlds/src/master/src/game/server/gamecontroller.cpp:142:3
    #1 0x5c9f43 in CGameContext::OnInit() /home/teeworlds/src/master/src/game/server/gamecontext.cpp:3291:20
    #2 0x4ae3aa in CServer::Run() /home/teeworlds/src/master/src/engine/server/server.cpp:2473:20
    #3 0x4c265d in main /home/teeworlds/src/master/src/engine/server/server.cpp:3551:21
    #4 0x7f400fedc09a in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x2409a)
    #5 0x451509 in _start (/home/teeworlds/servers/DDNet-Server-ubsan+0x451509)
```

## 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>
2020-11-07 18:32:42 +00:00
Jupeyy 5f7e8a7901 Fix chat scoreboard collision for 16:9 and disable scoreboard checks for lower aspect ratios 2020-11-07 19:05:23 +01:00
bors[bot] 17895d701a
Merge #3265
3265: Fix scoreboard on ddnet server r=Jupeyy a=def-

![screenshot_2020-11-07_18-36-44](https://user-images.githubusercontent.com/2335377/98447851-5990c380-2128-11eb-8577-62a795aa915e.png)

Broken in https://github.com/ddnet/ddnet/pull/3251

Thanks to louis for report

## 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: def <dennis@felsin9.de>
2020-11-07 17:46:58 +00:00
def 6da48a0bc3 Fix scoreboard on ddnet server
Broken in https://github.com/ddnet/ddnet/pull/3251

Thanks to louis for report
2020-11-07 18:36:26 +01:00
def d0437df51d Smooth Camera -> Smooth Dynamic Camera, only show if dyncam active
As suggested by Pipou
2020-11-07 12:10:59 +01:00
def 254c970a8e Fix behaviour with cl_confirm_disconnect_time 0 2020-11-07 11:00:30 +01:00
bors[bot] 612c592ef2
Merge #3260
3260: "Connect to" popup: Don't disconnect on enter (fixes #3259) r=Jupeyy a=def-

## 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
- [x] 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>
2020-11-07 00:56:46 +00:00
bors[bot] b0ea7585b8
Merge #3248
3248: Update translations for 15.2 release r=Jupeyy a=def-

## 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>
2020-11-06 23:31:03 +00:00
bors[bot] eae65b2f5d
Merge #3251
3251: Scoreboard same line height and font size for each team (fixes #3216) r=Jupeyy a=def-

supersedes #3219
![screenshot_2020-11-05_12-21-53](https://user-images.githubusercontent.com/2335377/98235019-8cd52600-1f61-11eb-8d28-29ba62308008.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
- [x] Considered possible null pointers and out of bounds array indexing
- [x] Changed no physics that affect existing maps
- [x] 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>
2020-11-06 23:13:52 +00:00
bors[bot] a59f8495f4
Merge #3247
3247: Initialize pointer in dragger r=Jupeyy a=def-

How did this not blow up all day long for years?!
    
Found by UBSAN:

    /home/teeworlds/src/master/src/game/server/entities/dragger.cpp:32:29: runtime error: member call on address 0x0000013319b8 which does not point to an object of type 'CCharacter'
    0x0000013319b8: note: object has invalid vptr
     00 00 00 00  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  00 00 00 00
                  ^~~~~~~~~~~~~~~~~~~~~~~
                  invalid vptr
        #0 0x5501de in CDragger::Move() /home/teeworlds/src/master/src/game/server/entities/dragger.cpp:32:29
        #1 0x5522c2 in CDragger::Tick() /home/teeworlds/src/master/src/game/server/entities/dragger.cpp:153:3
        #2 0x5eb11e in CGameWorld::Tick() /home/teeworlds/src/master/src/game/server/gameworld.cpp:261:11
        #3 0x58d660 in CGameContext::OnTick() /home/teeworlds/src/master/src/game/server/gamecontext.cpp:751:10
        #4 0x4afefe in CServer::Run() /home/teeworlds/src/master/src/engine/server/server.cpp:2558:19
        #5 0x4c26fd in main /home/teeworlds/src/master/src/engine/server/server.cpp:3551:21
        #6 0x7f2c8cc9309a in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x2409a)
        #7 0x451509 in _start (/home/teeworlds/servers/DDNet-Server-ubsan+0x451509)


## 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>
2020-11-06 23:06:27 +00:00
def 373275dc6c Connect to menu: Don't disconnect on enter (fixes #3259) 2020-11-07 00:00:25 +01:00
def 75b7474443 Add cl_showhud_timer option (requested by hussainx3) 2020-11-06 09:25:21 +01:00
def c478600935 Warn when connecting to new server with high gametime
as suggested by HalfNoob on Discord
2020-11-05 20:19:31 +01:00
def b03b75146c cl_chat_tee + cl_chat_background => cl_chat_old (fixes #3106) 2020-11-05 13:16:25 +01:00
def e75d7a2ff8 Scoreboard same line height and font size for each team (fixes #3216, supersedes #3219) 2020-11-05 12:15:27 +01:00
def 7a9a67c5d7 Enable most clang-tidy misc-* checks 2020-11-05 12:03:14 +01:00
def 312b9d3bd8 Enable clang-tidy performance-* checks 2020-11-05 11:34:20 +01:00
def b0f9dc2139 Update credits 2020-11-05 09:53:03 +01:00
def 5b5cfa7d9e nick name -> nickname 2020-11-05 09:32:14 +01:00
def 21d76ed31d NOLINT bugprone-parent-virtual-call where clang-tidy is stupid
/media/ddnet/src/game/editor/layer_game.cpp:42:35: warning: qualified name 'm_pEditor->m_Map.m_pFrontLayer->CLayerTiles::SetTile' refers to a member overridden in subclass; did you mean 'CLayerTiles'? [bugprone-parent-virtual-call]
                m_pEditor->m_Map.m_pFrontLayer->CLayerTiles::SetTile(x, y, through_cut);
                                                ^~~~~~~~~~~~~
                                                CLayerTiles::
/media/ddnet/src/game/editor/layer_game.cpp:42:35: note: FIX-IT applied suggested code changes
2020-11-05 08:25:34 +01:00
def bf8ae71b7d Fix and NOLINT bugprone-sizeof-expression 2020-11-05 08:25:34 +01:00
def 5e2776de0d Fix bugprone-misplaced-widening-cast 2020-11-05 08:25:34 +01:00
def 2c3000ba81 Minor code cleanup in dragger.cpp 2020-11-05 07:53:04 +01:00
def 5b5d4404a6 Don't access m_aaSpawnPoints out of bounds
As discovered by ASAN:

/home/teeworlds/src/master/src/game/server/gamecontroller.cpp:142:3: runtime error: index 65 out of bounds for type 'vec2 [64]'
    #0 0x5de082 in IGameController::OnEntity(int, vector2_base<float>, int, int, int) /home/teeworlds/src/master/src/game/server/gamecontroller.cpp:142:3
    #1 0x5c9f43 in CGameContext::OnInit() /home/teeworlds/src/master/src/game/server/gamecontext.cpp:3291:20
    #2 0x4ae3aa in CServer::Run() /home/teeworlds/src/master/src/engine/server/server.cpp:2473:20
    #3 0x4c265d in main /home/teeworlds/src/master/src/engine/server/server.cpp:3551:21
    #4 0x7f400fedc09a in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x2409a)
    #5 0x451509 in _start (/home/teeworlds/servers/DDNet-Server-ubsan+0x451509)
2020-11-04 23:16:04 +01:00
def 5a9d93f160 Initialize pointer in dragger
How did this not blow up all day long for years?!

Found by UBSAN:

/home/teeworlds/src/master/src/game/server/entities/dragger.cpp:32:29: runtime error: member call on address 0x0000013319b8 which does not point to an object of type 'CCharacter'
0x0000013319b8: note: object has invalid vptr
 00 00 00 00  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  00 00 00 00
              ^~~~~~~~~~~~~~~~~~~~~~~
              invalid vptr
    #0 0x5501de in CDragger::Move() /home/teeworlds/src/master/src/game/server/entities/dragger.cpp:32:29
    #1 0x5522c2 in CDragger::Tick() /home/teeworlds/src/master/src/game/server/entities/dragger.cpp:153:3
    #2 0x5eb11e in CGameWorld::Tick() /home/teeworlds/src/master/src/game/server/gameworld.cpp:261:11
    #3 0x58d660 in CGameContext::OnTick() /home/teeworlds/src/master/src/game/server/gamecontext.cpp:751:10
    #4 0x4afefe in CServer::Run() /home/teeworlds/src/master/src/engine/server/server.cpp:2558:19
    #5 0x4c26fd in main /home/teeworlds/src/master/src/engine/server/server.cpp:3551:21
    #6 0x7f2c8cc9309a in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x2409a)
    #7 0x451509 in _start (/home/teeworlds/servers/DDNet-Server-ubsan+0x451509)
2020-11-04 23:06:45 +01:00
def fea4481f8d Fix network x_ check (thanks to Jupeyy) 2020-11-04 19:28:06 +01:00
bors[bot] dcfdd05911
Merge #3237
3237: Create fallback wordlist in sourcecode (fixes #3206) r=Learath2 a=def-

<!-- 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
- [x] Considered possible null pointers and out of bounds array indexing
- [ ] Changed no physics that affect existing maps
- [x] 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>
2020-11-03 23:45:20 +00:00
def 06b534c07d Create fallback wordlist in sourcecode (fixes #3206) 2020-11-03 17:01:16 +01:00
bors[bot] 9b64b9ba1d
Merge #3222
3222: Kick-voting someone from team doesn't kill locked team (fixes #3207) r=heinrich5991 a=def-

<!-- 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
- [x] Changed no physics that affect existing maps
- [x] 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>
2020-11-03 11:59:34 +00:00
def 2c98f2b76b Kick-voting someone from team doesn't kill locked team (fixes #3207) 2020-11-03 08:37:56 +01:00
TsFreddie 996e519fe6 hint for disabling debug mode 2020-11-03 15:06:31 +08:00
bors[bot] 4abf699726
Merge #3117
3117: Enable further clang-tidy checks to modernize the code r=heinrich5991 a=def-

https://clang.llvm.org/extra/clang-tidy/checks/modernize-use-auto.html

And fix the code:

    cmake -GNinja -DWEBSOCKETS=OFF -DMYSQL=ON -DCMAKE_BUILD_TYPE=RelWithDebInfo -DVIDEORECORDER=ON -DAUTOUPDATE=OFF -DANTIBOT=OFF -DUPNP=OFF -DPREFER_BUNDLED_LIBS=OFF -DINFORM_UPDATE=OFF -DCMAKE_CXX_CLANG_TIDY="clang-tidy;--fix-errors" -DCMAKE_C_CLANG_TIDY="clang-tidy;--fix-errors" .
    ninja -j 1

Manually fixed sizeof(auto) in a few occurences (i.e. server.cpp:1359)

First steps for #3088

Co-authored-by: def <dennis@felsin9.de>
2020-11-02 21:56:04 +00:00
bors[bot] 1ee2462078
Merge #3231
3231: Fix skin index r=def- a=Jupeyy

Beside that this was wrong anyway, i hoped i could atleast get the index from the sorted list insert, but that returns the last index in the list, instead of the new inserted index(just like rn), so just revert what I added in 8d6148b20b

## 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>
2020-11-02 21:48:33 +00:00
bors[bot] d1cc109933
Merge #3228
3228: Add m_PosEnv (of sound sources) as index that must be offset when appending a map r=heinrich5991 a=Patiga

If you append a map to another, all indices of it must be offset. This doesn't happen with the position envelope index of sound sources, meaning it would (if the original maps had at least one envelope) point to the wrong envelope.

## 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
- [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>
2020-11-02 21:40:50 +00:00
def 63c093c065 Get rid of remaining strcpy calls 2020-11-02 22:40:41 +01:00
def 165857a5a8 Fix variable names manually 2020-11-02 22:40:40 +01:00
def b1f0fd8969 Enable modernize-loop-convert clang-tidy check
and run clang-format afterwards

https://clang.llvm.org/extra/clang-tidy/checks/modernize-loop-convert.html
2020-11-02 22:40:24 +01:00
def dad91eb763 Enable readability-qualified-auto clang-tidy check
https://clang.llvm.org/extra/clang-tidy/checks/readability-qualified-auto.html
2020-11-02 22:40:02 +01:00
bors[bot] 37ccb77377
Merge #3220
3220: Fix overlapping of combined binds with modifiers [Fixes #3182] r=heinrich5991 a=Banana090

Just fixes https://github.com/ddnet/ddnet/issues/3182

Works as it used to work, but does not call for binds with no modifier when the same key was used already for modified bind


Co-authored-by: Дядя Женя <spy090@yandex.ru>
2020-11-02 20:49:12 +00:00
bors[bot] 54b970b68b
Merge #3180
3180: Warn new players about name with points (fixes #3178) r=heinrich5991 a=def-

![screenshot-20201023@233252](https://user-images.githubusercontent.com/2335377/97056097-73f36a80-1588-11eb-8a43-dd42e4ef6e7d.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
- [x] Considered possible null pointers and out of bounds array indexing
- [x] Changed no physics that affect existing maps
- [x] 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>
2020-11-02 20:34:49 +00:00
Jupeyy 532d845aed Fix skin load 2020-11-02 21:21:57 +01:00
Patiga 143074349e Add m_PosEnv as index that must be offset when appended 2020-11-01 23:04:33 +01:00
Jupeyy 1d912b2df6 Don't align text with scoreboard open 2020-11-01 04:56:50 +01:00
Jupeyy c984203c2d Revert "Disable Chat render on TAB and fix tee icon position"
This reverts commit 75987a26cf.
2020-11-01 04:48:10 +01:00
bors[bot] 84ed6b7be2
Merge #3221
3221: Revert "Show halloween skins only on Halloween" r=Jupeyy a=def-

People are clearly unhappy with this event, so let's revert it. On
servers I've set events 0 already.

This reverts commit ae90bdf3f9.

## 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>
2020-10-31 22:55:33 +00:00
bors[bot] 664fa86071
Merge #3214
3214: Sort skins without case (fixes #3213) r=Jupeyy a=def-

![screenshot-20201030@100602](https://user-images.githubusercontent.com/2335377/97680791-8f360c80-1a97-11eb-8cdf-87f8c2014d47.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
- [x] Considered possible null pointers and out of bounds array indexing
- [x] Changed no physics that affect existing maps
- [x] 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>
2020-10-31 22:47:52 +00:00
def bb7ff2a482 Revert "Show halloween skins only on Halloween"
People are clearly unhappy with this event, so let's revert it. On
servers I've set events 0 already.

This reverts commit ae90bdf3f9.
2020-10-31 09:51:06 +01:00
Дядя Женя 119625d1c3
Merge branch 'master' into pr_animations_hud 2020-10-31 01:48:52 +03:00
Дядя Женя 7e180f93cb Fix rarest bug and typedef in UI animations 2020-10-31 01:45:46 +03:00
Дядя Женя 71079f0944 Fix overlapping of combined binds with modifiers 2020-10-31 01:23:07 +03:00
Дядя Женя c77648362d Some fixes to color picker 2020-10-30 22:30:06 +03:00
Дядя Женя 638a82b9bb Merge branch 'master' into pr_color_picker 2020-10-30 22:18:47 +03:00
Дядя Женя 75987a26cf Disable Chat render on TAB and fix tee icon position 2020-10-30 21:51:59 +03:00
bors[bot] 1f6eff2cd1
Merge #3204
3204: Much more readable Call Vote menu and code r=def- a=Banana090

I find "Call Vote" menu useless af right now, because it's simply impossible to read it. So when you want to call vote for a map you open website and find the one you want, after that making /map skipping the "Call Vote" menu completely. It's useful for calling for random map btw, but anyway too ugly to look at.

**OLD LOOK**
![callvoteold](https://user-images.githubusercontent.com/39315809/97338602-a48e1980-1892-11eb-8c93-5d8656d3abeb.png)

**NEW LOOK**
![callvotenew](https://user-images.githubusercontent.com/39315809/97339380-9096e780-1893-11eb-8c3c-1f8630096d9f.png)

**NEW LOOK (RconAuted)**
![callvotenewrcon](https://user-images.githubusercontent.com/39315809/97340605-0e0f2780-1895-11eb-898b-3c3b8258cced.png)



Changed nothing, but row and text size + View rect size, because for some reason it was small for preserving space for RCON Auted users. Why?
Also changed the name of rect "Extended" to "RconExtension" to make it more clear what is it for.

Would be cool also to remove all that junk that is not actual votes from DDNet server vote list (finishers, average time) and merge it into one line with map's name. 

## 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
- [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: Дядя Женя <spy090@yandex.ru>
2020-10-30 09:08:51 +00:00
def 055eadd88d Sort skins without case (fixes #3213) 2020-10-30 10:05:48 +01:00
Дядя Женя d681cc6787 Rcon Panel looks just like before in call vote 2020-10-30 06:40:15 +03:00
Дядя Женя 0f0e0caab9 ColorPicker 2020-10-30 00:39:07 +03:00
bors[bot] 641d4db676
Merge #3171
3171: Some chat fixes r=def- a=Jupeyy

Very round:
![screenshot_2020-10-22_22-16-56](https://user-images.githubusercontent.com/6654924/96926091-6a4d0280-14b5-11eb-81bf-387019f29562.png)

bit round:
![screenshot_2020-10-22_22-17-33](https://user-images.githubusercontent.com/6654924/96926098-6de08980-14b5-11eb-8086-6b1ffc48bc86.png)

No rounding left:
![screenshot_2020-10-22_22-18-16](https://user-images.githubusercontent.com/6654924/96926111-72a53d80-14b5-11eb-93d3-cb3e4ff8b475.png)

No rounding at all:
![screenshot_2020-10-22_22-18-54](https://user-images.githubusercontent.com/6654924/96926120-76d15b00-14b5-11eb-8ab8-1cb1dfc8c1a8.png)

old chat:
![screenshot_2020-10-22_22-28-43](https://user-images.githubusercontent.com/6654924/96926568-04ad4600-14b6-11eb-92eb-ff3400edc499.png)


Just gave some examples so its easier to see what is nice

Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-29 17:04:14 +00:00
Дядя Женя 94e227c8c3 Color picker: Settings UI + Picker Logic, Editboxes left 2020-10-29 03:55:01 +03:00
Zwelf 6eb95c6b96 Fix random_map and random_unfinished_map on SQLite server 2020-10-28 22:36:54 +01:00
Дядя Женя e817a179da Started making color picker 2020-10-28 05:59:50 +03:00
Дядя Женя 15f5ec9297 Tweaked call vote values 2020-10-27 20:31:27 +03:00
Дядя Женя ccbdfbb823 Much more readable Call Vote menu and code 2020-10-27 20:23:20 +03:00
Dennis Felsing 1347537561 Fix style in render.cpp 2020-10-27 13:18:33 +01:00
Дядя Женя 05d6201a72 DrawRoundRectEx readability 2020-10-26 21:50:56 +03:00
Дядя Женя b18d72db1f using time_get_mircoseconds and storing it as int64 val 2020-10-26 17:47:26 +03:00
bors[bot] 9a257a76e1
Merge #3195
3195: Use str_truncate more often 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: Dennis Felsing <dennis@felsin9.de>
2020-10-26 12:08:34 +00:00
bors[bot] a03df3a4d1
Merge #3141
3141: More hours (fixes #3140) r=heinrich5991 a=def-

Will also look into #3140 and fix here.

Co-authored-by: def <dennis@felsin9.de>
2020-10-26 12:00:13 +00:00
Dennis Felsing 9c8c36456b Use str_truncate more often 2020-10-26 12:56:21 +01:00
bors[bot] 499cbb254d
Merge #3128
3128: Add add_map_votes command for easier local map testing r=heinrich5991 a=def-

No need to tell new players how to manually add a vote or load a map from rcon

Co-authored-by: def <dennis@felsin9.de>
Co-authored-by: Dennis Felsing <dennis@felsin9.de>
2020-10-26 11:52:39 +00:00
Dennis Felsing 9b810017e1 str_truncate instead of str_copy 2020-10-26 12:49:19 +01:00
Dennis Felsing bb2f446802 Escape map in change_map 2020-10-26 11:28:04 +01:00
bors[bot] 331c9f695c
Merge #3124
3124: Remove option to make map sounds external r=def- a=Patiga

![2020-10-17-180507_401x333_scrot](https://user-images.githubusercontent.com/44099679/96347669-8dd21080-10a3-11eb-8b24-abdab7f41020.png)
Right now it is impossible to have a working external sound. External
sounds render unusable the moment the map is saved and given to another
player. For the mapper it seems like everything is working since the
mapper has the sound file. For anyone else it simply won't work. Since
1. there is no use for it and
2. it adds unnecessary complexity and confusion, 
I propose removing it entirely.

None of the ddnet maps use external sounds, only 25 maps from the map archive have external sounds

Please have a look over the changed ui code.

Co-authored-by: Patiga <dev@patiga.eu>
2020-10-26 09:50:06 +00:00
Dennis Felsing 23c005144b consistent formatting for dbg_msg
no capital letters, no spaces
2020-10-26 10:04:03 +01:00
bors[bot] b0803b26e0
Merge #3077
3077: UI Elements r=def- a=Jupeyy

Build will fail bcs of clang-format,
i'll update this comment to explain.

Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-26 08:37:25 +00:00
Дядя Женя b6d94a85f3 Visual Improvements, Fixed check-style 2020-10-26 06:10:58 +03:00
Дядя Женя 9b3d9965fb More UI Animation settings, more tabs animated 2020-10-26 05:48:05 +03:00
Дядя Женя c02086a689 Fixes 2020-10-26 04:43:34 +03:00
Дядя Женя e40539c9fd Settings Tabs Animations 2020-10-26 04:10:55 +03:00
Jupeyy 19ce3fa20e Disable text alignment for editboxes 2020-10-25 22:19:19 +01:00
bors[bot] e75cc41a9b
Merge #3191
3191: Fix IME state softlock under fcitx and macos + Update DoEditBox logic to be the same as chat r=def- a=TsFreddie

IME state fix closes #3185 and closes #3150 
DoEditBox update closes #3186, now cursor behave the same as chat where only one cursor (either the real one or the editing one) will be shown.

## 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
- [x] 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: TsFreddie <tsfreddiewang@gmail.com>
2020-10-25 21:05:29 +00:00
TsFreddie cc8fe178b5 Update DoEditBox logic to be the same as chat 2020-10-26 01:44:10 +08:00
TsFreddie f7ac41adeb Fix IME stuck when 0-len TEXTEDITING event is missing. 2020-10-25 23:48:12 +08:00
Jupeyy 13c5e039c9 Some chat fixes 2020-10-25 15:57:21 +01:00
Jupeyy 95824b24a3 Fix weapon muzzle texture cutoff 2020-10-25 15:40:22 +01:00
Jupeyy e96aba648b Reset quadsubset for muzzles 2020-10-25 14:34:02 +01:00
def b83b4c8e33 Warn new players about name with points (fixes #3178) 2020-10-23 23:37:49 +02:00
bors[bot] f74c3e5776
Merge #3176
3176: Fix float loops r=def- a=Jupeyy

Tested that one map from #bug channel

Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-23 13:36:22 +00:00
Jupeyy 6414d8d879 Fix float loops 2020-10-23 15:12:59 +02:00
Jupeyy be23e92671 Remove one particle component 2020-10-23 14:57:20 +02:00
bors[bot] 6332f90852
Merge #3115
3115: Smooth Camera r=def- a=TsFreddie

closes #3096

Since nobody expressed any opinions, how about we get this in and see some reactions. it is off by default anyway.

Co-authored-by: TsFreddie <tsfreddiewang@gmail.com>
2020-10-23 11:39:52 +00:00
bors[bot] 9832829633
Merge #3157
3157: Show option to disable system messages in settings r=Jupeyy a=def-

## Summary

Makes it a bit easier to find, prefer it on a busy server. Also clarified the friend message toggle is for highlighting only.

![screenshot-20201020@182835](https://user-images.githubusercontent.com/2335377/96615964-41d0d700-1302-11eb-910e-4c56f0c8451c.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 [does not apply]
- [x] Written a unit test if it works standalone, system.c especially [does not apply]
- [x] Considered possible null pointers and out of bounds array indexing
- [x] Changed no physics that affect existing maps
- [x] 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>
2020-10-22 15:19:31 +00:00
bors[bot] d9f08203a0
Merge #3169
3169: Allow zooming in further in Editor r=Jupeyy a=def-

As requested by Cøke

![screenshot-20201022@165820](https://user-images.githubusercontent.com/2335377/96890625-1a0b7b80-1488-11eb-9bf0-83d59f29c529.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
- [x] Considered possible null pointers and out of bounds array indexing
- [x] Changed no physics that affect existing maps
- [x] 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>
2020-10-22 15:10:47 +00:00
def 64c7f2b731 Allow zooming in further in Editor
As requested by Cøke
2020-10-22 16:59:31 +02:00
Jupeyy 07ca9b796c Killmessages should reset screen 2020-10-22 16:58:49 +02:00
Jupeyy 6eacccfba6 Make gfx_quad_as_triangle 0 default 2020-10-20 19:11:19 +02:00
def 3397869b31 Show option to disable system messages in settings 2020-10-20 18:27:58 +02:00
bors[bot] 3bdded3c4f
Merge #3122 #3137
3122: Fix arithmentic problems r=def- a=Jupeyy

The first three commits are safe

The ones i'll add later will be inside the gamecore, so might alter behaviour.

I'll see which ones are critical, but takes me some time

i fixed most in #3081

3137: Add gfx debug r=def- a=Jupeyy

If someone wants to try, you have to execute the client with a config that contains dbg_gfx 1
If opengl debug is supported it will show "Enabled OpenGL debug mode" in the console

Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-20 16:19:55 +00:00
bors[bot] e5870ab06f
Merge #3113
3113: Visual Chat Update r=def- a=Banana090

https://github.com/ddnet/ddnet/pull/3093

Co-authored-by: Дядя Женя <spy090@yandex.ru>
2020-10-20 16:03:57 +00:00
bors[bot] 2709afb007
Merge #3095
3095: Disallow player name changes when the player is muted r=def- a=heinrich5991



Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2020-10-20 15:56:16 +00:00
def 655bbd2cb6 Clamp /emote duration
/home/teeworlds/src/master/src/game/server/ddracechat.cpp:1108:65: runtime error: signed integer overflow: 99999999 * 50 cannot be represented in type 'int'
2020-10-20 16:46:25 +02:00
Jupeyy 74515d4b95 UI Elements 2020-10-19 23:52:29 +02:00
bors[bot] c1dea54d80
Merge #3149
3149: Fix memory leak on team finish and read of uninitialized data r=def- a=Zwelf

Fixes #2522, fixes #3144 and fixes second leak from #3134.

Co-authored-by: Zwelf <zwelf@strct.cc>
2020-10-19 17:09:43 +00:00
bors[bot] dfe3bb44cb
Merge #3139
3139: Use NUM_DUMMYS for dummy array length r=def- a=ChillerDragon

Should make code more readable by explaining that the array is used for dummy. Also makes modders life easier if there is a need to scale up dummy count.

I left out two places that do not include client.h

3be8a592e5/src/game/client/prediction/gameworld.h (L92)

3be8a592e5/src/game/gamecore.h (L212)

Moving the enum to protocol.h for example is probably not nice.

Co-authored-by: ChillerDrgon <ChillerDragon@gmail.com>
2020-10-19 16:37:22 +00:00
Zwelf 81131c7831 Fix grammar mistake 2020-10-19 15:23:48 +02:00
Zwelf 6d11c34d63 Load game UUID on /load
Fixes #2522 and #3144
2020-10-19 15:21:23 +02:00
bors[bot] aca143cb7d
Merge #3129 #3138 #3143
3129: Editor: Fix selection of None value in auto rules (fixes #3013) r=Jupeyy a=def-

by starting the indexing at 0

3138: Fix out of bounds access in GetSolo r=Jupeyy a=def-

As discovered in #3135

3143: Ignore ddnet-info.json dl failure again r=Jupeyy a=def-

too aggressive, might just be bad internet at the moment

Co-authored-by: def <dennis@felsin9.de>
2020-10-19 12:46:44 +00:00
bors[bot] 4360d78753
Merge #3148
3148: Fix out of bounds array access in DoEditBox r=Jupeyy a=def-

Introduced in 186206d40c

Co-authored-by: def <dennis@felsin9.de>
2020-10-19 12:39:39 +00:00
def 8e6b9f017d Fix out of bounds array access in DoEditBox
Introduced in 186206d40c
2020-10-19 14:34:10 +02:00
bors[bot] 51b5858b7e
Merge #3146
3146: Disallow cl_text_entities_size 0 (fixes #3145) r=Jupeyy a=def-

@BannZay 

Co-authored-by: def <dennis@felsin9.de>
2020-10-19 12:30:33 +00:00
Jupeyy 90db24c356 clamp font size to atleast 2 (fixes #3145) 2020-10-19 14:18:23 +02:00
def 5ba8d8ecdb Disallow cl_text_entities_size 0 (fixes #3145) 2020-10-19 13:49:38 +02:00
def bd14545b47 Show times with hours in SQL (fixes #3140) 2020-10-18 23:47:13 +02:00
def 67178b0ea0 Use str_time/str_time_float everywhere 2020-10-18 23:47:09 +02:00
def 8dfcd67fe6 Add str_time/str_time_float
Handles centisecs < 0

Uses int64, otherwise we're limited to ~260 days
2020-10-18 23:44:47 +02:00
ChillerDrgon f1bb5b5bd9 Use NUM_DUMMIES for dummy array length 2020-10-18 23:15:25 +02:00
def 3d94f9c7af Finish chat msg: Add comment 2020-10-18 17:57:27 +02:00
def 0748ad7a6b Finish time in HUD: Show hours 2020-10-18 17:57:02 +02:00
def debf263326 Fix out of bounds access in GetSolo
As discovered in #3135
2020-10-18 16:52:29 +02:00
ChillerDragon c81eb50b50 Fix halloween logic 2020-10-18 10:26:52 +02:00
bors[bot] 91773cd991
Merge #3116
3116: Show halloween skins only on Halloween r=heinrich5991 a=def-

Making use of the skin downloader.

Skin choice is based on your name, only active on October 31 and November 1 with events 1 in settings

Co-authored-by: def <dennis@felsin9.de>
2020-10-18 00:33:47 +00:00
def 343e48248e Editor: Fix selection of None value in auto rules (fixes #3013)
by starting the indexing at 0
2020-10-18 00:33:04 +02:00
def 81bc68d9d0 Add add_map_votes command for easier local map testing
No need to tell new players how to manually add a vote or load a map
from rcon
2020-10-18 00:06:43 +02:00
def ad3bc98578 Revert "Make GL 1.5 default"
As discussed with Lerath2, we should try to debug

This reverts commit 537f47d11d.
2020-10-17 23:34:16 +02:00
bors[bot] 54c7a5bba5
Merge #3108
3108: Make GL 1.5 default r=def- a=Jupeyy

If ppl see white textures its related to
#2125
and you need to revert it, bcs thats not fixable, there is no extension for GL_GENERATE_MIPMAP or smth

Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-17 21:09:11 +00:00
Jupeyy 896dd66dfe Don't render invalid laser 2020-10-17 21:34:10 +02:00
Jupeyy 3aef2ebfe0 Make closest_point_on_line safer
Does not change behaviour, all NaNs resulted in false checks
2020-10-17 20:22:13 +02:00
Patiga 8d7b00275f Remove obselete line 2020-10-17 20:16:26 +02:00
Jupeyy d52cd5c41a Check if distance is bigger than 0
Is safe, the first check even checks if Distance is > 0
The second check, checks if Distance is > something positive
2020-10-17 20:00:18 +02:00
Jupeyy 9f10dba7d1 Fix NaN in ninja muzzle 2020-10-17 19:58:17 +02:00
Jupeyy fa8b8b9324 More Target cleanup 2020-10-17 19:58:07 +02:00
Jupeyy 28ee13949b Fix NaN in gamecore move
Is safe, if the distance is zero and the NaN is created by 0 / 0.0
all values multiplied or checked stay NaN, so no new position is set
2020-10-17 18:45:59 +02:00
Jupeyy c9a1586dec Fix obvious division by zero 2020-10-17 18:24:34 +02:00
Jupeyy 6426e341f3 Fix NaNs created by bad initialization 2020-10-17 18:17:13 +02:00
Jupeyy 331249ed89 Fix NaN in LoadSkin 2020-10-17 17:59:18 +02:00
Patiga 14539a8046 Remove option to make map sounds external
Right now it is impossible to have a working external sound. External
sounds render unusable the moment the map is saved and given to another
player. For the mapper it seems like everything is working since the
mapper has the sound file. For anyone else it simply won't work. Since
1. there is no use for it and 2. it adds unnecessary complexity and
confusion, I propose removing it entirely.
2020-10-17 17:45:56 +02:00
Learath2 ba7b95f7ad Revert #3066
This reverts commits:
	a2b3f45f8b
	26a07c804f
2020-10-17 17:32:52 +02:00
bors[bot] b93896b37c
Merge #3112
3112: Fix and change text cursor r=def- a=Jupeyy

Pls check if u like the new cusor and if it works now
fixes #3110

Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-17 15:00:57 +00:00
def 08045f6bd9 Only assign skin when non-Halloween skin has been chosen 2020-10-17 16:58:47 +02:00
Дядя Женя 6708a7a69d Chat visual update 2020-10-17 15:50:35 +02:00
Jupeyy 186206d40c Fix and change text cursor 2020-10-17 15:26:33 +02:00
bors[bot] 996270af18
Merge #3120
3120: Embed map sounds by default r=heinrich5991 a=Patiga

Not one ddnet map has a external map sound since there are none which would work that way

Co-authored-by: Patiga <dev@patiga.eu>
2020-10-17 13:16:55 +00:00
Patiga 17e531374c Embed sounds by default 2020-10-17 14:05:06 +02:00
def ae90bdf3f9 Show halloween skins only on Halloween
Making use of the skin downloader.

Skin choice is based on your name, only active on October 31 and November 1 with events 1 in settings
2020-10-17 12:10:56 +02:00
def 28250897d3 Version 15.1.3 2020-10-15 18:59:17 +02:00
Jupeyy 537f47d11d Make GL 1.5 default 2020-10-15 18:47:06 +02:00
Learath 85f385b37b Optimize nameplate rendering. Fix #3103 2020-10-15 15:35:25 +02:00
bors[bot] 9e060d78b0
Merge #3100
3100: Fix offline client that is not in menu r=heinrich5991 a=Jupeyy

E.g. popups like "ddnet-info.json" failed will cause weird NaN glitches, bcs the impl relys on ChangePosition to clean movetime and animation start

Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-14 21:54:46 +00:00
bors[bot] 09549ebc85
Merge #3101
3101: Fix hookchains r=heinrich5991 a=Jupeyy

Its already increased by the for loop.
Might have made the hook shorter(for very very long hooks) the past 3 years xd

Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-14 21:47:21 +00:00
bors[bot] 6ed79fff5f
Merge #3099
3099: Add missing UpdateRenderInfo call r=def- a=Jupeyy



Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-14 21:27:28 +00:00
Jupeyy ca645bf53e Fix hookchains 2020-10-14 23:03:14 +02:00
Jupeyy 6eb6fad867 Fix offline client that is not in menu 2020-10-14 22:10:48 +02:00
Jupeyy fd0848291d Add missing UpdateRenderInfo call 2020-10-14 19:00:39 +02:00
heinrich5991 070504b5c8 Update ghost format to v6: Replace CRC with SHA256
To be friendly to other implementors of the format, the CRC field is now
zeroed out instead of completely gone.

Drop support for v2 and v3 of the ghost format, the ghost files should
have been automatically converted by the client already.
2020-10-14 17:08:58 +02:00
heinrich5991 6ff53358d3 Remove code for CRC in most places, except where needed for net compat
This should path the way to remove it altogether in the future.
2020-10-14 17:08:58 +02:00
heinrich5991 246d2ac3d6 Allow IServer users to check when client's names change
Use that available interface to process name change spam protection more
cleanly.
2020-10-14 16:42:35 +02:00
def 87b06d307f Fix clang-analyzer-core.UndefinedBinaryOperatorResult
/media/ddnet/src/game/client/animstate.cpp:54:27: warning: The left operand of '*' is a garbage value [clang-analyzer-core.UndefinedBinaryOperatorResult]
        pSeq->m_X += pAdded->m_X * Amount;
                                 ^
2020-10-14 15:45:47 +02:00
def 6443e708b5 Fix clang-analyzer-core.CallAndMessage
/media/ddnet/src/game/editor/auto_map.cpp:94:17: warning: Called C++ object pointer is null [clang-analyzer-core.CallAndMessage]
                                int RunID = pCurrentConf->m_aRuns.add(NewRun);
                                            ^
2020-10-14 15:45:47 +02:00
def 0867424749 Fix clang-analyzer-security.insecureAPI.strcpy
/media/ddnet/src/engine/server/sql_string_helpers.cpp:74:3: warning: Call to function 'strcpy' is insecure as it does not provide bounding of the memory buffer. Replace unbounded copy functions with analogous functions that support length arguments such as 'strlcpy'. CWE-119 [clang-analyzer-security.insecureAPI.strcpy]
2020-10-14 15:45:47 +02:00
def 98d4baabed Fix clang-analyzer-core.NonNullParamChecker
/media/ddnet/src/game/server/entities/projectile.cpp:201:37: warning: Forming reference to null pointer [clang-analyzer-core.NonNullParamChecker]
                                        Found = GetNearestAirPosPlayer(pTargetChr->m_Pos, &PossiblePos);
                                                                       ^
2020-10-14 15:45:47 +02:00
def 5c1b8cd221 Fix clang-analyzer-deadcode.DeadStores
/media/ddnet/src/game/client/components/statboard.cpp:288:3: warning: Value stored to 'tw' is never read [clang-analyzer-deadcode.DeadStores]
2020-10-14 15:45:47 +02:00
def a4f13ed4a8 Fix clang-analyzer-optin.portability.UnixAPI
and mark some false positives

/media/ddnet/src/engine/client/backend_sdl.cpp:329:30: warning: Call to 'malloc' has an allocation size of 0 bytes [clang-analyzer-optin.portability.UnixAPI]
2020-10-14 15:45:43 +02:00
def 911cb5cb9b CAutoMapper: Delete pUpdateLayer
/media/ddnet/src/game/editor/auto_map.cpp:433:1: warning: Potential leak of memory pointed to by 'pUpdateLayer' [clang-analyzer-cplusplus.NewDeleteLeaks]
}
^
2020-10-14 14:54:33 +02:00
def 7d476c3858 Fix clang-analyzer-security.FloatLoopCounter
[81/219] Building CXX object CMakeFiles/game-shared.dir/src/game/collision.cpp.o
/media/ddnet/src/game/collision.cpp:1197:2: warning: Variable 'f' with floating point type 'float' should not be used as a loop counter [clang-analyzer-security.FloatLoopCounter]
        for(float f = 0; f < d; f++)
        ^
2020-10-14 14:54:33 +02:00
TsFreddie 6006c9d85b smooth camera 2020-10-14 08:43:30 +08:00
heinrich5991 5b4c64005f Disallow player name changes when the player is muted 2020-10-14 01:19:41 +02:00
Jupeyy 8e9baedf9a Use pointer directly for tile layer building 2020-10-13 19:52:14 +02:00
Jupeyy 4c87b0cf05 Make menu background camera impl more robust 2020-10-13 15:37:34 +02:00
Patiga a252097e9a Fix comments 2020-10-13 09:53:33 +02:00
Patiga 06e90505b1 Use the same value as vanilla 2020-10-13 09:50:03 +02:00
def fedb031250 Version 15.1.2 2020-10-12 15:13:22 +02:00
Jupeyy ec16abdb54 Fix skin load 2020-10-12 12:31:43 +02:00
bors[bot] 1d961a262f
Merge #3069
3069: Recreate score hud when any score changed r=Learath2 a=def-

Fixes problem with too long strings because we display the score centered

Thanks to ExP for report:
![screenshot_2020-10-11_17-18-45](https://user-images.githubusercontent.com/2335377/95682429-7a2b3380-0be5-11eb-8186-c1dbf922b960.png)

Fixed:
![screenshot-20201011@171419](https://user-images.githubusercontent.com/2335377/95682443-88794f80-0be5-11eb-9d10-79ea5df785c0.png)
![screenshot-20201011@171423](https://user-images.githubusercontent.com/2335377/95682441-857e5f00-0be5-11eb-805a-8312e43f5ba1.png)


Co-authored-by: def <dennis@felsin9.de>
2020-10-11 15:45:35 +00:00
def d0005d3866 Right-align hud scores 2020-10-11 17:27:55 +02:00
def 2a06b3ccb5 Recreate score hud when any score changed
Fixes problem with too long strings because we display the score centered

Thanks to ExP for report
2020-10-11 17:15:43 +02:00
bors[bot] ea1acfd22c
Merge #3067
3067: Document highest and lowest values for cl_video_crf r=heinrich5991 a=def-



Co-authored-by: def <dennis@felsin9.de>
2020-10-11 14:54:03 +00:00
bors[bot] 91619b9886
Merge #3051
3051: Fix some undefined behaviour r=heinrich5991 a=def-



Co-authored-by: def <dennis@felsin9.de>
2020-10-11 14:46:44 +00:00
bors[bot] 7e84e1ef43
Merge #3066
3066: Disallow more commands with testing mode r=def- a=heinrich5991

Also show some useful error message

Supersedes #2778.

Co-authored-by: Andrii <bannzay3@gmail.com>
Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2020-10-11 14:39:29 +00:00
def ae1a266dac CCharacterCore::Tick caused out of bounds
src/game/teamscore.cpp:27:78: runtime error: index -1 out of bounds for type 'int const[64]'
    #0 0xf5b948 in CTeamsCore::CanKeepHook(int, int) const src/game/teamscore.cpp:27
    #1 0xf46fe1 in CCharacterCore::Tick(bool) src/game/gamecore.cpp:325
    #2 0xaf7366 in CGameClient::DetectStrongHook() src/game/client/gameclient.cpp:2441
    #3 0xadd734 in CGameClient::UpdatePrediction() src/game/client/gameclient.cpp:2249
    #4 0xad6e17 in CGameClient::OnNewSnapshot() src/game/client/gameclient.cpp:1675
    #5 0x522d55 in CClient::Update() src/engine/client/client.cpp:2767
    #6 0x5333e4 in CClient::Run() src/engine/client/client.cpp:3237
    #7 0x557fda in main src/engine/client/client.cpp:4341
    #8 0x7f55e8c75cc9 in __libc_start_main ../csu/libc-start.c:308
    #9 0x433e29 in _start (build/DDNet+0x433e29)

src/game/teamscore.cpp:34:78: runtime error: index -1 out of bounds for type 'int const[64]'
    #0 0xf5be68 in CTeamsCore::CanCollide(int, int) const src/game/teamscore.cpp:34
    #1 0xf46458 in CCharacterCore::Tick(bool) src/game/gamecore.cpp:271
    #2 0xaf7374 in CGameClient::DetectStrongHook() src/game/client/gameclient.cpp:2442
    #3 0xadd734 in CGameClient::UpdatePrediction() src/game/client/gameclient.cpp:2249
    #4 0xad6e17 in CGameClient::OnNewSnapshot() src/game/client/gameclient.cpp:1675
    #5 0x522d55 in CClient::Update() src/engine/client/client.cpp:2767
    #6 0x5333e4 in CClient::Run() src/engine/client/client.cpp:3237
    #7 0x557fda in main src/engine/client/client.cpp:4341
    #8 0x7f55e8c75cc9 in __libc_start_main ../csu/libc-start.c:308
    #9 0x433e29 in _start (build/DDNet+0x433e29)
2020-10-11 16:37:03 +02:00
def 476a912b3f Fix CRaceDemo + CGhost out of bounds access
#0 0x9f70dd in CRaceDemo::OnMessage(int, void*) src/game/client/components/race_demo.cpp:134
    #1 0xab81af in CGameClient::OnMessage(int, CUnpacker*, bool) src/game/client/gameclient.cpp:823
    #2 0x50ff76 in CClient::ProcessServerPacket(CNetChunk*) src/engine/client/client.cpp:2100
    #3 0x51bf62 in CClient::PumpNetwork() src/engine/client/client.cpp:2580
    #4 0x526b56 in CClient::Update() src/engine/client/client.cpp:2856
    #5 0x5333e4 in CClient::Run() src/engine/client/client.cpp:3237
    #6 0x557fda in main src/engine/client/client.cpp:4341
    #7 0x7f55e8c75cc9 in __libc_start_main ../csu/libc-start.c:308
    #8 0x433e29 in _start (build/DDNet+0x433e29)

src/game/client/components/ghost.cpp:600:35: runtime error: index -1 out of bounds for type 'CGameClient::CClientData [64]'
    #0 0x78201a in CGhost::OnMessage(int, void*) src/game/client/components/ghost.cpp:600
    #1 0xab81af in CGameClient::OnMessage(int, CUnpacker*, bool) src/game/client/gameclient.cpp:823
    #2 0x50ff76 in CClient::ProcessServerPacket(CNetChunk*) src/engine/client/client.cpp:2100
    #3 0x51bf62 in CClient::PumpNetwork() src/engine/client/client.cpp:2580
    #4 0x526b56 in CClient::Update() src/engine/client/client.cpp:2856
    #5 0x5333e4 in CClient::Run() src/engine/client/client.cpp:3237
    #6 0x557fda in main src/engine/client/client.cpp:4341
    #7 0x7f55e8c75cc9 in __libc_start_main ../csu/libc-start.c:308
    #8 0x433e29 in _start (build/DDNet+0x433e29)
2020-10-11 16:37:03 +02:00
def 6680ec388c Reset CCharacterCore at start
Hopefully fixes these by initializing m_Pos:

src/game/collision.cpp:345:10: runtime error: -nan is outside the range of representable values of type 'int'
    #0 0x55e85a8f0967 in CCollision::IntersectLineTeleHook(vector2_base<float>, vector2_base<float>, vector2_base<float>*, vector2_base<float>*, int*) /media/ddnet/src/game/collision.cpp:345:10
    #1 0x55e85a90767b in CCharacterCore::Tick(bool) /media/ddnet/src/game/gamecore.cpp:255:27
    #2 0x55e85af8e477 in CCharacter::Tick() /media/ddnet/src/game/client/prediction/entities/character.cpp:562:9
    #3 0x55e85afc867f in CGameWorld::Tick() /media/ddnet/src/game/client/prediction/gameworld.cpp:193:10
    #4 0x55e85af500b8 in CGameClient::UpdatePrediction() /media/ddnet/src/game/client/gameclient.cpp:2279:16
    #5 0x55e85af48b9b in CGameClient::OnNewSnapshot() /media/ddnet/src/game/client/gameclient.cpp:1675:3
    #6 0x55e85a9fdf8c in CClient::Update() /media/ddnet/src/engine/client/client.cpp:2767:22
    #7 0x55e85aa0cefe in CClient::Run() /media/ddnet/src/engine/client/client.cpp:3237:4
    #8 0x55e85aa2eb2e in main /media/ddnet/src/engine/client/client.cpp:4341:11
    #9 0x7feedbc65151 in __libc_start_main (/usr/lib/libc.so.6+0x28151)
    #10 0x55e85a77be0d in _start (/media/ddnet/DDNet+0x705e0d)

src/base/math.h:22:40: runtime error: -nan is outside the range of representable values of type 'int'
    #0 0x55e85a900c2f in round_to_int(float) /media/ddnet/src/base/math.h:22:40
    #1 0x55e85a90cac1 in CCharacterCore::Write(CNetObj_CharacterCore*) /media/ddnet/src/game/gamecore.cpp:515:22
    #2 0x55e85a90e171 in CCharacterCore::Quantize() /media/ddnet/src/game/gamecore.cpp:574:2
    #3 0x55e85af90be9 in CCharacter::TickDefered() /media/ddnet/src/game/client/prediction/entities/character.cpp:580:9
    #4 0x55e85afc8a1b in CGameWorld::Tick() /media/ddnet/src/game/client/prediction/gameworld.cpp:201:10
    #5 0x55e85af500b8 in CGameClient::UpdatePrediction() /media/ddnet/src/game/client/gameclient.cpp:2279:16
    #6 0x55e85af48b9b in CGameClient::OnNewSnapshot() /media/ddnet/src/game/client/gameclient.cpp:1675:3
    #7 0x55e85a9fdf8c in CClient::Update() /media/ddnet/src/engine/client/client.cpp:2767:22
    #8 0x55e85aa0cefe in CClient::Run() /media/ddnet/src/engine/client/client.cpp:3237:4
    #9 0x55e85aa2eb2e in main /media/ddnet/src/engine/client/client.cpp:4341:11
    #10 0x7feedbc65151 in __libc_start_main (/usr/lib/libc.so.6+0x28151)
    #11 0x55e85a77be0d in _start (/media/ddnet/DDNet+0x705e0d)
2020-10-11 16:37:03 +02:00
def 60f4e078b7 Out of bounds access in RenderPlayer
src/game/client/components/players.cpp:197:5: runtime error: index -2 out of bounds for type 'CGameClient::CClientData [64]'
    #0 0x56548eec0487 in CPlayers::RenderPlayer(CNetObj_Character const*, CNetObj_Character const*, CTeeRenderInfo const*, int, float) /media/ddnet/src/game/client/components/players.cpp:197:37
    #1 0x56548ec97234 in CGhost::OnRender() /media/ddnet/src/game/client/components/ghost.cpp:344:26
    #2 0x56548ef92b26 in CGameClient::OnRender() /media/ddnet/src/game/client/gameclient.cpp:676:28
    #3 0x56548ea4659e in CClient::Render() /media/ddnet/src/engine/client/client.cpp:1134:16
    #4 0x56548ea7b90f in CClient::Run() /media/ddnet/src/engine/client/client.cpp:3285:7
    #5 0x56548ea9bb2e in main /media/ddnet/src/engine/client/client.cpp:4341:11
    #6 0x7f7c844f1151 in __libc_start_main (/usr/lib/libc.so.6+0x28151)
    #7 0x56548e7e8e0d in _start (/media/ddnet/DDNet+0x705e0d)
2020-10-11 16:37:03 +02:00
def 47299e8586 Out of bounds access in CMenus::RenderGame
src/game/client/components/menus_ingame.cpp:108:16: runtime error: index -1 out of bounds for type 'CGameClient::CClientData [64]'
    #0 0x55733e6a64c4 in CMenus::RenderGame(CUIRect) /media/ddnet/src/game/client/components/menus_ingame.cpp:108:73
    #1 0x55733e632ba7 in CMenus::Render() /media/ddnet/src/game/client/components/menus.cpp:1228:6
    #2 0x55733e64b141 in CMenus::OnRender() /media/ddnet/src/game/client/components/menus.cpp:2338:2
    #3 0x55733e815706 in CGameClient::OnRender() /media/ddnet/src/game/client/gameclient.cpp:676:28
    #4 0x55733e2c959e in CClient::Render() /media/ddnet/src/engine/client/client.cpp:1134:16
    #5 0x55733e2fe90f in CClient::Run() /media/ddnet/src/engine/client/client.cpp:3285:7
    #6 0x55733e31eb2e in main /media/ddnet/src/engine/client/client.cpp:4341:11
    #7 0x7f9a2057e151 in __libc_start_main (/usr/lib/libc.so.6+0x28151)
    #8 0x55733e06be0d in _start (/media/ddnet/DDNet+0x705e0d)

SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior src/game/client/components/menus_ingame.cpp:108:16 in
src/game/client/components/menus_ingame.cpp:109:14: runtime error: index -1 out of bounds for type 'CGameClient::CClientData [64]'
    #0 0x55733e6a699a in CMenus::RenderGame(CUIRect) /media/ddnet/src/game/client/components/menus_ingame.cpp:109:71
    #1 0x55733e632ba7 in CMenus::Render() /media/ddnet/src/game/client/components/menus.cpp:1228:6
    #2 0x55733e64b141 in CMenus::OnRender() /media/ddnet/src/game/client/components/menus.cpp:2338:2
    #3 0x55733e815706 in CGameClient::OnRender() /media/ddnet/src/game/client/gameclient.cpp:676:28
    #4 0x55733e2c959e in CClient::Render() /media/ddnet/src/engine/client/client.cpp:1134:16
    #5 0x55733e2fe90f in CClient::Run() /media/ddnet/src/engine/client/client.cpp:3285:7
    #6 0x55733e31eb2e in main /media/ddnet/src/engine/client/client.cpp:4341:11
    #7 0x7f9a2057e151 in __libc_start_main (/usr/lib/libc.so.6+0x28151)
    #8 0x55733e06be0d in _start (/media/ddnet/DDNet+0x705e0d)
2020-10-11 16:37:03 +02:00
def f94d476cf2 Don't divide by 0 in LoadSkin
src/game/client/components/skins.cpp:142:14: runtime error: -nan is outside the range of representable values of type 'int'
    #0 0x55b6bd0f49e1 in CSkins::LoadSkin(char const*, char const*, int, int*) /media/ddnet/src/game/client/components/skins.cpp:142:14
    #1 0x55b6bd0f0942 in CSkins::SkinScan(char const*, int, int, void*) /media/ddnet/src/game/client/components/skins.cpp:55:16
    #2 0x55b6bcb33928 in fs_listdir /media/ddnet/src/base/system.c:2033:6
    #3 0x55b6bcb04024 in CStorage::ListDirectory(int, char const*, int (*)(char const*, int, int, void*), void*) /media/ddnet/src/engine/shared/storage.cpp:316:5
    #4 0x55b6bd0f9e2f in CSkins::Refresh() /media/ddnet/src/game/client/components/skins.cpp:222:13
    #5 0x55b6bd0f6e33 in CSkins::OnInit() /media/ddnet/src/game/client/components/skins.cpp:194:2
    #6 0x55b6bd14c63f in CGameClient::OnInit() /media/ddnet/src/game/client/gameclient.cpp:322:28
    #7 0x55b6bcc5f9f8 in CClient::Run() /media/ddnet/src/engine/client/client.cpp:3089:16
    #8 0x55b6bcc84b7e in main /media/ddnet/src/engine/client/client.cpp:4341:11
    #9 0x7f1144ded151 in __libc_start_main (/usr/lib/libc.so.6+0x28151)
    #10 0x55b6bc9d1e0d in _start (/media/ddnet/DDNet+0x705e0d)
2020-10-11 16:37:03 +02:00
def 612f665a6e Document highest and lowest values for cl_video_crf 2020-10-11 16:29:39 +02:00
heinrich5991 a2b3f45f8b Reintroduce CMDFLAG_TEST
Add some more helpful messages for executing test/game commands.
2020-10-11 16:27:28 +02:00
def b7c8da54a3 Make clan plates fit & only show when name plates enabled
Thanks to HamidReza for report
2020-10-11 16:24:01 +02:00
Andrii 26a07c804f Disallow game-related commands unless testing is enabled 2020-10-11 16:02:10 +02:00
bors[bot] 6ab806fde8
Merge #3048 #3063
3048: Add GUI & Game sound volume sliders r=heinrich5991 a=def-

As requested by Pipou

3063: increase buffer size for name_ban messages r=heinrich5991 a=12pm

otherwise reason can be cut off

Co-authored-by: def <dennis@felsin9.de>
Co-authored-by: 12pm <30786226+12pm@users.noreply.github.com>
2020-10-11 13:00:23 +00:00
Andrii 52efb23545 Update demo browser on demo save 2020-10-11 15:45:31 +03:00
bors[bot] e44df2d136
Merge #3059
3059: Add box offset to align better on spec tab r=def- a=ardadem

Old:
![2020-10-11-12:07:54-screenshot](https://user-images.githubusercontent.com/13207692/95674696-91a0f700-0bba-11eb-8291-275cc263b6c1.png)

New:
![2020-10-11-12:08:36-screenshot](https://user-images.githubusercontent.com/13207692/95674697-92d22400-0bba-11eb-8b60-36f0d85fbae4.png)

Very small visual change but heart fits better now for >32 players.

Co-authored-by: Arda Demir <ddmirarda@gmail.com>
2020-10-11 09:15:25 +00:00
def 4327194d27 Add GUI & Game sound volume sliders
As requested by Pipou
2020-10-11 10:16:38 +02:00
def 284c287c99 Version 15.1.1 2020-10-11 10:14:21 +02:00
bors[bot] a68fca6d7c
Merge #3036
3036: Consider as not-afk on emoticon, chat, vote, r=heinrich5991 a=def-

call vote, spectator mode, info change

Co-authored-by: def <dennis@felsin9.de>
2020-10-11 00:26:30 +00:00
def 507f7f6085 Version 15.1 2020-10-11 00:00:33 +02:00
Jupeyy 58bd8dcbb6 Fix virtual call in Constructor 2020-10-10 12:16:27 +02:00
bors[bot] 9d39e1da6d
Merge #3046
3046: Remove usages of qsort r=def- a=Learath2

Caught my eye while doing the integrity PR.

Co-authored-by: Learath2 <learath2@gmail.com>
2020-10-10 08:38:12 +00:00
Learath2 d8c9a71e18 Remove usages of qsort 2020-10-10 01:18:42 +02:00
bors[bot] 2917681bf5
Merge #3047
3047: Fix ui_page/ui_settings_page ranges r=Learath2 a=def-

For ui_page makes no difference since we limited in code

For ui_settings_page assets page is now remembered

Co-authored-by: def <dennis@felsin9.de>
2020-10-09 23:16:51 +00:00
def 10e7b2ed7b Fix ui_page/ui_settings_page ranges
For ui_page makes no difference since we limited in code

For ui_settings_page assets page is now remembered
2020-10-09 22:51:16 +02:00
Arda Demir 75cd653f4c Add box offset to align better on spec tab 2020-10-09 22:14:54 +03:00
ChillerDragon 263fdbd8e1 Use 0.7 gameskin by @Zatline
a5105264ff
db08239506
31c6d2684d
2020-10-09 21:04:06 +02:00
bors[bot] f93c8e4fdb
Merge #2987
2987: Modulize skins, particles, emoticons and game r=def- a=Jupeyy

fixes #2203 

Puh, something i always wanted todo.
Need to error read, bcs alot of copy paste.

Modulizes all images, so that all images are mipmap indepedent, without texeloffset problems

I also added the ninja bar analyzer for #2921


Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-09 15:20:48 +00:00
bors[bot] ce9ba5ec09
Merge #3018
3018: Editor: Improve usability of server settings r=Jupeyy a=def-

- Add Mod button
- Show Del button only when it makes sense
- Update command input text when clicking on an existing command
- Make command clearable

As requested by Cøke

Co-authored-by: def <dennis@felsin9.de>
2020-10-09 14:48:59 +00:00
def ea8bee4d34 Focus command field when something changed 2020-10-09 16:40:59 +02:00
bors[bot] b208ee3a81
Merge #3039
3039: Show friends on spectate tab r=def- a=ardadem

![2020-10-08-13:22:48-screenshot](https://user-images.githubusercontent.com/13207692/95447050-d5e98880-0969-11eb-923a-2b647933774d.png)
![2020-10-08-13:23:14-screenshot](https://user-images.githubusercontent.com/13207692/95447054-d71ab580-0969-11eb-8ace-a893cfa80a97.png)

Co-authored-by: Arda Demir <ddmirarda@gmail.com>
2020-10-09 14:38:12 +00:00
bors[bot] cf6ace1744
Merge #3022
3022: Text alignment r=def- a=Jupeyy

i think the round borders create a bit of optical illusion, e.g. the "V" in edtior is only 1 pixel of, but looks like its completly left xd

i checked at few resolutions with gimp and only saw around 1 pixel margin of error, but go ahead and test yourself :D

Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-09 14:31:25 +00:00
Jupeyy 8d6148b20b Modulize skins, particles, emoticons and game 2020-10-09 09:07:19 +02:00
Jupeyy 94a20d11fa Use renderinfo for player death effect 2020-10-08 21:54:53 +02:00
Arda Demir 84c36b3423 Show friends on spectate tab 2020-10-08 13:25:05 +03:00
bors[bot] 2d0c65bf53
Merge #3038
3038: Use std::sort instead of bubble_sort r=def- a=Jupeyy

Noticed, that its really slow, when you have alot of auto demos

Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-08 08:36:53 +00:00
bors[bot] cbec1a5eb4
Merge #3037
3037: Init date for demo dirs r=def- a=Jupeyy

Just to not rely on uninitialized values

Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-08 08:30:05 +00:00
Jupeyy 52911e4302 Use std::sort instead of bubble_sort 2020-10-08 08:00:01 +02:00
Jupeyy a4b32d19a1 Init date for demo dirs 2020-10-08 07:20:32 +02:00
bors[bot] 6376890fc1
Merge #3035
3035: Fix button rendering in "Render demo" r=Jupeyy a=def-

hopefully. For me "Show chat" didn't work, works now. For Дядя Женя
"Use sounds" was flickering, but can't reproduce

![screenshot-20201007@231230](https://user-images.githubusercontent.com/2335377/95388468-a3e90f80-08f2-11eb-8818-5b9e91116c49.png)

Co-authored-by: def <dennis@felsin9.de>
2020-10-08 04:59:34 +00:00
def 04b840f542 Consider as not-afk on emoticon, chat, vote,
call vote, spectator mode, info change
2020-10-07 23:24:50 +02:00
def 51b967085a Fix button rendering in "Render demo"
hopefully. For me "Show chat" didn't work, works now. For Дядя Женя
"Use sounds" was flickering, but can't reproduce
2020-10-07 23:12:18 +02:00
Arda Demir 9ead551b98 Render afk emote instead of chat emote 2020-10-07 22:04:07 +03:00
Tim Schumacher 29644780af
Redownload skins of other players on skin directory refresh (closes #3030) 2020-10-07 12:19:38 +02:00
Jupeyy 5ebabe2ece Text alignment 2020-10-07 04:44:35 +02:00
bors[bot] 4a30ef1e9a
Merge #3020
3020: Fix all Multiplication type alerts by CodeQL r=heinrich5991 a=def-

> Multiplication result converted to larger type

> A multiplication result that is converted to a larger type can be a
> sign that the result can overflow the type converted from.

Example: https://github.com/ddnet/ddnet/security/code-scanning/17?query=ref%3Arefs%2Fheads%2Fmaster

Co-authored-by: def <dennis@felsin9.de>
2020-10-07 00:56:19 +00:00
bors[bot] bbd87eb128
Merge #3025
3025: Don't make width depend on localized text r=heinrich5991 a=def-

or we end up with totally broken input boxes

As reported by Rezee:
![unknown](https://user-images.githubusercontent.com/2335377/95226414-31e2ce80-07fd-11eb-8ea6-a612bc2397bb.png)

Co-authored-by: def <dennis@felsin9.de>
2020-10-06 21:40:14 +00:00
def 6a0a1ce522 Don't make width depend on localized text
or we end up with totally broken input boxes
2020-10-06 17:55:24 +02:00
bors[bot] 1a4866182e
Merge #3023
3023: Add refresh button for skins, closes #2979 r=def- a=Blacksky780i

![image](https://user-images.githubusercontent.com/72441389/95212455-00163b80-07ee-11eb-953e-2e0593b8cfea.png)


Co-authored-by: Irisk <>
2020-10-06 15:14:46 +00:00
bors[bot] 4706b0f5be
Merge #3005
3005: Use rest instead of string in some commands r=heinrich5991 a=def-

where it makes sense, means you don't need to quote strings for those

Co-authored-by: def <dennis@felsin9.de>
2020-10-06 15:06:45 +00:00
Irisk fb0372b97f Add refresh button for skins, closes #2979 2020-10-06 16:04:59 +02:00
bors[bot] 1f7d544349
Merge #3010 #3014
3010: Use hours in score hud and record r=Learath2 a=def-



3014: Scale auto mapper text size (partially fixes #3013) r=Learath2 a=def-



Co-authored-by: def <dennis@felsin9.de>
2020-10-06 11:22:06 +00:00
bors[bot] 25e025dd16
Merge #3008
3008: Censor string multiple times r=Learath2 a=def-



Co-authored-by: def <dennis@felsin9.de>
2020-10-06 11:04:45 +00:00
bors[bot] 79b5852e17
Merge #3021
3021: only load + save auto mappers for tile layers, not physics layers r=def- a=Patiga

If I'm not mistaken, loading a map without auto mappers, then saving would've caused uninitialized values to be written to the auto mappers of physics layers.

Co-authored-by: patiga <dev@patiga.eu>
2020-10-06 07:37:26 +00:00
bors[bot] ecb5e4c790
Merge #3015
3015: Allow quitting instantly with SDL_QUIT when non-warning dialog showing r=Jupeyy a=def-



Co-authored-by: def <dennis@felsin9.de>
2020-10-06 00:33:04 +00:00
patiga 95fadea794 Fix style properly 2020-10-05 20:09:19 +02:00
patiga 09a9ca9699 Conform to style 2020-10-05 19:59:48 +02:00
patiga d123d928b4 only load + save auto mappers for tile layers, not physics layers 2020-10-05 19:44:26 +02:00
def 62dc12aacb Fix all Multiplication type alerts by CodeQL
> Multiplication result converted to larger type

> A multiplication result that is converted to a larger type can be a
> sign that the result can overflow the type converted from.

Example: https://github.com/ddnet/ddnet/security/code-scanning/17?query=ref%3Arefs%2Fheads%2Fmaster
2020-10-05 19:03:54 +02:00
bors[bot] 75bdcce3ce
Merge #2980
2980: Fix laser prediction for non ddrace mods r=def- a=Jupeyy

Correct me, if this is wrong, but only ddrace based mods cannot shot laser through itself.
Tested on vanilla, ictf and fng(with antiping on and prediction on)

Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2020-10-05 16:29:35 +00:00