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 2019-04-07 00:00:00Z and 2019-04-08 00:00:00Z
Avatar
ChillerDragon 2019-04-07 09:01:20Z
send help mi map is broken
09:01
09:01
crashes my ddnet client if i try to join or open in editor
09:02
works in vanilla 0.6.4 tho
09:04
ah no it crashes my ddnet server on join and client on editor open
09:09
k saved it with vanilla client and fixed speedups/front and tele manually. Cant remember exactly but i think i did some experiments with tml back then. So i got the map back. But still a crash bug that ddnet has and vanilla doesnt. So if somebody is bored pls fix xd
Avatar
Crashing servers and client with maps is extremely easy, I tried fuzzing it once
Avatar
ChillerDragon 2019-04-07 09:16:28Z
ya
Avatar
all the accesses seemed to be reads instead of writes so it's probably not THAT bad
Avatar
ChillerDragon 2019-04-07 09:16:45Z
but even vanilla 0.6.4 can handle this map
Avatar
basically we trust the map to report its data correctly and then just read over borders
Avatar
ChillerDragon 2019-04-07 09:17:00Z
didnt some guy reported is as security vuln latley in vanilla?
Avatar
vanilla doesn't support many of the game layers ddnet does
09:17
oh?
09:17
link please
Avatar
ChillerDragon 2019-04-07 09:17:16Z
lemme check
09:18
Hello Teeworlds dev team, There is an integer overflow in CMap::Load() which can lead to a buffer overflow. CTile *pTiles = static_cast<CTile *>(mem_alloc(pTilemap->m_Width * pTilemap->...
Avatar
[quakenet] <littlething> hey guys can someone help me a quide ? about in network.py I think you can only add whole 32 bit ints at a time. right?
09:33
[quakenet] <deen> I guess
09:33
[quakenet] <deen> There's a NetIntRange, but that still seems to put a full int in
Avatar
@ChillerDragon sounds good, want to cherry-pick that over to ddnet?
Avatar
ChillerDragon 2019-04-07 09:35:27Z
do i look like a git wizard?
09:35
xd but i can try
Avatar
you can start learning
09:36
and you can also test if that fixes your issue
Avatar
[quakenet] <littlething> so can i add more ?
Avatar
ChillerDragon 2019-04-07 09:41:01Z
dont think so tho @deen because their fix is like a few days old and i tested in 0.6.4 but ye lez see
Avatar
@ChillerDragon yea, it was our tml test, wasnt it?
Avatar
ChillerDragon 2019-04-07 10:06:00Z
no even way older think it was my first test
Avatar
ChillerDragon 2019-04-07 10:22:55Z
@deen i guess it is easier to copy over the few lines manually instead of using git magic
10:23
but we loose the real authors of the commits then ._.
Avatar
ChillerDragon 2019-04-07 10:39:53Z
i dont think ddnet is affected by this anways. Because vanilla added way more code to the Load() function . Left ddnet, right vanilla
Avatar
ChillerDragon 2019-04-07 10:57:54Z
aaaah fuck
10:57
-.-
10:58
wtf where did the commits go? I did cherry pick solved the conflicts and git said i should commit. And now im the only commit there and the one i cherrypicked disapeared
Avatar
ChillerDragon 2019-04-07 11:12:35Z
call me git wizard! Bitch pls
Avatar
@ChillerDragon git wizard
feelsamazingman 2
Avatar
1e0cc51 Add bound check in datafile.cpp anywhere m_ppDataPtrs is accessed as an array. Should fix #2073 - Dune-jr 79a6ae6 Merge #1592 - bors[bot]
Avatar
e27679e Remove some code duplication in CSaveTee::LoadString - def- 4931d00 Merge #1589 - bors[bot]
Avatar
ChillerDragon 2019-04-07 13:51:46Z
😜
Avatar
Im sure im not the only one who keeps pressing ctrl-a and ctrl-e in the teewoods console and nothing happens .-.
Avatar
ChillerDragon 2019-04-07 14:09:52Z
does anyone know a fix for tabbing back into ddnet client on debian10 ? The window is not centered anymore
14:12
Avatar
Rafael Fontenelle 2019-04-07 14:29:50Z
epic πŸ˜ƒ
14:30
sharing in a GNOME group.
Avatar
When you are in a solopart and watch people play, their hookcoll is not getting yellow if they aim at a tee. Even when you are in spectator mode. You have to unsolo first to see it working correctly and it works also for spectator mode then. Should not be too hard to fix i guess?
πŸ€ 2
Avatar
ChillerDragon 2019-04-07 14:31:38Z
zoozti
GWtoshFeelsWowMan 1
14:31
xd
14:33
remove solotiles -> problem solved
Avatar
ᢰ°Konͧsti 2019-04-07 14:33:43Z
f3
Avatar
@αΆ°°KonΝ§sti "Should not be too hard to fix i guess?" go fix it then
Avatar
ChillerDragon 2019-04-07 15:19:54Z
mean
Avatar
no, he is the mean one
Avatar
how does he come to this conclusion πŸ€”
πŸ€ 2
Avatar
i guess cus it already works correctly in some places so it could be a simple fix that doesnt require alot of new code
Avatar
where does anything related to solo prediction work?
Avatar
probably in gameclient.cpp, players.cpp, maybe gamecore.cpp
Avatar
don't think client knows whether another player is in solo or not
Avatar
does /showothers hide people who are in solo
15:56
if so then doesnt it know somehow
Avatar
[quakenet] <heinrich5991> all / commands are handled by the server
15:57
[quakenet] <heinrich5991> this only indicates that the server knows that ^^
Avatar
oo right
zzzz 1
16:51
is this what u wanted
Avatar
ᢰ°Konͧsti 2019-04-07 16:55:23Z
This is what i mean Ye xd
16:55
Or idk
Avatar
ok now pay me 10€
Avatar
ᢰ°Konͧsti 2019-04-07 16:56:32Z
its just when ur in solopart and watch people playing u will not see the hookcoll yellow when they aim a tee
17:03
wtf 3000 fps
Avatar
ΠšΠ°Ρ‚Π°ΠΊΠ°Π½ ΠΈΠ· ΠžΠΊΡΠ΅Π½Ρ„ΡƒΡ€Ρ‚Π° 2019-04-07 17:03:11Z
ryozoOoz (edited)
Avatar
@noby linux + good pc
17:08
xd
Avatar
linux + potato pc + no design + overclock
Avatar
it's funny cuz Gameclient on a method named OnRender is sending packets to the server, gg
Avatar
also in vanilla ._.
17:17
(src/game/clinet/components/chat.cpp, CChat::OnRender)
Avatar
vanilla no lag
Avatar
HADOKEN!!!
17:21
weeb code
Avatar
what's hadoken?
Avatar
1. From Japanese Ha Dou (Wave or Surge) and Ken (Fist, Technique, or Attack); a blastwave or fireball formed from a martial artist's life energy (or ki/ch'i). The hands are brought together, heels of the palms touching, and moved to beside the fighter's waist (which is as clo...
Avatar
its the thing that the guy that fights people spams
17:38
alpha for solo players!
17:38
yay
17:38
now i just have to fix the colision bug and the hook moving a little
17:41
fixed nameplate alpha too xd
feelsamazingman 1
Avatar
what does it change
17:42
from /showothers
17:42
@Ryozuki
17:43
on solo players
17:43
before it was u see him or not
17:43
now if u have showothers it appliues the alpha
17:43
from teams
17:43
idk if i explain good
17:43
xd
17:43
before u could see fully or not at all solo players
17:43
u get that
17:43
i get it
Avatar
Looks like client doesn't know who owns the projectile when rendering it.
Avatar
im wondering where does the client checks for colisions i want to fix the bug where if u are not in solo and other is u see a weird collision
18:00
intersectcharacter doesnt do this
Avatar
Well, how would you know that the other player is in solo=?
18:00
That information is not sent to client yet
Avatar
i added it
Avatar
i got m_IsSolo on cnet CNetObj_Character
Avatar
that sounds like it would break compatibility with vanilla?
Avatar
I thought we should use the new protocol extension thing
Avatar
if you explain me how i can try
18:02
what is it
Avatar
and maybe send a single uint64 where each bit says whether a tee is in solo
18:02
I don't know
Avatar
the network character by hmh
18:02
was closed
Avatar
see protocol_ex_msgs.h
Avatar
the @DDNet.tw things I thin
Avatar
what domain i put? ddnet.tw
18:05
if your goal is ddnet server/client
18:09
how to convert a unsigned char * to uin64 xD
Avatar
(uint64_t)
Avatar
int SoloPlayers = (uint64_t)Unpacker.GetRaw(64);
18:10
this easy?
Avatar
GetRaw(64)?
Avatar
const unsigned char *CUnpacker::GetRaw(int Size)
18:10
i can only get this
18:10
or a int
18:11
(or a string)
Avatar
I'd assume Size is number of bytes, not bits
18:11
so 8
Avatar
the way we usually do it is not that pretty
18:12
unsigned GhostMapCrc = (m_Header.m_aCrc[0] << 24) | (m_Header.m_aCrc[1] << 16) | (m_Header.m_aCrc[2] << 8) | (m_Header.m_aCrc[3]); is for 4 bytes for example
18:13
uint64_t SoloPlayers = (uint64_t)Unpacker.GetRaw(8);
18:13
xD
Avatar
so you get out each byte and shift them so that they all fit together
18:13
what you're doing casts the pointer
Avatar
not the actual content
Avatar
i get what u mean
Avatar
You could cast the content straight to uint64_t and probably it would mostly work, but it's probably not standard compliant
18:16
and about collision, I'd look for occurences of the player_collision tune
18:16
that leads to gamecore.cpp:417
18:17
sounds good: // handle player <-> player collision
Avatar
thanks
18:18
iff i shift << 56 clang tidy says it has more width than a unsigned char, i guess i should cast every array memeber to uint64? xD
18:19
or it isnt needed
18:22
The behavior is undefined if the right operand is negative, or greater than or equal to the length in bits of the promoted left operand.
18:22
so yes i have to cast
Avatar
ugly code (tm)
Avatar
not even a unicode β„’
Avatar
@heinrich5991 do you remember if copy_mem for the same thing would be fine on all kinds of platforms?
18:34
@heinrich5991 also, want the walkthrough now?
Avatar
no, because of big-endian vs little-endian
Avatar
ah, right
Avatar
yea, let me look at the PR again
Avatar
I think we still have locations that do it with mem_copy though
18:35
might have to fix them then
Avatar
yes
18:35
we have faulty code for big-endian machines, at least in the map reading code
Avatar
weird, no one noticed on debian?
18:36
i thought on debian we're built for dozens of platforms or something like that
Avatar
possibly elsewhere as well, if no one tests it, it doesn't work
18:36
I don't know if anyone actually executes the stuff or whether they just build it
18:36
we don't have a test suite for datafiles yet, that might uncover it
Avatar
true enough
18:37
probably no one tests it
18:37
Avatar
mips is le
18:39
@deen okay, so the idea behind OnCompletion is that it can close the file and thus check whether we wrote correctly?
18:39
if that fails, we just go to the generic error path?
Avatar
copy_mem might be causing some dangeorous situations on little endian, should go through and fix a few.
Avatar
eh, big endian, sorry
18:40
we're on little endian by default (x86, arm, …)
Avatar
I changed OnCompletion?
Avatar
yes, you did. and you're also claling it in the error path
Avatar
whats the reason behind putting everything on a interface and on a class ? IServer CServer Iwathever and Cwathever
18:42
double work
Avatar
so that they have a cleanly defined interface, in theory
Avatar
@heinrich5991 oops, that seems unintentional, let me take another look
Avatar
doesnt look that clean twintri (edited)
Avatar
it's kinda clean in vanilla, ddnet kinda walks over it due to casting it to CServer anyway
Avatar
ah, the idea is that if you don't call OnCompletion then the updater is just stuck
18:43
and nothing will be shown
18:43
so you need to call it and OnCompletion can then do something depending on whether m_State is HTTP_DONE/ERROR/whatever
18:45
and before it was called in most error paths, just not all consistently
Avatar
okay
Avatar
e539bba Handle FS failures while updating (fixes #1560) - def- 52c00dc Merge #1573 - bors[bot]
Avatar
void CServer::GetSolos(unsigned char *aPlayerSolos) { for(int i = 8; i > 0; i--) { unsigned char x = 0; for(int j = 8; j >= 0; j--) { x |= m_aClients[64 - (i * 8 + j)].m_Solo << j; } aPlayerSolos[i] = x; } } is this clever, or really stupid
19:10
twintri
Avatar
sounds much more expensive than the previous solution
Avatar
wich one is it?
19:11
which
19:11
the cast?
19:12
i spend 10 mins to do this
19:12
twinbop
19:13
also this limits us to 64p
Avatar
u can only send 1 int with the packet extension?
19:13
hmm
Avatar
I'd guess you can send anything
Avatar
i can put a int with the client size
19:17
this is more complicated than i expected
19:17
just to keep vanilla compat cammostripes
19:18
adding m_IsSolo to network.py is way easier and faster monkaS
Avatar
not just vanilla compat, also compat with other clients and old ddnetclients, right?
19:19
@heinrich5991 the protocol extensions are the way to go for that, right?
Avatar
hmm
19:22
better to add a new netobj with the protocol extensions
19:22
demos need that thing available in every tick
Avatar
it would be cool to have packet extensions too
19:23
instead of brand new packet
19:23
25c54ef Implement show_ips to protect accidental leaking of IPs - def- a4e2130 Merge #1571 - bors[bot]
Avatar
@Ryozuki how would you do that?
Avatar
I may be ignorant, but maybe checking the packet length
19:30
and having a default
19:30
if the server doesnt support the extended
19:30
it would work for this m_solo case maybe
Avatar
it would probably work if you'd introduce a new netobject
21:32
old netobjects have a fixed size due to the way they're compressed
21:33
maybe add a CNetObj_CharacterExtended or so
22:02
found a weird name
22:02
the ? its the face
Avatar
it's the mouthless emoji
22:09
oh
22:09
probably mysql not being able with chars outside the bmp?
Exported 259 message(s)