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 2023-06-25 00:00:00Z and 2023-06-26 00:00:00Z
Avatar
Avatar
Ewan
discord app so slow for me on phone
use old version, i'm using the 2021 one and everything is loading fast
Avatar
how do u show tee skins darker when in the freeze instead of ninja
06:52
is that a custom client
Avatar
National Insurance Clerk 2023-06-25 06:57:53Z
Why do they have the ninja skin when frozen at all?
Avatar
that's the game
Avatar
chillerdragon BOT 2023-06-25 07:28:00Z
Such a nice map (@Chairn)
@ChillerDragon still on narcissistic i see
07:28
You can freely move the camera with the mouse in the demo (@cauldron)
i finally beat notelebro \o/, now how to fake camera position of a demo? can i edit the demo files with a binary file editor?
Avatar
Avatar
National Insurance Clerk
Why do they have the ninja skin when frozen at all?
f1 - cl_show_ninja 0 if u want normal skins in freeze (edited)
Avatar
ChillerD1 BOT 2023-06-25 09:08:15Z
:q
09:08
ops
Avatar
When using "Save Copy" to save a copy of the current map to a new file and selecting a file that already exists, a confirmation popup is shown. However, this confirmation popup did not differentiate between regular saving and saving a copy, so the regular save callback was always called. Add the GET parameter w=1 to the URL of this PR to show simpler diff (ignoring whitespace).

Checklist

  • [X] Tested the change ingame
  • [ ] Provided screenshots if it is a visual change
  • [ ]...
