IRC logs for #openttd on OFTC at 2024-12-31
        
        
        
            ⏴ go to previous day
00:10:31  <xarick> tile + GetDockDirection(tile) == t
 
00:10:31  <xarick> what's evaluated first?
 
00:19:32  <talltyler> Aw, Copilot got it right 😦
 
00:22:20  *** Wolf01 has quit IRC (Quit: Once again the world is quick to bury me.)
 
01:58:29  *** nielsm has quit IRC (Ping timeout: 480 seconds)
 
02:03:59  *** gelignite is now known as Guest4580
 
02:04:02  *** gelignite has joined #openttd
 
02:11:18  *** Guest4580 has quit IRC (Ping timeout: 480 seconds)
 
03:18:14  *** gnu_jj_ has joined #openttd
 
03:21:36  *** gnu_jj has quit IRC (Ping timeout: 480 seconds)
 
03:25:31  *** Zathras has joined #openttd
 
03:28:48  *** D-HUND has quit IRC (Ping timeout: 480 seconds)
 
03:28:53  *** debdog has quit IRC (Ping timeout: 480 seconds)
 
03:34:05  *** firmat has quit IRC (Remote host closed the connection)
 
03:58:57  *** firmat has quit IRC (Remote host closed the connection)
 
04:42:27  <DorpsGek>   - Update: Translations from eints (by translators)
 
07:54:14  *** Flygon has quit IRC (Remote host closed the connection)
 
09:45:13  <peter1138> I mean it works, but the UI side is basically duplicated.
 
09:47:27  <peter1138> And that we haven't migrated the old setting-style cheats to settings means it's not too coherent.
 
09:54:45  <peter1138> Is this too verbose?
 
09:55:27  *** tabytac has joined #openttd
 
09:55:27  <tabytac> Would a more long term solution be to just have 1 settings page with added tabs for something like "client", "Company", "Game" and "Sandbox" added to the existing Game Options windows, maybe needing a slight design to accommodate the extras. If splitting up certain categories more to like "current game/all games" and "current company/all companies"
 
09:55:47  <kuhnovic> peter1138: Why is there separator line? What makes these settings different from a user perspective?
 
09:56:56  <truebrain> peter1138: Think about the savegame size ! 😛
 
09:57:30  <peter1138> truebrain: Yeah. We currently only log changes to things that can't be changed in network games.
 
09:59:10  <peter1138> Logging everything is clearly too much.
 
10:01:01  <peter1138> kuhnovic: Exactly. There are some cheats that are settings-style, and then other cheats that are actions. If all the settings-style cheats are moved to settings, the distinction is that the line separates actions from settings.
 
10:01:11  <peter1138> But yes, that isn't the case here right now.
 
10:01:56  <peter1138> Amazing, I can actually see sky today.
 
10:08:18  <kuhnovic> I still don't really see how that makes a difference from a user perspective 😛
 
10:13:15  <kuhnovic> The cheese is brown here
 
11:35:45  *** Flygon has quit IRC (Ping timeout: 480 seconds)
 
11:40:50  *** Smedles has joined #openttd
 
11:54:06  <peter1138> Why is it ARMOURED, and why is the description so long?
 
11:56:31  <peter1138> This one is also very long, but at least it is formatted to be readable.
 
12:01:19  *** Flygon_ has joined #openttd
 
12:06:44  *** Flygon has quit IRC (Ping timeout: 480 seconds)
 
12:30:20  <xarick> 69.8 seconds to 70.7 seconds...
 
12:30:37  <xarick> it's not much of a slowdown
 
12:46:50  <andythenorth> what are we doing today?
 
12:46:57  <andythenorth> compression fit waste plumbing?
 
12:50:07  *** gelignite has joined #openttd
 
13:20:25  <andythenorth> I think the plumbing
 
13:20:28  <andythenorth> owing to the leaks
 
