IRC logs for #openttd on OFTC at 2023-09-24
β΄ go to previous day
01:36:16 *** gelignite has quit IRC (Quit: Stay safe!)
01:42:37 <Eddi|zuHause> but do base grfs have an action 14?
01:45:38 <_pruple> they have an .obg file, apparently.
01:45:59 <_pruple> unless that info is out of date
02:08:46 <_pruple> but an updated baseset does not necessarily mean an updated extra grf, if the changes are elsewhere?
02:09:57 <_glx_> it makes sense to set extra version the same as the baseset
02:40:51 *** debdog has quit IRC (Ping timeout: 480 seconds)
02:41:43 *** D-HUND is now known as debdog
02:57:17 *** tokai|noir has joined #openttd
02:57:17 *** ChanServ sets mode: +v tokai|noir
03:03:55 *** tokai has quit IRC (Ping timeout: 480 seconds)
05:14:40 *** bryjen has quit IRC (Quit: Leaving)
06:32:51 *** Heili has quit IRC (Read error: Connection reset by peer)
06:32:59 *** Hieki is now known as Heili
07:27:27 *** gelignite has joined #openttd
07:32:48 <peter1138> Hmm, miserable looking weather :/
08:11:56 <andythenorth> something about fish
08:16:36 <peter1138> Yeah buttons keep going missing
09:00:50 <andythenorth> ok stations need a StationLayout, like industries
09:01:32 <andythenorth> that's the sort-of-missing bit of the grf spec
09:01:52 <andythenorth> I will make my compile pretend it's there π
09:01:57 <peter1138> Station layouts depend on the platform and tracks
09:02:06 <peter1138> They are in the spec...
09:02:32 <andythenorth> we what now? π
09:03:22 <andythenorth> ok good, that's the thing I was missing
09:03:25 <peter1138> You define a layout for each size of station you want a specific layout four, and that lets you pick one of the 4 allow tile types.
09:03:48 <peter1138> However, mostly NewGRFs use the callback instead, because 1 or 4 tiles isn't very flexible.
09:04:17 <peter1138> Not Callback 24, that also only allows 1 or 4 tiles.
09:04:48 <andythenorth> I was reading 24 π
09:05:01 <peter1138> You can then select the specific tile layout based on position.
09:05:14 <peter1138> Ideally the spec would've been changed to allow more than 4 tile types.
09:05:24 <andythenorth> "we are where we are"
09:06:03 <peter1138> IIRC in the original map layout, tile types 0-7 were stations, and then the things like bus stops and airports continued. But they are distinct in OpenTTD.
09:06:25 <andythenorth> ok so this is similar to how big grfs *actually *do industry tiles
09:06:32 <peter1138> The default in game layouts use the equivalent of propery 0E.
09:06:45 <andythenorth> there's something something about odd and even numbers
09:07:24 <peter1138> That's why I say 4. There are actually 8, but split between X or Y direction.
09:08:03 <andythenorth> ok so every station I define can have a layout composing 'tiles', it's not just a single tile
09:08:06 <andythenorth> I was missing that link
09:08:29 <andythenorth> and a single 'tile' is just a layout with [0, 0, foo_spritelayout]
09:09:42 <peter1138> You don't even need to define layouts with Prop 0E or CB 24, as CB 14 does all the work.
09:10:20 <peter1138> It's all a compromise to allow the original stations to still do their thing, and also allow newgrfs to do their thing.
09:10:28 <andythenorth> ok so I interleave the results so it's returning `[NE_SW_RED, NW_SE_RED, NE_SW_BLUE NW_SE_BLUE]`
09:10:43 <andythenorth> that's not quite right
09:11:42 <andythenorth> I need to read prop 08
09:11:58 <andythenorth> but then nml magics around that I think
09:12:21 <peter1138> Property 08? That's just the station class label.
09:13:09 <andythenorth> yeah no I fat-fingered
09:13:13 <andythenorth> are you still in irc? π
09:14:24 <andythenorth> propo 0x09 supports up to 8 tiles, so originally this was what? platform, platform with building, big roof part 1, big roof part 2?
09:14:36 <andythenorth> then repeat for the other orientation?
09:18:14 <peter1138> It's an extended byte, so it supports more than 8.
09:18:35 <peter1138> But the original 8 is those things, yes.
09:19:18 <peter1138> Only the first can be used directly in the station layout stuff (Prop 0E or CB 24)
09:19:23 <peter1138> ... Only the first 8
09:19:31 <peter1138> But CB 14 doesn't have that limit.
09:19:45 <peter1138> CB 14 is, however, called whenever the tile is drawn.
09:20:12 <andythenorth> "Number of tiles supported - Normally this is 8, but you can specify fewer as well"
09:20:17 <andythenorth> so that's just docs being quite old
09:20:25 <andythenorth> it also mentions the extended byte later
09:20:45 <andythenorth> stations is like peeling off layers of wallpaper in an old house π
09:21:18 <peter1138> CB 14 came before CB 24, so...
09:21:56 <peter1138> Ultimately I don't see why we couldn't allow the first 255 sprite layouts to be stored on the map, avoiding the need for so much CB 14.
09:22:13 <peter1138> Although many stations are actually only a tile sprite layout anyway, so all that is irrelevant.
09:24:57 <andythenorth> ok so cb 14 doesn't return a spritelayout, it returns an index into prop 0x09?
09:25:14 <andythenorth> lol imagine if we made the docs page list all params and returns in a standard format π
09:25:17 <andythenorth> we'd be so grown up
10:02:11 <andythenorth> ok so nml magics prop 0x09 off into a cb instead
10:04:57 <andythenorth> hmm there are also tiles
10:05:25 <andythenorth> but they're not Tiles
10:06:59 <andythenorth> ok so that's cb 24 stuff I think
10:08:06 <andythenorth> stations have tiles, but tiles aren't real, they're indexes into a list of spritelayouts?
10:08:56 <andythenorth> "not real" => no Tile entity, no tile action 0 etc
10:09:13 <andythenorth> so I can index into the spritelayout via a tile num?
10:09:33 <andythenorth> and I can pre-set which tile num is used for each xy pos in a station layout?
10:09:40 <andythenorth> or I can handle that as a cb result
10:11:00 <andythenorth> so cb 24 is construction-time-only, and cb 14 is called whenever drawing the station?
10:30:20 *** nielsm has quit IRC (Ping timeout: 480 seconds)
10:35:04 <peter1138> If it's pre-set in the station layout property, then it's simply stored in the map.
10:39:17 <peter1138> It's weird having to explain this to someone who's been doing NewGRFs all their life ;)
10:56:18 <_glx_> I skipped some props when there was a callback allowing more choices
10:56:46 <andythenorth> it's weird that there are so many station grfs, made in nfo, from docs that don't really flow like the rest of the spec π
10:57:00 <andythenorth> and nobody turns up in irc or discord asking about it either π
10:57:44 <andythenorth> I am very glad I did industries first, the industry spec is just obvious and clear π
10:59:28 <_glx_> 09/0A/1A are autofilled from sprite_layouts
10:59:54 <andythenorth> it would almost be easier if Station and Tile were distinct entities eh
10:59:55 <_glx_> 0E is skipped because CB24 is better
11:00:16 <andythenorth> /me looks how objects work
11:00:32 <andythenorth> FIRS has them, but I just cargo-culted someone else's code I think
11:02:09 <andythenorth> hmm no...I forgot objects because they're trivial π
11:02:54 <andythenorth> there's something about multi-tile objects, no idea what that was, but FIRS seems to handle it
11:04:14 <peter1138> They were there before all those other specs...
11:05:21 <andythenorth> hmm can roadstops span multiple tiles?
11:09:26 <andythenorth> is there an XY offset I'm not seeing there?
11:10:18 <peter1138> Roadstops are built as individual tiles, only rail stations have platform length & count.
11:10:20 <andythenorth> it's not essential, just working out what my python compile needs to handle in terms of parity (or not) across different types of station feature
11:11:09 <andythenorth> hmm....so could walk nearby tiles to fake an XY offset
11:11:36 <andythenorth> or at least to find contiguous blocks of same tile, same station
11:12:00 <andythenorth> fancy bus stations? π
11:24:04 <andythenorth> hmm factory or factories?
11:24:20 <andythenorth> `add_station(type="rail_non_track")`
11:24:35 <andythenorth> or `add_rail_station(type="non_track")`
11:24:38 <andythenorth> such programming
11:24:57 <andythenorth> one has more if-else than the other π
11:25:27 <andythenorth> well strictly it's a dict mapping string keywords to classes that are instantiated
11:25:32 <andythenorth> so not if-else at all
11:30:51 <andythenorth> `RoadStopDriveThrough`, but then is it `RoadStopDriveIn` or `RoadStopBay` or `RoadStopTerminus`?
11:38:55 <andythenorth> going with Bay then
11:40:58 <talltyler> Bay is how the new error message calls it
11:41:16 <talltyler> But apparently that was a new wording because I was questioned about it in the PR
11:42:39 <andythenorth> it's potato / potato to me, but I might as well be consistent with something π
11:42:50 <andythenorth> consistent with inconsistency perhaps? π
11:44:37 <peter1138> I think it was just "Road stops" and "Drive-through road stops" originally :p
11:46:00 <andythenorth> hmm `object` is really not usable in python eh
11:46:08 <andythenorth> `grf_object` again then
11:50:11 <andythenorth> oh object is not a reserved keyword
11:50:29 <peter1138> They used to be called 'unmovable' in OpenTTD.
11:51:34 <peter1138> The well known unmovable company owned land.
11:52:12 <talltyler> Yeah, I looked for a name and never found one, so I invented one
11:54:35 <talltyler> Shouldβve used one that was a protected name in Python just to fuck with andythenorth π
11:55:28 <andythenorth> I should just prefix or suffix everything 'tile'
11:55:29 <talltyler> But it needed to be something that made intuitive sense to players, like they knew it was called that all along despite no tooltip ever using it
11:55:43 <andythenorth> somewhat 'tile' has already lost all meaning in FIRS π
11:56:01 <andythenorth> there is Tile, but also sprites are referred to as tiles
11:56:12 <andythenorth> and objects are also tiles, even though they're objects
11:56:58 <andythenorth> ok so stations have classes
11:57:02 <andythenorth> but I need classes of classes
11:57:05 <andythenorth> are they meta-classes?
11:57:31 <andythenorth> 'industry, mud ground', 'industry, cobble' etc are all classes
11:57:42 <andythenorth> and they're all industry metaclass?
11:57:59 <andythenorth> 'class category' or 'class group' seem wrong
11:58:14 <andythenorth> metaclass is an ugly word though
12:01:10 <andythenorth> ok, 4 letter identifiers π
12:01:16 * andythenorth can think of some that are NSFW
12:01:45 <andythenorth> seems TOWN would be easy π
12:01:49 <andythenorth> and DOCK in future
12:02:11 <andythenorth> industry, asphalt ground: "INAS"?
12:02:24 <andythenorth> industry, dirty asphalt ground: "INDA"?
12:02:33 <andythenorth> industry cobble: "INCO"
12:02:43 <andythenorth> industry, dirt: "INDI"
12:14:44 *** snoopdogg has joined #openttd
12:24:38 *** keepinitrail has joined #openttd
12:24:38 <keepinitrail> Industry, London: βINITβ
13:16:02 <truebrain> I fixed those in nightly
13:37:42 <andythenorth> hmm....SpriteLayoutLayout? π
13:37:56 * andythenorth thinks TileLayout might go better there, even though there is no Tile
13:52:44 <peter1138> Would be nice to fix it going to 200% :)
14:04:35 <andythenorth> station tiles-by-ground-type
14:04:38 <andythenorth> "what could go wrong"
14:12:48 <andythenorth> I am allocating IDs in blocks of 100 per station / roadstop / object
14:12:57 <andythenorth> "650 stations is enough for anyone"
14:17:42 <alfagamma7> andythenorth: *Cue "I Can't Get Enough"*
14:18:14 <andythenorth> we can't hide "Default" yes / no?
14:18:31 <andythenorth> but I might be able to overload the string?
14:19:56 <peter1138> It's just the name of the DFLT class.
14:20:56 <peter1138> Disabling the default station isn't a thing though.
14:21:27 <_glx_> hmm action0 wiki says 16 class max
14:23:11 <andythenorth> "rename works good"
14:23:31 <andythenorth> I don't actually want to disable default, I like it
14:23:43 <_glx_> you can't disable default
14:23:54 <andythenorth> hmm StationVariants?
14:25:27 <peter1138> What does that even mean?
14:25:59 <peter1138> It sounds like "I've never designed a station set but I want to say random bingo words"
14:26:07 <andythenorth> that's exactly what it is
15:02:52 *** ChanServ sets mode: +v tokai
15:09:21 *** tokai|noir has quit IRC (Ping timeout: 480 seconds)
15:09:40 <peter1138> Hmm, can I be bothered to self-compile OBS...
16:07:12 <peter1138> Huh, how does this code even work...
16:09:13 <peter1138> Uses a ringbuffer (good)
16:09:18 <peter1138> Uses a vector (not so good)
16:09:35 <peter1138> Pushes into the vector from the main non-audio thread (ish)
16:10:02 <peter1138> Reads from a the vector from the audio thread... (not good)
16:10:28 <peter1138> Keeps an iterator in the audio thread which the main thread could have invalidated with a push_back (ummm)
16:13:38 <Rubidium> well... it mostly works, so it's fine right?!?! :(
16:19:41 <peter1138> Oh, it's not a vector, it's a std::list.
16:25:39 <peter1138> That isn't so bad as it won't invalidate, but still.
17:26:15 <andythenorth> wonder if we should give nml station_layout feature
17:26:36 <andythenorth> that wraps around spritelayouts list, and a varact2 xy check
17:27:03 <andythenorth> might be too specific, but it would be similar to industry, where it works well π
17:33:59 <andythenorth> FacilityTypeIndustryFactoryFactory?
18:37:05 <DorpsGek> - Update: Translations from eints (by translators)
19:29:56 *** gelignite has quit IRC (Quit: Stay safe!)
20:22:17 *** Flygon has quit IRC (Quit: A toaster's basically a soldering iron designed to toast bread)
20:41:40 <peter1138> Hmm, do we need [[maybe_unused]] if the function (an override) does use the parameter?
21:33:29 <andythenorth> "my first proper station"
21:33:54 <andythenorth> needs some track eh
22:10:04 *** Wolf01 has quit IRC (Quit: Once again the world is quick to bury me.)
22:17:01 *** NGC3982 has quit IRC (Ping timeout: 480 seconds)
22:19:22 *** HerzogDeXtEr has quit IRC (Read error: Connection reset by peer)
22:19:45 *** tokai|noir has joined #openttd
22:19:45 *** ChanServ sets mode: +v tokai|noir
22:20:14 *** NGC3982 has joined #openttd
22:26:38 *** tokai has quit IRC (Ping timeout: 480 seconds)
continue to next day β΅