Avatar
Avatar
Cøke
f1 - cl_show_ninja 0 if u want normal skins in freeze (edited)
yeah but how do i dim them
09:20
i've seen it in demos sometimes
09:20
if i don't have them dimmed i just think they're not frozen and die lol
Avatar
maybe taterclient
Avatar
9ecb010 Use IO_MAX_PATH_LENGTH in CFileCollection - Robyt3 34df022 Use IO_MAX_PATH_LENGTH for editor map saving and loading - Robyt3 4372932 Remove unnecessary storage argument of CEditorMap::Load/Save - Robyt3 e04eee9 Extract CEditor::HandleCursorMovement function - Robyt3 72fbfaa Fix save copy callback not called when confirmation popup used - Robyt3 bb773b9 Merge #6761 - bors[bot]
Avatar
If they're below the freeze layer they should automatically be dimmed right? @Cøke
Avatar
@Learath2 yo bro. I hope you're doing well. Got any time to look for the discord bot? My hope is that with that bot the skin submission gets a bit more active again. It's been over 3 months already since the last upload. Have a nice rest sunday
Avatar
What does the bot have to with it being 3 months since the last upload? I thought we already have a way to upload skins
09:52
I'll take a look at the bot thing I guess tonight. Ping me again later 👍
Avatar
Avatar
Learath2
What does the bot have to with it being 3 months since the last upload? I thought we already have a way to upload skins
i think the database crew finds it too annoying to download the skins, go on the website, manually fill the forms just to upload a single skin ^^
09:54
the bot automates all these steps and u can upload multiple skins at once
Avatar
Did the database crew say this or do we maybe just need more people in the skin database crew?
Avatar
mh let me search the message. i cant remember if it was the database crew or murpi
Avatar
any reason why templated work can't be done automatically xd
Avatar
Avatar
murpi
I assume Ravie hasn't talked to about the skin upload form on ddnet.org yet @Jupstar ✪
^ it was about uploading hd skins is annoying
09:56
so i decided to generally make the upload easier
Avatar
Avatar
murpi
No, it would be great if you could change it so the skin db crew doesn't have to upload skins twice/seperately for uhd skins
.
Avatar
ChillerDragon BOT 2023-06-25 09:57:35Z
jupsti writing emails on discord
Avatar
Actually it's been 3 months can't it wait another week until I'm done with exams?
10:10
Or murpi could spin it up, he has the same permissions I have on all the relevant servers
Avatar
Avatar
Teero
If they're below the freeze layer they should automatically be dimmed right? @Cøke
Ofc, u can also try to make ur entities freeze darker
Avatar
Avatar
Learath2
Actually it's been 3 months can't it wait another week until I'm done with exams?
yeah no hurry, i'll ping u in a week xds
Avatar
chiller i can't blocxk
10:35
block
Avatar
ChillerDragon BOT 2023-06-25 10:36:39Z
skill issue
10:37
is there any chance asan and ubsan dont catch something?
10:38
seems like my client starts to randomly send malformed garbage over the network but i get no asan warnings
Avatar
Yes, ASan and UBSan can have false negatives
10:41
But if it's sending uninitialized memory then you need MSan to detect it
Avatar
ChillerDragon BOT 2023-06-25 10:43:17Z
ou msan
10:43
where to buy it
10:43
why isnt it in ddnet readme? is it even slower?
10:44
-fsanitize=memory i assume
Avatar
I think you can't combine it with the other sanitizers
10:45
So we'd need to run it separately
10:46
Would still be a good idea if it's possible
Avatar
is there any documentation on map_create_pixelart?
10:47
somehow just segfaults for me
10:47
im probably doing something wrong with the arguments
Avatar
Seems like MSan is included in Valgrind though, so I guess we don't need it
MSan implements a subset of functionality found in Valgrind (Memcheck tool).
Avatar
Avatar
Teero
is there any documentation on map_create_pixelart?
Can you share the command line arguments you are using to call it?
Avatar
ChillerDragon BOT 2023-06-25 10:48:05Z
invalid argument '-fsanitize=address' not allowed with '-fsanitize=memory'
10:48
ye u rite robi
10:48
sad
Avatar
./map_create_pixelart ~/Downloads/map_sao.png 0 ~/.local/share/ddnet/maps/pixelart1.map 0 0 0 0 0 ~/.local/share/ddnet/maps/pixelart.map
10:49
Usage: ./map_create_pixelart <image.png> <img_pixelsize> <input_map> <layergroup_id> <layer_id> <pos_x> <pos_y> <quad_pixelsize> <output_map> [optimize=0|1] [centralize=0|1] this is the usage
Avatar
ChillerDragon BOT 2023-06-25 10:49:28Z
cool TIL there is a pixelart tool
Avatar
Note: set img_pixelsize to 0 to consider the largest possible size. Note: set quad_pixelsize to 0 to consider the same value of img_pixelsize. Note: if image.png has not a perfect pixelart grid, result might be unexpected, manually fix img_pixelsize to get it better.
Avatar
Yeah, seems like it's correct according to the those docs
10:50
I'll try if it crashes for me
Avatar
ChillerDragon BOT 2023-06-25 10:50:51Z
send pic and map
Avatar
the input and output maps are just empty maps btw
Avatar
ChillerDragon BOT 2023-06-25 10:51:17Z
will it create tile layers then?
10:51
how does the tool even work
10:51
@Rasho wanted this (edited)
Avatar
ChillerDragon BOT 2023-06-25 10:51:58Z
the image is huuughe
Avatar
ChillerDragon BOT 2023-06-25 10:52:08Z
u insane?
Avatar
It works for me with another image and map
Avatar
but who cares xD
Avatar
ChillerDragon BOT 2023-06-25 10:52:16Z
every pixel would be a tile or what?
Avatar
(if I counted correctly) Are you missing the quad_pixelsize argument? Seems like there's one argument missing as you provided the output map where it expected quad_pixelsize. (edited)
Avatar
Avatar
UnlucksMcGee
(if I counted correctly) Are you missing the quad_pixelsize argument? Seems like there's one argument missing as you provided the output map where it expected quad_pixelsize. (edited)
you counted wrong
👍 1
Avatar
Avatar
ChillerDragon
every pixel would be a tile or what?
yy (edited)
Avatar
Avatar
Robyt3
It works for me with another image and map
hmm. so the image is just too large?
10:54
It creates a quad for every pixel
10:54
I used the game.png to test and that already makes the editor very laggy
10:55
It's pixel-art, so I assume you should use it with actual pixel art
Avatar
hmm i always thought itd just make tile layers with diffrent colors
10:56
is there a specific reason to do it with quads? (edited)
Avatar
each tile layer could only have 256 colors, the algorithm for that would be more complex
Avatar
Avatar
Patiga
each tile layer could only have 256 colors, the algorithm for that would be more complex
@ChillerDragon its your turn now
Avatar
ChillerDragon BOT 2023-06-25 10:57:40Z
wot
Avatar
you would probably need a lossy algorithm for images with too many colors
Avatar
start coding!
10:58
xD
Avatar
ChillerDragon BOT 2023-06-25 10:58:17Z
idk how to code
10:58
idk wat even u want to do
10:58
just embed the image
Avatar
hmm yes seems smart.
Avatar
ChillerDragon BOT 2023-06-25 10:59:42Z
woah mem san is no fun
10:59
client is booting since 2mins
Avatar
but if someone wanted to edit some tiles then the whole image would need to be edited externally and then pasted in again
Avatar
ChillerDragon BOT 2023-06-25 11:00:08Z
tiles?
Avatar
this is for a gores map
Avatar
ChillerDragon BOT 2023-06-25 11:00:17Z
is it guads or tiles now?
11:00
so you want it to be tiles?
11:00
like the pokemon maps?
Avatar
And msan won't work very well because you don't have your libc compiled with it
Avatar
exactly.
Avatar
Should have stuck to valgrind
Avatar
ChillerDragon BOT 2023-06-25 11:01:09Z
ok ill use valgrind
Avatar
or quads as long as you can edit them pixel by pixel everything is fine
Avatar
ChillerDragon BOT 2023-06-25 11:01:27Z
using quads to map gametiles sounds cursed
Avatar
Avatar
ChillerDragon
using quads to map gametiles sounds cursed
true
Avatar
ChillerDragon BOT 2023-06-25 11:01:49Z
i dont understand why the tool uses quads anyways? is it for easier coloring?
Avatar
Avatar
ChillerDragon
is it guads or tiles now?
your image doesn't look suitable for a tiles layer. I think your image needs fewer colors
Avatar
ChillerDragon BOT 2023-06-25 11:02:43Z
yea when i look at the image i dont really see a gores map but maybe im not creative enough
Avatar
(replied to the wrong message @Teero)
Avatar
ChillerDragon BOT 2023-06-25 11:03:01Z
reply moment
11:03
loading skin files ...
11:03
okok ill abort xd
11:03
jesus
Avatar
Avatar
ChillerDragon
yea when i look at the image i dont really see a gores map but maybe im not creative enough
you gotta think outside the 3rd dimension!
Avatar
Avatar
ChillerDragon
yea when i look at the image i dont really see a gores map but maybe im not creative enough
i really dont know either. @Rasho asked me to do it
Avatar
Avatar
Teero
or quads as long as you can edit them pixel by pixel everything is fine
That's going to be impossible for such a large image. Even if the tool and mapformat would be able to support it, the editor would probably run at less than 5 FPS.
Avatar
ChillerDragon BOT 2023-06-25 11:04:41Z
yea and hfgl mapping such a long map by hand
Avatar
Avatar
Robyt3
That's going to be impossible for such a large image. Even if the tool and mapformat would be able to support it, the editor would probably run at less than 5 FPS.
if i can edit every pixel of an image in gimp then why cant i in the tw map editor trollet
Avatar
well that is what image editors are for
Avatar
ChillerDragon BOT 2023-06-25 11:05:33Z
im currently working on a 3 x 1.7 k gores map and it takes forever
11:06
its chillerdragores317 justatest
Avatar
ChillerDragon BOT 2023-06-25 11:06:12Z
chillerdragores6 actually xd
Avatar
btw how do you choose your map names wtf? there is chillerdragores18 and others but now its 6?
Avatar
ChillerDragon BOT 2023-06-25 11:07:05Z
6 always has been before 18
11:07
18 just was faster to finish
justatest 2
Avatar
ah ok sure
Avatar
@Teero if my python script is correct, your image contains 317386 different colors ^^
Avatar
We would need to render the hint first and then wait for the next frame to initialize the blocking operation, so the user can see the hint while the client is blocked. Depending on how much work it is, also show hint while loading maps and other files. Separated from #6693.
Avatar
print(len(set(Image.open(image_path))))
Avatar
A copy of the map currently open in the editor is saved every 10 minutes to the maps/auto folder (interval configurable, see below). The automatically saved map uses the filename of the original map with an additional timestamp. Per map name 10 autosaves are kept in the auto folder before old autosaves will be deleted (number configurable, see below). Add config variable ed_autosave_interval (0 - 240, default 10) to configure the interval in minutes at which a copy of the current edi...
Avatar
Avatar
chillerdragon
You can freely move the camera with the mouse in the demo (@cauldron)
still curios if it can be done in the demo file to change the "standard" camera position? 😅 (edited)
Avatar
ChillerDragon BOT 2023-06-25 12:02:18Z
what does that mean?
12:02
press your spectator options bind and select free view
12:02
while playing the demp
Avatar
i want to render many demos with exact same camera position
12:03
that's why i want to hard code it into the demo file
12:05
because when you play the demo without anything it has the camera position of when you were recording, so the demo must have a "default" camera position
12:05
but when i try to edit the demo with a text editor it is binary
Avatar
ChillerDragon BOT 2023-06-25 12:05:52Z
for what to record a video?
12:06
you can use free view and set_view command
Avatar
i didn't know set_view
12:06
but i would need to set it for every frame
Avatar
ChillerDragon BOT 2023-06-25 12:07:01Z
open console while in free view while watching a demo
12:07
then do set_view 10 10
12:07
and it stays like that for all frames
12:07
you can just play the demo
Avatar
but what if i want to have the camera follow the tee
Avatar
ChillerDragon BOT 2023-06-25 12:08:18Z
which tee?
12:08
your tee?
Avatar
ChillerDragon BOT 2023-06-25 12:08:27Z
isnt it doing that by default?
Avatar
ChillerDragon BOT 2023-06-25 12:08:48Z
what okay
Avatar
but if i want to follow a self-set path
Avatar
ChillerDragon BOT 2023-06-25 12:09:04Z
???
Avatar
not just the same camera position for the whole demo
Avatar
ChillerDragon BOT 2023-06-25 12:09:12Z
so not follow a tee?
12:09
not follow a tee
Avatar
ChillerDragon BOT 2023-06-25 12:09:25Z
move randomly?
Avatar
not random
Avatar
ChillerDragon BOT 2023-06-25 12:09:32Z
but the same way across multiple demo files?=
Avatar
a pre defined path
12:09
yes
12:09
exactly
Avatar
ChillerDragon BOT 2023-06-25 12:09:38Z
i see
12:09
is rerecording the demos a option?
Avatar
ChillerDragon BOT 2023-06-25 12:10:35Z
im not sure if there are any demo parsers out there
12:12
you could probably edit camera.cpp to record the current coordinates and then do you camera movements and then force camera.cpp to replay those in the demo player
12:12
seems way easier than editing the demo files
12:14
yikes
Avatar
ey where do you have the 2x slowdown with tunings? i mean the map config things
Avatar
Avatar
Teero
ey where do you have the 2x slowdown with tunings? i mean the map config things
Avatar
Avatar
ChillerDragon
you could probably edit camera.cpp to record the current coordinates and then do you camera movements and then force camera.cpp to replay those in the demo player
i believe it's the best i can do to overwrite coordinates in camera.cpp
12:16
thanks
Avatar
nah i think there was a specific config that made the game physics exactly 2x slower
12:30
how do i make tune zone settings global?
12:31
maybe i should ask in #mapping
Avatar
just dont' put tune zone in fron of the command?
12:33
in the map settings
12:34
yeah #mapping
Avatar
ChillerDragon BOT 2023-06-25 12:47:38Z
@cauldron i cracked something together that kinda works xd
12:47
its more a proof of concept
Avatar
tell me (edited)
Avatar
ChillerDragon BOT 2023-06-25 12:49:38Z
Chillers contribution fork of DDraceNetwork, a cooperative racing mod of Teeworlds - GitHub - ChillerDragon/ddnet at chiller_cam_rec
12:50
open demo and do cl_rec_cam 1 to record you camera movement and then playback the same demo with cl_rec_cam 2 and itll do the same move
12:51
its looking at the game tick to do the sync it so different demos will not work
12:51
it needs adjust but yea its just a proof of concept of what is possible
12:53
so different demos with same map don't work?
12:53
what else could it look for, instead of the game tick
12:53
could it do it per frame?
12:53
or is that not accessible in the code
Avatar
ChillerDragon BOT 2023-06-25 12:54:35Z
you could sync it based on start of replay
12:54
but that might get of sync with varying frame times
Avatar
i am also tempted by the simple stupid idea of rendering all my demos with static view zomming out of the whole map and then rendering with 8k or more and then do the stuff with rendered mp4s
Avatar
ChillerDragon BOT 2023-06-25 12:55:28Z
can you even record 8k without a 8k screen?
Avatar
maybe with software renderer
Avatar
what r u guys planning
Avatar
ChillerDragon BOT 2023-06-25 12:56:12Z
sounds complicated
Avatar
virtual screen
12:56
chiller_cam_rec
12:56
kog_cam
Avatar
oh yeah speaking of demo rendering i had this idea about like, a mini video editor inside the demo preview, where you can place keyframes and have the demo automatically change settings accordingly like playback speed, where its spectating, zoom
Avatar
Avatar
Voxel
what r u guys planning
render many demos on top of eachother with synced camera movement
Avatar
Avatar
Voxel
oh yeah speaking of demo rendering i had this idea about like, a mini video editor inside the demo preview, where you can place keyframes and have the demo automatically change settings accordingly like playback speed, where its spectating, zoom
yeah we discussed such stuff already, maybe u can find it here in this channel
Avatar
what is gles, is it only in the linux build?
Avatar
Avatar
cauldron
what is gles, is it only in the linux build?
yes
12:59
and android
Avatar
is it software rendering?
Avatar
no
13:00
its OpenGL ES
Avatar
but wasn't there software rendering?
Avatar
embedded systems
Avatar
then it was something else
Avatar
i remember making this too
Avatar
Avatar
cauldron
but wasn't there software rendering?
on linux u can select under vulkan a software renderer
13:00
but why would u want this? D:
Avatar
because i want to render 8k demo
Avatar
ChillerDragon BOT 2023-06-25 13:03:14Z
ok the camera sync i built kinda works for multiple demos
Avatar
and for some reason i think it could be possible with software rendering?
Avatar
ChillerDragon BOT 2023-06-25 13:03:21Z
buts its somehow not very smooth
Avatar
okay, i'll try to build it
Avatar
Avatar
cauldron
because i want to render 8k demo
but software rendering does not help
13:04
quick google said u can create a virtual x server
13:04
with custom resolution
13:04
or use a linux VM
Avatar
what is a virtual x server? can you see it or does it run invisible in the background?
Avatar
i dunno, ask search engines
13:08
why do u even need it in 8k in first place xD
13:08
do you make a chile nature docu?
Avatar
i would render the demo of the whole map with static view zoomed completely out
13:09
and then define the camera position in a video editing program by zooming in (edited)
Avatar
and 8k is enough for that? 😄
13:10
well rendering in 8k, i hope u have at least 16 cores 😄
Avatar
it's just an idea... i can render through nights (edited)
Avatar
Avatar
Voxel
i remember making this too
damn, that's pretty good looking
13:22
shouldn't even be that hard to code too
Avatar
there is set_view, is there also get_view for getting the current camera positions in a demo
Avatar
ChillerDragon BOT 2023-06-25 14:48:19Z
no
14:48
but oh no wat u wanna do? :D
14:48
use set_view frame by frame? :D
Avatar
idk... it's complicated project...
Avatar
@Testing Lead @Tester What do you think about #6755 now? Some still want to use the RGB format quickly, so I added hotkeys for copy/pasting colors:
  • Support shift-rightclicking color picker buttons to copy the color to the clipboard in RRGGBBAA hex format.
  • Support shift-leftclicking color picker buttons to paste a color from the clipboard in RGB, RGBA, RRGGBB or RRGGBBAA format with optional leading # or $.
