Back to Home / #openttd / 2022 / 06 / Prev Day | Next Day
#openttd IRC Logs for 2022-06-23

---Logopened Thu Jun 23 00:00:15 2022
00:10-!-wallabra [~Gustavo60@2804:14d:4cd8:96b6:b038:7b10:b018:9590] has quit [Ping timeout: 480 seconds]
00:27-!-Smedles_ [] has quit [Quit: - Chat comfortably. Anywhere.]
00:27-!-Smedles [~quassel@2403:580d:1:0:aaa1:59ff:fe53:1a69] has joined #openttd
00:27-!-Smedles is "Paul Smedley" on #openttd
01:27-!-Flygon [] has joined #openttd
01:27-!-Flygon is "Flygon" on #openttd
01:28-!-wallabra [~Gustavo60@2804:14d:4cd8:96b6:b038:7b10:b018:9590] has joined #openttd
01:28-!-wallabra is "Gustavo Ramos Rehermann" on #openttd #llvm #linux #C #
01:39-!-andythenorth [] has joined #openttd
01:39-!-andythenorth is "andythenorth" on #openttd
01:43-!-sla_ro|master [] has joined #openttd
01:43-!-sla_ro|master is "slamaster" on @#sla #openttd
02:23-!-andythenorth [] has quit [Quit: andythenorth]
02:23-!-D-HUND is now known as debdog
02:24-!-andythenorth [] has joined #openttd
02:24-!-andythenorth is "andythenorth" on #openttd
02:33-!-andythenorth [] has quit [Quit: andythenorth]
02:35-!-andythenorth [] has joined #openttd
02:35-!-andythenorth is "andythenorth" on #openttd
04:37-!-wallabra [~Gustavo60@2804:14d:4cd8:96b6:b038:7b10:b018:9590] has quit [Ping timeout: 480 seconds]
04:56-!-HerzogDeXtEr [] has joined #openttd
04:56-!-HerzogDeXtEr is "purple" on #openttd
05:04-!-sla_ro|master [] has quit []
05:20-!-Samu [] has joined #openttd
05:20-!-Samu is "realname" on #openttd
05:29<Joel>Is there a window event handler that will be triggered by changing the settings? I want to be able to set a member variable of the window when a setting changes, not OnPaint
05:36<Eddi|zuHause>a setting can have a callback function when it changes
05:56<Samu>how to know which is the most advanced railtype if they both have the same max speed and cost?
05:56<Samu>i gotta pick one!
05:57<@peter1138>Pick the one that is compatible with the engines you want to use.
06:13<Samu>they already are
06:13<Samu>i have that check
06:13<@peter1138>Okay, then it doesn't matter.
06:14<Samu>i went with the cost factor , the higher, the better, keks, which may not always be the case
06:20<Samu>problem is when everything is equal
06:20<Samu>then i really have to random pick
06:27<Samu>let's see now what it comes up for mail
06:37<Samu>Driving Van Trailer + 4x Sliding Wall Van (Twin) on Advanced electric high-speed line construction
06:39<Samu>absurd line costs
06:39<Samu>for such a cheap train
06:39<Samu>guess going with the highest rail cost isn't always the best idea
06:48<@DorpsGek>[OpenTTD/OpenTTD] Joel-Milligan updated pull request #9928: Change: Remove scrollbar from town authority actions panel
06:49<@DorpsGek>[OpenTTD/OpenTTD] Joel-Milligan commented on pull request #9928: Change: Remove scrollbar from town authority actions panel
06:50<@DorpsGek>[OpenTTD/OpenTTD] Joel-Milligan commented on pull request #9928: Change: Remove scrollbar from town authority actions panel
06:50<@DorpsGek>[OpenTTD/OpenTTD] Joel-Milligan commented on pull request #9928: Change: Remove scrollbar from town authority actions panel
07:58-!-virtualrandomnumber [] has joined #openttd
07:58-!-virtualrandomnumber is "virtualrandomnumber" on #openttd
07:58-!-virtualrandomnumber [] has quit []
08:07-!-glx [] has joined #openttd
08:07-!-glx is "Loïc GUILLOUX" on #openttd
08:07-!-mode/#openttd [+v glx] by ChanServ
08:34<@DorpsGek>[OpenTTD/OpenTTD] glx22 commented on pull request #9928: Change: Remove scrollbar from town authority actions panel
08:42-!-Joel [] has quit [Ping timeout: 480 seconds]
08:44-!-joel [] has joined #openttd
08:44-!-joel is "joel" on #openttd
08:47-!-sla_ro|master [] has joined #openttd
08:47-!-sla_ro|master is "slamaster" on @#sla #openttd
08:51<Samu>i don't know how to program this...
08:51<Samu>i got 3 railtypes, each with 50, 70 and 90 max speed, then i have the train with 60 max speed
08:52<Samu>i want to compute the railtype which is faster than the train but not the highest
08:52<Samu>so, i want to get the railtype with 70 max speed
08:52<Samu>don't know how to do this in code
08:55<Samu>so, the one which is closest to the train speed, but never lower
08:56<+glx>rail list, valuate speed, filter
08:56<Samu>and the other situation is, 3 railtypes with 30 and 50 max speed, with train 60 max speed
08:56<Samu>in this case i want to get the fastest possible, which is 50
08:58<Samu>i said 3 railtypes, i meant 2
08:59<Samu>and then there's the matter of ties
08:59<Samu>3 railtypes, each with 60 60, i want to get both
08:59<Samu>60 60 60
09:00<+glx>they might have different costs
09:00<Samu>that's okay for now
09:00<+glx>build or maintenance
09:04<Samu>i got this far only
09:04<Samu>i can only get a list of the fastest
09:09<Samu>maybe i need a table?
09:09<Samu>instead of array?
09:09<Samu>i dunno, i'm lost
09:09-!-Joel__ [] has joined #openttd
09:09-!-Joel__ is "realname" on #openttd
09:09<+glx>I'd get an AIRailTypeList, valuated (and sorted) with AIRail.GetMaxSpeed, then you store the fastest railtype, then you remove items slower than the train
09:10<+glx>if the list is empty you use the stored value, else the slowest in the list
09:13<+glx>descending sort for unfiltered speed, so Begin() is the fastest, ascending sort for filtered so Begin is the slowest
09:35<andythenorth>augment / replace train prop 25 with a dword, and add a var to read it?
09:35<andythenorth>maybe ignoring the slightly odd var 42 OR thing
09:37<andythenorth>it's such a classic :)
09:38-!-nielsm [] has joined #openttd
09:38-!-nielsm is "Niels Martin Hansen" on #openttd
09:43<Samu>thanks, I think I did it, let me test
09:45<+glx>of course before valuation with speed, you valuate with can run/has power and keep only what the train can use
09:46<Samu>nop, i failed somewhere, the final list became empty :(
09:46-!-Joel__ [] has quit [Ping timeout: 480 seconds]
09:54<Samu>for some reason, the 2 temporary lists became both empty?
09:55<+glx>hmm you had list1 then did list2=list1 before filtering ?
09:55<Samu>i have 3 lists
09:56<Samu>or 4 if i count the original one
09:56<+glx>IIRC lists are not copied when assigned to a variable
09:57-!-WormnestAndroid [~WormnestA@] has quit [Remote host closed the connection]
09:57<Samu>list 1-> railtypes, it's an array
09:58<Samu>list 2-> railtypes_list, it's an AIList
09:58<Samu>list 3-> railtypes_below_train_speed, it's an AIList
09:58<Samu>list 4-> best_railtypes, it's an array
09:59<+glx>you didn't valuate, so all values are 0
09:59<+glx>I think
09:59<Samu>i added the value railtypes_list.AddItem(railtype, railtype_max_speed);
10:00<Samu>cant use valuate because some railtypes have 0 in it
10:00<+glx>ah right the values should be right
10:00<@peter1138>if 0 then 9001
10:01<+glx>railtypes_below_train_speed.KeepBelowValue(train_max_speed); <-- don't you want the opposite ?
10:02<+glx>a rail speed limit higher than train speed limit
10:03<Samu>ah, i think i found the problem
10:04<andythenorth>dword per train vehicle then? :P
10:04<andythenorth>breaks everything?
10:07<Samu>okay, it got somewhere!
10:08-!-joel [] has quit [Remote host closed the connection]
10:09<Samu>it picked Zeus (Electric), with Suburban Coach (Large) on Dual-power accelerated main line construction
10:09<Samu>rail line max speed is 180 km/h
10:09-!-joel [] has joined #openttd
10:09-!-joel is "joel" on #openttd
10:10<Samu>zeus electric is 159 km/h
10:10-!-Tirili [] has joined #openttd
10:10-!-Tirili is "realname" on #openttd
10:10<+glx>would still be faster to use valuate, you can use a custom valuator
10:10<Samu>suburban coach theres' 140 and 159 km/h
10:10<Samu>with the same name
10:11<Samu>so i assume it's the 159 km/h
10:12<Samu>guess it got it right, the previous railtype speed is 130 km/h
10:12<Samu>and the next is 230
10:14-!-Joel__ [] has joined #openttd
10:14-!-Joel__ is "realname" on #openttd
10:17-!-joel [] has quit [Ping timeout: 480 seconds]
10:18<Samu>i'm against valuators, they cause spikes
10:18<Samu>openttd becomes a stutterfest with them
10:21-!-WormnestAndroid [~WormnestA@] has joined #openttd
10:21-!-WormnestAndroid is "WormnestAndroid" on #openttd
10:28<Samu>hmm there's no way to know if an engine is dual-headed
10:29<Samu>can't do a precise measure of air drag
10:29<Samu>it counts number of parts, and multihead engines are 2 parts in the equation
10:29<andythenorth>air drag is silly
10:32<Samu>very niche use case
10:43-!-joel [] has joined #openttd
10:43-!-joel is "joel" on #openttd
10:43-!-andythenorth [] has quit [Quit: andythenorth]
10:44<@DorpsGek>[OpenTTD/OpenTTD] Joel-Milligan updated pull request #9928: Change: Remove scrollbar from town authority actions panel
10:51-!-joel [] has quit [Ping timeout: 480 seconds]
10:59<@DorpsGek>[OpenTTD/OpenTTD] Joel-Milligan commented on pull request #9928: Change: Remove scrollbar from town authority actions panel
11:00-!-joel [] has joined #openttd
11:00-!-joel is "joel" on #openttd
11:01<+glx>joel: yeah some part of the code are "hidden"
11:01<+glx>(not really, but settings is part of generated code)
11:02<Joel__>Yeah I found out about setting callbacks, but couldn't figure out where to find it. Seems obvious in hindsight. Thanks for all the help so far, I really appreciate it
11:03<LordAro>We appreciate you sticking with it :)
11:03<LordAro>and all our unreasonable demands
11:10<+glx>github mobile app is weird, it correctly says 6 files changed, but if I click to see the diff, it also includes unrelated modified lang files from previous WT commit
11:17-!-joel [] has quit [Remote host closed the connection]
11:18-!-joel [] has joined #openttd
11:18-!-joel is "joel" on #openttd
11:27-!-sla_ro|master [] has quit []
11:27<LordAro>rebase related?
11:29-!-andythenorth [] has joined #openttd
11:29-!-andythenorth is "andythenorth" on #openttd
11:33<+glx>don't think so, branch is 1 ahead, 3 behind and the website display is correct
11:36-!-Montana_ [] has joined #openttd
11:36-!-Montana_ is "realname" on #openttd
11:37<@DorpsGek>[OpenTTD/OpenTTD] Joel-Milligan updated pull request #9928: Change: Remove scrollbar from town authority actions panel
11:37-!-Joel__ [] has quit [Quit: Leaving]
11:38-!-joel [] has quit [Remote host closed the connection]
11:39-!-joel [] has joined #openttd
11:39-!-joel is "joel" on #openttd
11:57-!-jinks [~jinks@] has quit [Quit: ZNC -]
11:57-!-jinks [~jinks@] has joined #openttd
11:57-!-jinks is "Got ZNC?" on #openttd
11:58<@DorpsGek>[OpenTTD/OpenTTD] glx22 commented on pull request #9928: Change: Remove scrollbar from town authority actions panel
12:04-!-andythenorth [] has quit [Quit: andythenorth]
12:10<@DorpsGek>[OpenTTD/OpenTTD] Joel-Milligan updated pull request #9928: Change: Remove scrollbar from town authority actions panel
12:28-!-joel [] has quit []
12:32-!-Smedles [~quassel@2403:580d:1:0:aaa1:59ff:fe53:1a69] has quit [Quit: - Chat comfortably. Anywhere.]
12:32-!-Smedles [~quassel@2403:580d:1:0:aaa1:59ff:fe53:1a69] has joined #openttd
12:32-!-Smedles is "Paul Smedley" on #openttd
12:57-!-Tirili [] has quit [Quit: Leaving]
12:57-!-Tirili [] has joined #openttd
12:57-!-Tirili is "realname" on #openttd
13:08-!-wallabra [~Gustavo60@2804:14d:4cd8:96b6:b038:7b10:b018:9590] has joined #openttd
13:08-!-wallabra is "Gustavo Ramos Rehermann" on #openttd #llvm #linux #C #
13:37-!-Tirili [] has quit [Quit: Leaving]
13:38-!-Tirili [] has joined #openttd
13:38-!-Tirili is "realname" on #openttd
13:46<Samu>i finally integrated that whole advance distance from openttd into the script
13:47<Samu>well, parts of, i assumed a lot of things
13:50<Samu>from iron horse, it picked Hector (Electric) with 5 Railcar Trailers
13:51<Samu>i assumed in code that train are going uphill the entire time
13:51<Samu>maybe that's affecting the results
14:02-!-Montana_ [] has quit [Quit: Leaving]
14:16-!-Flygon [] has quit [Quit: A toaster's basically a soldering iron designed to toast bread]
14:19-!-Smedles [~quassel@2403:580d:1:0:aaa1:59ff:fe53:1a69] has quit [Quit: - Chat comfortably. Anywhere.]
14:20-!-Smedles [~quassel@2403:580d:1:0:aaa1:59ff:fe53:1a69] has joined #openttd
14:20-!-Smedles is "Paul Smedley" on #openttd
14:36-!-Etua [~Thunderbi@2a00:f41:18f5:25c1:a8f6:7279:f8b2:477d] has joined #openttd
14:36-!-Etua is "Etua" on #openttd #debian-pl #osm-pl
14:50<@DorpsGek>[OpenTTD/OpenTTD] DorpsGek pushed 1 commits to master
14:50<@DorpsGek> - Update: Translations from eints (by translators)
14:58-!-Wormnest [~Wormnest@] has joined #openttd
14:58-!-Wormnest is "Wormnest" on #openttd
15:30-!-tokai [] has joined #openttd
15:30-!-tokai is "Christian Rosentreter" on #openttd
15:30-!-mode/#openttd [+v tokai] by ChanServ
15:37-!-tokai|noir [] has quit [Ping timeout: 480 seconds]
15:49-!-sla_ro|master [] has joined #openttd
15:49-!-sla_ro|master is "slamaster" on @#sla #openttd
16:00<Samu>woah, iron horse has some wagons with the exact same running cost, capacity and weight
16:00<Samu>only differenciator is price
16:01-!-Mapminik [] has joined #openttd
16:01-!-Mapminik is "Etua" on #openttd #debian-pl #osm-pl
16:01<Samu>oh, also same speed
16:02<Samu>guess i need to take price into account in the formula, lol
16:04-!-Etua [~Thunderbi@2a00:f41:18f5:25c1:a8f6:7279:f8b2:477d] has quit [Ping timeout: 480 seconds]
16:04-!-Mapminik is now known as Etua
16:11-!-Etua [] has quit [Quit: Etua]
16:32-!-andythenorth [~andytheno@] has joined #openttd
16:32-!-andythenorth is "andythenorth" on #openttd
16:50<@DorpsGek>[OpenTTD/OpenTTD] 2TallTyler opened pull request #9931: Feature: Multi-track level crossings
17:19<Samu>so professional
17:27-!-nielsm [] has quit [Remote host closed the connection]
17:31-!-andythenorth [~andytheno@] has quit [Quit: andythenorth]
17:42<Samu>tables behave quite random
17:42<Samu>i never get the same ordering
17:45<Samu>it feels like I'm doing something wrong
17:45<Samu>but I'm not
17:47<Samu>look at this piece of code
17:50<Samu>I get different ordering
17:50<Samu>on multiple runs
17:50<Samu>because I'm using engineWagonPairs is a table
17:51<Samu>so weird
17:55-!-Samu [] has quit [Quit: Leaving]
17:57-!-sla_ro|master [] has quit []
18:10-!-HerzogDeXtEr [] has quit [Read error: Connection reset by peer]
18:49-!-Tirili [] has quit [Quit: Leaving]
18:49-!-Tirili [] has joined #openttd
18:49-!-Tirili is "realname" on #openttd
18:49-!-Tirili [] has quit [Remote host closed the connection]
19:14<@DorpsGek>[OpenTTD/OpenTTD] Joel-Milligan updated pull request #9929: Fix #9363: Rebuild client list on reinit event
19:15-!-Joel [] has joined #openttd
19:15-!-Joel is "realname" on #openttd
19:19-!-Joel [] has quit []
19:58-!-grossing [] has quit []
19:58-!-grossing [] has joined #openttd
19:58-!-grossing is "Florian Gross" on #openttd #centos #oftc #kaschemme #osm-de-ot
20:30-!-wallabra [~Gustavo60@2804:14d:4cd8:96b6:b038:7b10:b018:9590] has quit [Ping timeout: 480 seconds]
21:47-!-wallabra [~Gustavo60@2804:14d:4cd8:96b6:b038:7b10:b018:9590] has joined #openttd
21:47-!-wallabra is "Gustavo Ramos Rehermann" on #openttd #llvm #linux #C #
22:15<@DorpsGek>[OpenTTD/OpenTTD] Eddi-z commented on pull request #9931: Feature: Multi-track level crossings
22:20-!-Wormnest [~Wormnest@] has quit [Quit: Leaving]
22:30-!-D-HUND [~debdog@2a00:79c0:63a:3700:7a24:afff:fe8a:d04d] has joined #openttd
22:30-!-D-HUND is "Wowbagger" on #openttd
22:33-!-debdog [~debdog@2a00:79c0:64e:4b00:7a24:afff:fe8a:d04d] has quit [Ping timeout: 480 seconds]
22:38-!-Smedles [~quassel@2403:580d:1:0:aaa1:59ff:fe53:1a69] has quit [Quit: - Chat comfortably. Anywhere.]
22:38-!-Smedles [~quassel@2403:580d:1:0:aaa1:59ff:fe53:1a69] has joined #openttd
22:38-!-Smedles is "Paul Smedley" on #openttd
23:26-!-glx [] has quit []
---Logclosed Fri Jun 24 00:00:16 2022