Commit graph

8039 commits

Author SHA1 Message Date
清歌 c976e6d017
Provide more controlable command for dummy
When g_Config.m_ClControlDummy id 1, we can control dummy by toggle g_Config.m_ClDummyJump or another to 1 or 0.
2018-03-14 20:14:18 +08:00
bors[bot] c65ffeb4ae Merge #1082
1082: Fix a bug with name bans r=Learath2 a=heinrich5991

Overlong nick names could be used to circumvent name bans.
2018-03-14 02:00:42 +00:00
heinrich5991 11304661db Put name ban stuff into a separate file
Fix a bug when overlong names could be used to circumvent name bans. Add
tests for name bans.
2018-03-14 02:35:31 +01:00
heinrich5991 d7f6cf2892 Fix some system.c insanity
`str_utf8_isspace` now returns true if the passed code point renders as
a space, instead of when not.

Add `str_utf8_trim_right`, use this function and
`str_utf8_skip_whitespaces` in the server.

Add tests for the three functions
2018-03-14 02:27:15 +01:00
bors[bot] cc6449bcd6 Merge #1055
1055: Keep track of lost frames and update time r=heinrich5991 a=Jupeyy

The problem a friend was occuring was, that on a fresh Windows install settings like cl_refresh_rate are set to 480.
Since the render calls take longer time than no render calls, it happened that client was sleeping on one update cycle and then took to long in another, where it called the render functions, leeding to less FPS than the cl_refresh_rate. this caused mouse lags and rarely frame drops.

another thing is, that select on Windows is non microsecond accurate, or just often returns too early, which caused that the refresh rate is much too high, or even ignored, (probably windows can only sleep on milliseconds, or again, is extremly inaccurate).

Another things on windows is that time_freq might be a "very odd" number ^^
i mean like on unix it's one microsecond (1,000,000 = 1s), but on windows the time_freq depends on the CPU leading to inaccurate calculation of the sleep time and render time.
This wasn't insanly huge issue, but probably skipped a few microseconds here and there.

This fix should stabilize the frames. I'd like to hear your opinion on this tho.
2018-03-13 19:41:38 +00:00
bors[bot] fcddc5aaf8 Merge #1079
1079: Add reason to name bans r=heinrich5991 a=Learath2
2018-03-13 18:00:07 +00:00
Learath 729a42adec More style 2018-03-13 00:13:50 +01:00
bors[bot] 42e1e3cf0c Merge #1076
1076: Execute `git_revision.py` in the source directory r=Learath2 a=heinrich5991

Previously, if using an out-of-source build directory, git would report
an error and no revision string would be added to the final executable.
2018-03-12 22:32:32 +00:00
Learath b7610901e3 Handle empty reason. Fix formatting 2018-03-12 23:29:46 +01:00
Dennis Felsing 335d458c27
Merge pull request #1080 from Ryozuki/pr_update_catalan
Update catalan translation
2018-03-12 19:48:19 +01:00
Ryozuki 1230f4e016 update catalan translation 2018-03-12 19:45:55 +01:00
Learath 22c21f73ae Actually display the reason 2018-03-12 19:09:53 +01:00
Learath c1a7c30f0f Add reason to name bans 2018-03-12 19:05:49 +01:00
Jupeyy 3858a930a9 merge mac and linux impl into one 2018-03-12 17:10:11 +01:00
Jupeyy 5b56e5b2c4 move the keyboard state back into the gfx update 2018-03-12 16:51:31 +01:00
Jupeyy 72c38bca0c devide by the time_freq 2018-03-12 16:41:02 +01:00
Jupeyy c6a9aadbb0 add missing return statement 2018-03-12 16:21:21 +01:00
Jupeyy e0b8ecabe4 move time fetch to time_get_impl 2018-03-12 16:12:06 +01:00
Jupeyy 081057d6b9 style fixes and remove float cast 2018-03-12 15:43:31 +01:00
Jupeyy 5e1bee2760 clean up a bit to and descripe it better 2018-03-12 15:10:49 +01:00
Dennis Felsing 1e3ce67ce4
Merge pull request #1077 from VeH-c/patch-1
Fixed typo
2018-03-10 09:20:55 +01:00
VeH-c 748007d525
Fixed typo 2018-03-09 22:24:56 -08:00
heinrich5991 a71cc2a55b Execute git_revision.py in the source directory
Previously, if using an out-of-source build directory, git would report
an error and no revision string would be added to the final executable.
2018-03-10 00:58:10 +01:00
heinrich5991 31a3e8d4c0 Add possibility to ban players by name
This uses the Unicode confusable data together with judging how close
two strings are by using the Levenshtein distance.