This system of copy&pasting could also be extended to other properties in the future, e.g. images, sounds, etc.
Avatar
Remove the individual RGBA sliders for editor color pickers and only show one button that opens the color picker popup instead. Decrease size of layer and point popups that previously had color pro...
Avatar
@Robyt3 from what I understand they just want the hex field to stay but don't realize that it's now inside the color picker, but quick copying of values is a nice feature anyway
Avatar
Avatar
Ravie
@Robyt3 from what I understand they just want the hex field to stay but don't realize that it's now inside the color picker, but quick copying of values is a nice feature anyway
Yeah, either that or opening the color picker popup to paste the RGB color is too slow for them, so the hotkeys should also solve this
Avatar
the screenshots in that pr don't show the color picker itself so it's not clear that the hex field is inside it
15:32
I don't think one more click to get to it is the problem
Avatar
@texnonik what is your opinion on this?
15:37
would you be annoyed if the color picker is always one click away
Avatar
Avatar
Ravie
I don't think one more click to get to it is the problem
i knew it was inside the color picker and still didn't like the 1 more click
15:42
the shortcuts fix it though
Avatar
Which was causing the listbox selection to be cleared when activating the filename editbox, as the filename search expects names without the file extension. Add fs_split_file_extension to separate filename and extension. Add fs_filename to extract file/folder name from path. This commit is not required for this PR, but including it reduces conflicts with #6752 and #6763, which need this commit.

