IRC logs for #openttd on OFTC at 2024-09-22
β΄ go to previous day
00:04:55 *** Wormnest has quit IRC (Quit: Leaving)
01:06:05 *** Tirili has quit IRC (Quit: Leaving)
01:36:13 *** ChanServ sets mode: +v tokai
01:43:03 *** tokai|noir has quit IRC (Ping timeout: 480 seconds)
02:19:29 *** gnu_jj_ has quit IRC (Ping timeout: 480 seconds)
02:36:13 *** debdog has quit IRC (Ping timeout: 480 seconds)
03:01:25 *** D-HUND is now known as debdog
04:47:29 <DorpsGek> - Update: Translations from eints (by translators)
04:57:53 *** tokai|noir has joined #openttd
04:57:54 *** ChanServ sets mode: +v tokai|noir
05:04:28 *** tokai has quit IRC (Ping timeout: 480 seconds)
06:03:13 *** johnfranklin has joined #openttd
06:03:57 <johnfranklin> You cannot eat very full, but calorie/weight value is high, you also donβt feel hungry until next lunch
06:05:45 <johnfranklin> The coach is late
06:15:14 <johnfranklin> Expt 0711, in fact 0714.
06:29:18 *** alfagamma0007 has joined #openttd
07:02:09 *** belajalilija has joined #openttd
07:02:09 <belajalilija> johnfranklin: In the UK?
07:02:21 <belajalilija> Wait yes the time zone
07:02:47 <belajalilija> Donβt expect anything to be on time here
07:08:47 *** HerzogDeXtEr has joined #openttd
07:14:33 <peter1138> Where are all meeting up?
07:16:03 *** andythenorth has joined #openttd
07:16:08 <peter1138> Is it legal to compose a string to draw by using std::string?
07:16:44 <peter1138> I need a comma-separated list of any number of items.
07:17:12 <peter1138> The only vaguely similar thing is inside FormatString, but that takes a uint64_t bitmask of cargotypes.
07:31:44 <Rubidium> given parameters are a variant now, might adding std::vector<uint64_t> or std::vector<std::string> make more sense?
07:37:06 *** akimoto has joined #openttd
07:48:54 <peter1138> Is this "make it initially more complex but also generic so other things can use it" territory π
07:53:03 <peter1138> And then there's translation support... we know how trying to be flexible worked out...
07:53:13 <peter1138> (Stupid English person complaining...)
07:56:48 <peter1138> Ah that one was specifically only cargo.
08:09:20 <andythenorth> my entire game-making career: "random isn't mathematical random'
08:15:15 <Rubidium> peter1138: it might also be that I'm not understanding what you're trying to achieve. I assumed you wanted to pass a comma separated string into a dparam, and based on the content construct something
08:16:46 <peter1138> Oh you are understanding, and doing it in the string system is probably cleaner. But also more work than just concatening with a comma.
08:25:20 <peter1138> std::vector<std::string> s;
08:25:20 <peter1138> s.push_back(string);
08:25:21 <peter1138> SetDParamStrList(1, s);
08:25:23 <peter1138> doesn't gain much over
08:25:27 <peter1138> if (!s.empty()) s += ", ";
08:25:29 <peter1138> SetDParamStr(1, s);
08:25:31 <peter1138> and has a disadvantage of making more string copies.
08:26:21 <peter1138> Can't use string_view either because my strings come via GetString() allso
08:27:02 <peter1138> std::vector<StringID> is possibly more sensible
08:46:28 <peter1138> Hmm, if I could GetString into std::string... π
08:49:01 <peter1138> Hmm, GetStringWithArgs does that.
08:49:23 <peter1138> But is strings_internal
08:55:16 <peter1138> GetStringPtr is 'public' though. Hmm.
09:05:12 <peter1138> Okay, `GetStringInPlace(std::string &, StringID)` works for me.
09:34:34 *** _pruple has joined #openttd
09:44:40 <andythenorth> shift-ctrl-click for reversing articulated vehicles though π
09:44:52 <andythenorth> /me word-souping
09:47:32 <peter1138> He's been infiltrated by LLM.
09:49:37 <peter1138> Such effort to make this not so bad :p
09:50:00 <peter1138> It was two separate lines before.
09:50:09 <andythenorth> peter1138: the irc logs suggest I was always just word-soup π
09:50:15 <andythenorth> maybe LLMs are trained on me?
09:50:28 *** truebrain has joined #openttd
09:50:28 <truebrain> or you were just an early release
09:53:18 <_pruple> peter1138: is this text auto-added by the badges?
09:55:02 <peter1138> Naming things is weird.
09:55:55 <peter1138> "Traction type" only comes up in medical things.
09:57:40 <peter1138> Well, it doesn't matter too much to the core game.
09:58:27 <_pruple> I do need to change it, one way or another
09:58:35 <peter1138> Only if you use badges π
09:58:44 <peter1138> And in that case you are already changing things.
09:58:47 <_pruple> also because my track type is called "third rail", not "3rd rail". π
09:59:46 <peter1138> Although, if you set a badge on a rail ype, and that badge has the copy flag, then it will also apply to any vehicles of that railtype.
10:01:11 <peter1138> So maybe I should only show the first name π
10:01:45 <peter1138> Or have another flag to decide that.
10:01:56 <_pruple> what if they're not strictly of that railtype? π
10:02:26 <peter1138> Vehicles only have 1 railtype.
10:02:52 <peter1138> They won't get badges from compatible railtypes applied.
10:04:24 <_pruple> fair enough. In this case they're compatible but not the same, although that's obviously within my power to change.
10:05:45 <peter1138> I can see the use of more flags. "Stop name list after including this badge" and "Exclude from name list if not first badge"
10:05:51 <peter1138> But maybe confusing and foot-guns.
10:06:20 <peter1138> When it comes to drawing an icon in the list, only the first icon (in each class) is displayed.
10:27:38 <_pruple> so here's a question for an LLM
10:28:24 <_pruple> if the map highlights for "remove" actions are generally red, why is "demolish" white?
10:40:46 <johnfranklin> 30min late arrival
10:46:32 <andythenorth> it said white is more serious than red
10:47:36 <peter1138> One thing that would improve the demolish tool would be for the tile highlight to expand to include whatever will be deleted.
10:48:17 <peter1138> Not saying that I've accidentally destroyed an entire station when I meant to remove a single tile before, but... I've accidentally destroyed an entire station when I meant to remove a single tile before.
10:48:59 <_pruple> in that case, it would be nice to (have an option to?) demolish stations one tile at a time
10:49:30 <peter1138> Well, that's the remove tile tool does...
10:49:43 <peter1138> Ctrl-bulldoze could do that?
10:50:22 <_pruple> I'd like to see it be an option to just have demolish not remove the whole station. it's how demolishing multi-tile truck or dock stops works.
10:50:41 <_pruple> and the "remove" tool doesn't remove the track, which makes removing a platform or two an annoying two-stage task.
10:57:52 <peter1138> Removing a single platform is also a use-case.
11:13:24 <LordAro> peter1138: i wonder if that would allow getting rid of the ::None enum values
11:13:34 <LordAro> but perhaps it's not desirable to do so
11:14:03 <peter1138> Probably not, that's needed as a default value when nothing is set.
11:16:02 *** akimoto has quit IRC (Remote host closed the connection)
11:57:32 *** ahyangyi has joined #openttd
11:57:32 <ahyangyi> _pruple: The current behavior isn't very consistent between train stations and bus stops: removing a train station is removing all train station tiles, but removing a bus stop is just that stop
12:56:06 <peter1138> I can do "first issues"
12:57:49 *** reldred has joined #openttd
12:57:49 <reldred> PeterNviaGitHub: Oh god I need this π
12:58:17 <reldred> Always annoys me how random that was
12:58:45 <peter1138> It's still (slightly) random π
12:59:00 <peter1138> Perhaps unnecessarily.
13:20:54 <truebrain> now it isn't really random at all π
13:21:24 <truebrain> not saying that is a bad thing btw π
13:21:46 <peter1138> Yeah but that is random π
13:22:24 <truebrain> It sure is random, yes π Just not as random π
13:22:43 <truebrain> basically we go from one end of the spectrum to the other π π
13:23:00 <peter1138> Yes. That's the point π
13:23:42 <truebrain> owh, it is even always N/X or N/X-1 amount, that become cities π
13:23:58 <truebrain> I also want N/X+1! π
13:25:08 <truebrain> More chaos! MOAR! π
13:25:42 <peter1138> I added the offset because with 9 towns, 1-in-4 would always produce 3 cities. Which is 1-in-3...
13:26:02 <truebrain> yeah, now it can be either 2 or 3 π
13:26:07 <truebrain> it is just a bit boring, that is all π
13:26:30 <peter1138> The description of the setting doesn't ask for randomness.
13:26:51 <truebrain> still not saying it is a bad thing; just boring π
13:26:56 <truebrain> I was thinking with 1000 towns
13:27:01 <truebrain> means either 249 or 250 are cities
13:27:14 <truebrain> I guess that is fair; only for small amounts of towns it is relevant
13:27:18 <truebrain> (the random offset)
13:27:58 <peter1138> Well, with 1000 towns it will always be 250.
13:28:53 <truebrain> really? If the offset is anything not zero, it will be 249, not? Not that it matters, but now I am curious π
13:33:38 <peter1138> No, only if the number of towns is not a multiple of X.
13:34:10 <truebrain> owh, lol, like that. Fair enough π
13:34:44 <peter1138> If there's 4 towns, then a 1-in-4 proportion means there will always be 1.
13:34:51 <truebrain> For a moment I did consider if a statistical approach wouldn't be better for larger towns, so with 1000 towns it can be anything between 240 and 260 cities. Still "1:4" int hat sense. But it is a lot of code for very little added value π
13:35:04 <peter1138> If the setting had as "1-in-4 chance" then I would've been closing as "not a bug" π
13:35:27 <truebrain> if the setting had "1-in-4 chance" we should change the setting description π
13:35:41 <truebrain> so I am happy the description isn't that π
13:36:05 <peter1138> Apparently 2 people find the behaviour annoying. Although only one considered it a problem.
13:36:17 <peter1138> Now, out of the millions (lol) of players, that's.... none.
13:36:44 <truebrain> I am going to close all bugs now; "your opinion is irrelevant against the millions of players we have; bye now" π π π
13:37:23 <peter1138> "You never listen to players" -- "Players never say anything"
13:41:47 <Rubidium> or might it be the millions of players that did not count the exact number of towns and cities
13:42:43 <peter1138> Well, you need a nightly more recent than 3 months ago to easily see the number of towns.
13:42:56 <peter1138> We never did add a filter for city though.
13:43:37 <peter1138> Maybe I should do that.
13:44:45 <peter1138> Filtering the town list by cities is the (unwritten) solution that avoided having to explciitly say "N towns, N cities"
14:10:34 *** Flygon has quit IRC (Quit: A toaster's basically a soldering iron designed to toast bread)
14:29:03 <_pruple> what are the last 5 sprites in autorail (action 5 type 13)? I can't find them. And it's kind of weird there's an odd number of them.
14:37:14 *** locosage has joined #openttd
14:37:14 <locosage> I posted a full sheet of action5 sprites at some point
14:37:59 <_pruple> I know what they look like, from the opengfx source. I just don't know what they're used for.
14:39:28 <locosage> ah, dunno then, didn't get to them in bonky
14:45:46 <peter1138> Surely the spec says? π
14:46:32 <_pruple> the spec says there are 55 sprites. Handy. π
14:48:02 <_pruple> the last 5 | sprites appear to be superfluous. And like I said, it's strange that there's an uneven number of them, 3 left and 2 right.
14:51:43 <Rubidium> looks like someone just drew many sprites, moved them around or something and left stuff but didn't want to change the constant because it required a lengthy recompile or something
14:51:48 <_pruple> huh, so they're just junk? fine. π
14:53:45 <Rubidium> it certainly looks like it... and it looks like they were when they were merged. I wonder who approved that PR ;)
14:54:18 <_jgr_> That looks like it was before the days of PRs and approving things
14:54:41 <_pruple> 20 years ago, wow. π
14:55:13 <peter1138> Ok that animation was annoying :p
15:07:46 <peter1138> > eesh, Vanilla making weird changes for sake of change again
15:07:53 <peter1138> Another happy customer
15:10:11 <_pruple> I saw that, but it makes very little sense to me.
15:16:15 <_pruple> it shows the current order when you mouse over the bar on a stopped train
15:16:23 <_pruple> this is a thing that happened more than 4 years ago
15:16:42 <_pruple> "weird changes for the sake of change" indeed.
15:18:45 <peter1138> The label used to go red.
15:20:42 <peter1138> In 14.1, it goes red the moment you click on it, but still shows the speed.
15:21:01 *** Wormnest has joined #openttd
15:22:08 <_pruple> what kind of scrub is stopping/starting trains using the window bar, instead of ctrl-clicking on the train itself, anyway?
15:23:08 <_jgr_> How will a typical player ever find out about ctrl-click to start/stop?
15:27:35 <_pruple> mind you, is it supposed to also show the current order on mouseover when waiting for a path? because it doesn't seem to...
15:28:06 <peter1138> I think the bug is that `TC_RED | TC_FORCED` is not working.
15:32:58 <peter1138> Yeah, my change that stopped strings being cached twice due to colours has broken TC_FORCED.
15:46:42 *** Smedles_ has joined #openttd
15:49:21 *** gelignite has joined #openttd
15:49:51 *** Smedles has quit IRC (Ping timeout: 480 seconds)
15:59:52 *** Smedles has joined #openttd
16:06:06 *** Smedles_ has quit IRC (Ping timeout: 480 seconds)
16:19:59 <andythenorth> Changes for the sake of change -> Horse
16:33:31 <Rubidium> I'd say that PR is also a change for the sake of change
16:40:14 <andythenorth> we should certainly remove the feature that shows the next stop of a stopped train on hover
16:40:32 <andythenorth> then it can be added back in a patchpack, so the 5 players with pitchforks can complain that vanilla never adds anything
16:40:49 <andythenorth> it's funny how loud such a small number of squeaky wheels are
16:53:39 <truebrain> Na-apert π (sorry, translation doesn't do justice π )
16:55:24 <Rubidium> who's to say I didn't press the button first? I just didn't pay for a super fast computer or internet connection, so it got registered later... ;D
17:08:59 *** tokai|noir has quit IRC (Ping timeout: 480 seconds)
17:09:49 <peter1138> Lone dev on a rampage spamming the PRs.
17:14:15 *** ChanServ sets mode: +v tokai
17:19:38 *** tokai|noir has joined #openttd
17:19:38 *** ChanServ sets mode: +v tokai|noir
17:20:06 <xarick> Why did I put these changes here? ` && st->owner != OWNER_NONE`
17:23:03 *** tokai has quit IRC (Ping timeout: 480 seconds)
17:30:28 *** tokai|noir has quit IRC (Ping timeout: 480 seconds)
17:31:09 <xarick> isn't there a smart way to code this?
17:32:26 *** ChanServ sets mode: +v tokai
17:33:35 <xarick> `if (st->owner != ScriptObject::GetCompany() && st->owner != OWNER_NONE)`
17:35:02 <merni> Well, what do you think is dumb about that way?
17:37:18 *** tokai|noir has joined #openttd
17:37:18 *** ChanServ sets mode: +v tokai|noir
17:38:11 <LordAro> the pythonic way would be `if st.owner not in (ScriptObject.GetCompany(), OWNER_NONE)`
17:38:25 <LordAro> c++ doesn't really have an equivalent
17:40:28 *** tokai has quit IRC (Ping timeout: 480 seconds)
17:44:42 <peter1138> Test for OWNER_NONE first.
17:45:07 <_glx_> yeah always the less expansive first
17:45:09 <peter1138> Probably doesn't matter here but I remember we did some performance improvements by tweaking the order of some script tests.
17:45:23 *** tokai|noir has quit IRC (Ping timeout: 480 seconds)
17:48:34 *** ChanServ sets mode: +v tokai
17:59:13 *** tokai|noir has joined #openttd
17:59:13 *** ChanServ sets mode: +v tokai|noir
18:02:23 *** tokai has quit IRC (Ping timeout: 480 seconds)
18:08:18 *** tokai|noir has quit IRC (Ping timeout: 480 seconds)
18:11:24 *** ChanServ sets mode: +v tokai
18:11:52 <johnfranklin> Gotta play some openttdβ¦
18:14:00 *** Wormnest has quit IRC (Ping timeout: 480 seconds)
18:22:56 <peter1138> Hmm, okay, badge filter for other things.
18:48:18 *** Wormnest has joined #openttd
19:58:21 *** wallabra has quit IRC (Read error: No route to host)
19:58:50 *** wallabra has joined #openttd
20:09:42 *** gelignite has quit IRC (Quit: Stay safe!)
20:10:24 *** Wormnest has quit IRC (Ping timeout: 480 seconds)
20:43:47 <xarick> oh snap... got a NOT_REACHED
20:48:33 *** nielsm has quit IRC (Ping timeout: 480 seconds)
20:48:43 *** Wormnest has joined #openttd
20:58:39 <LordAro> alter the code such that the NOT_REACHED is ...not reached
20:59:37 <xarick> I have a somewhat controversial solution
21:06:00 <xarick> yeah... this is troublesome
21:12:21 *** HerzogDeXtEr has quit IRC (Read error: Connection reset by peer)
21:13:59 <xarick> okay, solution is ready
21:16:57 <xarick> not quite what I'd like as a solution, but fine...
21:18:21 <xarick> || ::IsOilRig(tile) is added
21:19:47 <xarick> oil rigs are not considered airports according to the rest of API logic, so I also made it not getting an airport tile
21:20:20 <LordAro> as long as it's well documented, i don't see an issue with that
21:20:22 <xarick> but in my other PR, I want them to be
21:40:23 *** keikoz has quit IRC (Ping timeout: 480 seconds)
22:02:52 *** Wolf01 has quit IRC (Quit: Once again the world is quick to bury me.)
continue to next day β΅