IRC logs for #openttd on OFTC at 2024-01-02
            
00:01:37 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain commented on pull request #11670: Change: Limit total script ops that can be consumed by a list valuate https://github.com/OpenTTD/OpenTTD/pull/11670#pullrequestreview-1799884470
00:02:22 <DorpsGek> [OpenTTD/OpenTTD] glx22 commented on pull request #11670: Change: Limit total script ops that can be consumed by a list valuate https://github.com/OpenTTD/OpenTTD/pull/11670#issuecomment-1873533774
00:02:37 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain commented on pull request #11670: Change: Limit total script ops that can be consumed by a list valuate https://github.com/OpenTTD/OpenTTD/pull/11670#pullrequestreview-1799884596
00:04:44 <DorpsGek> [OpenTTD/OpenTTD] PeterN commented on pull request #11670: Change: Limit total script ops that can be consumed by a list valuate https://github.com/OpenTTD/OpenTTD/pull/11670#pullrequestreview-1799884890
00:05:25 <talltyler> https://cdn.discordapp.com/attachments/1008473233844097104/1191532666210758676/heightmap.png?ex=65a5c845&is=65935345&hm=ee95130ca47d237ddfce91ac2126e1af6e57e252200d659171223c03a1c55626&
00:05:25 <talltyler> Hmm, heightmap doesn't have the same number of buttons on each side. How do I get the heights even? (spacer?)
00:06:34 <peter1138[d]> Add two rows of spacers, or move one row from the right to the left...
00:07:15 <_glx_> move desert coverage
00:07:38 <_glx_> makes sense to group it on the left side
00:09:48 <DorpsGek> [OpenTTD/OpenTTD] JGRennison commented on pull request #11670: Change: Limit total script ops that can be consumed by a list valuate https://github.com/OpenTTD/OpenTTD/pull/11670#pullrequestreview-1799885974
00:10:09 <talltyler> https://cdn.discordapp.com/attachments/1008473233844097104/1191533855778291852/worldgen.png?ex=65a5c960&is=65935460&hm=36cb971e0db127c0a5ad1024076bc2b46e0cc2ba754e8d3de540bc70235f6ef5&
00:10:09 <talltyler> Regular worldgen is even though, I don't want to be inconsistent by moving desert coverage
00:10:29 <talltyler> (yes, we can make it tabs someday, but redesigning this is so, so out of scope ๐Ÿ˜› )
00:12:24 <_glx_> spacers on the left then
00:12:32 <talltyler> Yep, building that now ๐Ÿ™‚
00:13:53 <peter1138[d]> E_TOO_MANY_BUTTONS
00:15:59 <talltyler> Yeah ๐Ÿ˜ฆ
00:16:38 <peter1138[d]> "Minutes per year"
00:17:45 <LordAro> microfortnights per year
00:18:10 <peter1138[d]> "Minutes per year" is odd here because it's changeable in game.
00:19:20 <_glx_> dwfreed: I meant `<your_url_goes_here>`
00:20:56 <DorpsGek> [OpenTTD/OpenTTD] JGRennison updated pull request #11670: Change: Limit total script ops that can be consumed by a list valuate https://github.com/OpenTTD/OpenTTD/pull/11670
00:28:42 <talltyler> peter1138[d]: Yes, it's odd but I think it's worse to omit it, because it's so closely related to start date and timekeeping units
00:29:02 <talltyler> I've gone back and forth on it ๐Ÿ™‚
01:18:45 <talltyler> I will sleep on it, I guess
02:43:14 *** Flygon has joined #openttd
03:04:15 *** herms has quit IRC (Ping timeout: 480 seconds)
03:42:48 *** Wormnest has quit IRC (Quit: Leaving)
03:47:48 *** herms has joined #openttd
03:57:38 *** debdog has joined #openttd
04:00:06 *** D-HUND has quit IRC (Ping timeout: 480 seconds)
04:23:38 *** felix has quit IRC ()
04:23:52 *** felix has joined #openttd
04:38:02 *** Eddi|zuHause2 has joined #openttd
04:44:00 *** Eddi|zuHause has quit IRC (Ping timeout: 480 seconds)
05:10:36 *** keikoz has joined #openttd
07:12:45 <andythenorth> o/
07:12:59 * andythenorth will be pretending it's sunny today
07:13:30 <andythenorth> although my brief foray into the outdoors suggests that's a pleasing self-delusion
07:31:15 *** tokai|noir has joined #openttd
07:31:15 *** ChanServ sets mode: +v tokai|noir
07:38:06 *** tokai has quit IRC (Ping timeout: 480 seconds)
07:40:41 *** pppp has joined #openttd
07:40:59 *** pppp has quit IRC ()
07:48:29 <_zephyris> talltyler: I hope you don't mind me bombarding you with my 2C for terminology for game speed...
07:53:47 <_zephyris> "Minutes per year" is OK, "minutes per in game year" is better but probably too long. If the setting is "minutes per..." then putting the minutes unit with the number is redundant, could just be "12" etc.
07:55:28 <_zephyris> It should probably indicate the default value, ie. "12 (Default)". Also, I'm not keen on "Frozen" - it doesn't mean that you minutes per year is frozen, it means that in-game year is fixed. "Fixed year", "unchanging year" or even "infinite" would probably be better.
07:58:05 <_zephyris> Alternatively, you could omit minutes from the label and have more space for a string. Eg. "In-game year length": "12 minutes (default)".
07:58:24 <_zephyris> (I realise this can get broken by translations though)
07:58:52 <locosage> maybe "year duration"?
08:03:39 <locosage> though I don't think it should be in the worldgen window at all
08:04:55 <locosage> it's no more significant than, say, cargodist or breakdowns
08:08:59 <locosage> and, yeah, it's a run-time setting not generation-time
08:16:37 <_zephyris> "World Generation" is actually "New Game Settings", with settings that can't be changed later... Now it's got the AI, Game Script and NewGRF settings it's almost a tabbed interface in disguise.
08:31:40 <peter1138[d]> Well.
08:40:52 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191662385015046164/game_setup_gui_3f.png?ex=65a64114&is=6593cc14&hm=4d17992c244d656a40b8371102bb246396280b05ecf583ea75d49fddf24e43f3&
08:40:52 <andythenorth> once upon a time
08:40:56 <andythenorth> 2010 I made that
08:41:09 <andythenorth> 1/3 of my life ago ๐Ÿ˜ฎ
08:41:22 <andythenorth> * life so far, all other bets are off
08:42:41 <alfagamma7> Looks good
08:44:26 <andythenorth> needs more flat docks
08:44:43 <peter1138[d]> 1/3? Youngster.
08:45:33 <andythenorth> I went for the nearest whole number
08:45:44 <andythenorth> there are fractions if I'm being strict
08:46:32 <_zephyris> (2024-2010)*3=confirmed millennial
08:46:42 <_zephyris> It's a good UI concept though.
08:47:01 <andythenorth> the generation boundaries are thoroughly confusing these days
08:47:10 <andythenorth> I am millennial, gen X, and a Boomer apparently
08:47:12 <andythenorth> super confused
08:47:30 <peter1138[d]> Hmm, we don't have persistent window state do we?
08:47:59 <peter1138[d]> Perhaps the configurable default size stuff is the closest.
08:50:13 <alfagamma7> andythenorth: Depends on your age I think
08:50:42 <_zephyris> Depends on the age of the person judging ๐Ÿ˜œ
08:50:48 <andythenorth> ^ this
08:51:02 <andythenorth> in purely objective provable factual terms
08:51:04 <andythenorth> I am gen X
08:51:06 <andythenorth> because I say so
08:51:17 <andythenorth> anything else is people projecting weird crap
08:54:52 <locosage> hm... is the action7/9 the only way to do conditions in actionD calculations?
09:09:36 <alfagamma7> I really don't know / care about what generation I am from
09:10:41 *** keikoz has quit IRC (Ping timeout: 480 seconds)
09:11:56 <peter1138[d]> Hmm, per-windowdesc state sort of works.
09:46:44 <peter1138[d]> Right, that's... email caught up. Oddly not much.
09:49:30 <_zephyris> On the subject of getting started with work but getting distracted with discord, do you think there's appetite for wider 2CC usage?
09:49:36 <peter1138[d]> Yes
09:49:40 <_zephyris> I'm thinking company signs and base set infrastructure...
09:50:05 <peter1138[d]> You mean the bought-land signs?
09:50:25 <_zephyris> Station signs
09:51:08 <peter1138[d]> I'm not sure how that should work.
09:52:22 <peter1138[d]> How should we apply 2cc to a rectangle or some text?
09:53:05 <_zephyris> https://cdn.discordapp.com/attachments/1008473233844097104/1191680558892331100/image.png?ex=65a65201&is=6593dd01&hm=4db31cb8420f7e4ca5a4c25b2e71082eaf916d06ffbf7b7299274030d77b34c9&
09:53:13 <_zephyris> Could be a stripe
09:53:50 <locosage> looks meh
09:54:07 <emperorjake> could make it a border
09:54:10 <_zephyris> https://cdn.discordapp.com/attachments/1008473233844097104/1191680830028918886/image.png?ex=65a65242&is=6593dd42&hm=a743cbb41488a69a4ecc341ed93786fa9924b4dbc43ace2e67dc6dc5f220b6d9&
09:54:24 <_zephyris> (It partly looks meh becaus this is a slightly broken font)
09:55:49 <xarick> different shades filling the red
09:55:57 <xarick> using the 2 cc
09:57:23 <_zephyris> https://cdn.discordapp.com/attachments/1008473233844097104/1191681639026266122/image.png?ex=65a65303&is=6593de03&hm=d94ce954e538c4c5e2bd2e631eef7886a4b575a108376e457de12cd86d7b2864&
09:57:56 <_zephyris> Or an underline
09:57:58 <_zephyris> https://cdn.discordapp.com/attachments/1008473233844097104/1191681784996429894/image.png?ex=65a65325&is=6593de25&hm=8657e87b1282ca1903259e8f3b166440214210ea78c8fc88373fe8672a302137&
09:58:04 <_zephyris> Many concepts...
09:58:18 <_zephyris> I might make some proper mockups, once I've actually cleared my inbox
09:59:57 <peter1138[d]> Okay, well by 'wider 2CC usage' I was only thinking viewport sprites.
10:00:00 <rau117> _zephyris: This... least of all looks like a bug.
10:00:23 <_zephyris> peter1138[d]: Well, that too ๐Ÿ˜‰
10:01:06 <peter1138[d]> What about a 2CC version of the the company splot?
10:01:42 <_zephyris> Yeah
10:02:16 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191682866564841562/image.png?ex=65a65427&is=6593df27&hm=9bcff0ad199ab192d37905e79546d699ba1a589b524803fa4f655834dc8495b2&
10:02:25 <_zephyris> I was also thinking 'boring' infrastructure like rail fences, tile purchase signs, base stations
10:02:31 <peter1138[d]> It's basically a flag blowing in the wind, it's perfect for it.
10:02:52 <peter1138[d]> I know OpenGFX simplified it to something... else... but to me it's a flag.
10:03:27 <_zephyris> Yeah, it's a 1px bordered oval blob
10:03:57 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191683293310095400/image.png?ex=65a6548d&is=6593df8d&hm=ec98f2c592c08f91c3f62ce19113f77089ad77c90a27cfe6e605652450ea7b96&
10:04:21 <peter1138[d]> Of course it takes a slight leap of imagination, but still... ๐Ÿ™‚
10:05:13 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191683612572139641/image.png?ex=65a654d9&is=6593dfd9&hm=4343e36ffc0678f3112ffc296b538ffd981b19ff9b49cfa6898103733c2b29f6&
10:05:13 <peter1138[d]> Flags ๐Ÿ˜„
10:05:49 <_zephyris> I like it!
10:06:06 <peter1138[d]> So 1) have a 2CC company flag.
10:06:30 <locosage> https://cdn.discordapp.com/attachments/1008473233844097104/1191683931821572137/image.png?ex=65a65525&is=6593e025&hm=532abb567e25dc76bafa901b9874d572176cbbfd4d126e6dc7b76ca80d6edc97&
10:06:44 <peter1138[d]> creature feep: 2) maybe have different designs and allow players to pick one.
10:07:54 <merni> 3. Go the whole hog and allow arbitrary logos
10:08:47 <_zephyris> https://cdn.discordapp.com/attachments/1008473233844097104/1191684507154260029/image.png?ex=65a655ae&is=6593e0ae&hm=88bb59cd3a3e31d7e79991772f7e72406d19b1c4abad84075dc2c61463a7dd3e&
10:11:44 <locosage> https://cdn.discordapp.com/attachments/1008473233844097104/1191685249638350908/image.png?ex=65a6565f&is=6593e15f&hm=2f3e6701e7eaf29d19576917e41986cb2b1482857f83d38afe9757d1c7f101c7&
10:11:56 <xarick> wow, looks so modern
10:11:58 <locosage> can go full gradient
10:12:30 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191685442924449872/image.png?ex=65a6568e&is=6593e18e&hm=bda39c968b44c9a82f21cf5cd9c053402abcee9f324afd9c22e6e15d37654745&
10:12:37 <peter1138[d]> Heh
10:12:38 <_zephyris> Arbitrary gradients are ๐Ÿคฎ Works for similar colours, but not others
10:13:04 <locosage> idk, seems fine if done right
10:13:23 <locosage> i.e. not in rgb xD
10:14:13 <_zephyris> HSV/L is _OK_ but then you get weird desaturated stripes, eg. for blue to yellow
10:15:26 <locosage> hsv is pretty bad too
10:15:31 <locosage> need some lab
10:16:10 <_zephyris> peter1138[d]: Was it textured in TTO? I vaguely remember the toolbar having a different texture...
10:16:31 <peter1138[d]> TTO had texture all over the place.
10:18:43 <peter1138[d]> Okay, it didn't, misremembering ๐Ÿ™‚
10:18:53 <peter1138[d]> It had texture on the toolbar buttons.
10:19:24 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191687181635420200/image.png?ex=65a6582c&is=6593e32c&hm=4b72e306ac73bd05fad60d7f86f78ac34bca4fe50c7db9f508c8216b1d0fd7e3&
10:19:24 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191687181786427462/image.png?ex=65a6582c&is=6593e32c&hm=df9b1da43e35597d628a3e3d3eb1ee02ae848ca76abb1ab5db03ae1b1297248e&
10:19:24 <andythenorth> got a uniquely Eddi-shaped problem ๐Ÿ˜›
10:19:34 <peter1138[d]> State-machine?
10:19:46 <andythenorth> this uses modulo to split trains into blocks of 6 or so
10:20:00 <peter1138[d]> Also, interesting that the toolbar buttons are not square.
10:20:02 <andythenorth> but I don't like the remainder 2
10:20:41 <peter1138[d]> Is that all one engine type?
10:20:46 <andythenorth> yes
10:21:05 <peter1138[d]> How old-school.
10:21:21 <peter1138[d]> TTO had chunky bevels before chunky bevels were cool.
10:21:29 <_zephyris> So chunky
10:22:22 <xarick> I'm in pursuit of more performance on station removal
10:22:42 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191688009683308554/image.png?ex=65a658f2&is=6593e3f2&hm=c5432e6356b4b715195b2421dfb8d947096df92633e76c412c48713ece8cdee7&
10:22:42 <peter1138[d]> Nice colours.
10:22:50 <andythenorth> nice bulldozer sprite
10:22:53 <peter1138[d]> How often do players remove stations?
10:23:22 <xarick> not much...
10:23:29 <xarick> but AIs.... ๐Ÿ˜ฎ
10:23:36 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191688237660516454/image.png?ex=65a65928&is=6593e428&hm=4ae173adf25270c78639874be3b9464528fe23de3c304f14310a9f3dd4076876&
10:23:36 <peter1138[d]> Yes
10:23:46 <peter1138[d]> It's animated.
10:24:01 <_zephyris> I'd forgotten! Excellent
10:25:12 <peter1138[d]> Anyway, TTO indicates company-owned windows by using the flag on the top right, instead of colouring the caption panel.
10:25:47 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191688787466657884/image.png?ex=65a659ab&is=6593e4ab&hm=bd001120ccdd681df017205850c11ddb1520ff6b7986bfb86c6af05887defe18&
10:25:47 <peter1138[d]> So colourful
10:26:13 <peter1138[d]> Also: wider scrollbar.
10:27:11 <_zephyris> That font has some charm... And is horrible to read!
10:27:24 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191689194263814214/image.png?ex=65a65a0c&is=6593e50c&hm=fa3ef120ca75946402c2fc7336fa548b7734a3069dea44b4711a6528b156baf4&
10:27:24 <peter1138[d]> Even tooltips.
10:28:25 <locosage> https://cdn.discordapp.com/attachments/1008473233844097104/1191689447134216212/tmpab9n0k5y.PNG?ex=65a65a48&is=6593e548&hm=d788f819c82b2d822a6b1ebd17b8a3951628b3acdefd9b184de75cb1217bfbd3&
10:28:25 <locosage> _zephyris: all cc gradients in oklab
10:29:10 <_zephyris> locosage: Definitely better, no perceptual banding.
10:29:50 <peter1138[d]> Drawing that in game will be awkward.
10:30:08 <_zephyris> And not stylistically 8bppish
10:31:55 <peter1138[d]> It's amazing how controversial 8bpp is, to a 30 year old 256 colour game ๐Ÿ™‚
10:32:24 <rau117> Or maybe allow the player to choose the color of the interface headers regardless of the color of the company?
10:32:48 <peter1138[d]> No... they are company coloured...
10:33:13 *** keikoz has joined #openttd
10:34:33 <andythenorth> something in my maths doesn't do what I need ๐Ÿ˜› https://github.com/andythenorth/iron-horse/blob/gen-5-6-speed-rebalance/src/templates/procedures_rulesets.pynml#L348
10:36:18 <peter1138[d]> Write down how you want the different lengths split. Then work out rules for that.
10:38:07 <locosage> https://cdn.discordapp.com/attachments/1008473233844097104/1191691889792004126/tmplmnmjjw0.PNG?ex=65a65c8f&is=6593e78f&hm=a2957d160ab0e00d280bc5952f206c6f092f66610509bf6f7618034a5bf74a9b&
10:38:07 <locosage> increased 8bitness xD
10:39:13 <rau117> peter1138[d]: Letโ€™s say if you are โ€œunluckyโ€ on the server and all the โ€œgoodโ€ colors are occupied, you will have to use interface in your unliked color. Not super-critical, but still not very pleasant.
10:39:13 <rau117> The color of vehicles can be manually changed. The color of the infrastructure is needed to separate what belongs to whom. But the color of the interface matters only to you, it is visible only on your screen.
10:39:21 <peter1138[d]> Now do that but with only one dither pattern.
10:39:46 <peter1138[d]> Then it can be a sprite with 2CC applied.
10:39:55 <peter1138[d]> == quick to draw.
10:40:15 <peter1138[d]> Good colours. No. Just no.
10:40:48 <peter1138[d]> Mum!!!! They won't let me use my colour!
10:41:02 <locosage> https://cdn.discordapp.com/attachments/1008473233844097104/1191692624768282644/tmp9he02jjd.PNG?ex=65a65d3e&is=6593e83e&hm=976f00d93c9dba48883eb08d451799ac7d5590ad825f17d8e7f732f2b07de298&
10:41:02 <locosage> same pattern
10:41:07 <peter1138[d]> Oh good, my CI still works after the break.
10:41:17 <rau117> https://cdn.discordapp.com/attachments/1008473233844097104/1191692688605593661/image.png?ex=65a65d4d&is=6593e84d&hm=208596e412c4a62798e21451f075c2bd036dfa8997af8823665b3ab703a387ec&
10:41:17 <rau117> ?
10:41:18 <peter1138[d]> locosage: Not horrible.
10:41:27 <rau117> https://cdn.discordapp.com/attachments/1008473233844097104/1191692731299401768/image.png?ex=65a65d57&is=6593e857&hm=2c43e6cfc616fdfda12a3ddf11a995a2a33ce2e6a4b41416bf9ab5e7f0f1b02a&
10:41:27 <rau117> locosage: ?
10:41:48 <peter1138[d]> But yes, if it's a 2CC sprite, then it could be possible for each player to choose from a selection of sprites.
10:42:08 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191692900082393148/image.png?ex=65a65d7f&is=6593e87f&hm=fcabc118cbab913a15e422e6449fadf28cfaa18e07228c1ac68542a4442b4986&
10:42:08 <andythenorth> if the consist has more than 12 units in it, I want to do a 6 car unit, then apply the existing rules to the remainder
10:42:14 <xarick> https://cdn.discordapp.com/attachments/1008473233844097104/1191692924589723749/image.png?ex=65a65d85&is=6593e885&hm=82627fd7050a751f5d1a76ed7a9193ace2aa1ccfa65f92eb0d96a57a8b136f94&
10:42:14 <xarick> https://cdn.discordapp.com/attachments/1008473233844097104/1191692924853952592/Captura_de_ecra_2023-12-31_203317.png?ex=65a65d85&is=6593e885&hm=035635b66a4e3c972cc0d7e190346eef48318cce51b3e496e6173d3dcdbaf6a2&
10:42:14 <xarick> Rau, that's cool
10:42:49 <andythenorth> I think I need to store a start point in a temp register
10:42:51 <peter1138[d]> NewGRF-Caption/Signs.
10:43:22 <xarick> slight... negligible improvement when removing stations, I expected better since I'm cycling vehicle lists 1 less time
10:43:22 <peter1138[d]> What are you rules below 12?
10:43:38 <andythenorth> they're in a bunch of switches above
10:43:59 <locosage> rau117: yeah, likely better idea than random diffusion gradients, don't want to code this for all cc combinations though
10:45:26 <peter1138[d]> If total > 12 && position > 6 position -= 6;
10:45:41 <andythenorth> yes, that's the kind of thing ๐Ÿ™‚
10:46:12 <andythenorth> it's quite weird, my brain does some maths and patterns easily, but this one is like boxing fog ๐Ÿ™‚
10:47:08 <locosage> here is the code if someone wants to play with cc gradients <https://github.com/citymania-org/grf-py/blob/main/misc/all_cc_gradients.py>
10:56:44 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191696576536645672/image.png?ex=65a660ec&is=6593ebec&hm=cf90a200741521dd9d349f2982a8979bee5dfd9cc89079c69562f4d29c784de2&
10:56:44 <peter1138[d]> Some kind of (stolen from image search) half-tone gradient.
11:02:01 <peter1138[d]> Hmm, buy from Bandcamp for ยฃ22 + vat + shipping = ยฃ30, or from Amazon with one-day delivery for ยฃ18. Sigh.
11:02:47 <_zephyris> Pretty cool
11:02:50 <peter1138[d]> Given Bandcamp was bought out and is no longer the happy place...
11:10:06 <xarick> if (CleaningPool()) is true in some parts of bankruptcy, and not in others, why's that?
11:10:26 <xarick> it's true for removing stations, but false for removing depots
11:11:28 <peter1138[d]> Think about what CleaningPool is for.
11:11:49 <xarick> I'm trying to figure that out
11:13:17 <peter1138[d]> src/core/pool_type.hpp
11:15:08 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191701205316010065/image.png?ex=65a6653c&is=6593f03c&hm=1a7fd9816da5b96b691236f2ec1cc97eae7239574d96d642f125de6c40fc9253&
11:15:08 <andythenorth> well
11:15:15 <peter1138[d]> Perfect ๐Ÿ™‚
11:15:27 <andythenorth> commiting now
11:16:09 <xarick> it seems it's not the ~station that is slowing down bankruptcy, it's ~depot
11:16:18 <xarick> I was mislead ๐Ÿ˜
11:16:57 <peter1138[d]> Have you taken a step back and considered what you are even doing yet?
11:17:55 <xarick> I'll figure out what I'm doing
11:17:57 <andythenorth> no I haven't ๐Ÿ™‚
11:18:00 <andythenorth> what am I doing?
11:24:47 <xarick> wow, I'm stoopid
11:25:19 <xarick> the station isn't totally removed... the ghost sign stays for a while before its poofed
11:26:29 <xarick> it's a good thing Company::Iterate only iterates valid companies
11:26:45 <xarick> the owner of these ghost stations is already gone
11:28:31 <peter1138[d]> Ghost station signs should not exist for removed companies.
11:51:17 * andythenorth such blocks of 6
11:51:36 * andythenorth rabbit holed
11:52:51 <andythenorth> maybe I need to subtract 12 from the total length, then divide the remained by 6 to find how many 6 blocks there are
11:53:04 <andythenorth> or something
11:53:10 <andythenorth> probably a bad feature anyway ๐Ÿ™‚
12:04:02 <xarick> All this time I had been doing improvements to RemoveOrderFromAllVehicles I thought this was being called from ~Station removal, but it was ~Depot removal doing the calls!
12:04:49 <xarick> ~Station removal happens only after a while, which I didn't wait for in my previous measurements
12:05:07 <xarick> the more I investigate
12:05:44 <xarick> the more (less?) I know
12:09:52 <xarick> on bankruptcy the relevant vehicles are already gone by the time ~Station is called, but this still goes over the entire pool.... 3 TIMES!
12:10:06 <xarick> so much improvements could be done here ๐Ÿ™‚
12:11:32 <peter1138[d]> Can you show me the percentage of time used by closing bankrupt companies over a 1 year game period?
12:11:54 *** Eddi|zuHause2 is now known as Eddi|zuHause
12:12:42 <xarick> I'm working on it, i just didn't measure it properly
12:13:36 <_zephyris> https://cdn.discordapp.com/attachments/1008473233844097104/1191715920045936730/2CCMockup.png?ex=65a672f0&is=6593fdf0&hm=9a5477897d790893876941161e9b42a0d3c58ed67a05359d83406cfb8951f377&
12:16:34 <_zephyris> https://cdn.discordapp.com/attachments/1008473233844097104/1191716664832704602/2CCMockup.png?ex=65a673a1&is=6593fea1&hm=895ef71069bb42d30fd9023e38a7e31c0b3c5c5c71db6b2b356d7bdf7b76ad15&
12:16:34 <_zephyris> Forgot one ๐Ÿ™‚
12:16:49 <Eddi|zuHause> <andythenorth> maybe I need to subtract 12 from the total length, then divide the remained by 6 to find how many 6 blocks there are <-- do you have existing code you can show me? i might have an idea or two
12:17:29 <reldred> _zephyris: Okay those look downright cool
12:18:12 <xarick> the last one looks great
12:18:28 <reldred> Borders/underline not so hot on, but all the variations of the gradient/coloured end tab look great
12:19:05 <xarick> the two last ones, go for it
12:19:06 <reldred> That said 2nd and 3rd last have grown on me
12:19:53 <andythenorth> Eddi|zuHause: https://github.com/andythenorth/iron-horse/blob/gen-5-6-speed-rebalance/src/templates/procedures_rulesets.pynml#L348
12:19:59 <andythenorth> and reading switches upwards
12:20:34 <peter1138[d]> I like the coloured end-tab -- along with allowing players to pick a style. Include the company flag and caption background as a single choice, and that gives a bit of variety between companies, without being a complete free-for-all.
12:21:22 <Eddi|zuHause> LOAD_TEMP(${temp_storage_ids.num_vehs_in_vehid_chain_multiple_ids}) % 8 <-- why is it %8 in all the switches?
12:21:55 <andythenorth> read up not down ๐Ÿ™‚
12:22:08 <andythenorth> it's % 12 in the relevant chain
12:24:40 <_zephyris> https://cdn.discordapp.com/attachments/1008473233844097104/1191718706032685157/2CCMockup2.png?ex=65a67588&is=65940088&hm=af6945867001a9c06c7f4cb9d48ad942b164546e1877bd11cd91d265fe27677c&
12:24:40 <_zephyris> The fan favourites
12:25:29 <Eddi|zuHause> andythenorth: right...
12:26:13 <xarick> Could I ask for 11548 to be merged? It's already approved. The savegame I'm using for testing is one affected
12:26:25 <xarick> that would help
12:26:59 <Eddi|zuHause> andythenorth: so you need to check "if count>12 -> STORE_TEMP(count % 6)"
12:27:26 <andythenorth> plausible ๐Ÿ™‚
12:27:45 <Eddi|zuHause> something like that
12:27:47 <andythenorth> and then subtract that when checking the position?
12:28:10 <andythenorth> this should be simple, but for some reason it's not ๐Ÿ™‚
12:28:21 <Eddi|zuHause> it's not THAT simple
12:29:09 <andythenorth> it's quite easy to visualise, but not to describe or do the maths for
12:29:23 <andythenorth> all we do is cut off blocks of 6 until we have 12 or fewer units remaining
12:30:01 <DorpsGek> [OpenTTD/OpenTTD] PeterN commented on pull request #11548: Fix #10511: Delay 'go to nearest depot' orders https://github.com/OpenTTD/OpenTTD/pull/11548#pullrequestreview-1800358960
12:30:08 <Eddi|zuHause> yes. but you can't do it iteratively, because of no loops, you have to nest / and % operations
12:30:31 <andythenorth> yes
12:30:51 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191720260882153554/618zT7fB7aL.png?ex=65a676fb&is=659401fb&hm=a6d000a2960ba5816f7b118d46560c23145b634089119ca86f750d5f2ae344b1&
12:30:51 <andythenorth> in the UK we have these to learn basic number maths with
12:31:14 <peter1138[d]> Oh... them...
12:31:19 <andythenorth> so in plastic-brick operations, it's just disconnecting sticks of 6 until there are 12 or fewer
12:31:39 <andythenorth> if we had loops and array slice, this would also be trivial ๐Ÿ˜›
12:31:44 <peter1138[d]> I've also just remembered Stickle Bricks.
12:31:49 <andythenorth> weebles
12:31:55 *** schnitzelpfanne has joined #openttd
12:31:55 <schnitzelpfanne> i've to download AI right?
12:31:55 <schnitzelpfanne> I'm confusing cuse if i start a game there is random Ai selected
12:32:09 <peter1138[d]> You need at least one AI downloaded, yes.
12:32:52 <Eddi|zuHause> andythenorth: what your current switch is missing is the case for if count/6 is odd
12:33:20 <Eddi|zuHause> you currently chop it up into blocks of 12
12:33:57 <Eddi|zuHause> but you need to chop it up in blocks of 6, with the remaining block being larger than 6
12:34:03 <peter1138[d]> andythenorth: Shall I? <https://www.amazon.co.uk/Learning-Resources-Mathlink-Cubes-Set/dp/B000URL296>
12:35:09 <peter1138[d]> I remember them, but I don't ever remember using them for learning about numbers.
12:35:33 <andythenorth> we had hundreds tens and units
12:35:42 <andythenorth> in various types of plastic brick
12:35:46 <DorpsGek> [OpenTTD/OpenTTD] npabisz started discussion #11671: Favourite multiplayer servers https://github.com/OpenTTD/OpenTTD/discussions/11671
12:36:44 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191721741555335199/image.png?ex=65a6785c&is=6594035c&hm=036f6625f6a1aaf6fdfb7ed57510e3ac270e8e5dbd9a64d3fff9d197447f5e33&
12:36:44 <andythenorth> Eddi|zuHause: yes, it looks odd, but the 12 is intended - it enables more specific handling of cases between 6 and 12
12:37:12 <andythenorth> so 4 + 4 or 5 + 5
12:37:30 <andythenorth> for > 12, it would be fine to do 6 + 4 + 4 or 6 + 5 + 5
12:37:43 <rau117> May I know why the โ€œlet the player chooseโ€ option is not suitable?
12:37:44 <Eddi|zuHause> yes. and that's the part that's not working
12:37:51 <peter1138[d]> You only want the last segment to be up to 12.
12:38:01 <andythenorth> rau117: because I have zero interest in units
12:38:02 <Eddi|zuHause> because instead of 6+4+4 you get 6+6+2
12:38:14 <andythenorth> yes
12:39:38 <rau117> andythenorth: *wellโ€ฆ then you can forget about selecting combinations and return to other, more interesting things*
12:40:00 <andythenorth> no, because 6 + 6 + 2 looks weird
12:40:41 <Eddi|zuHause> andythenorth: so in the switch you linked, you need to think in 6's, not 12's
12:41:05 <andythenorth> yes
12:41:09 <Eddi|zuHause> and special case if there's less than 2 full blocks of 6's remaining
12:41:44 <andythenorth> the only way I can see to do it is to fork between 2 chains
12:41:50 <andythenorth> fork / branch /s
12:42:10 <Eddi|zuHause> no, change the %12 to %6, and special case 1,2,default
12:42:44 <andythenorth> what does the case of e.g. 7 look like?
12:42:53 <andythenorth> well, 8 is easier, this is all on even number counts
12:43:07 <andythenorth> how does % 6 handle 8 units?
12:43:33 <Eddi|zuHause> 1-6 go into case 1, 7-12 go in case 2 (both chain to "less than 12 remaining") and rest goes to generic
12:43:51 <Eddi|zuHause> and potentially you need to STORE_TEMP
12:44:53 <andythenorth> I think I need to STORE_TEMP for a slice point
12:45:27 <andythenorth> [count - % 6:]
12:45:42 <Eddi|zuHause> you potentially need to STORE_TEMP(count := count-6) in either case 1 or case 2, not sure which one
12:46:10 <Eddi|zuHause> or +6, doesn't matter because you %12 everywhere
12:47:09 <andythenorth> ok so the slice point depends on the current vehicle position
12:48:44 <Eddi|zuHause> switch (count-position)/6 [rounded down] -> 0, 1, larger
12:49:56 <andythenorth> I think TMWFTLB no longer applies ๐Ÿ™‚
12:50:04 <Eddi|zuHause> STORE_TEMP(count+((count-position)/6)%2)*6)
12:50:10 <andythenorth> this has become a 'must be solved no matter the actual benefit' ๐Ÿ™‚
12:50:19 <Eddi|zuHause> something along those lines
12:50:29 <Eddi|zuHause> modulo () errors
12:50:48 <andythenorth> wonder if OpenTTD could do this ๐Ÿ˜›
12:50:51 <andythenorth> it has...loops
12:50:54 <Eddi|zuHause> potentially a +1 after the %2
12:50:54 <peter1138[d]> Just make a look up table for each possible length... ๐Ÿ˜‰
12:51:04 <andythenorth> peter1138[d]: I could....generate one
12:51:13 <andythenorth> lol, that would be the horrific approach
12:51:18 <andythenorth> just generate this up to 128 TL
12:52:17 <Eddi|zuHause> the STORE_TEMP goes in the less_than_12 switch
12:52:27 <andythenorth> 'precedent' https://github.com/andythenorth/iron-horse/blob/gen-5-6-speed-rebalance/src/templates/procedures_alternative_var_41.pynml
12:52:51 * andythenorth seriously wondering if we could add some vars for this stuff
12:53:05 <Eddi|zuHause> andythenorth: it's really only 3 or 4 lines changed
12:53:22 <andythenorth> my +/-128 loop unroll to check multiple IDs is very amusing...but can't be good ๐Ÿ™‚
12:53:25 <Eddi|zuHause> just have to be the correct lines :)
12:53:33 <andythenorth> Eddi|zuHause: ๐Ÿ™‚
12:53:39 <locosage> andythenorth: dunno about vars but perm storage for vehicles would help a lot
12:54:02 <andythenorth> doesn't add loops though eh ๐Ÿ˜›
12:54:21 <peter1138[d]> Use the random probability callback to determine if the engine-part should be front or rear facing...
12:54:23 <andythenorth> how about storing per-vehicle lambdas
12:54:26 <andythenorth> written in squirrel
12:54:28 <locosage> yeah, but you only need to recurse on consist change
12:54:43 <andythenorth> grf could initiate squirrel VMs on the fly? o_O
12:54:48 <peter1138[d]> Oh yeah, there's no position during the probability callback ๐Ÿ™‚
12:55:06 <andythenorth> I can read random bits
12:55:12 <andythenorth> from various places in the consist ๐Ÿ˜›
12:55:46 <peter1138[d]> With the persistent storage patch, one issue was "when should it be allowed to be updated"
12:55:55 <Eddi|zuHause> andythenorth: thoughts like this is why modern games are always considered "not optimized"
12:56:39 <Eddi|zuHause> because "just one more lane^W^Wyer of indirection solves my problem"
12:58:07 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191727123522670663/image.png?ex=65a67d5f&is=6594085f&hm=d0b6d8b953bfcfa36dd8b3939fba221ab6639d7b08e78cf9d74574081d336618&
12:58:07 <peter1138[d]> I wonder what vehicles that adds ๐Ÿ˜‰
12:58:39 <Eddi|zuHause> try to load it? :p
12:58:51 <_jgr_> Strictly speaking, trains have permanent storage already
12:59:35 <_jgr_> (One byte of it via CB36/property 25 and the silly interface in var42)
12:59:45 <andythenorth> it's one of the best newgrf features
12:59:55 <andythenorth> don't you get an OR of the bits in the whole consist?
13:00:03 <locosage> it's like the most useless permanent storage ever :p
13:03:57 <Eddi|zuHause> you can do stuff like "does this consist have a dining car", or "do all vehicles in the consist have electric heating"
13:04:14 <locosage> yeah, and nothing else
13:04:40 <andythenorth> isn't it theoretically prone to cross-grf interference?
13:04:45 <Eddi|zuHause> yes
13:04:50 <andythenorth> assuming anyone bothered to use it ๐Ÿ™‚
13:05:04 <locosage> by "do all vehicles in the consist have electric heating" you mean "no vehicles in consist lack electric heating" ?
13:05:10 <Eddi|zuHause> but lots of features break if you mix newgrfs
13:05:43 <Eddi|zuHause> like, engine attach callback
13:05:56 <locosage> attach cb can check grfid
13:06:33 <Eddi|zuHause> yes. but you can circumvent the callback entirely if you add invisible engine at the front
13:07:08 <Eddi|zuHause> because the check only works one way, not both ways.
13:07:24 <andythenorth> openttd var, "where am I in a list of contiguous vehicles, with optional repeating blocks"
13:07:43 <andythenorth> params: block size, [list of IDs]
13:07:50 <andythenorth> what would it return?
13:08:15 <locosage> isn't horse the only grf using something like this?
13:08:19 <andythenorth> it needs to return position, and size of the block the vehicle is in
13:08:32 <andythenorth> dunno, haven't played other grfs much ๐Ÿ™‚
13:08:35 <andythenorth> nor decompiled them
13:08:45 <andythenorth> but stuff like pantographs that repeat every n vehicles
13:08:48 <andythenorth> also needs this
13:09:14 <andythenorth> I learnt to not ask for vars that can be done in templated varact 2, but this case is silly to handle in varact 2
13:09:22 <locosage> I feel like that's too specific of a usecase to add to the game
13:09:34 <locosage> just add perm storage and grf can calculate all that on consist change
13:09:45 <andythenorth> it's still stupid nml to write
13:11:36 <locosage> nml problems :p
13:11:37 <andythenorth> lot of var 61 checks
13:11:57 <_jgr_> Templating can be a problem if it means that every vehicle has its own copy of a huge bloat of identical varaction2 chains
13:12:27 <andythenorth> **every** Horse vehicle with this varact 2 chain potentially runs 4096 checks every time the graphics chain is resolved
13:12:48 <andythenorth> IRL it's probably more like 256 because consists aren't usually 128 vehicles ๐Ÿ˜›
13:15:56 <peter1138[d]> So persistent storage during wagon-attach stuff?
13:16:13 <peter1138[d]> And also, not 256 slots of persistent storage because that's lol.
13:16:34 <locosage> sounds like a plan
13:16:49 <peter1138[d]> You basicaly only need 1 byte for this...
13:16:55 <peter1138[d]> Not 1024 bytes.
13:17:54 <locosage> one byte for this, one byte for that... but, yeah, not that many
13:18:01 <andythenorth> with persistent storage, I could cut the number of checks by factor of 16
13:18:07 <peter1138[d]> If it's limited to 8 bytes (2 * 32 bit values) that's enough data for "most" use cases, and is less memory than a pointer to a PSA struct.
13:18:12 <andythenorth> currently my stupid loop checks up to 16 IDs
13:18:26 <andythenorth> but it could just check one storage for a specific value
13:18:36 <andythenorth> (on each vehicle in the consist)
13:18:41 <peter1138[d]> But it needs to use the same interface as PSA, I guess.
13:19:00 <peter1138[d]> Should be okay, PSA size is templated
13:19:15 <andythenorth> hmm standardised vehicle compatibility label schema?
13:19:17 <andythenorth> ๐Ÿ˜›
13:19:24 <andythenorth> "this is a passenger coach"
13:19:32 <peter1138[d]> Make PSA private-use only?
13:19:39 <peter1138[d]> "But my add-on NewGRF..."
13:19:54 <locosage> overrite_psa(...)
13:20:08 <peter1138[d]> andythenorth: We have persistent storage for that already. Checkout the cargo-type property.
13:20:35 <andythenorth> an intriguing idea
13:21:22 <peter1138[d]> And it automatically updates if the player refits...
13:21:35 <andythenorth> subtypes though ๐Ÿ˜›
13:21:45 <peter1138[d]> They don't exist.
13:21:47 <andythenorth> some passenger coaches are more equal than others
13:22:38 <peter1138[d]> If I leave the station class picker docked, should the bus station class picker and the object class picker also be docked?
13:22:54 <locosage> peter1138[d]: I think I know a usecase for 3 ints of storage: train upgrades that boost, max speed, hp and te
13:23:27 <DorpsGek> [OpenTTD/OpenTTD] SamuXarick commented on pull request #11548: Fix #10511: Delay 'go to nearest depot' orders https://github.com/OpenTTD/OpenTTD/pull/11548#pullrequestreview-1800421018
13:23:31 <peter1138[d]> The key here is "a few values" rather than the lol-rious 256 of industries.
13:23:34 <andythenorth> child just sent me a photo of cooling a water bottle inside his new gaming PC
13:23:40 <andythenorth> due to it having lots of fans
13:23:43 <andythenorth> "what could go wrong"
13:23:59 <andythenorth> industries only have 256? ๐Ÿ˜ฎ
13:24:07 <andythenorth> goes it throw limit?
13:24:13 <peter1138[d]> Values. Each value is 4 bytes, so 1KiB.
13:24:19 <peter1138[d]> That's per industry.
13:24:25 <locosage> peter1138[d]: yeah, just as not that as few to fit in a pointer xD
13:24:49 <peter1138[d]> No, but if it's "4" values, then it's "probably" not worth bothering with a pointer.
13:25:07 <peter1138[d]> Unless it needs to be a pointer anyway, I dunno ๐Ÿ˜„
13:25:51 <peter1138[d]> Oh, it does. Because it's in a pool.
13:26:05 <peter1138[d]> But still, limiting it...
13:26:37 <peter1138[d]> Hmm, the StoragePool is on PersistentStorageArray<int32_t, 256>
13:26:49 <locosage> also if you embed storage into vehicle it can bloat savegame size
13:26:50 <peter1138[d]> So maybe I can use PersistentStorageArray<int32_t, 4> outside of a pool.
13:27:09 <peter1138[d]> Adding data makes the savegame bigger. Who knew?
13:27:19 <xarick> help! I don't know how to comment
13:27:56 <andythenorth> can we compress the persistent storage?
13:28:07 <locosage> peter1138[d]: yeah, but if vehicles has no psa it shouldn't ideally
13:29:24 <xarick> aren't savegames compressed already? it goes into the lzma filter by default
13:36:16 <Eddi|zuHause> perm storage for trains is probably nice to have, but i think this case doesn't really need it.
13:36:24 <peter1138[d]> Hmm, 16 bytes of struct PSA is 48 bytes of memory.
13:37:11 <Eddi|zuHause> 48 bytes, times 5000 trains, times 16 companies?
13:37:38 <peter1138[d]> It's per vehicle, not per train.
13:37:52 <andythenorth> Eddi|zuHause: the modulo case doesn't need it ๐Ÿ™‚
13:38:03 <Eddi|zuHause> what's the vehicle limit nowadays? 1 million?
13:38:18 <andythenorth> but there is a related loop that checks families of vehicle IDs, and that would be aided by permanent storage
13:38:48 <andythenorth> or a var ๐Ÿ˜›
13:38:56 <peter1138[d]> 0xFF000
13:39:12 <andythenorth> odd number of bytes there ๐Ÿ™‚
13:39:21 <peter1138[d]> 50MB on a fully maxed out game. Not *that* bad.
13:39:44 <Eddi|zuHause> @base 16 10 ff000
13:39:44 <DorpsGek> Eddi|zuHause: 1044480
13:40:02 <Eddi|zuHause> that's basically a million.
13:40:21 <xarick> https://cdn.discordapp.com/attachments/1008473233844097104/1191737750056087582/image.png?ex=65a68745&is=65941245&hm=9103e86270b2749616e0a5057ee6ea07fc4e3d52af34522cc3dbad8a2f4aa813&
13:40:23 <locosage> iirc max vehicles I've seen in real games is about 30k
13:40:32 <xarick> oh, i added 1 extra 0
13:40:48 <Eddi|zuHause> locosage: we used to have a 64k limit, and people complained it's not enough
13:40:48 <peter1138[d]> PSA store grfid, feature and tile.
13:40:59 <peter1138[d]> Which is a waste here.
13:41:06 <xarick> https://cdn.discordapp.com/attachments/1008473233844097104/1191737939395358760/image.png?ex=65a68772&is=65941272&hm=52a67565fa15a532b23fddff5fe212ae716220470307deefb86e79f0439ab95f&
13:41:23 <peter1138[d]> Maybe they can be moved to the pool item version.
13:41:56 <Eddi|zuHause> "tile"? should probably be something like "vehicleID" here
13:42:34 <peter1138[d]> They're only used for debug output.
13:43:43 <Eddi|zuHause> that might be a bit wasteful :p
13:43:43 <peter1138[d]> Seems towns use grfid for some purpose, but I don't think that's needed here either.
13:44:17 <Eddi|zuHause> you can already query the grfid of a vehicle
13:45:11 <Eddi|zuHause> are we still on the advisory of "don't mix vehicle grfs"?
13:45:49 <peter1138[d]> Not really, but other GRFs will not be able to write to another GRF's PSA.
13:46:14 <Eddi|zuHause> IIRC towns have one set of storage per grf that wants one. do we want that for vehicles?
13:46:29 <peter1138[d]> Of course not.
13:47:18 <_jgr_> locosage: The number of vehicles can be significantly inflated by sets which use tiny articulated parts like Timberwolf's, etc
13:47:33 <peter1138[d]> 32 bytes after moving those fields.
13:47:48 <peter1138[d]> So potentially still pointer-material :/
13:47:55 <peter1138[d]> But that makes saveload harder.
13:48:08 <Eddi|zuHause> do we outright want to block writing to storage of other GRF? might block some features that want to write to the engine's storage
13:48:09 <xarick> *cough* AIs need more stations, *cough* because buoys... I can't max out *cough* a game
13:48:14 <peter1138[d]> The pool exists for this, but the saveload for PSA is fixed and only supports 256 items.
13:48:33 <peter1138[d]> IMHO, a vehicle can only write to its own PSA.
13:49:20 <Eddi|zuHause> but then engine must again loop over all wagons
13:49:31 <Eddi|zuHause> doesn't that defeat the point?
13:49:50 <locosage> va2 kinda only writes to own psa by definition
13:50:14 <Eddi|zuHause> i'm talking here about a PARENT va2
13:50:40 <locosage> well, in that case it's parent's psa
13:50:44 <Eddi|zuHause> i think that's how industries write to town storage
13:50:44 <peter1138[d]> The point is it's persistent, so it can do it once on say wagon attaching, and then it's done.
13:51:20 <Eddi|zuHause> locosage: yes, but PARENT can be an engine from another grf
13:52:31 <peter1138[d]> parent means you are querying the properties of the parent engine, not that you are now executing as the parent engine.
13:53:08 <Eddi|zuHause> but the storage is a property of the parent engine then
13:53:16 <peter1138[d]> So it could be prohibited from modifying PSA when in parent scope.
13:53:49 <Eddi|zuHause> i think that makes it completely unusable
13:54:22 <locosage> Is "executing as" even a thing in newgrf? parent runs in parent context with everything parent only relation with "child" is temporary storage
13:54:35 <Eddi|zuHause> because pretty much all use cases i have in mind would use the parent PSA for writing
13:55:50 <peter1138[d]> Doesn't this use-case of andy's require writing to each wagon?
13:56:15 <Eddi|zuHause> but that's a not-use case, because it's not needed.
13:56:15 <locosage> it does iirc
13:57:09 <Eddi|zuHause> at best it's an optimisation, because the calculation only runs on consist update instead of sprite query
13:57:26 <Eddi|zuHause> but it doesn't really simplify the calculation
13:58:43 <locosage> make callback that iterates vehicle chain while keeping temporary storage
14:00:14 <Eddi|zuHause> yeah, like a more flexible var42, allowing arbitrary operations
14:01:52 <andythenorth> oo
14:02:14 <andythenorth> PSA, and a callback for when player flips vehicle in depot? ๐Ÿ˜›
14:02:37 <peter1138[d]> Okay, so allow storing PSA if it's the same GRF?
14:02:49 <peter1138[d]> Or just don't care and rely in GRFs to cooperate?
14:03:07 <Eddi|zuHause> that was basically the question i meant to ask.
14:03:40 <peter1138[d]> Limiting by GRFID means addons can't do their thing.
14:05:00 <locosage> allow other grfid if engine_override active?
14:06:35 <peter1138[d]> Ah, there are 3 booleans stored in BasePersistentStorageArray that bloat it by 8 bytes ๐Ÿ˜ฎ
14:06:57 <peter1138[d]> engine_override isn't something that is "active"
14:07:36 <peter1138[d]> They exist only during NewGRF loading.
14:07:48 <Eddi|zuHause> it currently only does something during loading
14:08:14 <locosage> well, it can be saved after loading
14:09:29 <peter1138[d]> Oh wait, they are static ๐Ÿ™‚
14:09:48 <peter1138[d]> Hmm, why is this so large then ๐Ÿ˜ฎ
14:10:53 <peter1138[d]> Maybe vtable.
14:12:57 <peter1138[d]> And that's a fairly pointless distinction :/
14:15:37 <peter1138[d]> Okay, so what is this even for?
14:18:51 <DorpsGek> [OpenTTD/OpenTTD] SamuXarick updated pull request #10548: Change: Groups cache vehicle lists https://github.com/OpenTTD/OpenTTD/pull/10548
14:19:03 <peter1138[d]> Same applies.
14:19:21 <_zephyris> Does anyone know hte the default font size for the monospace font?
14:19:50 <peter1138[d]> Same as medium -- 10 pixels high, including 2 pixel descender.
14:21:47 <rau117> andythenorth: well, at best he will get a bottle of warm water and shattered expectations
14:28:06 <DorpsGek> [OpenTTD/OpenTTD] Kuhnovic updated pull request #10543: Feature: Region-based pathfinder for ships (no more buoys!) https://github.com/OpenTTD/OpenTTD/pull/10543
14:29:49 <DorpsGek> [OpenTTD/OpenTTD] Kuhnovic commented on pull request #10543: Feature: Region-based pathfinder for ships (no more buoys!) https://github.com/OpenTTD/OpenTTD/pull/10543#pullrequestreview-1800509858
14:31:14 <belajalilija> imo i think that buoys should be kept around, even if hidden behind a button because they add a little decoration and its nice to keep ships further away from land
14:33:00 *** kuhnovic has joined #openttd
14:33:00 <kuhnovic> I should probably change that to "no more buoys required". They haven't been removed, you can still use them as waypoints... sort of
14:33:44 *** nielsm has joined #openttd
14:34:11 <peter1138[d]> AIs that spam buoys...
14:38:41 <andythenorth> 1 per tile
14:38:48 <andythenorth> then calculate the best route in squirrel
14:38:53 <andythenorth> then modify ship orders on the fly
14:40:30 <xarick> AIs not using buoys... the dream!
14:41:24 <xarick> might make it possible to 5000 * 4 * 15 vehicles
14:41:34 <xarick> without hitting the station limit
14:47:05 <belajalilija> there's a station limit? :widdle_goblin:
14:47:27 <xarick> yes, it's a nightmare! it ruins my dream ๐Ÿ™‚
14:47:54 <belajalilija> i am outraged about this thing i have just now learned about
14:48:07 <locosage> it's about 64k....
14:48:55 <belajalilija> oh like 65535 probably
14:49:13 <belajalilija> whats the decoration limit?
14:49:38 <xarick> I still doubt 64k is enough though, unless the AIs make good management of their existing routes
14:50:09 <xarick> but without buoys, it's a possibility. Buoys were the real offender
14:50:12 <belajalilija> oh the trick is to not use ai
14:50:41 <locosage> belajalilija: nah, 64000 actually
14:50:50 <Eddi|zuHause> buoys will be buoys
14:50:55 <belajalilija> oh
14:51:09 <belajalilija> i always expect things to be 65535
14:51:12 <belajalilija> idk why
14:51:26 <merni> xarick: Just... why
14:51:45 <merni> A save with that many vehicles would not run at any reasonably speed anyway
14:51:54 <belajalilija> i think a lot of the limits in locomtion were 65535
14:51:58 <belajalilija> so my brain applies the same logic
14:52:31 <locosage> well, that's powers of 2, but here someone decided to set 64000 ๐Ÿคทโ€โ™‚๏ธ
14:52:39 <merni> https://cdn.discordapp.com/attachments/1008473233844097104/1191755944288337960/image.png?ex=65a69836&is=65942336&hm=729fb98ef32b8b06b91b9631f26c4136e85ff642656f6128c19b796fe06b4332&
14:52:39 <merni> Lol google
14:53:32 <belajalilija> so its a 16 thing
14:53:49 <belajalilija> 65536 will have been the total # of things
14:53:54 <belajalilija> because it started at 0, not 1
14:54:27 <merni> Well it's not necessarily that it's a 16-bit variable, could just have been a limit that a programmer decided, and they went for 2^16 because they like powers of 2 (being a programmer)
14:54:33 <belajalilija> like in locmotion if you want a vehicle always available you set the intro date to 0 and the obsolete date to 65535
14:55:16 <_glx_> main issue is AIs usually don't reuse their own buoys
14:55:40 <xarick> i have a PR increasing pool of stations, it's not pretty. Things slow down indeed
14:55:57 <merni> It's almost like limits are set for sensible reasons
14:56:06 <_glx_> 3 lines following similar path and they put new buoys for each line
14:58:17 <_glx_> locosage: because it looks nicer for human brain
14:59:04 <xarick> I forgot if there was a "next pool" limit reached after the station pool. Need to check the chat logs for it
14:59:28 <_glx_> index storage in map for once
15:00:56 <_jgr_> Some StationID values are sentinels for other things, so the maximum value isn't exactly 2^16 - 1
15:02:32 <_glx_> and increasing limits just because AIs are not smart enough and spam way too much buoys is not a solution ๐Ÿ™‚
15:07:02 <kuhnovic> Does anyone know what I did wrong here? I'm quite the git noob ... https://github.com/OpenTTD/OpenTTD/actions/runs/7386913040/job/20094464683?pr=10543
15:09:03 <kuhnovic> I did a clean checkout of my fork, amended my last commit, force pushed... now I get this
15:11:19 <merni> have you rebased your fork?
15:11:39 <merni> could be that your fork has got too out of date from master
15:12:35 *** Wormnest has joined #openttd
15:14:49 <kuhnovic> I can give that a try
15:15:51 <xarick> glx, I remember trying it with my AI
15:16:18 <xarick> 15x my AI using the least amount of buoys possible, it still reached the limit.
15:16:47 <xarick> maybe without buoys that can be done
15:16:54 <xarick> not reach the limit
15:17:43 <xarick> the current pathfinder still not strong enough to navigate without buoys
15:17:59 <xarick> I was getting lost ships
15:18:16 <merni> Well, that is what #10543 is trying to solve...
15:18:33 <xarick> I know, looking for it to be in master
15:19:03 <DorpsGek> [OpenTTD/OpenTTD] Kuhnovic updated pull request #10543: Feature: Region-based pathfinder for ships (buoys no longer required!) https://github.com/OpenTTD/OpenTTD/pull/10543
15:21:11 <merni> Commit checker passed :)
15:23:48 <Rubidium> xarick: you're wondering why with 15 AIs you can't reach 5000 stations per AI, given the 64000 limit?
15:24:59 <xarick> no
15:25:21 <DorpsGek> [OpenTTD/OpenTTD] Kuhnovic commented on pull request #11606: Fix #11528: Don't auto-build past tunnelbridge ends https://github.com/OpenTTD/OpenTTD/pull/11606#issuecomment-1874168737
15:25:37 <xarick> it's not really 5000 stations per AI, it's 5000 vehicles of each type
15:26:12 <xarick> many vehicles repeat the same orders, go to the same stations, there's less stations than vehicles
15:26:17 <merni> Why do you think that a save with 15 AIs having more than 5000 vehicles of each type is a practical requirement
15:27:26 <xarick> i've also made sure i use shared orders
15:27:41 <xarick> for those vehicles with repeated orders, as that saves the order pool
15:28:00 <xarick> spares*
15:30:08 <xarick> when I don't use ships, I have enough stations for my 5000 rvs + 5000 aircraft
15:30:18 <xarick> and 15 companies
15:30:31 <xarick> I already tested it
15:31:37 <xarick> game slows down to a crawl, but at least it is possible to do without reaching the limit
15:33:05 <xarick> maybe in the future, cpus will be stronk enough to run my AIs at a proper pace ๐Ÿ™‚
15:37:57 <xarick> it's part of my other dream, to smooth out AI cpu spike usage ๐Ÿ˜ Try to find the sources of these stalls and... "solve it".
15:46:49 <andythenorth> are they stalls, or are they opcode limitations?
15:47:06 <andythenorth> and are they caused by the AI, or inherent to core OpenTTD?
15:47:41 <andythenorth> and if they are caused by the AI, is it due to Squirrel performance, which we might know much about empirically?
15:53:50 *** HerzogDeXtEr has joined #openttd
15:55:52 <xarick> at this scale, it's both core OpenTTD and the API
15:56:20 <xarick> too many vehicles for OpenTTD to handle
15:58:13 <_jgr_> You want to consider using longer but fewer trains, and larger capacity ships, road vehicles, etc
15:58:21 <peter1138[d]> Using the default vehicle limits?
15:59:02 <peter1138[d]> Everything you do seems to be "max out the numbers of everything, and then wonder why it's slow"
16:00:10 <DorpsGek> [OpenTTD/OpenTTD] 2TallTyler commented on pull request #11548: Fix #10511: Delay 'go to nearest depot' orders https://github.com/OpenTTD/OpenTTD/pull/11548#pullrequestreview-1800644033
16:01:23 <LordAro> _jgr_: ah, but that's not absolute worst possible case
16:01:27 <LordAro> therefore insufficient.
16:01:57 <Eddi|zuHause> "maybe in the future CPUs will be fast enough" is never a useful approach. because every increase in CPU performance will immediately be eaten up by more demanding algorithms.
16:02:49 <Eddi|zuHause> or as a student in bio-computing put it: "we just simulate one atom more, and the CPU is back on its knees"
16:04:32 <_jgr_> Single-core performance is already plateauing, you may be waiting a long time
16:07:20 <_jgr_> Memory access speeds/latencies are even worse than CPU speed in this regard
16:08:46 <Eddi|zuHause> that, too
16:27:47 *** Wormnest has quit IRC (Quit: Leaving)
16:28:03 <talltyler> _zephyris: I like this approach best, and agree that Frozen doesnโ€™t make sense anymore (the setting used to be โ€œCalendar progress speedโ€). Although I am leaning toward removing it from Worldgen entirely, so itโ€™s a moot point. ๐Ÿ™‚
16:29:36 <talltyler> Also, the Settings menu needs some reorganization, I thinkโ€ฆas a separate PR. Thereโ€™s lots of stuff arguably in the wrong category, and World Generation is the worst. Some of its contents canโ€™t actually be changed when starting a new game.
16:30:38 <talltyler> โ€œMinutes per yearโ€ needs a new category, essentially, maybe a Time submenu underneath Environment?
16:30:48 <_zephyris> Kinda, yeah.
16:31:06 <_zephyris> I agree I think. Plonk it in the worldgen menu for now, but looks like tabs are needed ๐Ÿ™‚
16:31:46 <talltyler> I was planning to remove it from worldgen menu?
16:31:48 <locosage> it can go into environment like cargodist does
16:31:49 <xarick> Even the code comments agree iterating vehicles is slow! <https://github.com/OpenTTD/OpenTTD/blob/master/src/station_gui.cpp#L544>
16:32:53 <_zephyris> talltyler: Oh, sorry, missed what you meant.
16:33:09 <_zephyris> Game speed can't be changed in a running game, right? While eg. cargodist can?
16:33:16 <_glx_> well the comment is about the assert IIRC
16:33:21 <_zephyris> I wouldn't put any setting that can only be applies to a new game in the settings
16:33:30 <_glx_> and those are disabled in stable release
16:33:33 <talltyler> Game speed can be changed at any time, timekeeping mode cannot
16:34:09 <_jgr_> How is that handled for scenarios?
16:34:19 <talltyler> Timekeeping mode will stay right under start date, but I am considering removing game speed from worldgen and having it only in Settings
16:34:43 <_zephyris> Ok, yeah, that seems reasonable.
16:34:52 <talltyler> _jgr_: Scenario Editor gets the same buttons as Worldgen, if thatโ€™s what youโ€™re asking ๐Ÿ™‚
16:35:02 <locosage> hm, but isn't there some dependency between time keeping mode and game speed?
16:35:26 <_jgr_> I was more thinking of "play scenario"
16:35:46 <talltyler> Yes, changing game speed is only possible in wallclock timekeeping mode. So in calendar mode, speed cannot be changed
16:36:06 <talltyler> The same is true for a scenario created in calendar modeโ€ฆspeed cannot be changed
16:37:16 <talltyler> It might be safe to change time mode in a new scenario, but players tend to rename save files to do magic in scenario editor and I donโ€™t know what edge cases that would produce
16:37:31 <talltyler> (Despite it being unsupported behavior)
16:37:43 <_jgr_> Is there any particular reason why it isn't possible to make it work during a game?
16:38:18 <locosage> I get why time mode can't be changed but that's actually very inconvenient...
16:39:00 <peter1138[d]> I don't get why time mode can't be changed :p
16:39:16 <locosage> would break all the stats I suppose
16:39:32 <locosage> you suddenly have 30 days a "month" instead of 28-31 etc
16:39:33 <_glx_> should be fine if there are no companies
16:39:38 <locosage> but maybe just let them break
16:39:52 <talltyler> https://discord.com/channels/142724111502802944/1008473233844097104/1170249203247751278
16:40:05 <talltyler> nielsm wrote a bit about it ^^
16:40:18 <peter1138[d]> Can it be explained in a one liner here?
16:40:30 <talltyler> Trying to write one now ๐Ÿ™‚
16:41:23 <_jgr_> I'd expect that the time taken to just make it work will be less than that taken dealing with users confused why it doesn't work
16:44:51 <_glx_> there's always the option to put a big red confirmation window and writing in game log
16:45:09 <_glx_> like newgrf change, don't report bugs
16:45:33 <_zephyris> The scenario editor only allows you to set _year_ anyway. If using the scenario editor then reset the date to 1st Jan for the savegame? Then it'd be safe to change calendar mode?
16:45:44 <locosage> _glx_: do a climate change while at it xd
16:46:05 <_glx_> climate used to be in cheat IIRC
16:46:12 <locosage> ik
16:46:26 <talltyler> I can't wrap my head around this right now
16:47:14 <_jgr_> It doesn't seem fundamentally more problematic than the existing date cheat
16:47:31 <peter1138[d]> Sorry, but this is kind of my "point". If the author can't explain it easily to other devs, how is a user meant to understand?
16:47:31 <locosage> oh, yeah, and cheat menu allows to change date as well
16:48:36 <_zephyris> current _year_
16:48:47 <_glx_> btw I don't expect players wanting to change mode more than once
16:49:30 <talltyler> The timekeeping modes start at different places (year 1 vs calendar year), tick at different rates, and affect cached stuff like service intervals, company graphs, and linkgraph updates. It's possible to shift those, but at risk of introducing bugs that will be hard to reproduce and diagnose.
16:50:52 <_glx_> it's easy to ignore them if the mode change is written in gamelog and people are warned before changing
16:51:46 <locosage> hm, yeah, date cheat avoids many issues by only changing the year
16:52:22 <locosage> though I wonder what happens with leap years xD
16:52:42 <_jgr_> Even if the date cheat allowed arbitrary dates, it wouldn't be much of a problem
16:52:48 <Eddi|zuHause> can't you now change calendar date independent from economy date, which would solve a majority of the issues?
16:53:23 <talltyler> In Wallclock mode, the date cheat only touches the calendar
16:53:38 <_zephyris> locosage: Date changes from 29th Feb to 1st Mar, ie. keeps the number of days since the start og the year
16:53:47 <talltyler> And the current date cheat is broken in all sorts of ways, like with graphs
16:53:50 <locosage> and on 31 dec?
16:54:09 <locosage> also does it run month tick?
16:54:22 <Eddi|zuHause> probably not
16:54:50 <_jgr_> Graphs and company finance are just nice to look at and don't directly affect anything
16:55:08 <_zephyris> locosage: Stays on 31st Dec, but in the new year
16:55:14 <_jgr_> They're not important enough to block changing the time mode
16:55:33 <_glx_> they eventually self correct after some times
16:59:01 <andythenorth> it would be socially easier to remove the limit in future than implement a limit later
16:59:09 <andythenorth> fewer pithforks
16:59:14 <andythenorth> pithforks? pitchforks
17:00:33 <talltyler> I allowed changing mode months ago in this process, but that commit is lost to the wind probably and I don't remember what it even contained
17:00:50 <locosage> talltyler: wait, I just realized, there is no daylength with calendar at all?
17:01:04 <talltyler> Yes, that's the entire point of Wallclock mode
17:01:06 <locosage> thats... awkward
17:02:19 <talltyler> How would you display town/industry production stats, company stats, graphs, subsidy deadlines, etc., if calendar time was very slow or frozen, and you didn't have wallclock units?
17:02:44 <talltyler> The Daylength implementation of years that last hours is untenable
17:02:54 <locosage> it's only a problem when it's very slow
17:02:58 <locosage> like 100x and slower
17:03:03 <jfs> how about storing a flag in savegames for the timekeeping mode, but let it be TRI-state: calendar, wallclock, and undecided.
17:03:03 <jfs> - loading a savegame with undecided mode converts to use calendar mode
17:03:03 <jfs> - loading a scenario into the editor keeps the mode unchanged
17:03:03 <jfs> - creating a new scenario sets the mode to undecided
17:03:03 <jfs> - changing the date in the editor when there is one or more companies gives a warning that this will reset the timekeeping mode of the game (asks the player to choose the new mode, while resetting the date to jan 1st) -- this might need to do a more thorough reset of various things
17:03:04 <jfs> - starting a new game from a scenario with zero existing companies lets the player choose mode
17:03:04 <jfs> - starting a new game from a scenario with undecided mode and one or more companies sets the game to calendar mode
17:03:56 <locosage> and requiring wallclock for gamespeed is kinda not even a daylength
17:04:04 <locosage> you have length but no day anymore xD
17:04:13 <jfs> that's why tyler calls in NotDaylength
17:04:30 <jfs> but it allows you to stretch and shrink the passage of calendar time
17:04:50 <locosage> I'd expect a lot of cofused players :p
17:05:34 <Eddi|zuHause> isn't the editor effectively wallclock mode anyway, but the date never progresses?
17:05:42 <jfs> it kind of is yes
17:05:57 <jfs> it runs the simulation with no passage of the calendar
17:06:54 <talltyler> Wallclock mode runs the economy clock though, which does a lot of work behind the scenes
17:07:44 <Eddi|zuHause> so editor also pauses most of the economy clock?
17:09:24 <talltyler> I don't think any of the timers tick in Scenario Editor
17:09:53 <talltyler> When you load a game and click on an industry to see last month's production, those last three months are simulated without any time passing
17:10:11 <_glx_> scenedit is kinda in frozen calendar
17:10:26 <talltyler> (this is from memory, I think it's three months... it's been a while since I looked into it)
17:11:29 <Eddi|zuHause> i think starting a new game runs about 3 months before the start date progresses
17:11:44 <talltyler> Anyway, I'm off to do Real Job things
17:12:38 <_jgr_> Eddi|zuHause: It doesn't "run" the game, it just fills in the history with sensible values
17:13:12 <Eddi|zuHause> well, it runs some number of ticks, to allow snowfall and stuff
17:13:50 <_jgr_> That's just the tile loop, it doesn't require any advancement of time
17:16:26 <Eddi|zuHause> i see
17:16:59 <Eddi|zuHause> all these special cases don't really make things easier :p
17:18:09 *** virtualrandomnumber has joined #openttd
17:23:05 *** virtualrandomnumber has quit IRC ()
17:48:05 <DorpsGek> [OpenTTD/OpenTTD] SamuXarick updated pull request #10548: Change: Groups cache vehicle lists https://github.com/OpenTTD/OpenTTD/pull/10548
17:52:25 <DorpsGek> [OpenTTD/OpenTTD] SamuXarick dismissed a review for pull request #11548: Fix #10511: Delay 'go to nearest depot' orders https://github.com/OpenTTD/OpenTTD/pull/11548#pullrequestreview-1794867550
17:52:28 <DorpsGek> [OpenTTD/OpenTTD] SamuXarick updated pull request #11548: Fix #10511: Delay 'go to nearest depot' orders https://github.com/OpenTTD/OpenTTD/pull/11548
17:55:10 <DorpsGek> [OpenTTD/OpenTTD] rubidium42 approved pull request #11670: Change: Limit total script ops that can be consumed by a list valuate https://github.com/OpenTTD/OpenTTD/pull/11670#pullrequestreview-1800799592
17:58:00 <DorpsGek> [OpenTTD/OpenTTD] glx22 commented on pull request #11548: Fix #10511: Delay 'go to nearest depot' orders https://github.com/OpenTTD/OpenTTD/pull/11548#pullrequestreview-1800802925
18:00:37 <DorpsGek> [OpenTTD/OpenTTD] rubidium42 updated pull request #11632: Fix: Missing word in conditional order comparator https://github.com/OpenTTD/OpenTTD/pull/11632
18:02:15 <DorpsGek> [OpenTTD/OpenTTD] glx22 merged pull request #11670: Change: Limit total script ops that can be consumed by a list valuate https://github.com/OpenTTD/OpenTTD/pull/11670
18:03:17 <xarick> no!!!
18:03:20 <xarick> ๐Ÿ™‚
18:03:44 <xarick> oh well, it was needed
18:04:51 <Rubidium> it's definitely a better stop-gap solution than nothing, but nothing/no-one prevents you from coming up with an improvement that does exactly what you like
18:04:58 <DorpsGek> [OpenTTD/OpenTTD] glx22 approved pull request #11632: Fix: Missing word in conditional order comparator https://github.com/OpenTTD/OpenTTD/pull/11632#pullrequestreview-1800811737
18:07:20 <_glx_> valuate still has an extra limit which is not yet added to constructor (the per call limit should be enough)
18:08:04 <xarick> upstream/master isn't being fetched for some reason
18:08:08 <DorpsGek> [OpenTTD/OpenTTD] PeterN merged pull request #11669: Fix: Autorenew failed message consumes arguments. https://github.com/OpenTTD/OpenTTD/pull/11669
18:08:21 <_glx_> but getting shorter list should help with valuate limit
18:08:42 <peter1138[d]> Time to switch VS Code from $work to $play.
18:08:52 <DorpsGek> [OpenTTD/OpenTTD] SamuXarick updated pull request #11548: Fix #10511: Delay 'go to nearest depot' orders https://github.com/OpenTTD/OpenTTD/pull/11548
18:09:16 <DorpsGek> [OpenTTD/OpenTTD] rubidium42 closed pull request #11387: Add: per-use customisable cargo list separators https://github.com/OpenTTD/OpenTTD/pull/11387
18:09:19 <DorpsGek> [OpenTTD/OpenTTD] rubidium42 commented on pull request #11387: Add: per-use customisable cargo list separators https://github.com/OpenTTD/OpenTTD/pull/11387#issuecomment-1874371031
18:10:10 <peter1138[d]> ^ agreed ... the stuff I nitpicked about isn't important, but some other languages do lists in "strange" ways...
18:12:46 <xarick> ah, it finally fetched
18:12:50 <xarick> took a while
18:18:19 <DorpsGek> [OpenTTD/OpenTTD] rubidium42 updated pull request #11648: Fix #11646: Non-thread safe shared buffer returned from GetLogPrefix(). https://github.com/OpenTTD/OpenTTD/pull/11648
18:19:03 <xarick> no glx, it needs to go back into the loop
18:19:06 <xarick> return UpdateOrderDest(v, order, conditional_depth + 1, pbs_look_ahead);
18:20:37 <_glx_> so break is fine
18:20:39 <xarick> it's the loop that sets dest_tile to 0
18:21:15 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain updated pull request #11639: Fix: race-conditions in GUI updates when downloading HTTP files https://github.com/OpenTTD/OpenTTD/pull/11639
18:23:19 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain updated pull request #11639: Fix: race-conditions in GUI updates when downloading HTTP files https://github.com/OpenTTD/OpenTTD/pull/11639
18:23:26 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain commented on pull request #11639: Fix: race-conditions in GUI updates when downloading HTTP files https://github.com/OpenTTD/OpenTTD/pull/11639#pullrequestreview-1800834198
18:27:59 <xarick> nevermind, it's the pathfinder
18:29:29 <DorpsGek> [OpenTTD/OpenTTD] 2TallTyler merged pull request #11632: Fix: Missing word in conditional order comparator https://github.com/OpenTTD/OpenTTD/pull/11632
18:37:59 <peter1138[d]> Hmm, window stacking?
18:40:59 <DorpsGek> [OpenTTD/OpenTTD] eints-sync[bot] pushed 1 commits to master https://github.com/OpenTTD/OpenTTD/commit/344bdafb5300a3b8d070825b6635e433e9c63311
18:41:00 <DorpsGek> - Update: Translations from eints (by translators)
19:08:38 <DorpsGek> [OpenTTD/OpenTTD] rubidium42 updated pull request #11648: Fix #11646: Non-thread safe shared buffer returned from GetLogPrefix(). https://github.com/OpenTTD/OpenTTD/pull/11648
19:14:43 <Rubidium> have we already found the enigmatic eints admin?
19:15:09 <truebrain> did anyone wrote a patch for eints to add that to the GitHub backend? ๐Ÿ™‚
19:15:53 <Rubidium> @seen anyone
19:16:01 <Rubidium> I guess not :(
19:17:33 <truebrain> then sadly, that is also your answer ๐Ÿ™‚
19:22:00 <truebrain> might be quickest to write a small script to do it via the API, honestly
19:24:03 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191824244179472535/image.png?ex=65a6d7d2&is=659462d2&hm=b50074e27746a4ad49fa2262835ad17e2cb27bedb63e171183699d340ceecf72&
19:24:03 <peter1138[d]> What a monster.
19:25:01 <peter1138[d]> And not a practical use in sight... just testing behaviours.
19:25:13 *** Flygon has quit IRC (Quit: A toaster's basically a soldering iron designed to toast bread)
19:27:38 <DorpsGek> [OpenTTD/OpenTTD] rubidium42 commented on pull request #11665: Fix: replace the cedilla characters with comma ones for Romanian https://github.com/OpenTTD/OpenTTD/pull/11665#issuecomment-1874451867
19:27:42 <peter1138[d]> Huh, shading almost works.
19:31:12 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191826043120652401/Screencast_from_2024-01-02_19-30-34.webm?ex=65a6d97f&is=6594647f&hm=ce7ed8805053e807e4a0506a757dfa4ddf050796f4121f0b0b00b84a83b95efb&
19:31:12 <peter1138[d]> Bizarre
19:31:50 <peter1138[d]> Almost even works but... there's a flash of everything in the wrong place ๐Ÿ˜„
19:32:36 <peter1138[d]> Anyway, these windows aren't intended to be dockable (although...), but I wanted stacking to work better than just two windows completely overlapping.
19:35:13 <locosage> peter1138[d]: it's a nice approach in principle as openttd desperately needs some way to deal with window spam
19:35:22 <locosage> but how to make it actually usable is a big freaking question
19:36:11 <peter1138[d]> It's awkward because windows have resize steps, and minimum sizes can be quite large.
19:37:08 <peter1138[d]> This tries to allocate vertical space equally, but if a window is greedy that leaves not much left for another one.
19:38:00 <peter1138[d]> When docked, windows can be resizes horizontally which is a problem for windows on the right hand side as the resize button is at the edge.
19:38:24 <peter1138[d]> So perhaps modern "pointer just on the edge of the window" resizing...
19:40:13 <locosage> and that's just technical issues
19:41:10 <locosage> there is a whole other usability issue that set of windows that you'd like to keep on borders isn't constant and how to keep them opening in the right place is unclear
19:41:43 <locosage> i.e. when building station it can be type/class selector, when buiding objects object selectors, when buying vehicles buy menu
19:42:17 <locosage> and then there are windows that player wants to be docked atm like keeping town window in cb or some vehicle windows
19:42:42 <locosage> or company goals or league table or network client list...
19:48:45 <xarick> I found a "maybe not a bug"
19:49:26 <xarick> when a train visits a station, last_station_visited is updated for the front engine
19:50:48 <xarick> if the train has another engine in the consist and I now I swap it to the front, last_station_visited is invalid, it wasn't updaded, but it's still the same vehicle as a whole
19:52:13 <xarick> should it update last_station_visited for the whole train, or ... what
19:53:11 <peter1138[d]> What problem does last_station_visited being different cause?
19:53:29 <xarick> possibly linkgraph stuff, not really sure
19:53:47 <xarick> yeah... I don't know
19:54:27 <xarick> cargo packets
19:54:45 *** nielsm has quit IRC (Ping timeout: 480 seconds)
19:54:49 <xarick> hmm looking for all references for last_station_visited
19:55:07 <xarick> cargo payment seems to access it
19:55:55 <peter1138[d]> Okay.
19:56:12 <peter1138[d]> Does cargo payment access it when it is in this state?
19:56:47 <peter1138[d]> As far as I know, cargo payment only happens when in a station, and in that case you cannot shuffle the consist around.
19:57:00 <xarick> linkgraph stuff access it
19:58:25 <xarick> implicit orders
19:58:31 <peter1138[d]> When does linkgraph stuff access it in this state?
19:58:57 <xarick> I found it in RefreshLinks
19:59:21 <xarick> absolutely no idea what LinkGraph does
19:59:25 <peter1138[d]> Are you sure?
19:59:28 <xarick> yes
20:00:57 <xarick> refresh.cpp line 235
20:02:15 <xarick> oh, LinkRefresher
20:02:19 <xarick> ok, close name
20:03:39 <peter1138[d]> Can last_station_visited be in this state at that point?
20:05:15 <xarick> seems to require the vehicle full loading
20:05:26 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191834659760390245/image.png?ex=65a6e186&is=65946c86&hm=bb2b46c3d0e6c48949234264d06ea030bafc3f6525c99208b1dff50c36fa2a28&
20:05:26 <peter1138[d]> Biggest issue with docking the news history is you don't see much ๐Ÿ™‚
20:05:28 <xarick> that's only when it's in a station, hmm
20:05:55 <xarick> and when it visits a station, last_station_visited is the first thing that's updaded (I think)
20:06:48 <xarick> I'm unfamiliar with this code
20:08:13 <peter1138[d]> Hmm, window docking kind of needs to store information about the order in which windows should be stacked -- and that's for windows which don't exist.
20:09:07 <xarick> Pre-Destructor writes to it
20:09:13 <peter1138[d]> Perhaps a sorted list of window_class/window_number which persists even if those windows aren't open.
20:12:05 <xarick> how do in visual studio, get a breakpoint that breaks when a variable is writen to?
20:12:37 <xarick> I wanna detect where last_station_visited is written
20:14:01 <xarick> ah
20:14:05 <xarick> break when value changes, found it
20:15:27 <xarick> oh, not quite what I wanted ๐Ÿ˜ฆ
20:18:55 <peter1138[d]> Hmm, if I ReInit() when switching between docked and undocked, I can change window layout...
20:21:26 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191838685172342804/Screencast_from_2024-01-02_20-20-47.webm?ex=65a6e545&is=65947045&hm=19dc70bd313833205313fec0cf659f5688fdf131cb734250075accf5cfac1a98&
20:21:26 <peter1138[d]> I dunno WHY you can have the object builder open at the same time as the station builder...
20:22:20 <peter1138[d]> andythenorth: tiling window manager when?
20:23:47 <peter1138[d]> Missing an email client.
20:25:54 <peter1138[d]> WindowLabels...
20:27:33 <peter1138[d]> There's definitely some missing handling, either here, or in vanilla.
20:27:54 <rau117> peter1138[d]: To build โ€œlarge aesthetic scenesโ€, it can be convenient to not_switch attention between station and object window
20:27:58 <peter1138[d]> Opening the object builder closes the station builder, but opening the station builder does not close the object builder.
20:28:08 <peter1138[d]> What does that mean?
20:28:16 <peter1138[d]> "not_switch attention"
20:32:08 <rau117> peter1138[d]: ah... looks like a translation error. Iโ€™m about when building โ€œbeautiful stations,โ€ all the scenery is visible at the same time, and you donโ€™t need to switch station/object tools
20:32:51 <peter1138[d]> Well, no.
20:33:26 <peter1138[d]> The already annoying long and unwieldy lists, of both classes and types, will be even more unwield
20:34:09 <peter1138[d]> And they have different place characteristics. (always 2 orientions vs 1, 2, or 4 orientations)
20:35:38 <peter1138[d]> 1-7x1-7/drag-n-drop, versus 1x1 (which allows dnd), or1x2/2x1/2x2
20:36:08 <peter1138[d]> Oh, it's whatever size the object says. I guess that bit isn't that different.
20:37:53 <peter1138[d]> Okay, I probably overthought that.
20:38:25 <peter1138[d]> Yeah, so the object builder and station builder are already semi-mutually exclusive
20:38:34 <xarick> ToolbarVehicleClick has been optimized!
20:38:51 <xarick> much amazing, very fast
20:39:00 <peter1138[d]> And given the SIZE of the windows at the moment, when you have lots of objects/stations loaded, that seems unfeasible to do.
20:39:09 <andythenorth> peter1138[d]: Customisable personal homepage?
20:40:23 <peter1138[d]> Maybe they play at 4k resolution with 1x interface scale...
20:41:06 <andythenorth> โ€œStation is just a flag on an object tileโ€? ๐Ÿ˜›
20:42:28 <rau117> peter1138[d]: On the same 21:9 - this width is not very convenient to use for construction, but nice for a vertical interface with a bunch of buttons
20:43:15 <peter1138[d]> Super wise.
20:43:16 <peter1138[d]> ..
20:43:20 <peter1138[d]> Super wide.
20:47:15 <DorpsGek> [OpenTTD/OpenTTD] SamuXarick updated pull request #10548: Change: Groups cache vehicle lists https://github.com/OpenTTD/OpenTTD/pull/10548
20:47:52 <peter1138[d]> https://cdn.discordapp.com/attachments/1008473233844097104/1191845338911350784/image.png?ex=65a6eb78&is=65947678&hm=979670f8b6261278b8bed147528bbe41b2505bca2b370e3de898104eed6426b9&
20:47:52 <peter1138[d]> I guess I could fit a lot on.
20:48:38 *** orudge has quit IRC (Remote host closed the connection)
20:48:39 *** orudge has joined #openttd
20:49:03 <peter1138[d]> While this is a diversion, I see so many "questions".
21:04:34 <andythenorth> the first I see is "I will need to buy a bigger screen"
21:05:16 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191849717768912986/image.png?ex=65a6ef8c&is=65947a8c&hm=cf8a877062779641331611400f647b0b7ecefa669e9ad7332f976ec33e92089f&
21:05:16 <andythenorth> probably need more anyway, to fit all these trains on
21:05:27 <DorpsGek> [OpenTTD/OpenTTD] rubidium42 approved pull request #11639: Fix: race-conditions in GUI updates when downloading HTTP files https://github.com/OpenTTD/OpenTTD/pull/11639#pullrequestreview-1801092485
21:05:30 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain merged pull request #11639: Fix: race-conditions in GUI updates when downloading HTTP files https://github.com/OpenTTD/OpenTTD/pull/11639
21:05:33 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain closed issue #11636: [Bug]: Various thread safety issues with use of libcurl for HTTP downloads https://github.com/OpenTTD/OpenTTD/issues/11636
21:06:25 <xarick> time for some mental gymnastics. CheckTrainsLengths iterates all trains. v->first can be a free wagon, if the first one is not outside a depot, the length checks are not run for any attached vehicle. Is it safe to assume I can iterate from group vehicle lists?
21:08:45 <peter1138[d]> Why not iterate the depot vehicle list?
21:08:48 <rau117> andythenorth: #130 ?
21:09:40 <xarick> what else can v->first be?
21:14:08 <peter1138[d]> Hmm, these windows should be equal size, but one has 2 rows more than the other ๐Ÿ˜ฎ
21:21:13 <andythenorth> back to trying to make these consists work ๐Ÿ˜›
21:21:43 <Eddi|zuHause> xarick: what if a train gets removed from a list by selling its engine, thus creating a free wagon chain?
21:23:03 <andythenorth> integer maths, I divide the number of vehicles by 6, what do I get? ๐Ÿ˜›
21:23:10 <andythenorth> 14 / 6 =
21:23:12 <andythenorth> ?
21:23:14 <Eddi|zuHause> 2
21:23:18 <andythenorth> pff
21:23:21 <andythenorth> that won't work then
21:23:23 <Eddi|zuHause> rounded down
21:23:28 <andythenorth> yup
21:23:38 <Eddi|zuHause> 4/6=0, 10/6=1
21:23:51 <Eddi|zuHause> why wouldn't that work?
21:23:51 <andythenorth> I am trying to work this out on paper
21:24:10 <xarick> the free wagon chain is in the depot, the length check is performed when u->track != TRACK_BIT_DEPOT.
21:24:24 <Eddi|zuHause> 0,1 -> special case, 2+ -> generic case
21:24:27 <xarick> u being v->first
21:24:56 <andythenorth> it might work, but it wasn't the approach I was thinking of
21:25:01 <andythenorth> given consist length n
21:25:17 <andythenorth> I want to find how many blocks of 6 fit into (n - 6)
21:25:41 <andythenorth> or (n -12), not sure which
21:27:00 <locosage> (n - 6) / 6
21:27:03 <Eddi|zuHause> n-12 might overflow, though
21:27:18 <xarick> let's see what happens if i sell an engine
21:27:27 <xarick> save game, and load, what will happen
21:28:57 <Eddi|zuHause> although that might help you. if you check (n-12)ยง12 you can now split the special cases positiv/negative
21:29:24 <Eddi|zuHause> but negative % semantics is weird. i'd avoid it.
21:29:54 <andythenorth> sometimes it would be nice if we could print temp storage to screen eh
21:30:00 <andythenorth> nvm
21:30:57 <locosage> newgrf debugging is very lacking
21:31:05 <Eddi|zuHause> i don't even know if NFO/NML supports signed semantics for % operator
21:31:36 <xarick> https://cdn.discordapp.com/attachments/1008473233844097104/1191856344316260402/image.png?ex=65a6f5b8&is=659480b8&hm=206c7462d980c333989fa4dfd2cfd5292f49c03e9acb4c3e4afa8d42d215a984&
21:31:36 <xarick> tested! the free wagon keeps track of its track (pun)
21:32:03 <xarick> bottom left part of the screen
21:32:13 <locosage> nfo has signed % though I've no idea what it does
21:32:19 <locosage> probably just C %
21:38:52 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191858174035230851/image.png?ex=65a6f76c&is=6594826c&hm=d8a4ed3ba64d3bf0a0979093e775b5b67157b1045226a7630bfcbbd462014adf&
21:38:52 <andythenorth> ok this is promising
21:39:07 <andythenorth> trains 130 and 131 are broken in a way that suggests the split is working
21:40:02 <xarick> CmdBuildRailWagon iterates all vehicles when searching for a train to attach to! THE HORROR!
21:40:20 <andythenorth> don't tell Xarick what my grf does with iterating vehicles on every sprite redraw
21:41:27 <xarick> it may be possible to scope the vehicle search to just the depot tile
21:41:47 <xarick> to avoid iterating 1 million vehicles to find one to attach the wagon to
21:42:21 <xarick> my group vehicle cache can't help here
21:44:20 <Eddi|zuHause> andythenorth: so 130/131 now need the STORE_TEMP(count+6)
21:44:53 <andythenorth> why is + not -?
21:44:58 <andythenorth> I might miss something ๐Ÿ™‚
21:45:04 <Eddi|zuHause> doesn't matter
21:45:49 <andythenorth> no I think it does ๐Ÿ™‚
21:45:49 <Eddi|zuHause> because as long as count>6, (count+6)%12 = (count-6)%12
21:46:04 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191859986616299550/image.png?ex=65a6f91c&is=6594841c&hm=b669bad7f67c7dd712155f056f1ad36e15d6df194cb6c3588de7c97f23d400eb&
21:46:04 <andythenorth> this suggests it matters ๐Ÿ™‚
21:46:24 <andythenorth> I can see why
21:47:16 <andythenorth> ok it's now counting the blocks of 6 correctly
21:47:16 <Eddi|zuHause> you only need the STORE_TEMP if count/6 is odd
21:47:18 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191860293962309853/image.png?ex=65a6f965&is=65948465&hm=9ffff6f24537f03fa1008a2939489f37ec2c03952da6aa03ddf3843d9f3d19fb&
21:47:32 <andythenorth> just need to modify the the offset for trailing remainder
21:54:53 <peter1138[d]> So `if (w->resize.step_height > 1) dy -= dy % (int)w->resize.step_height;` does not work properly for me when dy is negative.
21:55:10 <peter1138[d]> Or rather, it works as it's written, but it's not quite what I want it to do ๐Ÿ™‚
21:56:39 <peter1138[d]> `-10 % 6 = -4` and thus `-10 - -4 = -6`. Which is correct but I need -12 ๐Ÿ™‚
22:02:59 <Eddi|zuHause> like i said, negative % semantics is weird...
22:03:26 <peter1138[d]> Did you say that? ๐Ÿ˜„
22:03:41 <Eddi|zuHause> like 30 minutes ago :p
22:04:17 <peter1138[d]> Oh you were talking about signed %, and the number 6... completely independently. lol
22:04:52 <DorpsGek> [OpenTTD/OpenTTD] SamuXarick updated pull request #10548: Change: Groups cache vehicle lists https://github.com/OpenTTD/OpenTTD/pull/10548
22:10:42 <andythenorth> ๐Ÿ˜›
22:12:33 <peter1138[d]> Oops, I was looking for a screwdriver to tighten a nipple.
22:16:35 <Eddi|zuHause> coincidence...
22:19:35 <andythenorth> ugh
22:20:04 <andythenorth> integer maths, what's 8 / 6?
22:21:05 <andythenorth> or to be more complete: what's `6 * ((8 / 6) - 1)`
22:26:01 <_glx_> 1
22:26:31 <_glx_> and the result is 0
22:26:33 <peter1138[d]> 6 * ((8 / 6) - 1 = 0
22:26:49 <peter1138[d]> Oh dear. It was not one broken spoke. It was two.
22:27:01 <peter1138[d]> I should've fixed this a month ago, but...
22:27:35 <andythenorth> nobody died?
22:27:49 <peter1138[d]> Not yet.
22:28:11 <peter1138[d]> Since the last time, I learned a trick to stop the nipple getting lost inside the double-wall rim.
22:28:45 <peter1138[d]> Huh. Shading docked windows now works too.
22:29:18 <peter1138[d]> We just need some design guide that says windows must be multiple of x wide so they all line up :p
22:29:26 <DorpsGek> [OpenTTD/OpenTTD] SamuXarick updated pull request #10548: Change: Groups cache vehicle lists https://github.com/OpenTTD/OpenTTD/pull/10548
22:29:28 <_zephyris> https://cdn.discordapp.com/attachments/1008473233844097104/1191870907287883897/OpenTTD-Mono-10px-aliased.png?ex=65a70348&is=65948e48&hm=129ae380af80f87080b33c5d7fe1444a0c05e7b11b14f2f4aed96c22a27fec81&
22:29:28 <_zephyris> https://cdn.discordapp.com/attachments/1008473233844097104/1191870907615035442/OpenTTD-Mono-40px-anti-aliased.png?ex=65a70348&is=65948e48&hm=95c60c08e5d0e342967bfad7270f9790f7ac162df2a968bacd31a1a31dfe43f8&
22:30:06 <peter1138[d]> Fancy. Is it 'just' OpenTTD-Sans but mono-space?
22:30:13 <_zephyris> Pretty much
22:30:25 <peter1138[d]> I guess some characters are not. Like `l`
22:31:14 <_zephyris> Yeah, some classic mono tricks for `i`, `l`, `j`. General squishing for `M`, `m`, `W`, `w`. etc. etc.
22:32:42 <_zephyris> Currency symbols in monospace 7px width wasn't quite as painful as for the small font, but close...
22:36:38 <andythenorth> well
22:36:40 <andythenorth> https://github.com/andythenorth/iron-horse/blob/1b4350ad1a39e5722640f7f70c4455d360fbaa3b/src/templates/procedures_rulesets.pynml#L361
22:36:43 <andythenorth> doesn't work ๐Ÿ™‚
22:36:59 <andythenorth> I think L361 is the problem, but it might be something else
22:37:34 <peter1138[d]> "This isn't all that much code..." -> "Just one more edge-case..." -> "Oh christ I've written a 1000 LOC..."
22:38:01 <andythenorth> pls send me your newsletter
22:38:17 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191873126557028362/image.png?ex=65a70559&is=65949059&hm=6adfde71c68ed2a653cf56891d1a7802f09fbb400341b92678e14771adcc6111&
22:38:17 <andythenorth> oof, the blocks of 6 work, the remainder blocks do not
22:40:51 <Eddi|zuHause> andythenorth: code?
22:40:59 <andythenorth> in the github link
22:41:45 <andythenorth> obviously there will be a failure of logic ๐Ÿ™‚
22:42:34 <andythenorth> `switch_graphics_railcar_ruleset_6_unit_sets_bar` is being reached, I can change the value it stores, and get differently broken results ๐Ÿ˜›
22:43:04 <andythenorth> I think the issue is switch_graphics_railcar_ruleset_6_unit_sets_less_than_12_remaining
22:43:38 <andythenorth> yeah that's wrong, it should be using length of consist, not position
22:44:59 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191874813619339395/image.png?ex=65a706eb&is=659491eb&hm=508074b3b886c6d40abf580ee0c4a8f08339a6007b9bfeeb58af4f6683d238dc&
22:44:59 <andythenorth> there we go ๐Ÿ™‚
22:45:02 <andythenorth> thanks Eddi et al
22:45:09 <andythenorth> emperorjake: ^^
22:45:35 <andythenorth> still some edge cases
22:46:06 <andythenorth> fails with consists < 6
22:46:16 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191875134475223111/image.png?ex=65a70738&is=65949238&hm=8c7372c8fcbf169d174618faa4aa65dd378376b8151407c0aa417be2a1d49e69&
22:48:28 <_zephyris> https://cdn.discordapp.com/attachments/1008473233844097104/1191875687452250162/image.png?ex=65a707bb&is=659492bb&hm=7d8ff35d1e4cc6bea582e552cd6d5dac74ccd9d546fc1177e45afc03cd5f9015&
22:48:28 <_zephyris> Looks quite nice TBH. https://github.com/zephyris/openttd-ttf/releases/tag/0.2
22:49:32 <_zephyris> Well, not as nice as andythenorth's pixels, but quite nice
22:50:15 <andythenorth> I'm getting smacked by integer maths somewhere ๐Ÿ™‚
22:51:25 <Eddi|zuHause> integer maths is sometimes more complicated than real(sic) maths
22:52:35 <andythenorth> am I getting a -1?
22:52:42 <andythenorth> so that I get -6 as the offset?
22:53:05 <andythenorth> `6 * ((LOAD_TEMP(${temp_storage_ids.num_vehs_in_vehid_chain_multiple_ids}) / 6) - 1),`
22:53:17 <andythenorth> will have that effect for num_vehs < 6?
22:53:25 <Eddi|zuHause> that can be -1 for very short trains, yes
22:53:58 <andythenorth> hmm
22:54:01 <andythenorth> can I change the rule?
22:54:05 <andythenorth> or do I just special case < 6
22:54:06 <andythenorth> ?
22:54:31 *** Wormnest has joined #openttd
22:56:58 <peter1138[d]> andythenorth: What if I want it reversed, so the shorter parts are at the front? ๐Ÿ˜„
22:57:15 <Eddi|zuHause> what's the -1 for anyway?
22:57:49 <andythenorth> if there are n blocks of 6 in the consist (and a remainder)
22:57:59 <andythenorth> I want n - 1 blocks of 6, then special rules
22:58:42 <andythenorth> peter1138[d]: compile the grf with your own rules ๐Ÿ˜›
22:58:52 <andythenorth> or...subtypes?
22:59:15 <andythenorth> ok fixed it, with a ternary check that I wish to never see again
22:59:17 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191878409597485187/image.png?ex=65a70a44&is=65949544&hm=1baa719b8cdde8af59443a5618d254d309112444d97b026df6532dcc01117b67&
22:59:35 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191878486055460904/image.png?ex=65a70a57&is=65949557&hm=70e4a6999cf272a4620d2fa397b3bd39fe9e20e254602b2d1dd6916db9fe3557&
22:59:41 <xarick> what's the vehicle hash for...
22:59:45 <xarick> viewport?
22:59:48 <andythenorth> goes it set my editor to openttd font?
23:00:18 <andythenorth> well that's pleasing
23:00:31 <andythenorth> sometimes these rabbit holes seem futile after all the rabbits are dead
23:00:37 <andythenorth> but this one is quite satisfying ๐Ÿ˜„
23:01:04 <talltyler> Poor rabbits ๐Ÿ˜ฆ
23:01:23 <peter1138[d]> Do you need persistent storage for it yet?
23:01:48 <andythenorth> I do not
23:01:59 <andythenorth> although if Xarick ever examines why this grf is so slow...
23:03:15 <xarick> i examine scripts, i don't know newgrf code
23:03:17 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191879416108810370/image.png?ex=65a70b34&is=65949634&hm=4e021750e9c22689edaecec56a15a1cd33c8b5e158b21382dafd734628475238&
23:03:17 <andythenorth> works across variants ๐Ÿ˜›
23:04:11 <xarick> CallVehicleTicks has a Vehicle iteration... the major, the king, the one!... can my group lists can't help it in any way ๐Ÿ˜ฆ
23:04:21 <andythenorth> oh these are articulated, so you can't flip them to mess up my rules ๐Ÿ˜ฆ
23:04:32 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191879732883640327/image.png?ex=65a70b80&is=65949680&hm=6a92e76ae0efbc7669e525a6dd10df42b72daf765ffb923a21d10e4334f371eb&
23:04:32 <andythenorth> the single-unit slower versions can do this
23:04:40 <andythenorth> train 154 is all wrong
23:05:30 <_zephyris> https://cdn.discordapp.com/attachments/1008473233844097104/1191879973586354206/image.png?ex=65a70bb9&is=659496b9&hm=88af84ce3b3796796e5d58f41ab3a8ba6c0525203903cee873ed533262e2d822&
23:05:30 <_zephyris> andythenorth: It's not the _worst_ thing I've ever seen... But I wouldn't recommend it!
23:05:43 <andythenorth> very BBC
23:05:56 <andythenorth> https://cdn.discordapp.com/attachments/1008473233844097104/1191880085918208090/image.png?ex=65a70bd4&is=659496d4&hm=333fa6a33628a2b3e4b29e69bf4cbcfaa28e0408b168d09acba0ac63079dc777&
23:05:56 <andythenorth> emperorjake: also do we want this single trailing unit prevented?
23:06:04 <andythenorth> I mean...it's totally realistic, but eh
23:07:15 <andythenorth> ok sleep
23:08:56 <peter1138[d]> Prevent it, yes. Because it needs a different paint job.
23:09:50 <andythenorth> network southeast?
23:10:00 <andythenorth> more pixels needed
23:10:48 <peter1138[d]> Well we have 2x and 4x...
23:11:18 <andythenorth> special easter egg, one train at 4x zoom
23:11:21 <andythenorth> the rest at 1x
23:14:01 <xarick> CheckClickOnVehicle iterates all vehicles! my disappointment is immeasurable.
23:14:13 <xarick> and my day is ruined
23:14:51 <xarick> clicking on a pixel
23:14:57 <andythenorth> never look at grf
23:15:03 <andythenorth> it will ruin months
23:19:07 <xarick> there must be a reason for doing it the way it is
23:19:33 <xarick> what do I know
23:20:14 <peter1138[d]> That's a bit weird because there is a vehicle hash...
23:22:05 <peter1138[d]> With VehicleFromTileHash the search would be much smaller?
23:23:00 <peter1138[d]> Hmm, but aircraft are high up...
23:23:58 <_jgr_> You'd have to use _vehicle_viewport_hash instead of _vehicle_tile_hash
23:26:04 <peter1138[d]> Yeah I knew there was another one, there's just no general search functions against that.
23:26:18 <peter1138[d]> So I assume JGRPP already has this sorted. I know there's a ton of hash changes.
23:26:30 <peter1138[d]> Anyway. It's not a performance issue afaik.
23:26:48 <_jgr_> CheckClickOnVehicle doesn't show up in valgrind traces so I'd never bothered looking at it
23:28:15 *** keikoz has quit IRC (Ping timeout: 480 seconds)
23:30:46 <peter1138[d]> 6ms, in a debug build, to click on a vehicle in Wentbourne.
23:33:05 <DorpsGek> [OpenTTD/OpenTTD] SamuXarick updated pull request #10548: Change: Groups cache vehicle lists https://github.com/OpenTTD/OpenTTD/pull/10548
23:33:15 <xarick> I'm off to bed. cyas goodnight