IRC logs for #openttd on OFTC at 2018-10-06
            
00:00:24 <Samu> ok, let me try
00:03:32 *** chomwitt has joined #openttd
00:07:00 <Samu> ugh, i dont think it's gonna work
00:08:17 <Samu> STR_REPLACE_ALL_AIRCRAFT_TYPES = 0xBD3
00:08:23 <Samu> @calc 0xBD3
00:08:23 <DorpsGek> Samu: 3027
00:08:29 <Samu> nooo, should be 0
00:09:55 <nielsm> are the strings in order in the translation file?
00:10:16 <nielsm> because you can just offset them with + or - in the code based on the first then
00:11:29 <Samu> yes
00:11:33 <Samu> they are in order
00:11:51 <Samu> https://github.com/OpenTTD/OpenTTD/compare/master...SamuXarick:autoreplace-aircraft-type-dropdown#diff-29f4ff9371a58379f5491e1cfa6a9d64
00:13:57 *** Wacko1976 has quit IRC
00:15:59 <LordAro> Samu: ...why did you expect it to be 0?
00:16:03 <LordAro> why does it matter?
00:18:07 <Samu> the StringID 3027 should be case 0, 3028 -> 1, 3029 -> 2, 3030 -> 3, 3031 -> 4
00:18:17 *** nielsm has quit IRC
00:18:54 <LordAro> right, so use the first to offset them all
00:19:09 <LordAro> it's quite commonly done - you can see the "must be in this order" comments in the lang file
00:19:46 <Samu> i really need the value to be 0
00:19:50 <LordAro> "...need to be in this order"
00:19:56 <Samu> and the string really needs to be what it is
00:20:03 <Samu> i'm confused
00:20:44 <LordAro> sel_air_type - STR_REPLACE_ALL_AIRCRAFT_TYPES
00:20:50 <LordAro> 0..4
00:21:33 <Samu> sel_air_type ranges from 0 to 4
00:21:51 *** hph^ has quit IRC
00:21:52 <Samu> 0 - 3027 = -3027
00:21:53 <Samu> sounds wrong
00:22:03 <Samu> case -3027 :(
00:23:08 <LordAro> instead of using 0..4, use STR_REPLACE_ALL_AIRCRAFT_TYPES..STR_REPLACE_LARGE_AEROPLANE
00:23:09 *** GroovyNoodle has quit IRC
00:23:38 <Samu> ah
00:23:50 <Samu> got it, let me try
00:25:43 <Samu> switch (this->sel_air_type + STR_REPLACE_ALL_AIRCRAFT_TYPES) {
00:25:50 <Samu> I think you meant a +
00:27:15 <Samu> yep, it works
00:27:22 <Samu> thx
00:27:27 <LordAro> i was expecting sel_air_type to have the 3028+ values
00:27:31 <LordAro> but yeah, that works too
00:28:23 <Samu> it's a selector
00:28:34 <Samu> uhm from a dropdown
00:28:37 <Samu> lel
00:28:53 <Samu> i should stop stating the obvious
00:29:15 <Samu> selection 0 -> all aircraft types
00:30:57 <Samu> the reason I can't start from 3027
00:31:04 <Samu> is because this->GetWidget<NWidgetCore>(WID_RV_AIRCRAFT_TYPE_DROPDOWN)->widget_data = _autoreplace_aircraft_type_dropdown[sel_air_type];
00:31:18 <Samu> I use it inside [sel_air_type]
00:32:20 <LordAro> there are a few ways of doing it, if it works, that's probabl yfine
00:36:20 <Samu> now, the issue about point B
00:38:41 <Samu> using pikka savegame :p
00:38:42 <Samu> https://imgur.com/Kv0ZGiU
00:38:54 <Samu> so i tried to replace helicopter with a airbus
00:39:12 <Samu> the heli does visit the hangar, and silently fails to be replaced
00:39:20 <Samu> no message is displayed
00:39:26 <Samu> what do you think about that
00:39:42 *** hph^ has joined #openttd
00:39:46 <LordAro> hrm
00:40:11 <LordAro> isn't there a message when vehicles fail to replace for other reasons (money, etc) ?
00:40:38 <LordAro> consistency is probably more important
00:40:40 <Samu> there would be, if the hangar was of an airport
00:41:09 <Samu> in this case, the airbus is not even available in helistation hangar
00:41:54 <Samu> let me try with airport
00:44:14 <Samu> https://imgur.com/3OPjn9c
00:45:01 <Samu> the vehicle that can't go to all stations is not the helicopter, but the airbus
00:45:09 <Samu> kinda confusing
00:48:02 <Samu> maybe instead of vehicle, it could say engine
00:48:23 <Samu> or I dunno
00:48:49 *** frosch123 has quit IRC
00:50:22 <Samu> or go back to what it was before
00:50:30 <Samu> helicopters only replaced with helicopters
00:50:57 <Samu> but that would defeat the point of this patch :(
00:51:07 <Samu> pretty much
00:53:26 *** synchris has quit IRC
00:56:08 *** Progman has quit IRC
01:16:38 *** Wolf01 has quit IRC
01:20:32 *** iSoSyS has quit IRC
01:45:22 *** hph^ has quit IRC
02:03:08 *** hph^ has joined #openttd
02:17:43 *** Compu has joined #openttd
02:32:43 *** guru3 has joined #openttd
02:35:31 *** guru3_ has quit IRC
02:36:16 *** urdh_ has joined #openttd
02:36:21 *** urdh has quit IRC
02:36:21 *** urdh_ is now known as urdh
02:39:14 *** chomwitt has quit IRC
02:47:58 *** Flygon has joined #openttd
02:52:24 *** HerzogDeXtEr1 has quit IRC
02:54:38 <Samu> The nightly database backup is currently running, and the site is unavailable as a result.
02:54:41 <Samu> bah terrible timing
03:09:37 *** hph^ has quit IRC
03:26:35 *** hph^ has joined #openttd
04:20:26 <Samu> what the heck is this regression thing?
04:32:32 *** hph^ has quit IRC
04:43:58 *** Samu has quit IRC
04:54:26 *** Mazur has quit IRC
05:03:03 *** Mazur has joined #openttd
05:10:27 *** haudrauf has quit IRC
05:12:07 *** haudrauf has joined #openttd
05:12:47 *** glx has quit IRC
07:15:00 *** sla_ro|master has joined #openttd
07:21:01 *** yellyFish has quit IRC
09:08:14 *** Mahjong has quit IRC
09:10:17 *** Mahjong has joined #openttd
09:15:34 *** andythenorth has joined #openttd
09:23:48 <andythenorth> o/
09:48:00 *** Progman has joined #openttd
09:54:42 *** sla_ro|master has quit IRC
10:22:10 *** nielsm has joined #openttd
10:58:43 *** Progman has quit IRC
10:58:49 *** Arveen has joined #openttd
11:03:01 *** Arveen2 has quit IRC
11:28:02 *** Arveen has quit IRC
11:31:10 *** Samu has joined #openttd
11:51:50 <Samu> hi
11:51:58 <LordAro> o/
11:52:28 <LordAro> Samu: are you still wondering what the regression tests are?
11:53:17 <Samu> yes, a bit
11:53:34 <Samu> i can't visualize it :(
11:53:41 <Samu> can only suspect what it does
11:53:55 <LordAro> essentially it's an AI that runs a load of stuff to check that the game is performing as expected
11:54:11 <LordAro> things like construction & associated costs
11:54:13 <Samu> I suspected it built a lock
11:55:04 <LordAro> the AI (and reference files) are in bin/ai/regression
11:55:27 *** sla_ro|master has joined #openttd
11:56:57 <Samu> @calc 465070 - 461320
11:56:57 <DorpsGek> Samu: 3750
12:00:33 <Samu> https://github.com/OpenTTD/OpenTTD/blob/master/bin/ai/regression/tst_regression/main.nut#L879
12:00:42 <Samu> yeah, it built a lock
12:01:01 <Samu> in some unknown map, dont even know
12:01:19 <LordAro> i imagine you can just load the save up
12:01:30 <LordAro> it'll be in that folder somewhere
12:02:14 <Samu> empty.sav?
12:02:23 <LordAro> maybe
12:03:37 <Samu> it's empty! :p
12:04:13 <LordAro> well, the AI hasn't run on it :p
12:04:27 <LordAro> i imagine it doesn't save the game when it runs
12:05:10 <Samu> ah, i can scroll to the tile in question
12:06:01 <Samu> https://imgur.com/XJKi2Uo
12:06:25 <Samu> so that's the cost of clearing land + simulated cost of building canal
12:06:42 <Samu> which is 3750? was expecting 5000
12:06:50 <Samu> unless easy costs
12:07:30 <Samu> Construction costs: Low
12:07:31 <Samu> ok
12:07:31 <andythenorth> peter1138: should I go try this? o_O https://www.youtube.com/watch?v=c7a8XjeDRGg
12:08:19 <Samu> 3750, confirmed
12:08:24 <Samu> so it's fine
12:08:29 <Samu> working as I intended
12:09:40 <Samu> https://imgur.com/o5DIpjH
12:10:07 <Samu> then it removes lock
12:10:49 <Samu> simulates cost of removing canal
12:10:55 <Samu> which is also 3750
12:11:40 <Samu> @calc 459675 - 452175
12:11:40 <DorpsGek> Samu: 7500
12:11:54 <Samu> @calc 3750 + 3750
12:11:54 <DorpsGek> Samu: 7500
12:11:57 <Samu> correct
12:12:20 <Samu> my edits to results are fine then
12:15:56 *** frosch123 has joined #openttd
12:21:52 <TrueBrain> awh, DorpsGek still doesn't rejoin channels? BOOOO
12:22:06 <andythenorth> yo TrueBrain
12:22:45 <LordAro> an TrueBrain
12:22:53 <LordAro> it got netsplitted, i think
12:23:01 <LordAro> probably thinks it's still connected
12:23:04 <TrueBrain> yup
12:25:21 <TrueBrain> meh, why does PyUp make N commits, instead of just one .. this looks silly
12:25:44 <LordAro> multiple PRs too, if the old one is still there
12:25:58 <TrueBrain> yeah ... which is a: IF YOU WERE TOO LAZY TO ACCEPT ME, I WILL DO THIS AGAIN OKAY
12:26:03 <TrueBrain> I think it is a good nutch to say: YOU FAILED
12:26:16 <LordAro> yup
12:27:54 <TrueBrain> meh, enough changes that I cannot simply accept the PR .. bah, I need more free time :(
12:28:09 <LordAro> :(
12:29:24 <TrueBrain> wow, indeed, the per commit stuff is very .. euh .. verbose
12:31:15 <TrueBrain> ah, because he does it one by one to a branch in the repository
12:31:19 <TrueBrain> yeah .. that is annoying as ...
12:34:53 *** DorpsGek_II has joined #openttd
12:34:53 <DorpsGek_II> [OpenTTD/DorpsGek-irc] pyup-bot merged pull request #9: Initial Update https://github.com/OpenTTD/DorpsGek-irc/pull/9
12:34:56 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain pushed 1 commits to master:
12:34:57 <DorpsGek_II> - Initial Update (#9) Update: version update of all dependencies * Update aiohttp from 3.3.2 to 3.4.4 * Update attrs from 18.1.0 to 18.2.0 * Update irc3 from 1.1.0 to 1.1.1 * Update multidict from 4.3.1 to 4.4.2 (by pyup-bot)
12:34:58 <DorpsGek_II> https://github.com/OpenTTD/DorpsGek-irc/commit/c7f2ab30793a
12:35:25 <TrueBrain> oops .. that commit message was not what I wanted it to be :D
12:35:54 *** DorpsGek_II has quit IRC
12:36:11 <LordAro> the author, or something else? there's an issue for the former :)
12:36:36 <TrueBrain> no, I forgot how GitHub worked, so now the commit message itself is just weird ... and not by specs :D
12:36:49 <LordAro> hehe
12:53:03 *** DorpsGek_II has joined #openttd
12:53:03 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain pushed 2 commits to master:
12:53:03 <DorpsGek_II> - Add: create pyup.io config file (#8) (by pyup-bot)
12:53:03 <DorpsGek_II> - Update: version update of all dependencies (#9) * Update aiohttp from 3.3.2 to 3.4.4 * Update attrs from 18.1.0 to 18.2.0 * Update irc3 from 1.1.0 to 1.1.1 * Update multidict from 4.3.1 to 4.4.2 (by pyup-bot)
12:53:04 <DorpsGek_II> https://github.com/OpenTTD/DorpsGek-irc/compare/c7f2ab30793a...4a9660406ceb
12:53:40 *** DorpsGek_II has quit IRC
12:53:56 <TrueBrain> I might have forced-pushed some things :D
12:54:10 <LordAro> haha
12:58:16 <TrueBrain> right, lets see about the bugs you lovely guys created for me :)
12:59:07 *** DorpsGek_II_ has joined #openttd
12:59:07 <DorpsGek_II_> [TrueBrain/Testing] TrueBrain opened pull request #2: Testing https://github.com/TrueBrain/Testing/pull/2
12:59:16 <TrueBrain> oops, that should not go to this channel
12:59:17 <TrueBrain> sorry
13:04:13 *** DorpsGek_II_ has quit IRC
13:07:21 *** DorpsGek_II has joined #openttd
13:07:21 <DorpsGek_II> [OpenTTD/DorpsGek-irc] LordAro commented on issue #7: PRQ merge messages are duplicated https://github.com/OpenTTD/DorpsGek-irc/issues/7#issuecomment-427565365
13:07:51 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain pushed 2 commits to pyup-scheduled-update-2018-10-01:
13:07:51 <DorpsGek_II> - Update: version update of all dependencies (#8) * Update aiohttp from 3.3.2 to 3.4.4 * Update attrs from 18.1.0 to 18.2.0 * Update cryptography from 2.3 to 2.3.1 * Update gidgethub from 2.5.0.post1 to 3.0.0 * Update multidict from 4.3.1 to 4.4.2 * Update pycparser from 2.18 to 2.19 (by pyup-bot)
13:07:51 <DorpsGek_II> - Remove: now unneeded hacks for gidgethub With version 3.0.0 of gidgethub, those hacks are now upstream. (by TrueBrain)
13:07:51 <DorpsGek_II> https://github.com/OpenTTD/DorpsGek-github/compare/5e277fa55e8b...32ebe6b7da15
13:08:00 <DorpsGek_II> [OpenTTD/DorpsGek-github] pyup-bot updated pull request #8: Scheduled monthly dependency update for October https://github.com/OpenTTD/DorpsGek-github/pull/8
13:08:18 <TrueBrain> this is so unreadable :D
13:08:42 <LordAro> i already mentioned the url shortener :p
13:08:48 <TrueBrain> guess all non-master stuff should not be notified
13:08:55 <LordAro> but most of that is the commit message
13:09:01 <TrueBrain> feel free to implement the URL shortener :D
13:11:22 <DorpsGek_II> [OpenTTD/DorpsGek-github] pyup-bot merged pull request #8: Scheduled monthly dependency update for October https://github.com/OpenTTD/DorpsGek-github/pull/8
13:11:22 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain pushed 2 commits to master:
13:11:22 <DorpsGek_II> - Update: version update of all dependencies (#8) * Update aiohttp from 3.3.2 to 3.4.4 * Update attrs from 18.1.0 to 18.2.0 * Update cryptography from 2.3 to 2.3.1 * Update gidgethub from 2.5.0.post1 to 3.0.0 * Update multidict from 4.3.1 to 4.4.2 * Update pycparser from 2.18 to 2.19 (by pyup-bot)
13:11:24 <DorpsGek_II> - Remove: now unneeded hacks for gidgethub With version 3.0.0 of gidgethub, those hacks are now upstream. (by TrueBrain)
13:11:24 <DorpsGek_II> https://github.com/OpenTTD/DorpsGek-github/compare/718fab3cafda...757a6c32c739
13:11:37 <TrueBrain> the wrong user is funny :)
13:12:18 <TrueBrain> okay, so the commit message should change to only the first line
13:12:20 <TrueBrain> not anything after that
13:12:51 <TrueBrain> how does that work out for the translation commits
13:13:13 <LordAro> some would argue better than it previously did :p
13:14:11 <DorpsGek_II> [OpenTTD/DorpsGek-runner] pyup-bot merged pull request #7: Scheduled monthly dependency update for October https://github.com/OpenTTD/DorpsGek-runner/pull/7
13:14:12 <DorpsGek_II> [OpenTTD/DorpsGek-runner] TrueBrain pushed 1 commits to master:
13:14:12 <DorpsGek_II> - Update: version update of all dependencies (#7) * Update aiohttp from 3.3.2 to 3.4.4 * Update attrs from 18.1.0 to 18.2.0 * Update multidict from 4.3.1 to 4.4.2 (by pyup-bot)
13:14:12 <DorpsGek_II> https://github.com/OpenTTD/DorpsGek-runner/commit/11aedf3c8206
13:14:53 <TrueBrain> as they are not announced? :P
13:16:06 <TrueBrain> why are they not .. .hmmmm
13:18:36 <TrueBrain> I really do not know why they are not announced ..
13:20:51 <andythenorth> oof
13:22:35 * andythenorth brain ache from sprite generation
13:29:03 *** HerzogDeXtEr has joined #openttd
13:31:18 <LordAro> TrueBrain: i'm actually putting together a url shortener thing
13:31:25 <LordAro> it's not actually too difficult
13:31:37 <LordAro> aiohttp's documentation is reasonably nice
13:32:16 <TrueBrain> \o/
13:32:36 <TrueBrain> and I believe the github url shortner was also pretty nice
13:37:30 *** Wolf01 has joined #openttd
13:37:35 <Wolf01> o/
13:37:53 <Wolf01> I forgot to run mirc :P
13:39:04 <Wolf01> andythenorth: you asked what didn't work with rebase, I don't know, I'm just not used to it and with merge I feel I can do things better
13:40:07 <DorpsGek_II> [OpenTTD/DorpsGek-irc] LordAro opened pull request #10: Add: Shortened GitHub urls https://github.com/OpenTTD/DorpsGek-irc/pull/10
13:40:35 <LordAro> completely untested, of course
13:40:40 <LordAro> but that's what the CI is for!
13:42:38 <Wolf01> https://www.youtube.com/watch?v=ZWQ0591PAxM mmmmh sprite composition, 50MB grf to 20KB! Fuck the 16GB of ram (+3GB video ones) 640KB are enough for everyone
13:43:28 <TrueBrain> LordAro: I love how easy coroutines make adding this stuff in :)
13:44:22 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain opened pull request #9: Add: allow filtering for which branch push notifications work https://github.com/OpenTTD/DorpsGek-github/pull/9
13:44:31 <TrueBrain> right, that commit should reduce the pyup spam
13:46:55 <DorpsGek_II> [OpenTTD/DorpsGek-irc] LordAro updated pull request #10: Add: Shortened GitHub urls https://github.com/OpenTTD/DorpsGek-irc/pull/10
13:48:35 <TrueBrain> guess I should test it first :)
13:48:41 <LordAro> probably
13:50:04 <TrueBrain> doesnt
13:50:05 <TrueBrain> even
13:50:07 <TrueBrain> run
13:50:32 <Wolf01> :D
13:50:34 <LordAro> :D
13:50:46 <LordAro> but it passed CI!
13:51:01 <TrueBrain> yeah .. guess CI doesnt run the code :P
13:51:08 <TrueBrain> (I think it only builds the docker and runs flake tbh)
13:51:34 <LordAro> did i make too many assumptions about what a ws is?
13:51:53 <TrueBrain> no, it is a syntax error :)
13:51:57 <TrueBrain> "async with" is not valid Python :)
13:51:58 <LordAro> nice.
13:52:14 <TrueBrain> you didnt make the function a coroutine :)
13:52:14 <LordAro> wait, what
13:52:17 <LordAro> oh
13:52:32 <LordAro> tbf, this is the first time i've ever tried to use python coroutines :p
13:52:37 <LordAro> s/use/write my own/
13:52:58 <TrueBrain> async in front of the function
13:53:01 <TrueBrain> await all usages
13:53:06 <TrueBrain> the last return in your function can be removed
13:53:11 <TrueBrain> (as it will never be executed)
13:53:34 <LordAro> so when you say how easy coroutines make this stuff... :p
13:53:50 <TrueBrain> I mean you at least have to read the "n00b guide to coroutines" :P
13:54:40 <DorpsGek_II> [OpenTTD/DorpsGek-irc] LordAro updated pull request #10: Add: Shortened GitHub urls https://github.com/OpenTTD/DorpsGek-irc/pull/10
13:54:55 <TrueBrain> ws.get doesn't exist either
13:55:00 <TrueBrain> ws is the websocket
13:55:08 <TrueBrain> so yeah, you cannot make another call with that
13:55:18 <LordAro> damn
13:55:29 <TrueBrain> you can however just use aiohttp to make a new one
13:55:29 <LordAro> ok, i retract my previous comments about aiohttp's documentation :p
13:55:59 <TrueBrain> well, this is not really aiohttp to blame .. 'ws' is just the WebSocket object
13:56:10 <TrueBrain> I don't pass the session object along
13:57:06 <LordAro> i did wonder whether i was following the code correctly
13:57:07 <LordAro> ah well
13:57:20 <TrueBrain> ws .. websocket .. guess it somewhat makes sense :D
13:59:08 <DorpsGek_II> [OpenTTD/DorpsGek-irc] LordAro updated pull request #10: Add: Shortened GitHub urls https://github.com/OpenTTD/DorpsGek-irc/pull/10
13:59:11 <LordAro> take 4...
14:00:20 <TrueBrain> no clue how smart aiohttp is with session recycling .. I hope sufficient :D
14:00:55 <LordAro> i can't imagine it's expensive
14:02:13 <TrueBrain> response code is 200 it seems?
14:02:30 <TrueBrain> did you test the function at least?
14:02:51 <TrueBrain> its returning 200
14:02:57 <LordAro> curl returns a 201...
14:03:05 <TrueBrain> (python3; import url; await shorten(...)
14:03:46 <TrueBrain> Sorry yo, that's an invalid URL
14:03:55 <TrueBrain> is what it is yelling
14:04:47 <TrueBrain> the CI is failing ... it shouldnt pass this :D
14:05:16 <TrueBrain> it continues if flake8 fails :D
14:05:17 <TrueBrain> hahaha
14:05:20 <TrueBrain> oops :D
14:08:05 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain opened pull request #11: Fix: fail the CI if flake8 fails https://github.com/OpenTTD/DorpsGek-irc/pull/11
14:09:38 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain updated pull request #11: Fix: fail the CI if flake8 fails https://github.com/OpenTTD/DorpsGek-irc/pull/11
14:09:39 <TrueBrain> good, that works now :)
14:09:55 <LordAro> :)
14:11:00 <Eddi|zuHause> what's better than "the CI apparently doesn't run the code"? "the CI runs the code, but ignores the result" :p
14:11:04 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain opened pull request #10: Fix: fail the CI if flake8 fails https://github.com/OpenTTD/DorpsGek-github/pull/10
14:12:22 <DorpsGek_II> [OpenTTD/DorpsGek-runner] TrueBrain opened pull request #8: Fix: fail the CI if flake8 fails https://github.com/OpenTTD/DorpsGek-runner/pull/8
14:12:35 <TrueBrain> think of it this way: at least it was consistent
14:13:08 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain merged pull request #11: Fix: fail the CI if flake8 fails https://github.com/OpenTTD/DorpsGek-irc/pull/11
14:13:09 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain pushed 1 commits to master:
14:13:09 <DorpsGek_II> - Fix: fail the CI if flake8 fails (#11) Without 'set -e', an non-zero exit code from flake8 is simply ignored and test.sh continues. With 'set -e' it abort on the first non-zero exit code. (by TrueBrain)
14:13:10 <DorpsGek_II> https://github.com/OpenTTD/DorpsGek-irc/commit/95048f7a2680
14:13:41 <TrueBrain> yeah, I think we just have to mute the 'push' if there was a 'pr merge' of the same
14:13:46 <TrueBrain> it doesnt add any value
14:14:06 *** DorpsGek_II has quit IRC
14:14:14 <Eddi|zuHause> can there be pushes without a PR?
14:14:18 <TrueBrain> yes
14:14:21 <TrueBrain> translator for example
14:15:46 *** DorpsGek_II_ has joined #openttd
14:15:46 <DorpsGek_II_> [OpenTTD/DorpsGek-github] TrueBrain updated pull request #10: Fix: fail the CI if flake8 fails https://github.com/OpenTTD/DorpsGek-github/pull/10
14:16:54 *** DorpsGek_II_ is now known as DorpsGek_II
14:19:27 <TrueBrain> can any of you make a pull request for https://github.com/TrueBrain/Testing ?
14:19:34 <TrueBrain> I need another username to test this username bug :D
14:20:00 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain merged pull request #10: Fix: fail the CI if flake8 fails https://github.com/OpenTTD/DorpsGek-github/pull/10
14:20:00 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain pushed 1 commits to master:
14:20:00 <DorpsGek_II> - Fix: fail the CI if flake8 fails (#10) Without 'set -e', an non-zero exit code from flake8 is simply ignored and test.sh continues. With 'set -e' it abort on the first non-zero exit code. (by TrueBrain)
14:20:02 <DorpsGek_II> https://github.com/OpenTTD/DorpsGek-github/commit/029ca44d5048
14:20:47 <nielsm> made one
14:21:15 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain updated pull request #9: Add: allow filtering for which branch push notifications work https://github.com/OpenTTD/DorpsGek-github/pull/9
14:21:22 <DorpsGek_II> [OpenTTD/DorpsGek-irc] LordAro updated pull request #10: Add: Shortened GitHub urls https://github.com/OpenTTD/DorpsGek-irc/pull/10
14:21:28 <LordAro> LOUD NOISES
14:22:00 <TrueBrain> tnx nielsm :)
14:24:00 <TrueBrain> LordAro: that PR still doesnt work btw
14:24:49 <DorpsGek_II> [OpenTTD/DorpsGek-runner] TrueBrain merged pull request #8: Fix: fail the CI if flake8 fails https://github.com/OpenTTD/DorpsGek-runner/pull/8
14:24:49 <DorpsGek_II> [OpenTTD/DorpsGek-runner] TrueBrain pushed 1 commits to master:
14:24:49 <DorpsGek_II> - Fix: fail the CI if flake8 fails (#8) Without 'set -e', an non-zero exit code from flake8 is simply ignored and test.sh continues. With 'set -e' it abort on the first non-zero exit code. (by TrueBrain)
14:24:50 <DorpsGek_II> https://github.com/OpenTTD/DorpsGek-runner/commit/fd0f5c49a5d0
14:25:04 <TrueBrain> and tnx for the reviews :)
14:27:13 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain opened issue #11: Wrong user in most actions https://github.com/OpenTTD/DorpsGek-github/issues/11
14:27:46 <LordAro> TrueBrain: fine i'll actually install aiohttp locally
14:27:59 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain commented on issue #5: Wrong data used for merge and close notifications https://github.com/OpenTTD/DorpsGek-irc/issues/5#issuecomment-427569865
14:27:59 <DorpsGek_II> [OpenTTD/DorpsGek-irc] glx22 closed issue #5: Wrong data used for merge and close notifications https://github.com/OpenTTD/DorpsGek-irc/issues/5
14:28:19 <LordAro> ^ nicely demonstrating the error :p
14:29:19 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain opened pull request #12: Fix #11: always use the 'sender' to notify who made the change https://github.com/OpenTTD/DorpsGek-github/pull/12
14:30:43 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain merged pull request #9: Add: allow filtering for which branch push notifications work https://github.com/OpenTTD/DorpsGek-github/pull/9
14:30:43 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain pushed 1 commits to master:
14:30:43 <DorpsGek_II> - Add: allow filtering for which branch push notifications work (#9) Pyup for example creates a branch in the repository. Pushes to these branches don't have to be announced. (by TrueBrain)
14:30:44 <DorpsGek_II> https://github.com/OpenTTD/DorpsGek-github/commit/7d589bdb6da5
14:31:21 <LordAro> TrueBrain: incidentally, "SyntaxError: 'await' outside function"
14:31:44 <TrueBrain> sorry?
14:32:00 <TrueBrain> so okay, 'sender' seems to be mostly the correct one, unless an App or something triggered the event
14:32:08 <TrueBrain> so we will have to experiment with it a bit, see how we like it
14:33:41 <LordAro> TrueBrain: i can't run "await url.shorten(foobar)", results in that error
14:33:53 <LordAro> and google is being unhelpful in finding a way around it
14:34:18 <TrueBrain> owh, shit, ofc :(
14:34:24 <TrueBrain> you need an asyncio context
14:34:26 <TrueBrain> euuhhh
14:34:42 <TrueBrain> this is a tiny bit more difficult
14:35:15 <TrueBrain> I believe: asyncio.run(func())
14:35:37 <LordAro> that's it, thanks
14:35:40 <TrueBrain> \o/
14:36:05 <TrueBrain> meh, the push payload doesn't indicate if it was triggered by a PR merge
14:37:40 <LordAro> mm, i didn't think so
14:38:04 <TrueBrain> in all my tests, the push always came after the PR
14:38:10 <TrueBrain> but not sure if that is a guarantee or something
14:41:22 <DorpsGek_II> [OpenTTD/DorpsGek-irc] LordAro updated pull request #10: Add: Shortened GitHub urls https://github.com/OpenTTD/DorpsGek-irc/pull/10
14:41:23 <LordAro> ok, it actually works now
14:41:25 <LordAro> promise
14:41:55 <TrueBrain> :D
14:42:39 <TrueBrain> and so it does :P
14:43:19 <LordAro> bad quotes? where did those come from?
14:43:52 <DorpsGek_II> [OpenTTD/DorpsGek-irc] LordAro updated pull request #10: Add: Shortened GitHub urls https://github.com/OpenTTD/DorpsGek-irc/pull/10
14:43:52 <TrueBrain> post vs get, lol
14:43:56 <LordAro> shhhh
14:44:10 <TrueBrain> you moved a ' out of a ", so yeah :)
14:44:11 <LordAro> i did not read curl's documentation closely enough
14:45:25 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain opened issue #13: Pull Request merge and push give duplicated information https://github.com/OpenTTD/DorpsGek-github/issues/13
14:45:38 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain commented on issue #7: PRQ merge messages are duplicated https://github.com/OpenTTD/DorpsGek-irc/issues/7#issuecomment-427570868
14:45:38 <DorpsGek_II> [OpenTTD/DorpsGek-irc] LordAro closed issue #7: PRQ merge messages are duplicated https://github.com/OpenTTD/DorpsGek-irc/issues/7
14:46:35 <LordAro> i wonder if it might be easier to solve from the irc side
14:46:53 <LordAro> given that can cache messages (assuming push comes after merge)
14:47:11 <Eddi|zuHause> user on "ticket closed" message still wrong
14:47:18 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain opened pull request #14: Fix #13: deduplicate pull request merge and push information https://github.com/OpenTTD/DorpsGek-github/pull/14
14:47:27 <TrueBrain> Eddi|zuHause: yes, it requires a review ;)
14:47:46 <TrueBrain> LordAro: the line between IRC and Github is a bit thin :) But I try to have most of the logic in Github for now
14:48:08 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain merged pull request #12: Fix #11: always use the 'sender' to notify who made the change https://github.com/OpenTTD/DorpsGek-github/pull/12
14:48:09 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain closed issue #11: Wrong user in most actions https://github.com/OpenTTD/DorpsGek-github/issues/11
14:49:37 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain merged pull request #10: Add: Shortened GitHub urls https://github.com/OpenTTD/DorpsGek-irc/pull/10
14:50:13 <Eddi|zuHause> i believe glx once made a ticket about the wrong user thing, but i don't know which repo he made the ticket against
14:50:27 <LordAro> Eddi|zuHause: scroll further up
14:50:35 *** andythenorth has quit IRC
14:50:38 *** DorpsGek_II has quit IRC
14:50:39 <LordAro> 13:27
14:50:44 <LordAro> though it is a little tricky to see
14:50:52 <TrueBrain> so much spam! :P
14:50:57 *** KouDy has quit IRC
14:52:38 <Eddi|zuHause> to be frank, it's a little intransparent which repo actually does what
14:52:54 *** KouDy has joined #openttd
14:53:28 <TrueBrain> the IRC repo only puts the notification on IRC
14:53:35 <TrueBrain> it can easily be replaced with Slack, Discord, etc
14:53:41 <TrueBrain> so there is no logic in there, just a gateway
14:54:06 <LordAro> i do wonder if it would be better just to merge the repos
14:54:10 <TrueBrain> the bugs like: wrong sender, etc, would be true for any of them
14:54:25 <TrueBrain> if there would be a Slack or Discord version, it would make a lot more sense :)
14:54:58 <TrueBrain> (and I still hope some day OpenTTD moves away from IRC :P)
14:55:09 <LordAro> heathen
14:55:16 <TrueBrain> LordAro: I cannot find documentation what merge_commit_sha is/does
14:55:22 <TrueBrain> I was hoping it would be what I thought it was
14:55:33 <Eddi|zuHause> i'm going to postulate that IRC will outlive those two things :p
14:55:57 <LordAro> TrueBrain: sounds like Truebrain/Testing needs some use :p
14:56:12 <TrueBrain> LordAro: fair point
14:56:17 *** DorpsGek_II has joined #openttd
14:56:19 <DorpsGek_II> [OpenTTD/DorpsGek-github] LordAro commented on pull request #14: Fix #13: deduplicate pull request merge and push information https://git.io/fx39J
14:56:23 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain commented on issue #7: PRQ merge messages are duplicated https://git.io/fx39U
14:56:24 *** iSoSyS has joined #openttd
14:56:27 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain commented on pull request #14: Fix #13: deduplicate pull request merge and push information https://git.io/fx39c
14:56:34 <TrueBrain> something got stuck in a queue :D
14:56:49 <LordAro> dem short urls
14:58:06 <Eddi|zuHause> "Banksy painting spontaneously self-destructs after auction"... from "the outside" that sounds incredibly funny :p
14:58:52 <TrueBrain> LordAro: tested both squash and rebase; does what I expect it to do :)
14:59:12 <LordAro> nice.
14:59:29 <LordAro> let's give it a go then
14:59:37 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain commented on pull request #14: Fix #13: deduplicate pull request merge and push information https://git.io/fx39z
14:59:45 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain merged pull request #14: Fix #13: deduplicate pull request merge and push information https://git.io/fx39g
14:59:46 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain closed issue #13: Pull Request merge and push give duplicated information https://git.io/fx392
14:59:57 <TrueBrain> it is a lot better tbfh :P
15:00:50 <LordAro> wait, why has it stopped reporting pushes on the DorpsGek-* repos?
15:00:57 <LordAro> before you merged that
15:00:59 <TrueBrain> because it was being deployed :)
15:01:14 <TrueBrain> so after the pull request, it started to deploy, and the push even is never received :P
15:01:17 <TrueBrain> ITS CHEATING :D
15:01:38 <LordAro> and it does that silently, because it's not the irc component that was restarted
15:01:42 <LordAro> nice
15:01:43 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain commented on issue #15: No message for reviews https://git.io/fx39w
15:01:56 <TrueBrain> yup
15:02:16 <TrueBrain> and because it is rare enough, I did not write code to capture the events and play them whenthe bot comes back online
15:02:19 <TrueBrain> read: I was too lazy
15:02:27 <LordAro> :)
15:07:42 <TrueBrain> sorry for the spam nielsm :) But it is appreciated :D
15:14:31 <LordAro> at what point do we start looking at OTTD again? :p
15:15:45 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain opened pull request #16: Add #15: support notifications about pull-request-review https://git.io/fx3HU
15:15:46 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain opened pull request #12: Add: handle the new pull_request_review actions https://git.io/fx3HT
15:17:28 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain opened pull request #17: Fix: don't shorten 'push' URLs https://git.io/fx3Hq
15:20:05 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain opened pull request #13: Fix: ignore activity on pyup- branches https://git.io/fx3Hn
15:20:10 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain opened pull request #18: Fix: ignore activity on pyup- branches https://git.io/fx3HC
15:20:58 <DorpsGek_II> [OpenTTD/DorpsGek-runner] TrueBrain opened pull request #9: Dorpsgek pyup https://git.io/fx3H4
15:21:13 <DorpsGek_II> [OpenTTD/DorpsGek-runner] TrueBrain updated pull request #9: Dorpsgek pyup https://git.io/fx3H4
15:21:55 <TrueBrain> LordAro: it is a regex, yes; that is why it is a *?
15:22:12 <LordAro> but that just matches any number of -
15:22:49 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain updated pull request #12: Add: handle the new pull_request_review actions https://git.io/fx3HT
15:22:55 <LordAro> should be .*
15:22:58 <TrueBrain> hmm
15:23:00 <TrueBrain> good point :D
15:23:20 <DorpsGek_II> [OpenTTD/DorpsGek-runner] TrueBrain updated pull request #9: Fix: ignore activity on pyup- branches https://git.io/fx3H4
15:23:21 <LordAro> i imagine it wouldn't make a difference in practice, it's not matching the whole line, but...
15:23:31 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain updated pull request #18: Fix: ignore activity on pyup- branches https://git.io/fx3HC
15:23:47 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain updated pull request #13: Fix: ignore activity on pyup- branches https://git.io/fx3Hn
15:25:04 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain opened issue #14: After net-split, the bot doesn't rejoin channels https://git.io/fx3Ho
15:28:04 <DorpsGek_II> [OpenTTD/OpenTTD] TrueBrain closed issue #6913: Request: support Discord's Rich Presence API https://git.io/fx3Hy
15:28:05 <DorpsGek_II> [OpenTTD/OpenTTD] TrueBrain commented on issue #6913: Request: support Discord's Rich Presence API https://git.io/fx3HS
15:28:18 <TrueBrain> closed + commented have similar issues I see :)
15:28:50 <DorpsGek_II> [OpenTTD/OpenTTD] TrueBrain commented on issue #6916: Re-implement building binaries via compile farm https://git.io/fx3H9
15:29:05 *** gelignite has joined #openttd
15:29:40 <TrueBrain> that Discord issue :) Hihi
15:30:35 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain merged pull request #12: Add: handle the new pull_request_review actions https://git.io/fx3HT
15:31:14 *** sim-al2 has quit IRC
15:31:30 *** DorpsGek_II has quit IRC
15:32:52 *** DorpsGek_II has joined #openttd
15:32:53 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain merged pull request #16: Add #15: support notifications about pull-request-review https://git.io/fx3HU
15:33:00 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain closed issue #15: No message for reviews https://git.io/fx3Qe
15:35:20 <DorpsGek_II> [OpenTTD/DorpsGek-runner] TrueBrain merged pull request #9: Fix: ignore activity on pyup- branches https://git.io/fx3H4
15:35:26 <TrueBrain> HA! No more push spam :)
15:35:47 <DorpsGek_II> [OpenTTD/DorpsGek-irc] TrueBrain merged pull request #13: Fix: ignore activity on pyup- branches https://git.io/fx3Hn
15:36:00 <TrueBrain> tnx for all the reviews LordAro :)
15:36:23 *** DorpsGek_II has quit IRC
15:36:53 *** DorpsGek_II has joined #openttd
15:36:54 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain merged pull request #18: Fix: ignore activity on pyup- branches https://git.io/fx3HC
15:37:50 <TrueBrain> owh, one more left to review :P
15:37:57 <TrueBrain> means we can see if that also works now :D
15:58:02 <DorpsGek_II> [OpenTTD/DorpsGek-github] LordAro approved pull request #17: Fix: don't shorten 'push' URLs https://git.io/fx3Qh
15:58:07 <TrueBrain> \o/
15:58:13 <LordAro> \o/
15:58:19 <DorpsGek_II> [OpenTTD/DorpsGek-github] TrueBrain merged pull request #17: Fix: don't shorten 'push' URLs https://git.io/fx3Hq
15:59:50 <TrueBrain> and look, even the names are correct :D
16:00:19 <LordAro> well, the PR was also yours
16:00:28 <LordAro> haven't fully checked that yet ;)
16:00:30 <TrueBrain> I meant the approval :)
16:00:40 <LordAro> yeah, that works
16:00:52 <LordAro> don't know about the merge messages though :p
16:01:12 <TrueBrain> time will tell :D
16:07:38 *** Progman has joined #openttd
16:30:49 *** Wormnest has joined #openttd
16:33:37 <Eddi|zuHause> about the discord thing, i think the counter-suggestion was to try that via an admin port library
16:34:20 <TrueBrain> go for it! :)
16:34:22 <TrueBrain> :D
16:34:47 <Eddi|zuHause> i don't think so :p
16:35:26 <TrueBrain> exactly ;)
16:36:55 *** Gja has joined #openttd
16:38:21 *** haudrauf has quit IRC
16:39:19 *** haudrauf has joined #openttd
16:44:35 <Samu> a patch for helping AI's https://www.tt-forums.net/viewtopic.php?f=33&t=75216&hilit=patch
16:44:39 <Samu> i'm undecided
16:44:54 <Samu> juanjo approach or my approach?
16:45:30 <Eddi|zuHause> so, what's actually the holdup with nightly builds?
16:46:07 <Samu> my approach feels incomplete in regards to industry tiles on water
16:46:12 <Samu> it isn't done
16:46:30 <LordAro> Eddi|zuHause: windows, i think
16:47:34 <Samu> juanjo approach is kinda... too global, some situations could be excused
16:52:07 <Samu> oh, right, object tiles on water, i haven't done that either
16:55:26 <Samu> removing stuff shouldn't care if a ship is nearby
16:55:56 <Samu> changing rail signals shouldn't care if a ship is nearby
16:56:07 <Samu> hmm, i'm torn apart
16:56:09 <LordAro> you wouldn't have thought so
16:57:01 <Samu> i think that's what juanjo's approach is doing, it's too global
17:15:28 <Samu> juanjo's approach has one advantage, it's much simpler, it's just that it can't be applied inside EnsureNoVehicleOnGround
17:16:17 <Samu> must think
17:17:32 <Samu> calls all ships and see if they're coming into "collision" route towards the tile we're working on
17:18:25 <Samu> my approach is too manual, case by case
17:19:17 <Samu> doesn't call all ships, it only checks for ships on the nearby tiles
17:20:14 <Samu> what's supposedly faster?
17:20:34 <peter1138> Who even knows what you are doing.
17:21:04 <Samu> check if there's a ship in 4 tiles, or check from all ships if one is coming into collision with the tile we're working on?
17:21:31 *** andythenorth has joined #openttd
17:21:50 <Samu> we're trying to make ships avoid deadlocks
17:23:07 <andythenorth> do ships deadlock often? o_O
17:23:23 <Samu> well, in AI games they do happen quite often
17:24:25 <andythenorth> ok
17:25:23 <Samu> i remember NoCAB, especially, would built docks in such a manner that it could make a ship become trapped between two docks, in a single tile, no means to change its route, it's stuck
17:25:47 <Samu> going forward is dock 1, going backwards, is dock 2, stuck
17:26:16 <Samu> and I think OtviAI was also suffering similarly, with ship depots
17:27:22 <Samu> for human games, this is pratically a non-issue
17:27:55 <Samu> if someone locks a ship, it's like 99% to be on purpose
17:28:03 <andythenorth> are you trying to fix it in AI?
17:28:25 <LordAro> doesn't sound like it
17:28:29 <Samu> no
17:29:04 <andythenorth> oof
17:29:12 <andythenorth> sounds like poor AI design, but I'll leave it
17:29:44 <LordAro> perhaps the solution is to check for adequate space when constructing the dock/depot
17:29:54 <LordAro> doesn't help if you alter the water though
17:31:19 <Samu> i could try make this work exclusively for AI
17:32:11 <Samu> have seen some similar exclusivity work on BuildRoad stuff, could try mimic that
17:33:33 <Samu> there is a 0,0000001% chance of an industry spawning on water to lock a ship
17:33:49 <Samu> i saw some report on flyspray years ago
17:34:05 <Samu> couldn't find it now
17:36:56 *** Flygon has quit IRC
17:38:41 *** iSoSyS has quit IRC
17:40:48 <Samu> are you still planning to remove 90 degrees for ships?
17:42:48 *** andythenorth has quit IRC
17:45:21 *** andythenorth has joined #openttd
17:46:07 <Samu> https://imgur.com/B9GKm0S
17:46:54 <Samu> there must be no ship coming from that direction when the oil rig is placed there
17:47:17 <Samu> all those directions*
17:48:00 <Samu> How am I gonna do this
17:48:12 <Samu> the industry builder places tiles 1 by 1 :(
17:48:33 *** andythenorth has quit IRC
18:12:28 *** Wormnest has quit IRC
18:13:10 *** Gja has quit IRC
18:19:27 *** andythenorth has joined #openttd
18:40:07 <Samu> gonna pick up juanjo's work, and try to make it a bit more specialized
18:49:24 *** gelignite has quit IRC
18:49:48 *** synchris has joined #openttd
19:32:25 *** wodencafe has joined #openttd
19:33:11 <andythenorth> this is nearly a whole day's work :P
19:33:12 <andythenorth> https://dev.openttdcoop.org/attachments/download/9152/roarer_pantographs.png
19:33:14 <andythenorth> I blame Eddi
19:33:18 <andythenorth> but it's nearly done
19:37:20 *** Thedarkb-T60 has joined #openttd
19:41:21 *** snail_UES_ has joined #openttd
19:46:25 <Samu> who's a network expert
19:47:49 <Samu> how would I test for desyncs?
19:53:30 *** yellyFish has joined #openttd
19:54:52 <Samu> hmmm nah... juanjo approach is bad
19:55:02 <Samu> really have to do this case by case... boring
19:58:17 *** Code has joined #openttd
19:58:45 <Code> IDENTIFY
19:58:54 *** Code is now known as Guest725
19:59:00 <Guest725> sad
19:59:19 <Guest725> FUDGE
19:59:24 *** Guest725 has quit IRC
19:59:52 <LordAro> rip
20:00:12 *** yellyFish has quit IRC
20:02:22 *** Thedarkb-T60 has quit IRC
20:04:19 <Eddi|zuHause> andythenorth: except, the pantographs should be mirror images
20:05:16 <andythenorth> yes that will come
20:05:19 *** Thedarkb-T60 has joined #openttd
20:05:56 <andythenorth> that's just needs some indices swapping
20:07:35 *** gelignite has joined #openttd
20:13:13 *** stefino has joined #openttd
20:17:11 <stefino> hello, Is possible to code industry what can be build only manualy? For example hotels. I could build them manualy and they will be not generated automaticly when the map is create.
20:17:38 <Eddi|zuHause> yes
20:17:56 <Eddi|zuHause> the default game has the tropic sawmill that can only be built manually
20:18:33 <Eddi|zuHause> it's also really simple to do, just set the appearance chance to 0
20:19:31 <andythenorth> oof buy menu offsets have to be different for pantographs
20:19:35 <andythenorth> this is getting nuanced
20:20:02 <Eddi|zuHause> just make a separate buy menu sprite without composition
20:20:19 <andythenorth> well
20:20:33 <andythenorth> that kind of defeats the point :P
20:20:52 *** Wacko1976 has joined #openttd
20:20:58 <Eddi|zuHause> why?
20:21:15 <andythenorth> then I have just 2 sets of pantograph sprites, except where I've copied them into every purchase menu sprite
20:21:23 <stefino> ahh, thank s a lot. we have an idea to make some objects to reduce the cash, in case you have a lot of money. So I have idea to code some industry - for example schools, hospitals etc, what will be more expensive (you will reduce cash) and it gives to you some bonus(pass production ets)
20:21:23 <andythenorth> also I don't generally have purchase menu sprites
20:21:35 <andythenorth> I just use sprite 6 or so
20:22:01 <andythenorth> at this point I might as well figure out the maths for 2 more offset adjustments, then it's done
20:22:20 <Eddi|zuHause> andythenorth: them file an issue that you want the offsets to be the same, potentially breaking some existing grfs :p
20:22:50 <andythenorth> do you think we'd accept that PR :)
20:23:04 <Eddi|zuHause> i don't know
20:23:06 <andythenorth> I suspect the problem originates with me, because I center the sprites in purchase menu
20:23:36 <Eddi|zuHause> possibly
20:23:46 <andythenorth> not sure why the yoffs is off by one pixel
20:23:46 <andythenorth> but the xoffs discrepancy is almost certainly my doing
20:24:30 <Eddi|zuHause> the xoffs may be some inherited issue
20:24:53 <Eddi|zuHause> where the bottom part of the sprite gets cut off or something
20:25:04 <andythenorth> -${int(consist.buy_menu_width / 2)}
20:25:12 <andythenorth> suggests the cause of the xoffs
20:25:55 <Eddi|zuHause> andythenorth: i don't know how the compositing works exactly, but ideally you would make that adjustment after the composition
20:26:07 <Eddi|zuHause> so the relative positions of the subsprite stay the same
20:26:35 <andythenorth> each layer resolves to a spriteset
20:26:35 <Eddi|zuHause> or you have to duplicate the calculation everywhere
20:26:49 <andythenorth> I have to duplicate the calculation everywhere
20:27:05 <andythenorth> interestingly, Horse buy menu rows are taller than default base set
20:27:12 <andythenorth> the actual UI row
20:27:38 <Eddi|zuHause> the ui scales to sprite sizes
20:27:41 <andythenorth> 28px vs 34px or so
20:28:00 <andythenorth> so I am pushing sprites down further to compensate
20:28:09 <andythenorth> which explains the yoffs discrepancy I think
20:28:35 <Eddi|zuHause> 28px does not sound like a height
20:28:57 <Eddi|zuHause> (assuming 1x zoom)
20:29:54 <andythenorth> it might be off by a couple, I used a screen ruler
20:30:29 <Eddi|zuHause> but if just one buy menu sprite across all your loaded GRFs is taller than default, it's going to rescale
20:34:26 <stefino> an how many cargo labels can I use in one inustry GRF?
20:34:46 <stefino> my friend said that only 32?
20:43:49 <andythenorth> https://github.com/OpenTTD/OpenTTD/pull/6802
20:44:00 <andythenorth> stefino: ^
20:44:14 <andythenorth> there is no stable release with that yet
20:44:29 <andythenorth> so it's a design choice whether you use 32 or 64
20:44:42 <andythenorth> and you'll have to compile your own OpenTTD to test the grf
20:45:03 <andythenorth> you should also see https://github.com/OpenTTD/OpenTTD/pull/6867
20:45:08 <andythenorth> which may or may not be approved
20:46:37 <Samu> I have a question, how do i iterate over all ships located on a tile?
20:47:00 <Samu> CommandCost ret = EnsureNoShipOnWater(tile); is insufficient
20:47:34 <Samu> there could be more than 1 ship
20:47:53 <stefino> thanks Andy
20:48:38 <andythenorth> I am working on FIRS v4 with up to 64 cargos, and 16 in / 16 out per industry
20:48:50 <andythenorth> I am hoping the second PR gets approved
20:51:12 <Samu> * When you fail to do this properly you create an almost untraceable DESYNC!
20:51:17 <Samu> I'm scared
20:51:56 <nielsm> andythenorth: nobody has lodged any conceptual complaint over the 16 in/out patches, so them getting in should really just be a matter of code quality
20:53:03 <andythenorth> frosch indicated same :)
20:53:12 <andythenorth> hopefully someone will review it some time :)
20:53:53 * andythenorth back tomorrow
20:53:55 *** andythenorth has quit IRC
20:56:52 <Samu> https://github.com/OpenTTD/OpenTTD/blob/master/src/vehicle.cpp#L400
20:57:10 *** glx has joined #openttd
20:57:10 *** ChanServ sets mode: +v glx
20:57:18 <Samu> so trains are different than ships in that they can't be on top of each other
20:57:34 <Samu> I can't resort to copy paste :(
21:00:27 <Samu> can't do a EnsureNoShipProcZ
21:00:55 <Samu> or the proc must return a list of vehicles on the tile, instead of returning only 1 vehicle
21:01:19 <Samu> how to do this?
21:06:37 *** stefino has quit IRC
21:14:46 <nielsm> what do you need a full list for?
21:15:25 <nielsm> if your goal is to detect whether or not there are any ships on a tile, if you can get just one from a query on the tile you know there are one or more ships there
21:40:25 *** sla_ro|master has quit IRC
21:43:02 *** Thedarkb-T60 has quit IRC
21:50:43 * LordAro compiled OTTD with clang7
21:50:59 <LordAro> only 3 new warnings (all the same thing), irritatingly from squirrel
21:51:21 <LordAro> sqcompiler.cpp:145:10: warning: local variable 'ret' will be copied despite being returned by name
21:56:26 <Samu> i need to check if a ship on a tile is on a specific track bit
21:57:28 <Eddi|zuHause> C++ has "return by name"?
21:57:50 <Samu> I am trying to avoid using FOR_ALL_SHIPS(s)
21:58:43 <Eddi|zuHause> can't even properly imagine what that would do
21:58:57 <Samu> hmm sec
21:59:58 *** HerzogDeXtEr has quit IRC
22:00:01 <Samu> https://paste.openttdcoop.org/pagop3ur5
22:00:58 <Samu> this is what I have right now, but it's not sufficient, because a ship could be on those tiles and yet not coming into collision with the tile
22:01:19 <Samu> i want to check in which tracks the ships are
22:02:18 <Samu> i need to iterate over all the ships on a tile and check each one individually in which track they are
22:02:25 <Samu> heh, repetition
22:03:51 <Samu> if (s->state & DiagdirReachesTracks(DiagdirBetweenTiles(tile, s->tile)
22:04:02 <Samu> s for vehicle of type ship
22:04:53 <LordAro> Eddi|zuHause: i have to admit, i'm not sure
22:05:55 <Samu> instead of CommandCost ret = EnsureNoShipOnWater(tile);, I want to get a list of vehicles on the tile :/
22:06:04 <Eddi|zuHause> i once learned about languages like algol that "call by name" was meant as something like "everywhere the parameter appears, the expression that is passed is put in, and then evaluated in that context"
22:06:13 *** iSoSyS has joined #openttd
22:06:47 *** frosch123 has quit IRC
22:07:12 <Eddi|zuHause> but that concept always seemed so crazy to me that nobody should ever use it
22:52:04 <nielsm> I think that warning message above might have something to do with return value optimizations, since it talks about "will be copied"
22:53:01 <nielsm> I assume that means the compiler wasn't able to prove the variable can be constructed in the return slot in the calling function's stack, or whatever it might do
22:59:37 *** synchris has quit IRC
23:10:41 *** sim-al2 has joined #openttd
23:14:46 <Samu> what's the difference between DiagDirection and DiagDirectionByte
23:20:42 *** nielsm has quit IRC
23:21:30 *** Wormnest has joined #openttd
23:24:00 *** gelignite has quit IRC
23:30:47 *** iSoSyS has quit IRC
23:34:25 *** snail_UES_ has quit IRC
23:41:48 <Samu> why doesn't this work? DiagDirectionByte diag_dir_byte = axis == AXIS_X ? 1 << DIAGDIR_SE | 1 << DIAGDIR_NW : 1 << DIAGDIR_NE | 1 << DIAGDIR_SW;
23:41:59 <Samu> Severity Code Description Project File Line Suppression State Error C2440 'initializing': cannot convert from 'int' to 'DiagDirectionByte' openttd D:\OpenTTD\OpenTTD GitHub\OpenTTD\src\water_cmd.cpp 138
23:42:32 <Samu> gonna try byte
23:45:30 <Samu> byte diag_dir_byte = axis == AXIS_X ? 1 << DIAGDIR_SE | 1 << DIAGDIR_NW : 1 << DIAGDIR_NE | 1 << DIAGDIR_SW;
23:52:49 *** HerzogDeXtEr has joined #openttd
23:57:01 *** Wolf01 has quit IRC
23:58:59 *** andythenorth has joined #openttd