13:21:49  <_glx_> yeah plumbing feels it should always be first
 
13:22:38  <_glx_> but it's often something that needs to be done on sunday, when everything is closed
 
13:26:08  <xarick> could you even tell the difference?
 
13:30:48  <xarick> there's a big emphasis on the "performant" path
 
13:31:02  <_glx_> right finished after left
 
13:31:25  <xarick> but it's kinda a "meh" difference between them
 
13:31:50  <_glx_> yeah 1s or 2s diff on a very long run doesn't really matter
 
13:36:32  <xarick> thinking what to do next
 
13:38:08  <xarick> should I chase those consts that don't allow me to use tile + dir directly... should I revert all the tile + dir smart code, ...
 
13:39:39  <peter1138> Colour's all wrong.
 
13:41:49  <xarick> I'm worried about tile + dir being very prone to errors
 
13:42:08  <xarick> not sure it's worth the risk
 
13:43:31  <andythenorth> peter1138: a bit
 
13:43:31  <xarick> maintainability and all that considered, it feels bad this just won't work for all the cases
 
13:43:41  <andythenorth> "settings are hard"
 
13:43:47  <andythenorth> windows control panel anyone?
 
13:54:03  <xarick> how to fix this stack overflow?
 
13:54:37  <peter1138> Make your operator-() not call itself.
 
13:55:28  <peter1138> By implementing the operator properly.
 
13:56:01  <peter1138> Adding/subtracting an axis doesn't seem like it should be an operator anyway.
 
13:56:55  <andythenorth> would we like me to learn C++ for general entertainment?
 
14:03:50  <Rubidium> andythenorth: yes, please. Entertain us ;)
 
14:13:29  <xarick> i just "implemented it properly"!
 
14:13:49  <xarick> too much copy paste code
 
14:15:43  <truebrain> andythenorth: trying to learn me NewGRF was entertaining, so I don't see why not!
 
14:18:41  <peter1138> Hmm, crazy devs, removing features that never existed.
 
14:20:01  <Rubidium> oh, what did we remove this time?
 
14:38:53  *** frosch123 has joined #openttd
 
14:38:53  <frosch123> Do we still need the Apple Developer Program? It's about to expire, and I don't know who reads info@
 
14:40:50  <_glx_> learning squirrel stack is entertaining too
 
14:49:01  <truebrain> frosch123: when I read those emails, I just forward them to orudge 🙂
 
14:49:29  <truebrain> and yes, we still need it 😛 The MacOS builds are signed because of it 😄
 
14:50:30  <truebrain> but so far it has been the case of: it expires, because we didn't sign their new agreements (there is a new one every, what, 3 months? It is insane), we notice the nightly fails, I poke orudge, he fixes it 😛
 
14:51:17  <truebrain> I really do not know why they insist on changing their terms this often ... they really are a special snowflake 🙂
 
14:53:42  <truebrain> (I just forwarded the mail to orudge)
 
15:03:16  <xarick> `DrawTrainDepotSprite(x, y, widget - WID_BRAD_DEPOT_NE + DIAGDIR_NE, _cur_railtype);`
 
15:03:16  <xarick> WID_BRAD_DEPOT_NE + DIAGDIR_NE is complaining
 
15:05:32  <peter1138> const-ness again, in case you can't figure it out like last time.
 
15:08:59  <xarick> please explain, i don't get it
 
15:09:47  <xarick> i addec const to TileIndex
 
15:11:17  <peter1138> Hehehe, still cursed.
 
15:11:31  <peter1138> Black on mauve is a bit...
 
15:12:22  <xarick> > error C2666: '+': overloaded functions have similar conversions
 
15:12:22  <xarick> > note: could be 'TileIndex operator +(const TileIndex &,DiagDirection)'
 
15:12:22  <xarick> > note: or       'built-in C++ operator+(int, DiagDirection)'
 
15:12:45  <xarick> it's the 2nd one in this case
 
