IRC logs for #openttd on OFTC at 2025-10-15
β΄ go to previous day
00:53:06 *** Wormnest has quit IRC (Quit: Leaving)
02:02:15 *** herms2 has quit IRC (Quit: bye)
02:22:34 *** gnu_jj_ has quit IRC (Ping timeout: 480 seconds)
03:10:49 *** Zathras_4 has joined #openttd
03:10:59 *** Zathras has joined #openttd
03:14:16 *** Zathras_1 has quit IRC (Ping timeout: 480 seconds)
03:14:31 *** Zathras_11 has quit IRC (Ping timeout: 480 seconds)
03:35:45 <_auxilian> _auxilian: Or ig if anyone knows which video driver is used by default on Linux that would help
05:49:28 <LordAro> _auxilian: DBG, along with the -d flag (see --help)
06:47:56 *** tokai|noir has joined #openttd
06:47:56 *** ChanServ sets mode: +v tokai|noir
06:51:35 *** tokai has quit IRC (Ping timeout: 480 seconds)
07:12:10 <aderom> Greetings. I still decided to try to make my own mod.
07:12:10 <aderom> My goal is to create a
07:12:11 <aderom> Πnd it seemed to me that the [rfirs](https://github.com/k-Knight/rfirs) mod would be an excellent reference, but it was created 4-8 years ago and I would like to ask you how relevant it is as a reference?
07:12:11 <aderom> Why there is a question of relevance, now I will write in the thread under my own message.
07:14:39 <LordAro> andythenorth: one for you :p
07:15:59 <LordAro> i would suggest that FIRS (or its derivatives) is not a good starting point for beginners, but as a question of "reference" then there's no issues at all
07:28:44 <aderom> LordAro: What can you recommend as a good starting point?
07:32:32 <vondpc> (should have at least mentioned the doc isn't in english when linking it π )
07:36:41 <aderom> vondpc: I may be wrong, but it seems that all browsers already have the ability to translate a page into any language with one or two clicks. But I heard you.
07:38:02 <LordAro> aderom: i have no recommendations, i know very little about NewGRF development, only that FIRS is huge and complex and generates most of the code that eventually gets compiled into a GRF
07:38:15 <LordAro> i also seem to be missing some context, rfirs is definitely in English as far as i can tell
07:39:59 <aderom> LordAro: I described my idea in more detail in my native language and gave a link in the post.
07:40:24 <LordAro> curious that the bridge did not copy that across
07:40:46 <LordAro> i thought it normally did (just in a confusing order)
07:43:11 <aderom> LordAro: My translator hard broke down here)))
07:45:30 <LordAro> i appear as a bot (beep boop) because i am on IRC rather than Discord. Messages are mirrored across, but IRC does not have threads
07:47:01 <aderom> Understood, don't use theads
07:47:36 <aderom> (in thread) The following error occurs when compiling the mod
07:47:36 <aderom> I have nmlc 0.8.0 installed.
07:48:28 <LordAro> might be worth installing nmlc from git, the latest release is kinda old
07:48:53 <LordAro> though not rfirs level of old, so i don't know
07:49:08 <LordAro> maybe 0.8.0 is too new :D
07:52:54 <LordAro> another reason why FIRS is a bad choice is that it often required an unreleased or custom version of NML
07:53:14 <LordAro> whether or not that's the case here, i can't say
07:56:51 <andythenorth> that's Rectal FIRS anyway
07:56:57 <andythenorth> that isn't maintained
07:59:36 <aderom> o nice It gives me hope that I will compile it at least.
08:00:00 <LordAro> i thought the "forked from ..." meant you already knew that :D
08:01:13 <LordAro> the rest of the stuff i've said hasn't changed though
08:10:20 <peter1138> FIRS is a terrible reference.
08:12:00 <ahyangyi> FIRS is a good reference about how you build things on top of NML
08:12:09 <ahyangyi> But not an NML reference in itself π
08:12:20 <peter1138> It's not a *good* reference for that.
08:13:01 <ahyangyi> At that level of complexity, and among those that exist and are open source, I think it's a good one.
08:14:30 <peter1138> TBH I think it's a "good" example of why it's probably a bdd idea.
08:16:55 <ahyangyi> Any specific example?
08:17:02 <ahyangyi> Like the FIRS reassignment of cargo classes?
08:18:37 <peter1138> Animated tiles are my gripe.
09:00:45 *** SigHunter_ has joined #openttd
09:04:06 *** SigHunter has quit IRC (Ping timeout: 480 seconds)
09:29:00 <andythenorth> are there 2 issues with animated tiles?
09:29:11 <andythenorth> 1) animating tiles that have no animation, which is because of nml
09:29:33 <andythenorth> 2) a quirky approach to animation playback control
09:33:43 <andythenorth> I think ahyangyi means "like the FIRS reassignment of cargo classes back closer to their original intent, and most vehicle grfs use them wrong anyway"
09:33:58 * andythenorth helpfully clarifying
09:40:11 <peter1138> It was custard cream.
09:40:36 <andythenorth> seems a long time since breakfast
09:41:01 *** reldred has joined #openttd
09:41:01 <reldred> Iβm having Mac and cheese
09:41:11 <reldred> Couldnβt be assed getting takeout
09:43:14 <peter1138> Normally it's having a takeout because you can't be arsed to cook. But I guess you mean a ready-made macaroni cheese.
09:53:23 *** gelignite has joined #openttd
09:56:32 <ahyangyi> andythenorth: Either way, I don't have any strong opinion on this π
10:04:02 <peter1138> "1) animating tiles that have no animation, which is because of nml"
10:04:14 <peter1138> You are animating tiles that have no animation because your python generator says they have animation.
10:05:16 <peter1138> I did forget about the cargo class changes though.
10:08:48 <xarick> RiverFlowsDown is a little bit flawed, but I don't know how to explain
10:16:55 <xarick> GetTileSlopeZ takes the min height into account
10:17:05 <xarick> which is 1 on both tiles
10:17:58 <xarick> this is fine for the BFS part, but not quite for the yapf part
10:18:10 <xarick> bfs part of the code works around the issue
10:19:40 <rito12_51026> LordAro: I disagree with you. NML logic differs a lot from programing languages that learning it is as hard as learning programing from beginning. For me it was easier to understand FIRS code than the nml tutorial especially as I wasn't intrested in vehicles. I wouldn't have understood nml without FIRS.
10:23:00 <xarick> it's maybe fine for yapf after all
10:23:43 <xarick> the only problem seems to be the addition of extra potential neighbours that lead to a dead end
10:24:02 <xarick> cost cpu cycles etc...
10:24:25 <peter1138> As far as I'm aware, FIRS isn't meant to be a general purpose templating language to be used generically. It's for building FIRS.
10:28:34 <ahyangyi> Anyways, I should do some animations too.
10:39:52 *** saladcritter has joined #openttd
10:41:29 <peter1138> Urgh, my CI now needs to install node which adds another 2 minutes to the set up time :(
10:42:03 <peter1138> (Existing time to complete the entire CI process is about 3 minutes)
11:22:58 <andythenorth> peter1138: it is not, I would not **encourage** anyone to fork FIRS
11:23:24 <andythenorth> the structure of the project is actually quite good, but I didn't build it for reuse
11:28:47 <andythenorth> hmm badges for industry tiles?
11:29:00 <andythenorth> FIRS has magic fences
11:29:06 <andythenorth> that could be badges
11:29:18 <peter1138> Oh, maybe I didn't do it for tiles.
11:30:22 <andythenorth> wondering about stations and objects that magically adapt to nearby industry tile
11:30:36 <andythenorth> I think life might be too short for that π
11:32:22 *** locosage has joined #openttd
11:32:22 <locosage> hm, maybe I should do better industry utils for grf-py
11:32:31 <locosage> so there is an alternative to forking firs xD
11:34:44 <xarick> a conflict on a deleted file... interesting, never had this happen before
11:40:02 <andythenorth> 'forking FIRS' usually means taking 300k lines of firs.nml I believe
11:40:05 <andythenorth> then manually editing it
11:41:14 <peter1138> If they're doing that... jfc.
11:42:01 <andythenorth> I don't know for a fact
11:42:12 <andythenorth> yeah, manually editing a huge auto-generated file
11:42:23 <andythenorth> that relies heavily on procedures and so forth
11:42:30 <andythenorth> and has objects threaded through it now
11:48:48 <_glx_> rito12_51026: Well nml is not really a programming language, it's more a markup language
12:00:28 <rito12_51026> It is not like HTML or Markdown either
12:01:24 <LordAro> you may be shocked to learn that those are not the only markup languages
12:01:39 <LordAro> and you should see the awful stuff people do with XML
12:06:22 <rito12_51026> Isn't XML like HTML with custom tags and customisable purposes?
12:07:18 <LordAro> that's certainly one way of describing it
12:14:49 <peter1138> Both XML and HTML are based on SGML.
12:15:11 <peter1138> XHTML was the version of HTML that tried to force HTML into XML but failed because people can't write code properly.
12:15:35 <peter1138> (It also cannot be properly parsed as a partially loaded document.)
12:33:25 *** saladcritter has quit IRC ()
13:29:20 *** gelignite has joined #openttd
13:39:33 <xarick> why can't we use our gpus to compile openttd
13:44:15 <LordAro> the simple answer is that they're not suited to that sort of task
13:44:28 <LordAro> you *could*, but no one has ever seen the need to try
13:50:39 *** wither9781 has joined #openttd
13:50:39 <wither9781> rito12_51026: yes. nmls is quite different from other languages.
13:58:14 <dwfreed> GPUs are terrible at anything that can't be reduced to a math problem
13:58:45 <dwfreed> they're basically just massively parallel calculators
14:00:42 <rito12_51026> So if we could calculate the outputed code we could run compilation on gpu
14:02:26 <LordAro> if you have no external inputs, sure
14:02:33 <LordAro> but that's a rather simple program :)
14:11:22 <peter1138> GPUs are good at 'compiling' images.
14:20:08 <_jgr_> Compiling code is very branchy and doesn't benefit from data parallelisation, it's not a good fit for GPUs
14:21:41 <LordAro> preemptive note: data parallelisation is very different from process parallelisation
14:21:46 <locosage> pathfinding on gpu when? π€
14:34:39 <xarick> testing marks.clear() and queue.clear() seems to gain a few milliseconds of time
14:39:49 <xarick> but not in the places it were originally
14:43:05 <xarick> weird, i can't reproduce the gains anymore
14:49:09 <andythenorth> hmm can I offload PIL to the GPU?
14:51:04 <andythenorth> me and my slow old ARM platform π
15:04:03 <xarick> the gains come from a cherrypick of my GetTileMaxZ, even though I'm not even using the function anywhere
15:12:57 <_auxilian> LordAro: I'm building it in debug mode I'm just not sure what function let's me log something
15:14:13 <LordAro> but i mean, fprintf(stderr, ...) is usually a good default regardless
15:18:37 <LordAro> `Debug` is the relevant macro
15:18:51 <_glx_> it's Debug(category, level, ...)
15:18:59 <xarick> woah.... the Copilot dude
15:19:10 <xarick> literally guessed what I was gonna do
15:19:25 <LordAro> stop personifying the matrix calculation
15:19:26 <_glx_> we don't accept AI generated code π
15:19:50 <xarick> but I was really going to type this
15:19:56 <LordAro> _glx_: s'alright, that type signature isn't remotely valid
15:20:11 <_glx_> (or actually code you don't understand yourself)
15:22:24 <xarick> oops tuples use <> brackets
15:34:23 <locosage> quite often pil stuff can be sped up by doing smart processing with numpy
16:30:08 *** Zathras_4 has joined #openttd
16:58:56 *** Wormnest has joined #openttd
16:59:45 <xarick> is there a way to extract the minimum value out of a tuple?
17:07:10 *** Flygon has quit IRC (Remote host closed the connection)
17:11:38 <xarick> this works, but it's uglier
17:52:39 <xarick> ah, I think I did it π
17:55:14 <ahyangyi> What C++ version do we use?
18:47:26 <locosage> hm, pbs_enabled seems to be off in purchase menu despite nml dosc saying it's always enabled
18:51:29 <locosage> "At the moment, PBS on/off refers to the switch setting, in a future alpha version it will actually refer to whether the switch is on and the current block actually uses PBS."
18:51:36 <locosage> nfo spec doesn't make much sense xD
18:52:22 <peter1138> The nfo spec refers to the PBS implementation in TTDPatch, which may or may not be enabled.
18:52:28 <peter1138> case 0x44: return 2; // PBS status
18:55:15 <peter1138> I suspect when I wrote that code, 19 years ago, NML didn't exist?
18:55:20 <peter1138> So the NML spec is wrong.
18:56:02 <peter1138> Or rather, the NML spec does not consider the purchase-list case.
18:57:54 <locosage> purchase using 4 would make more sense but I guess in theory it could break something if changed
19:00:25 <Wolf01> I play F with remote desktop
19:09:43 <xarick> std::initializer_list doesn't play along with std::tuple π
19:17:29 <andythenorth> I am out of chocolate
19:41:17 <xarick> am I misunderstanding something?
19:41:34 <xarick> why is _Last not {3} ?
19:44:21 <xarick> std::initializer_list is dumb?
19:44:55 <_jgr_> Last is an exclusive bound not an inclusive one
20:08:01 <_glx_> oh and eints workflow was disabled
20:08:52 <_glx_> (last run was on cotober 1st
20:12:46 *** ChanServ sets mode: +v tokai
20:15:41 *** tokai|noir has quit IRC (Ping timeout: 480 seconds)
20:18:49 <andythenorth> hmm was it naptime?
20:19:01 <andythenorth> I still didn't find chocolate
20:20:51 *** tokai has quit IRC (Ping timeout: 480 seconds)
20:24:42 *** ChanServ sets mode: +v tokai
20:28:27 <xarick> can i use std::span on tuples
20:29:58 <peter1138> You can have a span of tuples.
20:32:40 *** tokai|noir has joined #openttd
20:32:40 *** ChanServ sets mode: +v tokai|noir
20:32:44 *** tokai has quit IRC (Ping timeout: 480 seconds)
20:35:37 *** tony_pixel has joined #openttd
20:35:37 <tony_pixel> what are the two ints?
20:35:58 <xarick> lowest h and highest h
20:38:10 <_glx_> looks like too much tuple
20:40:54 <_jgr_> What is wrong with how `GetTileSlopeGivenHeight` is now?
20:42:52 *** Wolf01 has quit IRC (Quit: Once again the world is quick to bury me.)
20:54:43 <xarick> but it's still a tuple
20:55:20 <xarick> I'm trying to deduplicate some code
20:56:00 <xarick> but hmm yeah, my version of GetTileSlopeGivenHeight also returns the hmax
21:17:00 *** SigHunter has joined #openttd
21:17:56 <xarick> I'm not sure how to describe this part
21:18:19 <xarick> they're the x, y components
21:18:45 <xarick> that return comment is wrong
21:19:35 <peter1138> There was one tiny commit that could've been PRed...
21:31:43 <peter1138> andythenorth, I had mint aero bubbly thing.
21:31:46 *** keikoz has quit IRC (Ping timeout: 480 seconds)
21:32:20 <xarick> * Get the two X's and two Y's components of the four corners of a tile.
21:32:20 <xarick> * @param tile Tile to get the corners of
21:32:20 <xarick> * @return A tuple containing the XY components of the northern, western, eastern and southern corners.
21:32:35 <xarick> slightly better description
21:40:34 *** tokai|noir has quit IRC (Ping timeout: 480 seconds)
21:42:00 <xarick> interesting perspective, he sees 2 tiles
21:42:22 <xarick> but it's gonna be used to generate 4 tiles to extract their height
21:44:16 *** ChanServ sets mode: +v tokai
23:15:10 <_auxilian> LordAro: ohhhhh thats like a function lol sorry
23:17:12 <_auxilian> thought it was the build modeπ
23:33:26 <_auxilian> All of this to test why the function wasn't being called! When it was! My code worked already π
23:33:46 <_auxilian> Good to know I guess
23:47:49 <peter1138> I'd rather just read broken English that have some one fuck it up by passing it through a hallucination machine.
23:55:17 *** lobster has joined #openttd
23:58:19 *** lobstarooo has quit IRC (Ping timeout: 480 seconds)
continue to next day β΅