Adds the commands `name_ban`, `name_unban` and `name_bans`. Kicks
players who join using a banned name and doesn't allow ingame players to
change their names to the banned ones.
2018-03-09 20:30:27 +01:00
heinrich5991 710d0610d9 Ignore Makefiles generated by the CMake Make target 2018-03-07 19:47:45 +01:00
bors[bot] f1d4772043 Merge #1070
1070: Fix build with `-DCLIENT=OFF` on macOS r=Learath2 a=heinrich5991
2018-03-06 23:15:46 +00:00
bors[bot] 9e832174c5 Merge #1069
1069: Ignore another file generated in build directories r=Learath2 a=heinrich5991
2018-03-06 23:04:13 +00:00
heinrich5991 d118fbd5e0 Fix build with -DCLIENT=OFF on macOS 2018-03-06 19:25:59 +01:00
heinrich5991 b138f5450e Ignore another file generated in build directories 2018-03-06 19:22:56 +01:00
bors[bot] 731c329c13 Merge #1066
1066: Remove teamkill message on solo teams r=heinrich5991 a=ChillerDragon

For speedrunning alone in a team this "Everyone in your locked team was killed because '%s' %s."
is very annoying. So better only print it if more than 1 tee is in the team.
2018-03-06 13:14:18 +00:00
ChillerDragon 57cb136c55 Remove teamkill message on solo teams
For speedrunning alone in a team this "Everyone in your locked team was killed because '%s' %s."
is very annoying. So better only print it if more than 1 tee is in the team.
2018-03-06 14:08:04 +01:00
bors[bot] eef5131b0d Merge #1065
1065: Proper negative top5 calculation (fixes #1064) r=heinrich5991 a=def-
2018-03-05 11:00:57 +00:00
Dennis Felsing 93f0cd8933 Proper negative top5 calculation (fixes #1064) 2018-03-05 11:53:55 +01:00
bors[bot] fb69fa1815 Merge #1042
1042: Allow specifying DATA_DIR by compiler option r=heinrich5991 a=yangfl
2018-03-05 10:50:38 +00:00
bors[bot] 6303b11799 Merge #1062
1062: Ignore Build and Release r=heinrich5991 a=ChillerDragon

Thanks to heinrich5991
2018-03-04 10:24:09 +00:00
ChillerDragon b69b85ed54 Ignore Build and Release 2018-03-04 11:18:46 +01:00
bors[bot] e64919ddcb Merge #1058
1058: Add /pausevoted and /specvoted r=heinrich5991 a=def-

- Also fix /pause and /spec with name parameter a bit
- Move out common code between pause/spec
2018-03-02 14:41:31 +00:00
heinrich5991 458804c059 Make game dependency on generated protocol.h explicit 2018-03-02 03:42:35 +01:00
heinrich5991 565f963a7b Properly hide stderr in scripts/git_revision.py 2018-03-02 03:31:45 +01:00
Jupeyy ced0ea3f82 set the gfx refresh rate limit higher for the console 2018-03-02 03:29:02 +01:00
heinrich5991 b285d777f3 Python 2 support for scripts/git_revision.py on error /o\ 2018-03-02 03:22:44 +01:00
Jupeyy cc7371c1cd set upper limit, for the case, if the refreshrate is smaller than the gameticks 2018-03-02 03:12:30 +01:00
Dennis Felsing fca81553ba
Merge pull request #1056 from heinrich5991/pr_ddnet_cmake_regenerate_version
Regenerate version file on git changes
2018-03-01 22:01:13 +01:00
def ad99c58528 Add /pausevoted and /specvoted
- Also fix /pause and /spec with name parameter a bit
- Move out common code between pause/spec
2018-03-01 19:46:07 +01:00
heinrich5991 1387ee9a3a Regenerate version file on git changes
Previously, this file had to be manually deleted if you wanted to have a
new version compiled in.
2018-03-01 16:50:29 +01:00
Jupeyy 089cb1ea44 this must be inactive ofc 2018-03-01 08:25:34 +01:00
Jupeyy a808ee07d3 add accedentially removed cast 2018-03-01 08:07:48 +01:00
Jupeyy 3458ee0976 check if gfx_refresh_rate is non zero 2018-03-01 07:50:52 +01:00
Jupeyy 6f0509cfae the actual description to the problem 2018-03-01 07:44:22 +01:00
Jupeyy edaf632c04 Merge branch 'master' of https://github.com/ddnet/ddnet 2018-03-01 07:38:50 +01:00