15:13:33  <peter1138> Ah of course, you've overloaded things and now there are multiple options.
 
15:13:33  *** Wormnest has joined #openttd
 
15:13:55  <xarick> enum BuildRailDepotWidgets : WidgetID {
 
15:14:06  <xarick> WidgetID + DiagDirection
 
15:14:13  <peter1138> Convert DIAGDIR_NE to integer first.
 
15:15:32  <xarick> nice, that fixed it, but now this leaves me wondering what else could be broken
 
15:20:27  <xarick> AddSortableSpriteToDraw(overlay + RTO_SLOPE_NE + static_cast<int>(tunnelbridge_direction)
 
15:21:38  <xarick> what i find it boggling is that it's not even a TileIndex
 
15:21:48  <xarick> why would it catch that
 
15:26:39  <mnhebi> andythenorth: I mean if you like cthulhu picking apart your brain, sure C++ is entertainment
 
15:28:02  <peter1138> Because StrongType has a non-explicit default constructor from uint32_t.
 
15:28:33  <peter1138> And also an assignment operator.
 
15:29:41  <peter1138> Which kinda makes a mockery of StrongType. But at some point...
 
16:02:33  <talltyler> peter1138: White on mauve is better, but might be a bit harsh to look at
 
16:03:31  <talltyler> That said, remember when we had a disagreement several years ago about too many window colours, and I wanted more to be grey? I’ve since changed my mind. I want more colours! 😄
 
16:04:32  <talltyler> I’m even wondering how the game would look with the green vehicle windows from TTD… 😛 (or TT? I’ve never actually played)
 
16:06:37  <talltyler> Speaking of the settings menu, I wonder if it’s worth splitting Settings into client settings (news notifications, signal side, gui stuff, etch and game settings. Client settings would be a natural fit for the Options menu even if the game settings didn’t get merged into that window.
 
16:07:15  <peter1138> talltyler: This is what someone said above.
 
16:07:38  <talltyler> Oh, I guess I didn’t read the whole scrollback 😄
 
16:07:55  <peter1138> So actually I did something completely different to that suggestion, which wasn't about merging options and settings at all.
 
16:08:03  <talltyler> Huh, read the posts above and below, and missed that one…
 
16:08:26  <peter1138> IMHO I don't see a reason to merge only some of the options.
 
16:08:29  <talltyler> That’s what I get reading Discord first thing in the morning
 
16:08:39  <peter1138> But I do see value in splitting out the client-side preferences from the gameplay preferences.
 
16:09:48  <peter1138> The big tree was certainly an idea, but it's complex and a bit confusing.
 
16:10:04  <peter1138> It was originally tabs, too.
 
16:10:55  <talltyler> I do like the search feature, I use that more than exploring the tree
 
16:11:26  <peter1138> _glx_: Having looked, I think quite a lot of it wrong and only works because of the implicit conversion from basetype to strongtype.
 
16:57:03  *** nielsm has quit IRC (Ping timeout: 480 seconds)
 
17:20:11  <xarick> what's the difference vs inline and debug_inline
 
17:21:01  <xarick> #define debug_inline inline
 
17:23:01  <xarick> is there an advantage in not using inline for release?
 
17:28:15  *** kuka_lie has joined #openttd
 
17:32:15  <peter1138> debug_inline means it should/could be inlined even with a debug build.
 
17:34:20  * Rubidium wonders why I put all that documentation in stdafx
 
17:40:25  <peter1138> Write-only documentation?
 
17:45:22  <xarick> btw Intellisense is always complaining about script_ai
 
17:45:36  <xarick> seemingly for no reason
 
17:48:16  <xarick> it wasn't captured by visual studio
 
17:48:43  <peter1138> It's there. In the source code. You just need to look at it.
 
17:55:54  <xarick> okay, so i need to test performance on debug builds, does that also incluse RelWithDebInfo?
 
17:56:28  <xarick> not quite sure what a (pure) debug build is
 
17:57:43  <peter1138> You probably do not need to test performance on debug builds.
 
18:02:45  <xarick> i hear a ship sound and then silence
 
18:19:36  <xarick> wentbourne, let me check where i have it
 
18:20:03  <xarick> how do i run for 100 ticks
 
18:36:34  <kurzov> Not sure whether to ask this in Discord channel #add-on-development or here because it has to do with the addon hosting service: But is there any plans to make the "Check Online Content" / BANANAS addon browser less of a "giant monolith" (for lack of a better term) to browse - maybe some sorting options, such as by last update date?
 
18:41:24  <_glx_> one day someone® may do it
 
18:43:55  <xarick> last of my very scientific performance tests
 
18:46:44  *** tokai|noir has joined #openttd
 
18:46:44  *** ChanServ sets mode: +v tokai|noir
 
18:52:03  <xarick> let me remove all inlines and debug_inlines, see what happens
 
18:53:36  *** tokai has quit IRC (Ping timeout: 480 seconds)
 
18:54:07  <xarick> oh, link errors 😦 many of them
 
18:58:29  <xarick> whatever, can't even make it build, so...
 
19:10:34  <johnfranklin> £3 single bus ticket cap… it is still not sure whether a single ticket would rise up to £3.
 
19:11:25  <johnfranklin> New year gift, but that “gift” is in german language.
 
20:37:36  *** Flygon_ has quit IRC (Read error: Connection reset by peer)
 
21:05:38  <xarick> 3 minutes to recompile after a comment change 😦
 
21:10:52  <xarick> 2 minutes and 10 seconds...
 
21:26:28  <xarick> wish I could ask questions to rubidium without angering him
 
21:27:13  <xarick> `TileIndex operator+=` or `TileIndex &operator+=` ?
 
21:31:48  <peter1138> Have you tried thinking about it? Are you returning a new TileIndex or the existing one?
 
21:33:40  <xarick> I have this weird situation `*tile += DIR_N;`
 
21:34:08  <peter1138> Okay, which one of those will return a new TileIndex, and which one will return an existing TileIndex?
 
21:35:29  <xarick> `if (CircularTileSearch(&tile, 40, SearchLumberMillTrees, nullptr))`, this tile is passed around and is updated, needs to return back updated
 
21:36:07  <xarick> I think it's `TileIndex &operator+=`
 
21:36:39  <xarick> but I also have cases where it's just tile += other_dir
 
21:37:55  <xarick> question is, do I need both `TileIndex operator+=` or `TileIndex &operator+=`?
 
21:54:09  <peter1138> I said something and this happens 😉
 
21:55:24  <xarick> woah, only 22 changes files? I changed 54
 
21:55:27  <johnfranklin> Say someone, someone arrives
 
21:55:33  <peter1139> Rubidium, how did you identify all occurances?
 
21:55:57  <Rubidium> make the constructor explicit
 
21:56:07  <peter1139> Ah, tested that way.
 
21:56:23  <peter1139> Should we use TileIndex{...} so that it doesn't look like a function call?
 
21:57:28  <peter1139> Oops, I should comment on the PR. Silly me.
 
21:58:12  <Rubidium> peter1139: could do that, but window_number is int32_t and TileIndex wants uint32_t, so it'd become TileIndex{static_cast<uint32_t>(...)}
 
22:00:12  <peter1139> Ah right, it's basically only this->window_number then.
 
22:00:42  <peter1139> At least for this set.
 
22:00:46  <LordAro> feels like they should not be different underlying types
 
22:02:14  <peter1139> Technically TileIndex{static_cast<uint32_t>(...)}
 
22:02:26  <peter1139> ... makes it clearer what is going on. But it's also noisier.
 
22:03:18  <peter1139> LordAro, you mean this->window_number should be uint32_t?
 
22:03:47  <peter1139> Or perhaps we should drop the window_number system and use real types. Not sure how feasible that is.
 
22:04:10  <peter1139> this->window_number refering to different things is a bit annoying sometimes.
 
22:04:19  <peter1139> But here we have scope creep.
 
22:05:17  <xarick> what about places that check for tile 0 ? 😦
 
22:05:46  <xarick> TileIndex{} = undefined value
 
22:05:59  <peter1139> That's not implicit construction.
 
22:06:47  <peter1139> Hmm, last time I thought about using constructor-casts like that somebody disagreed. Hmm.
 
22:09:11  <peter1139> I guess this is where other languages have (expensive) unboxing.
 
22:19:00  <xarick> it's new year time soon
 
22:24:09  <johnfranklin> How long will I get used to say 2025 instead of 2024…
 
22:24:41  *** belajalilija has joined #openttd
 
22:24:49  <belajalilija> i still think 2013
 
22:25:18  <belajalilija> i think i wrote 2014 on something recently and it wasnt a typo
 
22:43:53  <peter1139> So many rabbit holes.
 
22:50:09  *** gelignite has quit IRC (Read error: Connection reset by peer)
 
22:57:09  *** gelignite has joined #openttd
 
22:59:33  <Rubidium> yup, rabbit holes ;)
 
23:15:47  <xarick> Rubidium stuff gets merged quickly
 
23:19:10  <peter1139> LordAro, stop partying :D Any better ideas than TileIndex(this->window_number)?
 
23:19:58  <xarick> TileIndex{this->window_number}
 
23:20:46  <peter1139> Would need to be TileIndex{static_cast<uint32_t>(this->window_number)}, which is a mouthful.
 
23:25:49  *** keikoz has quit IRC (Ping timeout: 480 seconds)
 
23:34:40  <xarick> wow, i just discovered a fix
 
23:35:21  <xarick> ```TileIndex operator+(const TileIndex &tile, DiagDirection &diagdir)
 
23:35:21  <xarick> TileIndex operator+(const TileIndex &tile, DiagDirection diagdir)```
 
23:36:05  <xarick> the first one solves the issue of `DrawTrainDepotSprite(x, y, widget - WID_BRAD_DEPOT_NE + DIAGDIR_NE, _cur_railtype);`
 
23:36:14  <xarick> i don't need static_cast anymore
 
23:36:22  <_glx_> multiple overloads for similar things is never a good idea
 
23:36:33  <xarick> I can get rid of the 2nd
 
23:38:34  <_glx_> but nothing is a TileIndex there, so it should not use any of these
 
23:39:12  <peter1139> It does because of what Rubidium is now working on fixing.
 
23:39:13  <_glx_> (I know it's the implicit conversion)
 
23:39:41  *** kuka_lie has quit IRC (Quit: hmm should i go to sleep? its just 1.39 am)
 
23:43:45  <peter1139> Not really helping but tidies that up.
 
23:48:13  <xarick> oops, didn't work for SpriteID
 
23:48:26  <xarick> SpriteID + DiagDirection 😦
 
23:48:58  <xarick> > 23:48:11:439    E:\OpenTTD Visual Studio\SamuXarick\OpenTTD\src\tunnelbridge_cmd.cpp(1316): error C2666: '+': overloaded functions have similar conversions
 
23:48:58  <xarick> > 23:48:11:720      E:\OpenTTD Visual Studio\SamuXarick\OpenTTD\src\map_func.h(503): note: could be 'TileIndex operator +(const TileIndex &,DiagDirection &)'
 
23:48:58  <xarick> > 23:48:11:721      E:\OpenTTD Visual Studio\SamuXarick\OpenTTD\src\tunnelbridge_cmd.cpp(1316): note: or       'built-in C++ operator+(SpriteID, DiagDirection)'
 
23:50:30  <_glx_> because any number can be implicitly converted to TileIndex
 
continue to next day ⏵