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 2017-10-23 00:00:00Z and 2017-10-24 00:00:00Z
Avatar
I think a tee is smaller than a gametile
Avatar
@Learath2 ask me anything :D Especially the if block with the code you mentioned is really not that nice... but all these checks are needed for the transition from local to serverside starting behavior. The problem is that the client does not know if the racetimer is on until it receives the first snapshot with the correspondint flag set. If there was a timer that is always on the code would be a lot cleaner. About the ddrace check: The client recoginzes the race start one tick earlier than the server. The servers just notices it one tick after the actual movement happened. So i need to correct the tick to keep in sync with old ghosts
00:04
for block tiles the tee is actually larger than gametiles >.<
Avatar
okay let's see, is the one tick difference always consistent?
Avatar
so the map would have to be changed?
Avatar
also btw @redix I think we need physics changes to be 100% backwards compatible
Avatar
this will be kind of impossible since the old position check was kind of non-working at all
Avatar
Not sure how many maps would need to be fixed and quite possibly all the ranks would be invalidated on those maps aswell
Avatar
in general this behavior is rather random since it does also rely on the starting position and not only on the speed. so in terms of race fairness i would prefer to completely remove it...
Avatar
I don't think it would influence ranks on the map I posted
00:11
or is it different behaviour in general, and not only special cases
Avatar
problem is that fixing this will break two and four direction stoppers
Avatar
regarding the ghost stuff, if IGhostRecorder and IGhostLoader are interfaces they do not need Interface pointers passed to them and they do not need helper functions in IClient as you can call them from anywhere in the code
Avatar
yes you are right... still some remains from the demo recorder code. i used it as a starting point
Avatar
also what do you mean by serverside starting behaviour and ServerControl, doesn't seem the server is actually controlling the playback and the recording either
Avatar
server controls means that the starting behavior relies on the race timer instead of checking for the startline client side
Avatar
when do you need to actually check for the startline client side?
Avatar
when the race timer is off
00:14
problem is that i only know that it is on after the local start already happened
00:14
so i need all this "transition" code
Avatar
hmm we really do need some kind of NETMSG_SUPPORTS or an actual way of sending race events
Avatar
for the ghost a reliable timer is even better for the starting. for the end a new netmsg would be great
Avatar
components/ghost.cpp:L261 what does this really check?
Avatar
damn... i will try it tomorrow but i'm pretty sure that the map @jao mentioned won't work anymore =\
00:25
@Learath2 i should have kept the previous version of that check. was better readable i guess if((ServerControl && !Predicted) || (!ServerControl && Predicted)) In the first case the "server side control" might have changed the RenderTick, in the second the local control might have changed it
00:26
i'm not even sure if this line is still needed ^^
Avatar
tbh I don't get what most of this is doing, always thought the ghost code was a mess :/
Avatar
this code has been in the render method before
00:28
the onsnapshot method has to deal with so many different cases =\
Avatar
OnNewSnapshot shouldn't the only thing you are checking be whether the race started or ended somehow?
Avatar
it is only the start 😄
Avatar
this is only checking for start? 😛
Avatar
yes... the rest of the code should be kind of okay... but i know that this method is horrible
Avatar
could maybe be generalized by abstracting changes in state, e.g. having an OnRaceStateChange hook
Avatar
this could maybe help... but the thing with the unreliable timer will still bloat the code
00:34
besides the onsnapshot method... any other things you found in the code ^^
Avatar
that was my main concern, but let me go on reading
Avatar
okay... each time i fixed some issue with the timer the onsnapshot method got worse 😮
Avatar
ghosts don't save every tick right?
Avatar
no only when the buffer of the recorder is full... every 2 seconds with default snap rate (edited)
00:44
about the blockers: i can bring back full entering for one direction blockers but fot 2 and 4 direction blockers it might cause a lot of trouble (edited)
Avatar
@redix CGhostLoader has only one ghost file loaded at any point, is there any reason to have GetTicks take a CGhostHeader *? GetTicks could just use m_Header as a member of CGhostLoader
Avatar
GetGhostInfo is used in the menu to get the header
00:52
getticks is actually not used there but gettime is
Avatar
GetTicks and GetTime then actually belong to CGhostHeader as they only depend on the header
Avatar
yeah. makes sense
Avatar
think I'm kinda being nitpicky
Avatar
ReadData and WriteData should take unsigned char * or void * from what I can read
Avatar
btw... while changing some things in player.cpp i stumbled across the Predict function. It seems to be part of antiping. A lot of commented out code... it says something about missprediction. some code depends on the ping value from scoreboard... i'm not sure what the guy who wrote it tried to measues... but it looks kinda weird (edited)
Avatar
oh I'm not sure anyone really knows what that stuff does anymore 😛
01:15
it's mostly @deen's code iirc
01:16
I think except for the things I mentioned and OnNewSnapshot I'm okay with this
Avatar
why did you need to friend CGhost in CPlayers btw?
Avatar
okay. i'll fix these things... not sure about onnewsnapshot though. right now this function is very fragile =\ maybe adding a new timer / netmsg and cleaning it up then is a better idea
01:20
for calling RenderPlayer. could also have made it public
Avatar
this is what I hate about OOP... RenderPlayer doesn't even need to be a member for CPlayers...
01:22
meh I guess it's fine like this
Avatar
the whole file is messed up. grabbing the predicted values inside a rendering function and stuff >.<
Avatar
well fix the small stuff, I'll merge then we can look at OnNewSnapshot
Avatar
okay. gonna do it tomorrow. time to sleep now 😄
01:25
about Predict
Avatar
yeah way too late 😛 (edited)
Avatar
the function depends on double d = length(PrevPredPos - Position)/s_Ping; Position depends on IntraTick So PrevPredPos - Position seems to depend on the frame time. I'm pretty sure this is wrong ^^
Avatar
one more thing before I also get some sleep
01:31
you don't seem to be using File after engine/shared/ghost.cpp:L355 you could just close it
01:31
would simplify your ifs
Avatar
right. thanks for that hint 😄
Avatar
I'll get some sleep, gn8
01:36
ofc as always thank you for thy contribution 😛
Avatar
same here. gn8 :) i wanted to merge this code (from teerace) for a long time 😄 was too lazy until now
Avatar
https://github.com/ddnet/ddnet/pull/801 Anyone want to fix this up?
Includes: png spritesheet python datasrc script changes :alias: to utf replacer utf/:alias: to png image replacer Needs code review, builds and works well, may need some offset fixes as I wasn't ...
07:42
152a715 Add DPI awareness support for MSVC compiling fo... - Jupeyy 907622e don't read the manifest of the target - Jupeyy 162b24c respect the CFG dir - Jupeyy 9a4efe7 use proper CMake 3.4 support for manifest files - Jupeyy 205b054 move manifest to other directory and add MinGW ... - Jupeyy
Avatar
Windows users don't have old versions of CMake from their repositories, Visual Studio installs CMake 3.9.
12:51
8b1559a Drop CMake 3.4 support for MSVS - heinrich5991 4e20349 Merge pull request #919 from heinrich5991/pr_dd... - def-
Avatar
Ur discord admins r bad(jao)
Avatar
He took away my rights to add reactions becuz u and mokuz were Spamming reactions
13:25
Wheres the logic
13:25
U can look up who added them and hes just like nope fuck it ima give this guy a reation mute instead
Avatar
haha you spam emotions and remove later
Avatar
not the place to discuss this
Avatar
@ezy you can PM an admin if you want
Avatar
That fixes the AMD driver bug, and readjusts fullscreen resolutions, so that the opengl viewport and render non dpi scaled at fullscreen(only)
Avatar
Have you seen that before?
307.19 KB
Avatar
Hooray all CI test passing now
17:38
nice work (whomever)
Avatar
yee @Savander
Exported 98 message(s)