2728: Allow loading from any server r=Zwelf a=def-
Since we are switching to a single write sql server for sake of simplicity
Co-authored-by: def <dennis@felsin9.de>
2722: Increase default font texture size r=heinrich5991 a=Jupeyy
Now that we have fallback fonts this makes sense.
Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2715: Fix server responses handling in game browser r=heinrich5991 a=BannZay
Fixes all problems for #2620
Explanations of existed problems:
Lan has non expected servers because we were creating browser entry regardless token check
DDNet tab has ping 0 for servers as we weren`t rejecting previous refresh responses
Co-authored-by: Andrii <bannzay3@gmail.com>
2713: allow empty max ping filter r=heinrich5991 a=BannZay
The inconvenieces I discovered so far:
1. You got to write 999 to "disable" this filter
2. If you try to clear this field and then type 75 then the field will contain 750 because the last zero is bugged at this point
Those are fixed
What I would like to be fixed as well (not sure if I gona do this soon):
1. Update browser servers live without refreshing. You press refresh - you receives all the servers and then you should be able (but currently not) to filter them out without pressing on "Refresh" button again but just by changing the max ping value
Co-authored-by: Andrii <bannzay3@gmail.com>
2674: Add nameplates friend marks r=heinrich5991 a=BannZay
Problem: when I play with a friend in team 0, and there are many players nearby, I cannot distinguish him due to nameplates overlapping. It's getting worse when they are in freeze.
Solution: Mark your teammate as "Friend" and setup "cl_nameplates_friendmark"
Result:
![v2](https://user-images.githubusercontent.com/17499770/91647684-08988b00-ea66-11ea-9407-336437391b4f.png)
Co-authored-by: Andrii <bannzay3@gmail.com>
2710: Fix layers right click on item opens menu for previously selected (left clicked) item r=heinrich5991 a=BannZay
```
Im 'corneumToday at 16:55
when i have a layer selected and rightclick on another one to change its properties, it doesnt switch to that layer. that hasnt always been this way and its throwing me off lately
especially because it still opens the menu for the other layer
```
Co-authored-by: Andrii <bannzay3@gmail.com>
2708: Disabling 3.3 in settings tab should reset to version 3.0 r=def- a=Jupeyy
We don't have a way to query the default config value, except including the config_variables.h, do we?
Co-authored-by: Jupeyy <jupjopjap@gmail.com>
Currently, this just shows the current map in the status. Might need
localization data in Steamworks to be available to work in languages
other than English.
CC #2642
2691: Also check for divisibility by 16 of height (fixes#2687) r=heinrich5991 a=def-
2701: Set search field active when opening file dialog in editor r=heinrich5991 a=def-
2702: Remove fallback for Teeworlds' settings.cfg (partially fixes#2698) r=heinrich5991 a=def-
2705: Clarify kill and /kill r=heinrich5991 a=def-
Co-authored-by: def <dennis@felsin9.de>
2678: Load serverbrowser more fairly r=heinrich5991 a=def-
One from each country and so on instead of doing one country fully first
before moving to the next. This makes loading servers like Japan and AUS
much faster since they're at the back of the list. This also reduces the
peak number of packets sent to each IP at once.
2681: Upgrade SDL2 for Linux Steam release to 2.0.12 (fixes#2679) r=heinrich5991 a=def-
Co-authored-by: def <dennis@felsin9.de>
One from each country and so on instead of doing one country fully first
before moving to the next. This makes loading servers like Japan and AUS
much faster since they're at the back of the list. This also reduces the
peak number of packets sent to each IP at once.
2665: Use the correct name for determining ranks r=def- a=heinrich5991
Was broken by the recent Steam name update.
Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2667: Fix server port in teehistorian r=def- a=heinrich5991
Official servers weren't affected because they didn't use the default of
`sv_port 0`.
Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2662: Read server port from CNetServer but not from app config r=def- a=BannZay
Due to a34c72530b we may see "[register]: ERROR: configure your firewall/nat to let through udp on port 0."
Reason: reading port data from configs but not from server object itself
I am new to server code, take a close look to changes please
Co-authored-by: Andrii <bannzay3@gmail.com>
2656: Forbid some more whitespace and whitespace-like characters r=Learath2 a=def-
Made sure everything from
https://en.wikipedia.org/wiki/Whitespace_character#Unicode is included
As reported by Im 'corneum
Co-authored-by: def <dennis@felsin9.de>
2653: Fix background map loading r=def- a=Jupeyy
As reported.
Tested all possible contexts, hope this is right now
Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2648: Support Linux shared libs in autoupdater r=Learath2 a=def-
Since we now ship our first shared lib on Linux, libsteam_api.so
Co-authored-by: def <dennis@felsin9.de>
2647: No sampler calls in old OpenGL API r=def- a=Jupeyy
Sadly didn't see it earlier, old API still binds its samplers to textures directly.
Need this before steam release @def-
Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2598: Allow specifying an OpenGL version manually r=def- a=Jupeyy
Ofc don't merge, we'll test it first, and if we want merge it, i'd need to enable shader compability for OpenGL 4+, and general support for OpenGL 3.1 and 3.2(bcs i think they already don't allow some older GL commands).
Also i never really read in the OpenGL 1.x specification, i remember that older OpenGL versions required glBegin and stuff like that
Co-authored-by: Jupeyy <jupjopjap@gmail.com>
2631: Enable "Switch weapon on pickup" by default r=heinrich5991 a=def-
As voted in Discord, suggested by Lady Saavik
Co-authored-by: def <dennis@felsin9.de>
2637: Send larger distance when zooming r=heinrich5991 a=def-
since sometimes with dyncam it can be just at the border.
As reported by Lady Saavik
Co-authored-by: def <dennis@felsin9.de>
2606: Remove need for custom certificate r=heinrich5991 a=def-
in anticipation of using CloudFlare
Co-authored-by: def <dennis@felsin9.de>
Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2590: Add DoxyFile and document CUIRect r=def- a=edg-l
I will probably document more stuff later.
To generate docs: `doxygen Doxyfile`
Co-authored-by: Edgar <git@edgarluque.com>
2595: Change default from borderless to fullscreen r=Learath2 a=def-
Switching the default means everyone with borderless window will be
switched to fullscreen. Fullscreen has lower latency and better
performance.
As suggested by Shyzo and voted on on Discord.
Co-authored-by: def <dennis@felsin9.de>
2602: Merge DejaVuSansCJKName with DejavuWenQuanYiMicroHei and use it for all (fixes#2593) r=Learath2 a=def-
allows reading CJK for everyone independent of language chosen.
got them merged with fontforge, finally looks good.
Hopefully the lags are gone.
Co-authored-by: def <dennis@felsin9.de>
Switching the default means everyone with borderless window will be
switched to fullscreen. Fullscreen has lower latency and better
performance.
As suggested by Shyzo and voted on on Discord.
2579: Ship map_convert_07 executable, allow drag'n'drop and ship Gold Mine map (with sixup version) instead of Kobra 4 and Goo! r=def- a=def-
2588: Add instructions about how to kill and pause game r=def- a=def-
Co-authored-by: def <dennis@felsin9.de>
2566: Optimization: Don't calculate with too small fraction r=heinrich5991 a=def-
since it won't add up to anything anyway.
Hopefully doesn't break any physics.
Co-authored-by: def <dennis@felsin9.de>
2465: Sqlite3 support and prepared statements r=heinrich5991 a=Zwelf
This PR changes the abstraction layer of the score backend to thin abstractions over the MySQL and SQLite3 library. It executes all Queries in one worker thread making it easier to use the ddnet thread pool. This doesn't change much, because each the mysql-connection was locked with `m_SqlLock` beforehand, serializing writes and reads respectively.
Behavior change (even though I tried to minimize them):
* `sv_use_sql` is used to determine if mysql server should be added
* `sv_sql_failure_file` is replaced by `sv_sqlite_file`
* `sv_sqlite_file` is either used as a backup server when `sv_use_sql` is enabled or as the primary read+write server when `sv_use_sql` is disabled
* `/load` now escapes the like-string
Since I am not good at designing config file commands, I would appreciate feedback on this part.
WIP:
* [x] rewrite SQL statements to work in both MySQL and SQLite (preferable just ANSI-SQL)
* [x] create tables (`COLLATE BINARY` and encoding info)
* [x] store rank (UPSERT for points)
* [x] load birthday (different function in sqlite for time handling)
* [x] `/mapinfo` (`convert(? using utf8mb4) COLLATE utf8mb4_general_ci`)
* [x] `/map` (`convert(? using utf8mb4) COLLATE utf8mb4_general_ci`)
* [x] store teamrank (`GROUP_CONCAT`)
* [x] `/teamrank` (`GROUP_CONCAT`)
* [x] ~`/top5team` (`GROUP_CONCAT`)~ doesn't contain GROUP_CONCAT
* [x] `/times` (`UNIX_TIMESTAMP`)
* [x] `/load` without any arguments (`UNIX_TIMESTAMP`)
* [x] all commits compiling, making future bisect easier
* [x] write a sqlite_to_mysql script
* [x] write an old_file_server to sqlite script
* [x] gracefully shutdown DbPool
Co-authored-by: Zwelf <zwelf@strct.cc>
2536: Send extended snap objects as is to Sixup r=def- a=Learath2
Seems to work, @fokkonaut can you take a look?
Co-authored-by: Learath <learath2@gmail.com>
2531: Client: Support .map file drag-and-drop to open map in editor r=heinrich5991 a=def-
As suggested by Lady Saavik
Co-authored-by: def <dennis@felsin9.de>
2502: Improved dummy switching r=def- a=Fireball-Teeworlds
- Fix a use-after-free when there are no new snapshots for the cl_dummy tee after the switch: #2499 .
- When one of the tees is hooked, cycling through them will no longer show phantom hook for the other tee: https://youtu.be/mxVT4pdyGnU.
- Dummy switch might happen a bit quicker since it doesn't depend on receiving new snapshots.
- Simplified code: m_LastDummy2 is no more.
Co-authored-by: Fireball <fireball.teeworlds@gmail.com>
2501: Show "Free View" for Sixup r=fokkonaut a=Learath2
@fokkonaut is this enough?
bors delegate=fokkonaut
Co-authored-by: Learath <learath2@gmail.com>
2433: Fix votes for sixup r=heinrich5991 a=Learath2
I think this looks sane but I haven't tested it at all for idk how to even test this locally/alone
2505: Fix legacy 64 player serverinfo, don't send duplicate packets (fixes#2495) r=heinrich5991 a=def-
For legacy we sent the first packet once correctly, then the 2nd and 3rd
packet without the marker and token at the start, so they never worked.
For new 64 player serverinfo we sent all packets correctly but the 1st
packet twice.
Introduced in #1955.
2506: Prevent whisper spam from 0.7 (fixes#2504) r=heinrich5991 a=def-
Co-authored-by: Learath <learath2@gmail.com>
Co-authored-by: def <dennis@felsin9.de>
For legacy we sent the first packet once correctly, then the 2nd and 3rd
packet without the marker and token at the start, so they never worked.
For new 64 player serverinfo we sent all packets correctly but the 1st
packet twice.
Introduced in #1955.
- Fix a use-after-free when there are no new snapshots for the cl_dummy tee after the switch.
- When one of the tees is hooked, cycling through them will no longer show phantom hook for the other tee.
- Dummy switch might happen a bit quicker since it doesn't depend on receiving new snapshots.
- Simplified code: m_LastDummy2 is no more.
Probably related to #2487, was previously fixed and caused stoppers not
to work.
src/game/collision.cpp:902:247: warning: bitwise or with non-zero value always evaluates to true [-Wtautological-bitwise-compare]
src/game/collision.cpp:891:252: warning: bitwise or with non-zero value always evaluates to true [-Wtautological-bitwise-compare]
src/game/collision.cpp:885:251: warning: bitwise or with non-zero value always evaluates to true [-Wtautological-bitwise-compare]
2478: Use (u)int64 from system.h instead of (u)int64_t from cstdint r=heinrich5991 a=def-
src/game/client/prediction/gameworld.h:62:90: error: ‘int64_t’ has not been declared
62 | void CreateExplosion(vec2 Pos, int Owner, int Weapon, bool NoDamage, int ActivatedTeam, int64_t Mask);
| ^~~~~~~
2480: Send zoom status for dummy too r=heinrich5991 a=def-
Co-authored-by: def <dennis@felsin9.de>
src/game/client/prediction/gameworld.h:62:90: error: ‘int64_t’ has not been declared
62 | void CreateExplosion(vec2 Pos, int Owner, int Weapon, bool NoDamage, int ActivatedTeam, int64_t Mask);
| ^~~~~~~
2482: Only write non-defaulted config values to settings_ddnet.cfg r=heinrich5991 a=def-
As a consequence changed defaults in an update will be respected
instantly if the player hasn't changed the value.
Co-authored-by: def <dennis@felsin9.de>
2474: Remove IP skins r=heinrich5991 a=def-
2476: Use x instead of y in show distance (fixes#2475) r=heinrich5991 a=def-
Co-authored-by: def <dennis@felsin9.de>
2429: Use a cubic polynomial for smoothing zoom r=def- a=heinrich5991
Supersedes #2420.
Co-authored-by: Edgar <git@edgarluque.com>
Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2446: Fix storing finish on solo server with practice mode enabled r=heinrich5991 a=Zwelf
Fixes#2445
vulnerable versions:
* 506602d472c48821b6e7bb846b86431a113834a1..59a7e1f1873ad58b838cd3470d51b6ba84c02926~
* b99bbccd248437c928b25e32d40deaf98d8ef3ad..4186622d8750f4288be86b9064886a86c665c45d~
Problem was that `OnFinish` is only suited for team0 finishes, where `/practice` can't be enabled. Solo server finishes have to be handled like team finishes in CheckTeamFinished, which checks if `/practice` was enabled.
Co-authored-by: Zwelf <zwelf@strct.cc>
2424: Keep hook when loading r=heinrich5991 a=Zwelf
Solves issue discussed in #2374. Also keeps direction and jump, which is evaluated when player is in /pause. Fire could be deleted, as it does not affect game play in any way.
Co-authored-by: Zwelf <zwelf@strct.cc>
2413: Fix showothers for specchar r=heinrich5991 a=edg-l
Fixes https://github.com/ddnet/ddnet/issues/2410
I also made it use the Alpha on specchars that are on another team.
Co-authored-by: Edgar <git@edgarluque.com>
2401: Client tells server its zoom level (fixes#2087) r=heinrich5991 a=def-
and server adapts the visible distance to it
Co-authored-by: def <dennis@felsin9.de>
2389: Ignore emoticon of spammy players (fixes#2387) r=heinrich5991 a=def-
Controlled with the regular ignore chat button in players menu
Co-authored-by: def <dennis@felsin9.de>
2388: Get rid of the annoying font size warnings r=heinrich5991 a=def-
Since we're not doing anything about them anyway, and I get them
spamming me on every client start.
Co-authored-by: def <dennis@felsin9.de>
2390: Support cl_show_hook_coll_own/other 2 to always show (fixes#2383) r=heinrich5991 a=def-
hook collision, without broadcasting to other players.
Removed cl_show_hook_coll_always in return
Renamed cl_video_showhookcollother to cl_video_show_hook_coll_other for consistency
Co-authored-by: def <dennis@felsin9.de>