IRC logs for #openttd on OFTC at 2026-10-27
⏴ go to previous day
00:37:56 *** WormnestAndroid has quit IRC (Remote host closed the connection)
00:38:58 *** WormnestAndroid has joined #openttd
00:38:59 *** WormnestAndroid has quit IRC (Remote host closed the connection)
00:58:51 *** f_ has quit IRC (Remote host closed the connection)
02:43:53 <mnhebi> rito12_13: funny you say that as Rust is one of the languages LLMs are most proficient in..
02:44:06 <mnhebi> right there on the top spot with Python
02:46:31 *** WormnestAndroid has joined #openttd
02:49:22 <mnhebi> also...there are people writing new LLMs in Rust.
04:39:35 *** Phileman has joined #openttd
04:42:54 *** Philemon has quit IRC (Ping timeout: 480 seconds)
05:01:08 *** ChanServ sets mode: +v tokai
05:07:54 *** tokai|noir has quit IRC (Ping timeout: 480 seconds)
06:22:54 <rito12_13> As like there are people who do it in python, PyTorch and stuff
07:27:06 * peter1138 notes that PLY is EOL.
07:35:08 <andythenorth> googling has turned up no obvious replacements
08:07:37 *** masteroktagon has joined #openttd
08:07:37 <masteroktagon> andythenorth: NML in rust when?
08:12:40 *** MinchinWeb[m] has quit IRC (Remote host closed the connection)
08:12:53 *** MinchinWeb[m] has joined #openttd
08:13:46 <_zephyris> Surely ply to sly, if anything?
08:13:52 <_zephyris> Not drop in, but...
08:13:54 <andythenorth> sly is also deprecated
08:13:54 <peter1138> No, sly is also EOL.
08:14:09 <andythenorth> and it's quite different
08:14:49 <andythenorth> it's going to be interesting in 5 years or so, when nobody is producing OSS libs any more
08:15:06 <andythenorth> there will be a bit of a software dark age maybe
08:15:56 <andythenorth> then maybe writing code will come back into fashion, like vinyl records
08:35:52 <peter1138> rust port or c++ port?
08:40:21 <peter1138> Yes, javascript definitely makes sense.
08:40:57 <andythenorth> just my little joke
08:48:15 *** kuhnovic has joined #openttd
08:51:15 <rito12_13> peter1138: rust rust rust rust
08:52:54 <peter1138> The installation instructions are so sketchy.
08:53:46 <andythenorth> we could just keep using PLY vendored
08:54:08 <rito12_13> Just run one long command
08:55:44 <rito12_13> That does not work on android
09:00:23 <peter1138> Android probably isn't a general-purpose operating system anyway.
09:13:42 <rito12_13> But you can use it as one
09:19:44 <peter1138> Good luck with that.
09:20:08 <peter1138> We don't have an official Android port of OpenTTD, I don't think I'm going to worry about tooling.
09:25:48 <_zephyris> If it's a serious suggestion, then surely C++...
09:26:07 <LordAro> andythenorth: i did briefly play with (getting an LLM to) converting it to lark. It was slower so I threw it away
09:26:31 <LordAro> the fact that PLY is vendored means that it doesn't really matter that the original has been discontinued
09:27:16 <LordAro> to the point where i (independently) thought about possible tweaks to it that might replicate similar improvements to #454
09:27:46 <peter1138> _zephyris, the world says starting new projects in C++ is a stupid idea.
09:28:03 <peter1138> Of course, the world keeps moving on to the newest greatest thing and then dumping it, while C/C++ are still around.
09:28:27 <peter1138> (I don't think rust is going away, of course)
09:29:04 <peter1138> I looked for a rust lexer/parser thing and it came with bits about how it uses unsafe code for performance.
09:29:10 <peter1138> So, uh... that's great.
09:29:24 <masteroktagon> peter1138: which one
09:29:49 <masteroktagon> peter1138: I have used logos
09:29:56 <peter1138> I know barely anything about rust so I didn't spend any more time.
09:29:58 <mnhebi> peter1138: ah yeah, that is the funniest thing about Rust. You always have these "necessary" unsafe bits of code
09:29:59 <masteroktagon> but its only a lexeer
09:30:46 <mnhebi> I have a few lines of unsafe code in my renderer here atm...but apparently its just "temporary".
09:31:01 <peter1138> Well, this is at my "is it feasible and what existing bits should I use" stage, nothing like actually planning anything.
09:31:16 <masteroktagon> I would probably also do a hand-written top-down parser anyways (I mean if NML is LR(1) which I don't know for sure) to be less dependent onlibraries
09:31:29 <mnhebi> apparently we'll be removing the unsafe code in a few milestones forward when the renderer is more feature complete..
09:32:06 <mnhebi> but yeah, unsafe code in Rust projects is always a fun sight
09:32:13 <peter1138> Probably not the best project to start learning a new language anyway.
09:32:35 <mnhebi> nonsense, didn't you know more languages know, smarter you become?
09:32:37 <masteroktagon> peter1138: I like rust but you are righht
09:33:51 <peter1138> As I alluded to on the fediverse, I don't really like the concept of all the dependencies being baked into the binary instead of using shared libraries.
09:34:46 <masteroktagon> peter1138: yes but it means you have to make sure they are present on the executing system
09:36:49 <mnhebi> I try to avoid libs like the plague..never wanna run into the situation where a lib decides to relicense or something
09:37:38 <LordAro> "unsafe" in Rust sounds worse than it is
09:37:48 <masteroktagon> mnhebi: one of the downsides of the rust ecosystem
09:37:52 <LordAro> "unreasoned" would be a better name
09:38:46 <masteroktagon> is there something like a NML grammar sheet or sth?
09:39:05 <mnhebi> masteroktagon: libs, or relicensing?
09:39:05 <LordAro> masteroktagon: the p_* functions in parser.py have BNF-ish comments
09:39:40 <masteroktagon> mnhebi: that you have like 100 libs recursive dependencies
09:39:56 <masteroktagon> most are MIT but yeah
09:41:22 *** SigHunter has quit IRC (Remote host closed the connection)
09:44:45 <peter1138> Yes, they mostly went with MIT because the copyleft license were too restrictive for companies to slurp up.
09:45:35 <masteroktagon> thank you. I have 1 or 2 days off so will try building some (very crude) NML in rust (bc I want to make use of my compiler construction course lol)
09:45:57 <masteroktagon> I know no one will use it
09:46:01 <mnhebi> masteroktagon: yeah I have less than 10 libs so far, most of them MIT, one zlib
09:46:16 <andythenorth> what did TrueBrain build? TrueGRF was Rust -> direct to GRF I think
09:46:45 <andythenorth> not an nml parser
09:46:58 <masteroktagon> I want to make a parser
09:47:42 <LordAro> chumsky is quite fun as it creates the parser in the type
09:47:58 <LordAro> does get a bit unweildy with anything mildly complicated though
09:48:15 <LordAro> "oh hey, when the type name gets too long the rust compiler outputs the type to a file instead of the console"
09:48:54 <LordAro> "why is this file 50kB"
09:51:10 <masteroktagon> Ill have a look
09:52:19 <LordAro> although i do need to find something else for actual work purposes because i would like to keep something resembling BNF as the input
09:52:40 <LordAro> (but without parsing it at runtime, because why would i do that when it's static?)
09:52:50 <masteroktagon> I just need to remember the name give me a sec
09:53:57 <masteroktagon> lalrpop was quite nice
09:55:07 *** Flygon has quit IRC (Read error: Connection reset by peer)
09:55:43 <peter1138> Do we have a formal definition for NML's grammar?
09:55:50 <peter1138> (Or whatever it's called)
09:56:34 <LordAro> masteroktagon: interesting. i think i rejected that in the past because it wasn't particularly close to BNF, but i might go back to it
09:56:53 <masteroktagon> it takes a while to get into but then i quite liked it
09:57:09 <masteroktagon> bc you can define your own ast actions based on the grammar
09:58:15 <masteroktagon> where is openttd's commit style checker placed? I would like to use it for this project as well
09:58:45 <DorpsGek> - Update: Translations from eints (by translators)
09:59:41 <LordAro> (the repo, not the folder)
10:00:28 <andythenorth> peter1138: I'm not aware of one, 'code is the grammar' probably
10:02:28 <peter1138> It's also possible that naïve coders (me) have added things that break the concept of it.
10:03:22 <peter1138> And yes, I like spelling that word that way.
10:03:53 <LordAro> most of the p_* functions have relevant comments so it probably wouldn't be *too* difficult to reconstruct an actual grammar
10:04:13 <LordAro> and the t_* functions
10:04:21 <peter1138> I couldn't see how they're called, but I guess that's magic in PLY.
10:04:51 <masteroktagon> LordAro: guess Ill need to learn git hooks for that
10:05:11 <LordAro> pretty sure the scripts can just be called directly
10:05:24 <LordAro> they're documented in the docs folder though
10:05:28 <LordAro> (of the actual OTTD repo)
10:05:32 <_zephyris> Yup, defined by the docstring comments for p_ functions
10:06:29 <masteroktagon> Oh and they are GLP so Ill need to make my repo GPL aswell if I use them
10:07:34 <peter1138> I think GPL is still appropriate for us. It's not like NML has any use-case outside of OpenTTD.
10:07:52 <masteroktagon> true but lalrpop is apache or mit
10:08:08 <LordAro> GPL can use others, just not the way around
10:08:23 <masteroktagon> ah got that qrong
10:09:50 <peter1138> Though depending where they (git-hooks) came from it might be possible to get the license changed.
10:10:39 <masteroktagon> should I use GPL 2 or 3?
10:10:55 <LordAro> even then, use of GPL stuff for build time stuff isn't a particular issue?
10:11:03 <LordAro> this isn't even that, it's just a development tool
10:11:27 <masteroktagon> I like to get it right in case it actually is a good project
10:11:52 <masteroktagon> ok then I'll use it as well
10:13:29 <peter1138> More to the point NML is GPLv2, so sticking with that removes a sticking point of copying and adapting parts of it.
10:16:50 <peter1138> blathijs, are you still the Debian maintainer for catcodec? We did an update :)
10:17:15 <blathijs> Yes, thanks for the poke :-)
10:28:45 <peter1138> Hmm, this old vinyl sounds a bit off. Suspect whoever mastered it was trying to spice up mono recordings with a fake stereo effect.
11:06:39 *** aperezdc has quit IRC (Remote host closed the connection)
11:14:32 *** aperezdc has joined #openttd
11:29:04 *** WormnestAndroid has quit IRC (Read error: Connection reset by peer)
11:29:23 *** WormnestAndroid has joined #openttd
11:39:32 *** aperezdc has quit IRC (Remote host closed the connection)
11:40:45 *** aperezdc has joined #openttd
11:56:48 *** SigHunter has joined #openttd
13:04:22 <masteroktagon> Do have to put the keys in a NML Block in the correct order? I have always used the order like in the documentation, can I shuffle them?
13:06:06 <_glx_> Order should not matter (except for some which should be always first, but nmlc will tell)
13:07:05 <masteroktagon> ok makes sense but parsing a lot harder
13:11:46 <_glx_> It's not handled at parsing level, but in a next step
13:13:03 <_glx_> Parser just pass the list to the GRF element
13:14:19 <masteroktagon> Yes ill need semantic analysis
13:49:38 <rito12_13> peter1138: I have build and then run OTTD on android many times though to do it I had to manually edit make files and then I wasn't so tempted to figure out what would need to be changed in cmake to get the same effect
13:50:20 <_glx_> though maybe 15.3 would fail on win7 if build with today's CI image
13:55:02 <_glx_> rito12_13: experimenting locally is fine, but we'll probably never support android ourself (it can already be a pain to support windows and macOS 😉 )
14:02:36 <rito12_13> I just only need it to test if a change to a grf works withouth upploading it to BaNaNaS (when I don't have my computer at a moment)
15:26:39 <peter1138> I'm kinda in favour of having an official Android build, the first part of that would be having it build and be runnable.
15:30:26 <peter1138> masteroktagon, yeah, other than some specific properties, there isn't really a "correct order", NML just outputs things in the same order they appear.
15:30:49 <peter1138> And in that case, NML also doesn't re-order them into the "correct order", it just complains afterwards.
15:31:29 <peter1138> Also for the things where order does matter, that doesn't also mean that they have to appear in the same block.
15:42:29 <andythenorth> it usually helps to know the grf (nfo) structure
15:42:41 <andythenorth> otherwise it's all a bit .... wtf
15:46:00 <andythenorth> your words not mine 🙂
15:46:06 <andythenorth> I have stockholm syndrome
15:50:21 <_zephyris> I'd really like better touchscreen support...
15:50:42 <_zephyris> How much of Android support is touchscreen vs. build?
15:51:11 <_zephyris> I do a lot of OpenGFX2 nml dev on a touchscreen 🙂
15:51:47 <LordAro> build itself is pretty easy afaik, the UI is the hard part
15:52:18 <_zephyris> Mmm. I suspected it might be an 80/20 thing
15:58:46 <peter1138> SDL2/SDL3 have touchscreen support, so in theory it can be done.
15:59:31 <_zephyris> Taking a coffee break to remind myself of the existing android port...
16:00:08 <peter1138> I have previously asked the Android porters to consider upstreaming parts, but nothing came of it.
16:00:20 <_zephyris> Yeah, there's lots of good UI ideas in htere
16:01:05 <peter1138> My main issue with that Android port is the build system is super weird, it's part of some mega-monolith-repository, not just OpenTTD.
16:01:13 <peter1138> Might've been changed since then.
16:10:12 <masteroktagon> I might need build my own error logging system, the one I was using is not very compatible with lalrpop
16:12:11 <_glx_> hmm it looks like vcpkg has some android triplets, that could simplify things
16:12:35 <peter1138> I tried once, I did actually get it to build, but didn't get as far as getting it to run.
16:19:25 <peter1138> openttd: ELF 32-bit LSB pie executable, ARM, EABI5 version 1 (SYSV), dynamically linked, interpreter /system/bin/linker, for Android 19, built by NDK r25c (9519653), BuildID[sha1]=6df8ef9e8c3a6cc939f418fb5ca7dc8a8e473f10, with debug_info, not stripped
16:19:29 <peter1138> Hmm, still have it.
16:26:32 <kuhnovic> Android does have keyboard and mouse support, you could use the UI as is. But not that practical for that quick game of building-trains-while-on-the-train.
16:26:39 <kuhnovic> As least not on a phone
16:31:55 <masteroktagon> Alr I can confidently say I have NO idea how newgrf files are actually encoded what all these actions do
16:33:10 <masteroktagon> Ill need to read the nmal implementation maybe I understand it afterwards
17:11:56 <peter1138> Why is the comment not indented... :)
17:14:40 <peter1138> Never mind that since that was added the rest of the code was switched to std::ofstream, not fopen. I wonder how necessary it even is :D
17:16:36 <peter1138> Of course someone obviously found it necessary, but it seems a bit weird for an ini file for a game :)
17:19:34 <peter1138> isosys has said they are not going to port 16.0
18:06:01 <andythenorth> Iron Horse has lots of choices for wagon colour
18:06:23 <andythenorth> dunno what Hog trucks should do though
18:06:31 <andythenorth> cab should stay company colour, surely?
18:06:46 <andythenorth> "what does Euro Truck Simulator do?"
18:07:30 <andythenorth> seems like a case where maybe the body should have an option for 3cc
18:29:50 <peter1138> Hmm, with git show --stat can I separate the added/removed count?
18:32:34 <andythenorth> wonder how much longer 😛
18:41:50 <peter1138> Funnily enough theyd didn't answer the OPs question :-)
18:43:00 *** Flygon_ has joined #openttd
18:45:18 <andythenorth> hmm on-device LLM, trained on man pages and O'Reilly text books (licensed), basically fancy search? 👀
18:46:35 *** belajalilija has joined #openttd
18:47:01 <belajalilija> All LLMs should be trained on Philomina Cunk
18:47:47 *** Flygon has quit IRC (Ping timeout: 480 seconds)
19:00:04 <_glx_> hmm let's clear the cache first, to be sure
19:01:42 <_glx_> same with a clear cache, it's weird
19:04:06 <andythenorth> CunkLLM would be phenomenal
19:04:26 <andythenorth> the first time I saw it was a YT clip, and it looked real
19:04:34 <andythenorth> took me like 2 mins to spot the trolling
19:12:21 <peter1138> Finding libs gets a bit confusing when cross-compiling, praps.
19:21:35 *** audigex has joined #openttd
19:21:35 <audigex> andythenorth: Would’ve probably been possible with custom GPTs until they turned them into plugins recently
19:21:35 <audigex> I have one based on Jack Aubrey that answers with a salty sea dog style and bad puns/malapproprisms
19:28:34 <andythenorth> I had an early one that just answered 'woof' to everything, but I could have scripted that in JS
19:28:46 <andythenorth> 10: print "woof"
19:40:36 <andythenorth> wonder if JS supports line numbers? 😛
19:41:14 *** MinchinWeb[m] has quit IRC (Ping timeout: 480 seconds)
19:41:30 *** MinchinWeb[m] has joined #openttd
20:01:40 <peter1138> Playing a Wad that I know I've played before. I have savegames and the map layout is familiar. But I'm sure that last time there were no custom textures, monsters and sounds...
20:08:08 <peter1138> Mind you is it H.P. Lovecraft themed, so, uh...
20:25:50 <andythenorth> worn out Dope Wars
20:25:58 <andythenorth> Warcraft 1 doesn't work on ARM macs
20:26:15 <andythenorth> I've played BadNorth the most I can
20:38:47 <belajalilija> andythenorth: postal 2
20:43:20 <peter1138> rito12_13, are you building ON Android, or cross-compiling?
20:43:46 <rito12_13> building on Android
20:44:24 <rito12_13> I did cross-compilation once in my life for a godot project and it was painfull
20:51:19 <peter1138> I guess that's cool, but also means I need to figure it out again :-)
20:51:31 <peter1138> I can't remember what I had set up last time, it was 2.5 years ago.
21:35:50 *** jfs_ has quit IRC (Ping timeout: 480 seconds)
21:35:58 *** Timberwolf has quit IRC (Remote host closed the connection)
21:54:40 *** MinchinWeb[m] has quit IRC (Read error: Connection reset by peer)
21:54:58 *** MinchinWeb[m] has joined #openttd
22:08:04 *** MinchinWeb[m] has quit IRC (Ping timeout: 480 seconds)
22:09:00 *** MinchinWeb[m] has joined #openttd
22:24:25 <_glx_> (I used "OPTION_DEDICATED" to skip the failing sdl2 detection)
22:24:53 *** Timberwolf has joined #openttd
22:28:32 <_glx_> ah I don't set min sdk version, that could be why
22:29:32 <_glx_> so it defaults to 21 but needs at least 24 for these 2 functions
22:33:30 <_glx_> oh 21 is old, it's android 5
22:38:15 *** MinchinWeb[m] has quit IRC (Read error: Connection reset by peer)
22:38:31 *** MinchinWeb[m] has joined #openttd
22:39:23 <_glx_> ok it's better with sdk 29 but "D:/developpement/GitHub/glx22/OpenTTD/src/os/unix/crashlog_unix.cpp:28:11: fatal error: 'client/linux/handler/exception_handler.h' file not found", let's remove breakpad from vcpkg.json
22:42:17 <_glx_> ah and now I get the fdatasync and close thing (not on latest master)
22:46:19 <_glx_> and linking failed (most likely because I didn't set ABI)
23:03:40 <_glx_> now the hard part will be to somehow put it on my phone
23:23:44 <peter1138> Hmm, okay, not enough diskspace to install the ndk :)
23:29:56 <_glx_> Not bad for a dedicated build made using VS on windows
23:38:16 <peter1138> Next I expect a github workflow ;-)
23:41:11 <_glx_> and now I know why it couldn't find SDL2, without a proper ABI it targeted a 32bit build while installed SDL2 is 64bit
23:50:14 *** WormnestAndroid has quit IRC (Remote host closed the connection)
23:50:33 *** WormnestAndroid has joined #openttd
continue to next day ⏵