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-11-24 00:00:00Z and 2019-11-25 00:00:00Z
Avatar
what's an efficient way of turning long .demo files into mp4 files?
Avatar
ChillerDragon 2019-11-24 14:13:55Z
ffmpeg
14:14
@Boci just record with a regular screen recording software like OBS
Avatar
I really dont wanna record like 2 hours of demos
14:22
Is there a workaround
Avatar
ChillerDragon 2019-11-24 14:23:01Z
2h is fine
14:23
where is the problem
14:23
you can record it in 2x times speed
14:23
well depends for what ypu need the recording
Avatar
I mean i am still unable to do anything with my computer for 1h in that case
Avatar
ChillerDragon 2019-11-24 14:24:33Z
use your secondary computer then ๐Ÿ˜›
14:24
or pay me 2bucks ill do it
Avatar
one more Q can i record demos where i can spec all of the tees?
Avatar
if you do /showall
14:35
(while playing)
Avatar
oh ok yea
14:36
how can i set that it's showall all the time ?
14:37
like every time i join a game it will be set to showall
Avatar
u cant
Avatar
idk
14:37
xd
Avatar
jao, help, can i? (edited)
Avatar
because it requires a lot server resources
14:45
you can bind it on some key that you always press anyways
Avatar
i thought about it, but for example if i bind it on mouse 1, it's gonna say "now you are able to see every player at all times regardless of distance" every single time i press mouse1 ?
Avatar
bind mouse1 "say /showall" ?
Avatar
it will toggle everytime i think
Avatar
bind mouse1 +fire; say /showall 1
14:47
xd
Avatar
you need the 1
14:47
works for me
Avatar
ohh i didnt know it accepted a number
Avatar
@jao is there like a line graph showing players rank and points over time? i think that would be cool
18:54
kinda like how osu shows it
Avatar
there isnt but the data is there
18:54
like this
Avatar
it can only go up for ddnet but yea
Avatar
well i think ranking could go down if the player takes a break but yeah that would be cool
Avatar
for solo ranks it would work
18:57
for teamranks no
Avatar
oh i meant like point ranking not time ranking
18:59
you should put the discord bot $profile image thingies on the website
Avatar
rank points or normal points
Avatar
how would those go down?
Avatar
if a player is inactive for a while like more players could pass them
18:59
i mean like rank in the world
Avatar
will the website ever be redesigned
19:01
why do u want $profile images on the website
Avatar
idk i feel the website looks kinda old n outdated
19:02
same with the client
19:03
but who would do it
19:03
someone pro
Avatar
i'll make like a layout thing to show what im thinking
Avatar
ChillerDragon 2019-11-24 19:37:23Z
Thatโ€™s like teerace
Avatar
@ChillerDragon link?
19:38
I think itโ€™s little bit inactive
19:38
But it used to show your points in a time graph
19:38
So you basically saw player activity there was interesting
Avatar
Cellegen | HU 2019-11-24 20:27:25Z
official infclass website has some similar ideas to it, will send the link here once i'll find it :p
20:28
ah here
20:29
on the stats menu it's actually designed for racing imo (edited)
Avatar
@louis there have been attempts in the past to re-do the site, but our unconventional way of generating the pages really discourages most from ever completing the work ๐Ÿ™‚
Avatar
@Learath2 what u mean generating the pages
21:30
also is there like a teeworlds api or smth
Avatar
No teeworlds api (although I had plans for one (although most my plans are left incomplete))
21:32
We generate the pages using python scripts
21:32
Every couple of minutes
Avatar
what the
Avatar
It's all black magic
Avatar
I mean the idea of serving static pages isn't too bad
Avatar
its not
Avatar
Which one? ๐Ÿ˜„
Avatar
but imo an api is better
21:33
i would love to do it in golang
Avatar
we should have like
21:34
a stat checker in game (edited)
Avatar
@heinrich5991 is the gen script public?
Avatar
you can right click someones name in tablist and see stuff
Avatar
@heinrich5991 yes, but very modern web dev unfriendly
21:34
@Ryozuki ddnet/ddnet-scripts
Avatar
The magic scripts that make DDNet run. Contribute to ddnet/ddnet-scripts development by creating an account on GitHub.
21:37
@Learath2 how many cores has the web server?
Avatar
a single one i'd wager
Avatar
2 cores, 2 threads
Avatar
there is a neat thing to bypass python GIL https://docs.python.org/3/library/multiprocessing.html
21:37
maybe we can optimize it
Avatar
eh, it's fine it works, not like we need much cpu to serve up the site anyway
Avatar
teeworlds should have like
22:02
camera follow
22:02
not like centered on tee
22:02
wait nvm that wont work
Avatar
then learn c++ and code it
Avatar
yeah it's not that easy ryozuki
22:02
"just learn c++" greenthing
22:03
i did that
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:03:22Z
std::cout << "Hello World!" << std::endl;
22:03
Congratulations, you are a programmer
Avatar
why u gotta put std:: before everything
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:11:06Z
they are part of the std namespace
Avatar
I'm not sure what a good first programming language is
22:20
perhaps python
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:21:07Z
Best first programming language is C
Avatar
the concept of UB is pretty hard to grasp IMO
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:22:09Z
Books help you navigate the waters safely until you get to a certain point, where you can start to understand it
22:22
If you REALLY want to avoid C, you need a very good regiment to follow to actually learn some computer science along with your high level language of choice
Avatar
yes c is the best
Avatar
what's UB
Avatar
undefined behavior
22:27
behavior you must not have in your program, else it is allowed to format your harddrive and eat your laundry
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:27:57Z
or kidnap your kids, it's undefined after all
Avatar
or do exactly what u intended it to do sometimes
22:28
to make it even harder to track down
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:28:41Z
Which is why it's dangerous I guess
Avatar
wait what
22:28
if you don't want undefined behavior can't you just not write it in your code
Avatar
yea, unfortunately, it's not that easy to avoid
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:29:18Z
Some things you write might not be defined
Avatar
e.g. referencing a pointed-to value after it's been freed is undefined behavior
Avatar
example of undefined behavior: array[i] = i++;
22:29
does it access array[i] first
22:29
or increment i first
Avatar
or does it eat your laundry, if it's indeed UB
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:29:59Z
Turns out, which happens is undefined :P
Avatar
the answer: its undefined
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:30:31Z
Or dereferencing a null pointer. Compilers are completely free to assume any pointer you try to dereference is not null
Avatar
derefernce null ptr == crash
22:30
more like dereferencing an invalid pointer
22:30
out of bounds/already been freed
22:30
might crash
Avatar
dereferencing a null ptr might not lead to a crash
22:31
so basically u just have to be very specific
Avatar
in what situation would that not crash
Avatar
if the compiler somehow managed to optimize out the access (e.g. copied the value from somewhere else before), the offset is large enough to point into mapped memory again (the latter often being used for exploiting security vulnerabilities)
22:32
i see
22:33
i didnt think of compiler optimizations affecting this
Avatar
In Part 1 of our series, we discussed what undefined behavior is, and how it allows C and C++ compilers to produce higher performance appli...
22:34
"Debugging Optimized Code May Not Make Any Sense"
22:35
that gives an example of where a null ptr doesn't crash
22:35
even a null function ptr
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:35:34Z
btw, I think an implementation is free to let you dereference a null pointer and have it refer to something
Avatar
what the
22:35
this stuff is complicated idk
22:35
like
Avatar
if u dont have compiler optimization turned on this will not affect anything right?
Avatar
i know how to code basic stuff
22:36
but idk how or where to learn about all this undefined blah blah null pointer etc
Avatar
google it
Avatar
wow thanks
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:36:30Z
The truth is, these things happen occasionally, not always
Avatar
if you know how to code basic stuff, you're basically good to go, I think ๐Ÿ™‚
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:36:49Z
So most of the time you are clear of all the intricacies of a language
Avatar
and lol that is intersesting article
Avatar
(also has part 1 and part 3)
22:37
@louis just be careful around code interacting with the network. if you put vulnerabilities in there, people from the internet can take over your computer
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:37:42Z
The best way to learn C is a book, the best book yet is imho K.N. King's C Programming: A modern approach
22:38
i thought it was online
22:38
idk
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:38:21Z
@noby that is a fun read indeed, especially that null pointer optimizations interaction with dead code elimination
Avatar
if u turn off optimizations does this bypass all of the things this article describes
22:39
-O0
Avatar
optimization is -O0 by default
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:40:20Z
I don't remember the entire article, it is possible there is an example there that doesnt relate to ub
Avatar
in practice yes, I think
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:40:27Z
relate to optimization*
Avatar
but remember that you can still do stuff like
the offset is large enough to point into mapped memory again (the latter often being used for exploiting security vulnerabilities)
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:42:05Z
I don't remember whether it's UB to access memory through a freed pointer
Avatar
yes, UB
22:42
double free: UB
22:42
free of non-malloced variable: UB
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:42:58Z
Writing good C code is hard, but I still maintain that it's the best way to actually learn programming
22:44
Yes you might want something like Scala if you are coding the backend for a bank, or ADA/SPARK if you are sending a rocket to the moon :)
Avatar
or certain other new languages when you're writing network-facing code ๐Ÿ˜‰
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:46:46Z
I'm not sure what I'd go for in network facing code nowadays. Probably something like js where sandboxing is high and integration with front-end is easy. Given performance isn't critical
22:47
(definitely typescript, not vanill js, ew)
22:47
I guess I'd still go for C for high performance applications
22:48
rust is probably safer, but I kinda gave up on ever learning it, it just looks like moon runes to me
Avatar
people have had success with rust too ๐Ÿ™‚
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:49:15Z
I'm learning hiragana faster then I'm learning rust
Avatar
ใ‚Œใ‚ใ‚‰ใ™ใคใƒผ
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:51:41Z
thst
22:51
that broke my terminal
Avatar
do you even unicode? โ˜ƒ
Avatar
[quakenet] Learath2 BOT 2019-11-24 22:52:50Z
It's the font rendering of this opengl terminal
22:53
because on macOS, the terminals that use corefont render so slowly it hurts
Avatar
Oh, I guess that's ใ‚ใŸใ—ใฎใชใพใˆ (edited)
22:56
Okay stupid phone keyboard decided it'd be helpful and contract my hiragana into kanji
Exported 207 message(s)