Checklist

  • [X] Tested the change ingame
  • [ ] Provided screenshots if it is a ...
Avatar
Avatar
Jupstar ✪
@texnonik what is your opinion on this?
Why you ask me ? I am used to select colors with sliders . First i choose color and then i regulate it in with sliders. Because you have more option to select . 1.Maybe after color picker selected you could change there also with sliders ? 2. Maybe ad option that can add this sliders back again ?
Avatar
Avatar
texnonik
Why you ask me ? I am used to select colors with sliders . First i choose color and then i regulate it in with sliders. Because you have more option to select . 1.Maybe after color picker selected you could change there also with sliders ? 2. Maybe ad option that can add this sliders back again ?
bcs u use the editor the whole day 😂
16:24
i think the sliders are still there, simply behind an extra click
Avatar
With popup open
16:25
You just don't have individual RGB sliders anymore
Avatar
ChillerDragon BOT 2023-06-25 17:52:12Z
yikes got a segfault in my bash script haha
Avatar
u segfaulted bash?
Avatar
hsv sliders is better than rgb anyways
Avatar
would u know the HSV value for yellow from head?
18:22
i find HSV pretty unintuitive xD
Avatar
its visually a lot easier
18:25
humans see colors in hue saturation and brightness more than they see it in red green blue
Avatar
i unironically use hsv more
Avatar
yeah but we talked about sliders? i think with sliders we mean the input fields
Avatar
arent the input fields in there also sliders
18:25
just click and drag right/left
Avatar
i meant, its not the thiong where u choose the color
Avatar
the hex is rgb anyway
18:26
who cant read hexadecimals 😏
Avatar
hi, how i can install mysql for my server?
19:18
on windows
Avatar
who can spot the bug: just found it after ages of putting print statements all over my code. Cant trust copilot to write BFS
Avatar
god isnt c++ ugly
Avatar
i mean i can probably rewrite this to look better, just refactored a node based tree into an array based one with indices
20:07
so this was the first rewrite just to pass all my tests
20:07
but holy fuck this little bug wasted hours of my time
Avatar
exceptions bad
20:11
idk
20:11
should u deref the childitr?
20:12
what is Idx
Avatar
nah, the bug was that parentIdx and parentItr are references, and then the stack got popped
20:12
right at the top of the screenshot
20:12
idx = index
Avatar
i meant is it a typedef
Avatar
ah yeah for a size_t
Avatar
i see u like to put const after it xd
Avatar
const correctness
Avatar
Avatar
BillionRay
nah, the bug was that parentIdx and parentItr are references, and then the stack got popped
oh look, this is totally prevented by rust
Avatar
Avatar
BillionRay
const correctness
why not const Idx
20:13
another bad thing about c++ its not const by default
Avatar
there was some thing where if you put const on the left its not always consistent. i cant recall the situation ottomh
20:14
if you put const to the right then the thing to the left is what is const
20:14
yes, there are some bad defaults in c++ i agree
Avatar
const is totally bad default, cuz u will forget to put const, but u cant forget to "unconst" something because the compiler can tell when u modify something
20:14
well in c++ case maybe there are some edges
20:14
cuz c++ is a shotgun
20:14
to the foot
20:15
const_cast
Avatar
Avatar
Ryozuki
const is totally bad default, cuz u will forget to put const, but u cant forget to "unconst" something because the compiler can tell when u modify something
yes agreed
Avatar
2d70a38 Add fs_filename to extract file/folder name from path - Robyt3 030ffc1 Add fs_split_file_extension to separate filename and extension - Robyt3 af9c271 Fix editor save dialog filename showing file extension - Robyt3 c41d6f1 Merge #6764 - bors[bot]
Avatar
anyway ima get back to coding, just wanted to vent my frustration at that bug
Avatar
Add button to play/stop audio preview and label showing selected sound duration in editor sound list and sound file browser. Show error message instead of preview in editor image/sound file browser when selected file cannot be loaded. Screenshots:
Avatar
yo my boys, what do you think about prefixing 'I' to abstract classes / interfaces in c++? I know its done in the DDNet codebase, but what do you guys think of the practice in general?
Avatar
not enough experience to comment on this, I think
Avatar
Wasn't the norm A instead of I?
Avatar
I think I saw I in c# as well
Avatar
Avatar
BillionRay
yo my boys, what do you think about prefixing 'I' to abstract classes / interfaces in c++? I know its done in the DDNet codebase, but what do you guys think of the practice in general?
No strong opinion on it, but from a pure reading perspective it probably is easier with such an prefix.. is the question how consistent it was used and if inherited classes are allowed to be inherited too
Avatar
Avatar
BillionRay
yo my boys, what do you think about prefixing 'I' to abstract classes / interfaces in c++? I know its done in the DDNet codebase, but what do you guys think of the practice in general?
National Insurance Clerk 2023-06-25 20:58:59Z
Me naming everything "idk lol" and other variations of that
20:59
Telling myself that when my project gets serious enough I'll switch to actually normal names
20:59
Haven't used abstract classes and interfaces that much at all actually
Avatar
In practice i don't find it very useful tho i think. Most of the time I have an idea of what I want to use. And I rarely type out a type. E.g. if there is an enum called EEngineTypes I'd probably type in engtyp and let the ide search the exact name of the type for me
Avatar
Avatar
BillionRay
who can spot the bug: just found it after ages of putting print statements all over my code. Cant trust copilot to write BFS
&stack top followed by stack pop, instant bug
21:01
ah, lol, mobile discord moment, why am I scrolled so high up?
Avatar
Avatar
Learath2
&stack top followed by stack pop, instant bug
yep, thats what I get for letting copilot write shit. Also for some reason asan didnt trip on it either, neither did my static analysis script -_-
21:02
tbh not sure about the static analysis, i may have missed it in the sea of output
Avatar
I like I prefix for ABCs, adding data to them is imo a little sketch, but teeworlds/ddnet does it sadly
Avatar
also interesting opinions wrt prefixing abstract classes, i'm leaning towards not prefixing them myself
Avatar
The I prefix makes you think it's an ABC but it turns out not to be...
Avatar
Avatar
Devinci
Wasn't the norm A instead of I?
according to Microsoft, who most would consider to have coined this interface convention, I as a prefix does not just apply to abstract classes; it applies to interfaces, which are pure virtual classes which intend only to define the behavior of the implementation (nothing more, nothing less) and serve as a handle for the implementation via. pointer in COM/OLE
Avatar
i dislike prefixes in the era of LSP and hovering
21:04
also most often u dont rly need to care much about what it is
21:04
thanks to autocomplete
Avatar
Avatar
Ewan
according to Microsoft, who most would consider to have coined this interface convention, I as a prefix does not just apply to abstract classes; it applies to interfaces, which are pure virtual classes which intend only to define the behavior of the implementation (nothing more, nothing less) and serve as a handle for the implementation via. pointer in COM/OLE
what DDNet does with I might not even be 'real' interfaces in this regard
Avatar
prefixes are old standards
21:04
when u used to code with ex
Avatar
Avatar
Ryozuki
i dislike prefixes in the era of LSP and hovering
I like being able to read code without a 69 core machine with treesitter 86.3 beta edition running on llvm/clangd, sue me
Avatar
LSP == liskov substitution principle right? what is hovering though?
Avatar
Avatar
Learath2
I like being able to read code without a 69 core machine with treesitter 86.3 beta edition running on llvm/clangd, sue me
ok where do i sue
Avatar
My lawyer will be in touch
Avatar
Avatar
BillionRay
LSP == liskov substitution principle right? what is hovering though?
lsp = language server protocol, what gives u autocomplete
21:04
clangd is a lsp implementor
21:05
i was confused about lsp
Avatar
Avatar
Learath2
I like being able to read code without a 69 core machine with treesitter 86.3 beta edition running on llvm/clangd, sue me
same, vscode regularly gets up to 5gb of ram for me -_-
Avatar
but as it is i haven't seen any convention which explicitly distinguishes normal classes from abstract classes/interfaces like that, abstract classes are probably more of just an implementation detail and should be called the same as an implementation class if that's how it's being used
21:06
but if you're using it as common grounds for API maybe I would be appropriate
Avatar
(fwiw my 4c/8t cpu can't deliver enough performance to give good ddnet completion, I may be holding it wrong but I cba to mess around with the setup)
Avatar
mine's good enough
Avatar
Avatar
Learath2
(fwiw my 4c/8t cpu can't deliver enough performance to give good ddnet completion, I may be holding it wrong but I cba to mess around with the setup)
what, ddnet clangd is ultra fast
Avatar
yea my clangd in qt creator is pretty good on ddnet
Avatar
the only thing it misses is some autocomplete in the header file itself, cuz c++ is hard to parse
Avatar
it's choking on something, no idea what, but have no reason to debug it anyway, I know my way around the ddnet code well enough that I don't need it
21:07
the autocomplete list will regularly arrive like in 5-15s, completely unusable latency for me
Avatar
Avatar
Learath2
(fwiw my 4c/8t cpu can't deliver enough performance to give good ddnet completion, I may be holding it wrong but I cba to mess around with the setup)
how many worker threads have u authorized it to use
Avatar
Avatar
Learath2
(fwiw my 4c/8t cpu can't deliver enough performance to give good ddnet completion, I may be holding it wrong but I cba to mess around with the setup)
idk how it works exactly, but I know that the game/components header files have a high recompile cost (edited)
Avatar
jobs or w/e (i don't think it corresponds to real cores)
Avatar
Avatar
Ewan
how many worker threads have u authorized it to use
haven't changed the defaults, I can mess around with that if it's a setting tomorrow
Avatar
it is in mine. not sure about your setup (vscode?)
Avatar
Avatar
BillionRay
idk how it works exactly, but I know that the game/components header files have a high recompile cost (edited)
@heinrich5991 is it hard to setup precompiled headers
Avatar
i tried vscode for cpp one time and i couldn't get mingw set up so i quit
21:09
getting the cmake and cpp and whatever other extensions to play in tandem with a custom cc path was painful
Avatar
Sadly with Electron taking my cpu hostage, I fear I just might not have enough cores available anyway. Thanks javascript people for making my life worse
Avatar
toolchain files and stuff
Avatar
Maybe I can try with just vim, I think there is a vim clangd plugin
Avatar
Qt Creator's kits are awesome cuz I don't have to deal with any of that
Avatar
Avatar
Learath2
Maybe I can try with just vim, I think there is a vim clangd plugin
yea maybe
Avatar
ChillerDragon BOT 2023-06-25 21:10:43Z
21:11
yea its as simple as this @Jupstar ✪ didnt expect a segfault somehow
Avatar
What did you expect? 😛
Avatar
ChillerDragon BOT 2023-06-25 21:11:16Z
idk
Avatar
Avatar
Ryozuki
@heinrich5991 is it hard to setup precompiled headers
you can try to do it, I have no clue how hard it is
Avatar
ChillerDragon BOT 2023-06-25 21:12:03Z
i only ever saw segfaults in the c/c++ land
21:12
come to rust land
21:12
is that a segfault cuz overflow?
21:12
stack overflow
21:12
set a higher ulimit
21:12
watch the world burn
Avatar
I think rust has no way of stopping infinite recursion either, not like it can ever fix it unless it disallows anything except tail calls
Avatar
i don't think there is infinite recursion detection in an interpret language like python
21:13
or sh
Avatar
ChillerDragon BOT 2023-06-25 21:13:26Z
Avatar
@Learath2 is there a general algorithm to convert recursion to loops, even indirect recursion?
Avatar
something something halting problem something something cant prove something something infinite recursion is undetectable in a turing complete language
21:14
halting problem always there
21:14
to remind us we human
Avatar
i forgot about this song lol
Avatar
ChillerDragon BOT 2023-06-25 21:15:01Z
hooman
Avatar
Avatar
Learath2
I think rust has no way of stopping infinite recursion either, not like it can ever fix it unless it disallows anything except tail calls
it panics reliably instead of maybe segfaulting
Avatar
im only human
Avatar
Avatar
Learath2
I think rust has no way of stopping infinite recursion either, not like it can ever fix it unless it disallows anything except tail calls
it has max recursion depth ye, u can configure it with nightly iirc
Avatar
Avatar
Ryozuki
@Learath2 is there a general algorithm to convert recursion to loops, even indirect recursion?
I know an algo for tail calls, I think you rely on code restructuring trying to get to tail calls when optimizing generic recursion
21:15
Idk if any other kind of recursion is optimizable
Avatar
wdym tail call void fn() { //do stuff fn(); //? }
Avatar
Avatar
Ryozuki
it has max recursion depth ye, u can configure it with nightly iirc
no, that's for macros (unless I'm talking about something else)
Avatar
Avatar
Ewan
wdym tail call void fn() { //do stuff fn(); //? }
tail call
Avatar
the last expresion must be a call to the function itself
21:16
to be tail call optimizable
Avatar
Avatar
Ewan
wdym tail call void fn() { //do stuff fn(); //? }
if you only call the function again at the very end of your recursive function it can be optimized out
Avatar
2 + fn() is not tail call
Avatar
with a lot of fineprint (edited)
Avatar
@Ewan this is like the pillar wall of functional programming langs
Avatar
void x() { std::vector<int> y; x(); }
Avatar
in erlang u do everything with tail calls
Avatar
that's not a tail call
Avatar
yes, very large ToS, I don't know off the top of my head the exact ruleset
Avatar
Avatar
heinrich5991
void x() { std::vector<int> y; x(); }
ah cuz RAII
Avatar
yep
Avatar
rust has same problem
21:17
but there is a rfc iirc
Avatar
yes
21:17
yes
21:17
become
21:17
where become guarantees tail calls and runs destructors beforehand
Avatar
yea i just didn't know that's what it was called lol
Avatar
Avatar
heinrich5991
void x() { std::vector<int> y; x(); }
fwiw, I think llvm and gcc still both optimize out these under some ruleset
Avatar
because it sees that the destructor of y is side-effect free?
21:19
I don't think the optimization is legal if it has side-effects
Avatar
Yeah, I think so, I only remember encountering a godbolt sample of people arguing about it
21:20
The as-if rule allows inlining then reordering the destructor call with the "tail-call"
21:20
making it an actual tail call
21:24
I hate recursion for some reason, always feels so unintuitive to me
21:24
The concept makes sense but looking at actual recursive code is always so meh for me
Avatar
@Learath2 recursion is only rly useful with tail calls, and it often requires u to reverse order the work done
21:25
in erlang its common
21:25
the reverse makes the runtime nearly equal
Avatar
like 99/100 times I would always use an explicit stack
f3 1
Avatar
idk if for longer inputs is better tso
Avatar
this seems like the kind of thing that would also be important in lisp
Avatar
tail recursion is important on all functional langs
Avatar
Avatar
Learath2
The as-if rule allows inlining then reordering the destructor call with the "tail-call"
only if the destructor is side-effect free
Avatar
how do I set the default score in the scoreboard to 0 instead of 00:00? I've set client_score_kind to points instead of tiem but I still get 00:00 (edited)
22:02
time*
Avatar
there's a gameinfoflag for it, I think
Avatar
okay I got it (edited)
Avatar
Updated 'Laser' category for Ukranian language Finally it looks normal xd

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 (especially base/) or added coverage to integration test
  • [ ] Considered possible null pointers and out of bounds array indexing
  • [ ] Changed no physics that affect existing maps
  • [ ] Tested the change with ...
Avatar
ah wait wha?
❔ 5
Avatar
does anyone understand what the dead reckoning system does?
23:34
I'm a little bit confused why its there
23:34
specifically the server side one
Exported 453 message(s)