Guild icon
DDraceNetwork
Development / developer
Development discussion. Logged to https://ddnet.tw/irclogs/ Connected with DDNet's IRC channel, Matrix room and GitHub repositories — IRC: #ddnet on Quakenet | Matrix: #ddnet-developer:matrix.org GitHub: https://github.com/ddnet
Between 2022-05-26 00:00:00Z and 2022-05-27 00:00:00Z
Avatar
05efc25 Add integration test script and coverage map - ChillerDragon 68bcd21 asan+ubsan clean - def- e311621 test -> integration_test - def- 8e3d5c1 Merge #5006 - bors[bot]
Avatar
hmm, I'm not sure how to do that
00:04
if I understand this right it seems to crash when something goes out of scope here
Avatar
guys, there's this annoying thing, idk if it's intended. so, you press esc, hold the disconnect button and press esc again. now you have set up a trap for whenever you press esc
00:06
this is really annoying
Avatar
Avatar
Tater
if I understand this right it seems to crash when something goes out of scope here
lol, mem_zero on class...
00:08
this is a heisenbug waiting to happen
Avatar
oh wait it's actually in CCharecterCore that the set is placed (edited)
Avatar
Basically title. This is UB as soon as the class is virtual (haven't found any case in our codebase) and for any class member variable as well. Example here: https://github.com/ddnet/ddnet/blob/8e3d5c1b5920e17274e126b8f8d8ad0b49dd6354/src/game/client/gameclient.cpp#L1100-L1104 Member variable that is probably UB (in CCharacterCore): https://github.com/ddnet/ddnet/blob/8e3d5c1b5920e17274e126b8f8d8ad0b49dd6354/src/game/gamecore.h#L225 What happens is: 1. TempCore is initialized, ...
Avatar
so probably set has no defined size
Avatar
i created an issue about this UB
00:18
oh, i forgot to credit you
00:18
sorry
00:19
you can edit if you want I think
Avatar
yup, corrected 😉
00:22
anyway, thanks for the help to improve the game 🙂
Avatar
yeah np :D
00:25
you can credit my gh account if you want @sjrc6
Avatar
Avatar
GitHub
Click to see attachment 🖼️
ty ty
Avatar
https://github.com/ddnet/ddnet/blob/master/other/ddnet.desktop when compiling the game from source and installing with sudo make install to the default directory of /usr/local/ the icon file doesn't display in the .desktop file. the path could be hardcoded in the .desktop file but that shouldn't be necessary. Does anyone know how to make it so that the Icon=ddnet will pick up on the icons located in /usr/local/share/icons/hicolor/*/apps/
Avatar
00e44ed M Target, A Merely forth 2 - ddnet-maps
Avatar
theofficialgman 2022-05-26 04:35:47Z
Hey all. I'm a developer from over at pi-apps (an open source raspberry pi app store). We are adding DDNet to the "store" but usually like to have out apps versioned (as most projects do). We have CI setup to automatically update our apps if they post github releases or any other method of obtaining the latest version. With DDNet, there doesn't appear to be any way to get the latest version number. You create tags on the github https://github.com/ddnet/ddnet but they aren't always for versions and you don't have any releases on the page. Using the website isn't really an option as that information can't really be parsed easily or reliably. Thoughts? (edited)
Avatar
@theofficialgman the https://info2.ddnet.tw/info JSON contains a "version" string, that should always be up-to-date, it's what the client uses to determine whether it's out-of-date
Avatar
theofficialgman 2022-05-26 05:31:57Z
are you referring to the news section at the bottom or something else?
05:32
ah nevermind I see it
05:32
"version": "16.1", is this guaranteed to match the github tag? not a big deal if it doesn't, our updater will just throw a warning. but its good to know anyway (edited)
Avatar
Avatar
Chairn
lol, mem_zero on class...
And I doubted the basics of C++ only because I had not figured out what is wrong and you see the mem_zero and think directly the right xD nice
Avatar
imo good style is to use struct for PODs and classes for complex types
06:10
tho generally mem_zero is more c style than c++ style
Avatar
yes, I also do not understand why we use mem_zero so often instead of using value initialisation
Avatar
yes and since c++11 u can also member initialize e.g. class CTest{ int m_A = 5; }; this cannot be skipped by the compiler
06:13
(in case u want to use a different value than 0)
06:13
its imo also nicer than to use constructors
👍 1
Avatar
Fixes #5226

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-addresss...
Avatar
@ChillerDragon A few suggestions to further expand the integration tests 1. Run the tests also on windows 2. Can we maybe output the output from the client/server somehow? currently nothing is output !grafik 3. can we do more complex processes? can you research if you could somehow simulate inputs, e.g. test if you can hook (other tees) and run.
Avatar
[quakenet] ChillerDragon BOT 2022-05-26 08:11:40Z
ou i think im onto something :D
08:11
are there any known client crashes on current master?
Avatar
you mean except when loading just about any malformed map or demo?
Avatar
[quakenet] ChillerDragon BOT 2022-05-26 08:17:26Z
yes xd
08:17
something new
08:17
maybe the new hud 🤷 last hud issue i reported was known
08:17
ill investigate
Avatar
Stun lets the client sometimes crash (edited)
08:21
but I only get it on release build
Avatar
Avatar
[quakenet] ChillerDragon
maybe the new hud 🤷 last hud issue i reported was known
what was that again xD
08:22
flickering Weapon display?
Avatar
Avatar
[quakenet] ChillerDragon
are there any known client crashes on current master?
do you have https://github.com/ddnet/ddnet/pull/5222 included in your build?
Avatar
[quakenet] ChillerDragon BOT 2022-05-26 08:26:04Z
yes i merged like 1h ago
08:28
oh wow ./DDNet > foo.log keeps colors o.O
08:28
isnt it common that programs detect such things
08:28
for example ls is colored but ls > ls.txt isnt
Avatar
cf03ada revert to SetHookedPlayer in ReadCharacterCore - C0D3D3V 62cad6b use value initialization in Evolve lambda - C0D3D3V 3b81157 Merge #5231 - bors[bot]
Avatar
Strictly enforces initialization of members, could be considered too extreme, but at least we'd end up with fewer uninitialized member accesses: https://clang.llvm.org/extra/clang-tidy/checks/cppcoreguidelines-pro-type-member-init.html

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
  • [ ] ...
Avatar
[quakenet] ChillerDragon BOT 2022-05-26 09:40:51Z
wew i get plenty of client crashes
Avatar
report all
Avatar
[quakenet] ChillerDragon BOT 2022-05-26 09:58:08Z
I WILL REPORT DA CRASHES TO THE AUTHORITIES IN A MINUTE
09:58
but first i gotta sell some 0d to US government
Avatar
[quakenet] ChillerDragon BOT 2022-05-26 10:05:50Z
i dont get the crash
Avatar
Avatar
[quakenet] ChillerDragon
oh wow ./DDNet > foo.log keeps colors o.O
You can set NO_COLOR env variable to disable colors
Avatar
Ясно Понятно 2022-05-26 10:13:12Z
@c0d3d3v did u fix crash?
Avatar

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--u...
Avatar
Avatar
c0d3d3v
but I only get it on release build
RelWithDebInfo too? Better for debugging
Avatar
Avatar
deen
RelWithDebInfo too? Better for debugging
Next time I play I will use that.
Avatar
Avatar
Ясно Понятно
@c0d3d3v did u fix crash?
yes should be fixed, and merged
Avatar
Avatar
Ясно Понятно
@c0d3d3v did u fix crash?
Avatar

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--u...
Avatar
Ясно Понятно 2022-05-26 10:38:43Z
Ok, ty later i check
Avatar
[quakenet] ChillerDragon BOT 2022-05-26 10:40:51Z
@deen yea sure but its just bad style isnt it? As I used i expect the cli colors to behave as in EVERY other application
10:42
also who of u trols is slidin in ma irc dms?
10:43
10:44
OK scratch my crashbugs they are only in my fork
Avatar
why is the client so insanly unstable rn xD what prs should i test
10:54
heap-use-after-free CGameClient::UpdatePrediction() /src/game/client/gameclient.cpp:2425:74
Avatar
``` Program terminated with signal SIGSEGV, Segmentation fault. #0 0x00007f833c0ec804 in pthread_mutex_lock () from /usr/lib/libc.so.6 [Current thread is 1 (Thread 0x7f832cf75000 (LWP 2543964))] (gdb) bt #0 0x00007f833c0ec804 in pthread_mutex_lock () at /usr/lib/libc.so.6 #1 0x000055afa324028c in gthread_mutex_lock(gthread_mutex_t*) (__mutex=0x10) at /usr/include/c++/12.1.0/x86_64-pc-linux-gnu/bits/gthr-default.h:749 #2 0x000055afa3240323 in std::mutex::lock() (this=0x10) at /u...
10:59
``` ==50506==ERROR: AddressSanitizer: heap-use-after-free on address 0x61900009f848 at pc 0x5593e52787b7 bp 0x7ffe0a0eac70 sp 0x7ffe0a0ea440 READ of size 8 at 0x61900009f848 thread T0 #0 0x5593e52787b6 in __asan_memcpy (/build_all/DDNet+0xc2a7b6) (BuildId: 901a71f18e0a233fe9284c4602d7754f132418f1) #1 0x5593e649eadd in CGameClient::UpdatePrediction() /src/game/client/gameclient.cpp:2425:74 #2 0x5593e648aba1 in CGameClient::OnNewSnapshot() /src/game/client/gameclient.cpp:1710:3...
11:00
``` ==50953==ERROR: AddressSanitizer: heap-use-after-free on address 0x61900431288b at pc 0x559fbd021cf2 bp 0x7ffdd999fe70 sp 0x7ffdd999fe68 READ of size 1 at 0x61900431288b thread T0 #0 0x559fbd021cf1 in CCharacterCore::Move() /src/game/gamecore.cpp:502:23 #1 0x559fbe01f148 in CCharacter::TickDefered() /src/game/client/prediction/entities/character.cpp:577:9 #2 0x559fbe0758e9 in CGameWorld::Tick() /src/game/client/prediction/gameworld.cpp:199:10 #3 0x559fbdfa71fa in CGa...
11:02
Yet another data structure that was uninitialized btw

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](http...
Avatar
Avatar
c0d3d3v
yes should be fixed, and merged
Ясно Понятно 2022-05-26 11:02:54Z
All work, ty
11:04
@c0d3d3v some time when i kill, i crash
11:05
Avatar
that smells like someone subtracted from a nullpointer
Avatar
Avatar
deen
that smells like someone subtracted from a nullpointer
Ясно Понятно 2022-05-26 11:08:34Z
i dont change anything
11:08
just pull , latest master, and start game
Avatar
yes i also have lot of crashes
11:09
basically unusable rn the client
Avatar
@Chairn u love small executables, remove dynamic_casts from our code and disable RTTI fno-rtti
Avatar
See for example https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94325

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...
Avatar
Avatar
Ясно Понятно
Click to see attachment 🖼️
what is the exception, and why do you have diffrent code numbers
11:46
ah read access violation, I was blind
Avatar

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--u...
Avatar
Avatar
Ясно Понятно
@c0d3d3v some time when i kill, i crash
also got a crash on kill right now. Maybe related to you get hooked + kill
Avatar
Avatar
c0d3d3v
also got a crash on kill right now. Maybe related to you get hooked + kill
#5241
Avatar
See for example https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94325 Checklist Tested the change ingame Provided screenshots if it is a visual change Tested in combination with possibly related ...
Avatar
Avatar
Jupstar ✪
#5241
strange that this change causes the delete function to crash
14:09
Avatar
Avatar
Jupstar ✪
#5241
so I let bors run on it? are you ok with it
Avatar
no lets wait until the supress is gone
Avatar
Avatar
c0d3d3v
strange that this change causes the delete function to crash
The code currently relies on UB, and the code that was added hid that
14:11
and changed behavior
Avatar
Avatar
c0d3d3v
also got a crash on kill right now. Maybe related to you get hooked + kill
I correct myself xD It basically crashes if any tee that the client knows of gets killed, but that should be clear by the issue causing it (edited)
Avatar
@Ryozuki do you use any language server in vim?
Avatar
[quakenet] ChillerDragon BOT 2022-05-26 15:04:54Z
YMC masterrace
15:04
YCM
15:05
a
15:05
@Learath2 as a true deen fanboi i use https://github.com/ycm-core/YouCompleteMe
A code-completion engine for Vim. Contribute to ycm-core/YouCompleteMe development by creating an account on GitHub.
15:05
thats all you need
Avatar
I'm guessing YCM with clangd?
15:05
Or just YCM?
15:06
Or does it come with clangd nowadays? 😄
Avatar
[quakenet] ChillerDragon BOT 2022-05-26 15:06:16Z
i think just YCM
15:06
im not aware of any clangd
15:06
never heard of it
15:06
but it works pretty feature complete to me
15:06
but i barley touch any c++ from vim
15:07
Y M C A
Avatar
``` Thread 1 "DDNet" received signal SIGSEGV, Segmentation fault. 0x00005555557f9df0 in CGameClient::UpdatePrediction (this=0x7fffec3a8010) at /home/chiller/Desktop/git/ddnet/src/game/client/gameclient.cpp:2263 2263 pLocalChar->Destroy(); (gdb) bt #0 0x00005555557f9df0 in CGameClient::UpdatePrediction() (this=0x7fffec3a8010) at /home/chiller/Desktop/git/ddnet/src/game/client/gameclient.cpp:2263 #1 0x00005555557f65d1 in CGameClient::OnNewSnapshot() (this=0x7f...
Avatar
so since we have the freeze progress bar, give us the option to disable the freeze stars
Avatar
4dc13ed Add donation by Steinchen99 - def-
16:18
Insane
16:18
Broadcom to Acquire VMware for Approximately $61 Billion in Cash and Stock
16:18
The last large buy was microsoft deal to buy blizzard for 69 bn
Avatar
peanuts
Avatar
wow VMware is worth 61 billion? (edited)
Avatar
if anyone is interested: my 1 hour demo with out of sound sync (at 1:00:00), and the demo mp4: https://btp.uber.space/ddnet/stronghold_2_bugdemo.mp4 demo: https://btp.uber.space/ddnet/stronghold_2.demo
Avatar
Avatar
cauldron
if anyone is interested: my 1 hour demo with out of sound sync (at 1:00:00), and the demo mp4: https://btp.uber.space/ddnet/stronghold_2_bugdemo.mp4 demo: https://btp.uber.space/ddnet/stronghold_2.demo
pm me your config
16:37
i wanna try out, u are on windows?
Avatar
no, on linux, and it was rendered a few months ago, i used the client from website back then. must be right after finish time. what config? opengl? is it a file?
Avatar
settings_ddnet.cfg in ~/.teeworlds
Avatar
about the removement of the freeze stars, because of freeze bar: what about deepfreeze? permanent bar? no stars at all? well i guess no stars?
Avatar
…estructor cc #5241

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/#u...
Avatar
Avatar
cauldron
if anyone is interested: my 1 hour demo with out of sound sync (at 1:00:00), and the demo mp4: https://btp.uber.space/ddnet/stronghold_2_bugdemo.mp4 demo: https://btp.uber.space/ddnet/stronghold_2.demo
ok it finished and its perfectly in sync for me what is your processor CPU & GPU?
Avatar
intel i5, intel hd3000 (edited)
Avatar
is this some intel hardware issue
17:37
i mean i used your config and can absolutly not reproduce it
17:37
perfectly in sync
17:38
https://discord.com/channels/252358080522747904/757720336274948198/979125287222640701 some other person with really modern hardware has this too
17:39
maybe smone of the devs with an intel CPU can test it
Avatar
i also have this issue: https://discord.com/channels/252358080522747904/757720336274948198/964252317094383736 maybe it is related. I rendered with mesa driver for gpu. i tried to render with LIBGL_ALWAYS_SOFTWARE=true, but then it was just black screen i think. maybe i have to select another renderer then in the settings? i would want to try to render without gpu and look if it works then. (if it's in sync then) (edited)
Avatar
the software renderer can also just be buggy if it gives u black screen
17:41
but can test it quickly
17:43
yeah black for me too
Avatar
could it work with another option/choice in graphic settings>renderer? (edited)
Avatar
maybe
Avatar
The check whether a dragger is active, I somehow got lost in the dragger teams. Sorry! Actually, I should have noticed this during testing. But when I tested Fall into the Future today, it seemed strange to me (already at the first part). I should have noticed it when I tested it. I have compared that in any case with 15.9.1 and looked at the code again and saw that there the check is made every tick.

Checklist

  • [x] Tested the change ingame
  • [ ] Provided screenshots if it is a v...
Avatar
i think software renderers mostly focus on opengl 4.5 nowadays
17:45
GLES 3 seems to work
17:45
but just to be clear, i rendered the 1h demo with OpenGL 3.0 just as your config
Avatar
i don't know anything about this, but i have the suspicion that it is related to my overall mesa freezes / crashes like in the short clip in watch_your_time. i have also issues with gpu / hardware acceleration for java guis.
Avatar
i mean you have a intel GPU, what do you expect xd
17:49
but i also have a laptop with intel hd 3000, i think everything ran fine there ^^
Avatar
yeah, i'm planning to buy a new laptop, anyway demos render with software and gles for me too, so i gonna use that.
Avatar
Avatar
cauldron
could it work with another option/choice in graphic settings>renderer? (edited)
so just to sum some stuff up the video rednerer works on the CPU, thats one of the weirdest things about this bug normally CPU bugs are rather ez to reproduce bencie tested it with vulkan and had the problem with video rendering too, so probs not even opengl related
Avatar
Avatar
cauldron
yeah, i'm planning to buy a new laptop, anyway demos render with software and gles for me too, so i gonna use that.
but with software rendering u wont have the delay? or just not tested it yet
Avatar
i tested a 28 second demo. but will try the 1 hour demo tonight when i sleep
Avatar
ok
Avatar
2402edc Remove predicted character from gameworld before calling base class destructor - trml aa5471f Merge #5244 - bors[bot]
Avatar
MSI GF63 THIN 10SCXR-1449, Gaming-Laptop mit 15,6 Zoll Display, Intel® Core™ i5 Prozessor, 8 GB RAM, 512 GB SSD, NVIDIA GeForce
Avatar
Avatar
cauldron
i might be getting nvidia in the near future: https://www.mediamarkt.de/de/product/_msi-gf63-thin-10scxr-1449-2710234.html xD
gl on linux xd
Avatar
i'll make it work
Avatar
make sure u can disable nvidia optimus, if the laptop has that
18:00
i warned you 😉
Avatar
laptops suck
18:01
beantyping
Avatar
vulcan graphic renderer problem button in the hud have no text on rx 580
Avatar
Avatar
HappyFray
vulcan graphic renderer problem button in the hud have no text on rx 580
update your drivers
18:25
this happens on outdated amd drivers
18:26
use ones from amd.com
18:26
not from windows
19:46
aw someone deleted troll
Avatar
d3bacca Add 20 € donation by Blade - def-
Avatar
62c9951 disable dragger beams soon, not only every 150ms - C0D3D3V 74b94b3 Merge #5245 - bors[bot]
Avatar
@Chairn shouldn't stuff like crashes be high priority, and not some general code cleanup stuff or https://github.com/ddnet/ddnet/issues/3533 where we don't even know the impact?
As reported by Im 'corneum: Well maybe you can recreate it. I used cheat engine to speed hack and after 14 hours some bullets stopped moving and my grenades don't rotate. Even after...
Avatar
highprio imo is either crash or potential cheat
Avatar
ad06a05 render allways the nameplate of a specchar - C0D3D3V e63b8e2 Merge #5183 - bors[bot]
Avatar
which code cleanup stuff?
21:25
my issue is about specifically a crash and UB that may or may not enable cheats or simply crashes in general
Avatar
Basically title. This is UB as soon as the class is virtual (haven't found any case in our codebase) and for any class member variable as well. Example here: ddnet/src/game/client/gameclien...
21:27
don't mem_zero CCharacterCore in that line?
Avatar
the issue does cover multiple things indeed, do you want me to split it in two?
Avatar
I guess, I was confused by the "high priority" of getting rid of all mem_zeros. maybe move that to a different issue
Avatar
it's just that i found this special case given in the first comment that was indeed crashing with MSVC due to their implementation of std::set, but the general rule applies to all mem_zero applied on classes instances
Avatar
only those that are not POD
Avatar
well, now that the special case has been solved, we can keep the current issue for the general case
21:30
yeah, but as you can see, the class CCharacterCore was POD until C0ded3v added std::set member
21:30
i'll try to move on on my initall branch this weekend
Avatar
maybe describe your approach in the issue first
Avatar
you don't, because it relied on UB anyway
21:36
non initialized value inherited random value from memory
21:36
this value could be non random if it used same space as a previous that always had the same value
21:36
but it 100% depends on the compiler
Avatar
I understand what UB is
21:44
sometimes UB results in consistent actual behavior
21:44
e.g. with the shotgun bug
21:45
also where are you picking the values from?
Avatar
no where especially, i zero initialize most of them in a safe way
21:45
compiler probably optimize most of it i hope
21:45
d2e9a78 Don't enable colors when stdout is redirected to a file (fixes #5233) - def- 0648f22 Merge #5236 - bors[bot]
Avatar
no, I see quite some non-zero values
21:46
e.g. m_Jumps, some weapon stuff, etc.
Avatar
those are default gameplay value i think, 2 jumps, infinite ammo for hammer and gun
21:48
i'll have to check those obviously 😉 (edited)
Avatar
I don't know. currently, I don't see the appeal of this solution, over, say letting the compiler initialize everything with a zero-value (I think you can do that in C++?)
Avatar
Avatar
heinrich5991
@Chairn shouldn't stuff like crashes be high priority, and not some general code cleanup stuff or https://github.com/ddnet/ddnet/issues/3533 where we don't even know the impact?
I will try to reproduce this, and make a video tomorrow... I still think this is just some visual bugs, caused by the external speed hack that forced the client to desync a lot from the server gametick
Avatar
Avatar
heinrich5991
I don't know. currently, I don't see the appeal of this solution, over, say letting the compiler initialize everything with a zero-value (I think you can do that in C++?)
i looked for compiler flags for this, haven't found anything that actually works
Avatar
Avatar
c0d3d3v
I will try to reproduce this, and make a video tomorrow... I still think this is just some visual bugs, caused by the external speed hack that forced the client to desync a lot from the server gametick
you can probably just initialize the right timer to a very big value
Avatar
the bug is not about huge timer!
Avatar
it's not?
Avatar
the issue is basically about he crying his speed hack is not working
Avatar
uh no? it's about bullets not moving and visual bug about grenade not rotating
Avatar
I think it's a bug because we think that this might also happen after a long time on the server
Avatar
I do not think its a bug. Speed hacks produce UB .. they can change what ever they want and make the client desync
21:59
... I will test it tomorrow
22:00
Also the description is pretty poor
22:01
He does not mention if he used the hack on client or server, and what he mean with "Even after reload"
Avatar
I don't think it's fair to call that UB (unless you mean something different from the UB for the C++ standard)
Avatar
e3f27b6 Enable less controversial cppcoreguidelines clang-tidy checks - def- f312308 Add portability-* clang-tidy checks - def- 551275a Merge #5235 - bors[bot]
22:04
This replaces all usages of sorted_array with std::vector. This requires the following general changes:
  • add_unsorted is replaced with push_back.
  • add is replaced with push_back and subsequent sort or stable_sort must be ensured.
  • In some cases, immediately sorting the entire list after adding an item was unavoidable. Previously items were added at the correct position, which was O(N) because all items after the inserted one had to be moved in any case.
  • `sort_rang...
Avatar
Avatar
heinrich5991
I don't think it's fair to call that UB (unless you mean something different from the UB for the C++ standard)
we could also detect the speedhack server side, We already send the client ticks to the server? We just could compare them to the server tick, and if the margin is to big, we can kick the player
Avatar
there is no "speed hack" that influences the server from the client
22:07
the client only ever sends inputs
22:07
hack detections never work, the only way to defend against them is on a systematic level
22:07
which we do, we don't trust the client
Avatar
Avatar
heinrich5991
there is no "speed hack" that influences the server from the client
that what I say the whole time... thats what I want to explain you
Avatar
are you interested in my opinion on why this is an issue on github?
Avatar
if the client would use a speed hack, its ticks would envolve faster, resulting in faster sending of inputs -> detectable -> kickable
Avatar
Avatar
heinrich5991
are you interested in my opinion on why this is an issue on github?
sure
Avatar
okay, it seems that deen heard about this behavior of the ddnet client or server after it ran for a while with "speedhacking" enabled
22:10
i.e. likely something with faster time
22:11
deen thinks that this might have exposed a bug that our servers run into even when normally running for a long time
22:11
so he wants to see if that can be reproduced
22:12
so you think this is an issue that the servers cannot run into when running normally for a long time?
Avatar
what would be the purpose of an artificial input margin? to circumvent some kind of input rate limit? (I dont see any)
22:14
oh, wait, I see, nvm (edited)
Avatar
it is only intended to increase user experience. A player should not turn on a speedhack and then complain that nothing moves. instead, you could kick the player with speedhack so that he also has nothing to complain xD
22:16
but you don't need to kick them, as I said, they only desync their client.
Avatar
I see
Avatar
Avatar
heinrich5991
so you think this is an issue that the servers cannot run into when running normally for a long time?
I'll just try that tomorrow and see where the server despairs xD
Avatar
i think i'll open a discussion about constructor/destructor and class initialization
Avatar
thanks. you're doing much better than me on this, I was only armchair-discussing the issue and you're verifying it. nice!
Avatar
Avatar
Chairn
i think i'll open a discussion about constructor/destructor and class initialization
thanks
Avatar
speed hack produces UB even on the server?
Avatar
Avatar
c0d3d3v
we could also detect the speedhack server side, We already send the client ticks to the server? We just could compare them to the server tick, and if the margin is to big, we can kick the player
It would be nice to still keep a high max value, like 5-10 seconds or so, just in case
Avatar
Avatar
Tater
speed hack produces UB even on the server?
"speed hack" in the client doesn't affect the server
22:23
"speed hack" in the server affects the server
22:24
So what's the benefit of kicking the "speed hack" player?
Avatar
maaaybe helping the user realize that it doesn't work
22:24
but I guess it might also just make them waste time trying to get around the check
Avatar
But speed hack should be useless right?
Avatar
it is useless
22:25
at least on official servers
Avatar
the server doesn't trust the client. it just accepts inputs
22:26
speedhacking like in minecraft or cs:go is literally impossible in ddnet
Avatar
I don't see why we should care other than to improve the user experience of someone who is trying to cheat?
Avatar
this was just a side note, I think
Avatar
we do not have to... I also do not want to implement it. I just wanted to point out it would be possible xD
Avatar
2ed6213 Add 20 € donation by corneum - def-
Avatar
don't fret about it too long ^^
Avatar
oh ok, sorry ill stop talking about it now xd
Avatar
Recently, we had some bug due to badly initialized classes or overriding whole class with mem_zero. An easy would be to initialise all class members everywhere in the code. One way is to declare a default constructor and to zero initialize each members. Other way is to use C++11 assignment in the class declaration. 1. Default constructor with initialisation in initialiser list (either in header or source file) ```c++ class A { public: A() : m_i(0) {} private: int m_i; };...
Avatar
if it only happens with time skip software, just close the issue. if it happens on real server with 14 hours, fix it. easy
👍 1
Avatar
you didn't specify about bullets being player's gun bullet, or game freezing bullet
Avatar
I can ask Im 'corneum maybe he remembers xD
22:31
but is probably not important...
22:31
After testing it, we will have more data 😄
Avatar
Judged the scope wrong.

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/#us...
Avatar
I need to use CServer class from some custom main(). It turned out to be a good reason to start cleaning this up. The first step is extracting server main() to its own file. I'm open to all ideas on how to handle InterruptSignaled (I've added an external getter function, somewhy it was the first that came to mind).

Checklist

  • [x] Tested the change ingame
  • [ ] Provided screenshots if it is a visual change
  • [ ] Tested in combination with possibly related configuration o...
Exported 297 message(s)