IRC logs for #openttd on OFTC at 2019-01-14
            
00:13:02 *** Progman_ has quit IRC
00:20:03 <Samu> gonna try make opf check for depot tiles somehow
00:20:13 <Samu> instead of me providing it
00:30:47 <DorpsGek_II> [OpenTTD/OpenTTD] PeterN updated pull request #6784: Ship cpu hog workaround for #6145 https://git.io/vpxjO
00:34:36 <LordAro> peter1138: can i be annoying and ask for commits 4 & 5 to be Codechanges?
00:39:19 *** HerzogDeXtEr has joined #openttd
00:44:39 *** nielsm has quit IRC
01:03:53 <Eddi|zuHause> LordAro: i was just trying to sort out the capitalisation and then i drew a complete blank on how capitalisation is meant to work...
01:04:52 <Eddi|zuHause> would be easier if someone else did this, my brain is for some weird reason not able to do this
01:08:17 <Eddi|zuHause> gonna --abort this, makes no sense like this
01:09:36 <DorpsGek_II> [OpenTTD/OpenTTD] PeterN updated pull request #6784: Ship cpu hog workaround for #6145 https://git.io/vpxjO
01:11:11 <peter1138> ^ LordAro
01:11:49 <LordAro> :)
01:18:13 <peter1138> One day I might post something other than food on Instagram. But not today.
01:22:33 <Eddi|zuHause> one day you upgrade for sublte advertising?
01:24:47 <DorpsGek_II> [OpenTTD/OpenTTD] PeterN commented on pull request #7057: Fix: A few minor compile warnings under MinGW https://git.io/fhnHW
01:32:00 <DorpsGek_II> [OpenTTD/OpenTTD] glx22 commented on pull request #7031: Add: squirrel_export.vbs https://git.io/fhnH4
01:34:41 <DorpsGek_II> [OpenTTD/OpenTTD] LordAro approved pull request #7031: Add: squirrel_export.vbs https://git.io/fhnHR
01:34:55 <DorpsGek_II> [OpenTTD/OpenTTD] LordAro merged pull request #7031: Add: squirrel_export.vbs https://git.io/fhZnQ
01:59:21 <Samu> wow, opf search method is really retarded
01:59:56 <Samu> without all the randoms choices, it just go straight until it finds an obstacle
02:00:03 <Samu> then it makes a turn
02:00:11 <Samu> usually turns back
02:02:09 <Samu> bird distance isn't used to help it make better choices
02:02:14 <Samu> why
02:02:56 <Samu> im no pathfinder expert
02:03:04 <Samu> but it's weird
02:05:39 *** Flygon has joined #openttd
02:09:16 <peter1138> It's designed to be low CPU usage.
02:16:01 *** Smedles_ has joined #openttd
02:18:26 <Samu> oh? and then it ends up being the most intensive
02:19:12 *** Smedles has quit IRC
02:21:40 <peter1138> How so?
02:21:52 <Samu> i guess the random choices makes it look "smarter"
02:22:11 <peter1138> They make it more likely to get there, heh.
02:22:28 <Samu> on my 5000 ship testing, OPF is too slow
02:22:50 <Samu> compared with the other 2
02:23:31 <Samu> but the test uses many buoys, so it could influence results
02:29:04 <DorpsGek_II> [OpenTTD/OpenTTD] glx22 commented on pull request #7057: Fix: A few minor compile warnings under MinGW https://git.io/fhnQv
02:30:06 *** HerzogDeXtEr has quit IRC
02:33:13 *** Thedarkb-X40 has joined #openttd
02:38:06 <Samu> just managed to decrease the stall from 14 seconds to 5 seconds
02:38:14 <Samu> for opf
02:38:45 <Samu> that means, npf is the worst when mass sending 5000 ships to depot
02:39:22 <Samu> also with 14 seconds
02:40:46 <Samu> why is this a DoCommand, it tests before executing, so basically, it's 10000 ships
02:41:00 <Samu> does the same work twice
02:42:11 <Samu> @calc 23.656 - 9.015
02:42:11 <DorpsGek> Samu: 14.641
02:42:23 <Samu> npf still stalls for 14 seconds
02:43:51 <Samu> @calc 30.156 - 25.421
02:43:51 <DorpsGek> Samu: 4.735
02:44:07 <Samu> opf stalls for ~5 seconds
02:45:18 <Samu> @calc 31.906 - 45.406
02:45:18 <DorpsGek> Samu: -13.5
02:45:32 <Samu> @calc 31.906 - 34.406
02:45:32 <DorpsGek> Samu: -2.5
02:45:48 <Samu> 2.5 secs for yapf, the king
02:47:56 *** triolus has joined #openttd
02:48:37 <Samu> mass sending 5000 ships to depot results:
02:48:53 <Samu> opf - 4.7 secs
02:48:59 <Samu> npf - 14,6 secs
02:49:04 <Samu> yapf - 2,5 secs
02:49:47 <Samu> must investigate what's so bad about npf for such a long stall
02:57:33 <peter1138> Did you investigate the underlying algorithms behind OPF, NPF and YAPF?
02:59:28 <Samu> in ship_cmd.cpp?
02:59:50 *** triolus has quit IRC
03:00:20 <peter1138> No, in the pathfinding code, heh.
03:00:31 <peter1138> Are you aware that NPF and YAPF are basically the same pathfinding algorithm?
03:00:41 <peter1138> OPF isn't.
03:00:57 <Samu> that's even stranger
03:01:17 <glx> NPF and YAPF are implementations of A*
03:04:54 <Samu> i dont know how to properly time a single search
03:06:34 <peter1138> NPF is a simple literal approach to the algorithm.
03:07:07 <peter1138> YAPF is heavily optimized by using C++ templating and implementing a cache.
03:07:49 <peter1138> So, yeah, YAPF is faster than NPF... by design.
03:08:38 <Samu> what does the cache do?
03:08:47 <peter1138> What does a cache normally do?
03:09:08 <Samu> but in this case, feels like cache isn't doing anything yet
03:09:15 <Samu> or is it?
03:26:03 <Samu> there is no cache for ships, or i dont understand whether it's working
03:29:47 <Samu> CYapfShipAnyDepot2::stFindNearestDepot = 0x00007ff615ebb360 {openttd.exe!CYapfFollowShipT<CYapfShip_TypesT<CYapfShipAnyDepot2,CFollowTrackT<2,Ship,1,0>,CNodeList_HashTableT<CYapfShipNodeT<CYapfNodeKeyExitDir>,10,12>,CYapfDestinationAnyDepotShipT> >::stFindNearestDepot(const Ship *, unsigned int, T...
03:29:54 <Samu> now in english, plz :p
03:33:04 *** Wormnest has joined #openttd
03:43:46 *** Wormnest has quit IRC
04:04:12 *** Thedarkb-X40 has quit IRC
04:06:20 <Samu> can't spot any cache being worked
04:07:02 <Samu> i think this cache is only for rail
04:07:11 <Samu> caches track segments?
04:11:47 *** D-HUND has joined #openttd
04:15:04 *** debdog has quit IRC
04:36:44 *** glx has quit IRC
04:38:57 <DorpsGek_II> [OpenTTD/OpenTTD] SamuXarick updated pull request #6928: Fix #5713: Use pathfinder to find closest ship depot https://git.io/fhZzm
04:50:37 *** Samu has quit IRC
04:56:27 *** triolus has joined #openttd
05:09:29 *** triolus has quit IRC
05:09:46 *** triolus has joined #openttd
05:44:24 *** snail_UES_ has quit IRC
05:49:01 *** triolus has quit IRC
06:02:45 *** triolus has joined #openttd
06:04:52 *** Smedles_ has quit IRC
06:18:01 *** triolus has quit IRC
06:23:58 *** triolus has joined #openttd
06:31:51 *** triolus has quit IRC
07:24:51 *** Smedles has joined #openttd
08:05:47 *** HerzogDeXtEr has joined #openttd
08:10:21 *** chomwitt has joined #openttd
08:25:54 *** HerzogDeXtEr has quit IRC
08:35:00 <peter1138> He should be a pathfinder expert by now.
08:35:25 <peter1138> I fear though that he hasn't figured out there's a built-in profiling mode for one of them.
09:01:33 *** andythenorth has joined #openttd
09:02:00 <andythenorth> Eddi|zuHause: I have a custom python sort challenge
09:02:19 <andythenorth> current implementation is "sorted(wagon_consists, key=lambda wagon_consist: wagon_consist.subtype)"
09:02:38 <andythenorth> subtypes are 'A', 'B', 'C', or 'U'
09:03:08 <andythenorth> I want sort rank to be 'U', 'A', 'B', 'C'
09:03:15 <andythenorth> I thought of at least two bad ways to do it
09:03:55 <andythenorth> but presumably sort can be given a custom comparison, such that U < A, U < B, U < C, and A B C remain lexical w.r.t each other
09:17:26 *** D-HUND is now known as debdog
09:34:02 *** Thedarkb1-T60 has quit IRC
09:44:27 *** andythenorth is now known as Guest625
09:44:27 *** andythenorth has joined #openttd
09:48:19 *** Guest625 has quit IRC
10:04:53 *** andythenorth has quit IRC
10:17:44 <peter1138> Hmm.
10:37:26 <planetmaker> moin moin
11:38:18 *** andythenorth has joined #openttd
12:08:28 *** D-HUND has joined #openttd
12:11:28 <peter1138> Anything left to close?
12:11:49 *** debdog has quit IRC
12:12:38 *** D-HUND is now known as debdog
12:24:01 <andythenorth> nothing
12:24:05 <andythenorth> all closed
12:28:14 <andythenorth> https://github.com/OpenTTD/OpenTTD/pull/6811
12:28:15 <andythenorth> ;)
12:43:50 <peter1138> Ah
12:43:55 <peter1138> Stale ;p
12:58:21 *** andythenorth has quit IRC
13:11:13 *** kragniz is now known as kgz
14:12:40 <DorpsGek_II> [OpenTTD/website] claman commented on pull request #18: Change copyright date to use site.time https://git.io/fhnxE
14:17:37 *** tokai|noir has joined #openttd
14:17:37 *** ChanServ sets mode: +v tokai|noir
14:22:04 *** snail_UES_ has joined #openttd
14:24:27 *** tokai has quit IRC
14:28:39 *** andythenorth has joined #openttd
14:29:35 <andythenorth> close it!
14:30:37 *** andythenorth has quit IRC
14:34:10 *** andythenorth has joined #openttd
14:52:16 <DorpsGek_II> [OpenTTD/OpenTTD] Gabda87 updated pull request #7047: Add #6887: Highlight tiles within local authority of towns https://git.io/fhn44
15:01:33 <DorpsGek_II> [OpenTTD/OpenTTD] Gabda87 commented on pull request #7025: Add #6887: Option to show zone inside local authority boundary of towns https://git.io/fhnpz
15:04:43 <Eddi|zuHause> andythenorth: depends how "exdentable" you need it, but as a start how about "sorted(wagon_consists, key=lambda wagon_consist: {"U": 1, "A": 2, "B": 3, "C": 4}[wagon_consist.subtype])"
15:05:10 <andythenorth> Eddi|zuHause: looks good I'll try
15:05:44 <Eddi|zuHause> you could also fiddle around with rexex
15:07:03 <Eddi|zuHause> or you could rename the subtypes so they are lexical ordering to begin with
15:07:38 <andythenorth> that was my crude solution
15:07:45 <andythenorth> but yours works, and is highly readable
15:08:28 <andythenorth> thanks
15:14:21 *** Gabda has joined #openttd
15:15:54 *** Flygon has quit IRC
15:17:59 <Gabda> @logs
15:17:59 <DorpsGek> Gabda: https://webster.openttdcoop.org/index.php?channel=openttd
15:25:50 *** andythenorth has quit IRC
15:35:55 *** sla_ro|master has joined #openttd
15:46:32 *** nielsm has joined #openttd
15:51:53 *** smoke_fumus has joined #openttd
15:58:38 *** Samu has joined #openttd
15:58:44 <Samu> hi
16:01:11 <Samu> how do I measure the time a code part takes to complete?
16:02:11 <Samu> need to investigate why npf stalls for too long
16:03:12 <Samu> want to know where exactly the slowdown comes from
16:05:48 <LordAro> Samu: the thing you want to google is "profiling"
16:05:58 <LordAro> and probably add "visual studio"
16:09:26 <Samu> diagnostic tools?
16:17:19 <milek7> i use gperftools
16:18:33 <nielsm> visual studio community should have microsoft's profiler built in
16:18:50 <nielsm> just keep in mind it can take a LOT of memory/storage to capture a profiling run
16:27:43 <DorpsGek_II> [OpenTTD/OpenTTD] gregcarlin commented on pull request #7003: Feature #6918: Add option to adjust font size separately from GUI size. https://git.io/fhnjW
16:29:09 *** Wormnest has joined #openttd
16:40:12 *** HerzogDeXtEr has joined #openttd
16:41:41 <Samu> dont know how to make it work
16:42:07 <Samu> it always says no code was run during selected time range
16:42:17 <DorpsGek_II> [OpenTTD/OpenTTD] glx22 commented on pull request #7003: Feature #6918: Add option to adjust font size separately from GUI size. https://git.io/fhnj7
16:52:04 <Samu> this is a lie https://blogs.msdn.microsoft.com/visualstudio/2016/02/15/analyze-cpu-memory-while-debugging/
16:52:13 <Samu> i always get no code was run during selected time range
17:00:49 <peter1138> Hmm, on my old server, I have an svn checkout from 2009 that contains patches to increase the cargo limit to 64...
17:12:24 <Sacro> I have many old files
17:12:37 <Sacro> Like the MiniIN
17:14:06 <DorpsGek_II> [OpenTTD/OpenTTD] gregcarlin updated pull request #7003: Feature #6918: Add option to adjust font size separately from GUI size. https://git.io/fhLFX
17:14:16 <peter1138> Heh
17:14:28 <peter1138> Simulation rate: 34.30 frames/s
17:14:32 <peter1138> Hmm, seems fast :/
17:15:09 *** WWacko1976-work has quit IRC
17:16:48 <DorpsGek_II> [OpenTTD/OpenTTD] gregcarlin commented on pull request #7003: Feature #6918: Add option to adjust font size separately from GUI size. https://git.io/fhce5
17:16:53 <peter1138> 1.02x
17:20:39 <Sacro> Running it in NTSC?
17:20:44 <peter1138> heh
17:20:58 <peter1138> It is running in a VM though.
17:21:08 <peter1138> Urgh, why is window resizing so broken.
17:21:19 <peter1138> Oh I remember, SDL doesn't technically support it.
17:21:36 <peter1138> It recreates the window every time. Some window managers cope.
17:31:19 *** GroovyNoodle has joined #openttd
17:44:48 *** Progman has joined #openttd
17:54:54 *** Alberth has joined #openttd
17:54:54 *** ChanServ sets mode: +o Alberth
17:58:34 <peter1138> Urgh, I really show clean up my stashes.
17:59:21 <peter1138> show -> should
17:59:57 <nielsm> status: https://0x0.st/shsw.png
18:01:08 <Samu> the slower part of yapf is memset ?
18:01:12 <Samu> I dont get this
18:03:28 <peter1138> nielsm, nice.
18:03:41 <nielsm> Samu: means it spends a lot of time zeroing memory, I guess
18:05:17 <nielsm> reversing little programs like this is an oddly fun kind of puzzle
18:06:09 <nielsm> taking guesses at what some things are/do, then try building a skeleton program for that, then deriving some more meaning from the original, blindly re-implementing code you don't understand, and then slowly getting to an understanding
18:06:18 <nielsm> I'm sure you can get better at it with practice :)
18:07:08 <peter1138> Surely you just try something once, realise it doesn't work, keeping try, still doesn't work, then give up and move on to something else?
18:07:41 *** GroovyNoodle has quit IRC
18:09:02 <Samu> in debug mode these times are skewed
18:11:48 <Samu> what takes 2.5 secs in release mode takes 40 secs in debug mode
18:12:58 *** GroovyNoodle has joined #openttd
18:16:22 <peter1138> That's because it's a debug build.
18:17:29 <Samu> https://imgur.com/FcpS2Zd
18:17:39 <Samu> sending 5000 ships to depots with NPF
18:18:03 <Samu> takes a spike of 14,112 s selected
18:18:16 <Samu> I'm not sure where to look at
18:19:36 <Eddi|zuHause> <peter1138> Hmm, on my old server, I have an svn checkout from 2009 that contains patches to increase the cargo limit to 64... <-- to whom should that be a surprise?
18:23:00 *** Thedarkb1-T60 has joined #openttd
18:23:08 <peter1138> )
18:23:09 <peter1138> :)
18:30:03 <peter1138> Hmm, got a stash here that attempts to implement a path cache for ships.
18:30:59 <Samu> i was able to filter out memset stuff
18:31:34 <Samu> https://imgur.com/a/TWnoS92 top - npf, middle - opf, bottom - yapf
18:31:52 <Samu> ah, memset was only shown on debug mode, i guess
18:32:44 <Samu> i'm still unsure what numbers are important
18:33:55 <Eddi|zuHause> i'm sure there were more people who attempted ship pathfinder optimisations
18:34:38 *** Gja has joined #openttd
18:35:27 <Eddi|zuHause> hm, now even "Der Spiegel" is citing xkcd
18:36:11 <Eddi|zuHause> (that's one of the largest news magazines and one of the largest news websites in germany)
18:37:08 <Samu> the slower part of NPF is BinaryHeap::Delete and Has
18:37:12 <Samu> Hash::FindNode
18:37:53 <Samu> doesn't look like stuff I should care about
18:38:00 <nielsm> Eddi|zuHause, correct horse battery stable?
18:38:34 <Eddi|zuHause> nielsm: no, it's about protein folding, and they cited the "now imagine folding a live one"
18:39:01 <Eddi|zuHause> http://xkcd.com/1430/
18:42:43 <Samu> the slow part is queue.cpp, I never touched this file
18:42:52 <Samu> dont even know for sure what's doing
18:43:15 <nielsm> it's a data structure for a priority queue, I believe
18:43:28 <Samu> it has BinaryHeap and Hash
18:43:30 *** Wormnest has quit IRC
18:44:15 <Samu> BinaryHeap sounds familiar, I had that thing on my AI, and switched to Fibonacci
18:44:17 <nielsm> and it's likely the part that takes up the most time because stuffing elements into a queue and taking them out again might be the basis of the algorithm
18:45:07 <Samu> now, i dunno anything about the hash
18:46:20 <Samu> There's nothing I can do here then :(
18:48:48 <Samu> * Deletes the item from the queue. priority should be specified if
18:48:48 <Samu> * known, which speeds up the deleting for some queue's. Should be -1
18:48:48 <Samu> * if not known.
18:49:01 <Samu> that's a funny comment, it ends being the slowest part of NPF
18:49:21 <Samu> bool BinaryHeap::Delete(void *item, int priority)
18:49:30 <Samu> ok, enough of this
18:49:36 <peter1138> Don't bother trying to optimise NPF. YAPF exists for a reason.
18:50:03 <Samu> yapf was the fastest
18:50:09 <peter1138> Odd that!
18:50:12 <Samu> thx for yapf
18:50:15 <Samu> maker
18:50:46 <Samu> and yesterday I just shoved off 10 seconds from opf
18:50:57 <Samu> with that code update
19:10:33 *** Wolf01 has joined #openttd
19:11:03 <Wolf01> o/
19:13:44 *** Alberth has left #openttd
19:14:17 *** acklen_ has joined #openttd
19:14:19 *** acklen has quit IRC
19:14:28 *** Laedek has joined #openttd
19:15:10 <Wolf01> Mmmh, I think it's a bit that I don't visit the forum... I don't remember the snow this winter
19:16:34 *** dwfreed is now known as Guest647
19:16:35 *** dwfreed has joined #openttd
19:17:55 <DorpsGek_II> [OpenTTD/OpenTTD] ABCRic commented on issue #4115: Default company color setting https://git.io/fhcfK
19:18:49 *** Gabda has quit IRC
19:19:42 *** Guest647 has quit IRC
19:21:30 *** Laedek_ has quit IRC
19:21:40 *** glx has joined #openttd
19:21:40 *** ChanServ sets mode: +v glx
19:25:37 *** newbie has joined #openttd
19:25:47 *** Hobbyboy|BNC has joined #openttd
19:26:02 *** tokai has joined #openttd
19:26:02 *** ChanServ sets mode: +v tokai
19:27:20 *** HerzogDeXtEr1 has joined #openttd
19:27:29 *** Eddi|zuHause2 has joined #openttd
19:27:57 *** heffer has quit IRC
19:27:57 *** ToBeFree has quit IRC
19:27:57 *** reldred has quit IRC
19:28:28 *** heffer has joined #openttd
19:28:28 *** ToBeFree has joined #openttd
19:28:28 *** reldred has joined #openttd
19:29:07 *** Progman has quit IRC
19:29:07 *** HerzogDeXtEr has quit IRC
19:29:07 *** smoke_fumus has quit IRC
19:29:07 *** nielsm has quit IRC
19:29:07 *** tokai|noir has quit IRC
19:29:07 *** crem has quit IRC
19:29:07 *** urdh has quit IRC
19:29:07 *** TrueBrain_ii has quit IRC
19:29:07 *** ericnoan has quit IRC
19:29:07 *** argoneus has quit IRC
19:29:07 *** V453000 has quit IRC
19:29:08 *** planetmaker has quit IRC
19:29:08 *** Yexo has quit IRC
19:29:08 *** SmatZ has quit IRC
19:29:08 *** Ammler has quit IRC
19:29:08 *** luaduck has quit IRC
19:29:08 *** ZirconiumX has quit IRC
19:29:08 *** SpComb has quit IRC
19:29:08 *** Hobbyboy has quit IRC
19:29:08 *** eirc has quit IRC
19:29:08 *** Sacro has quit IRC
19:29:08 *** Hobbyboy|BNC is now known as Hobbyboy
19:29:38 *** urdh has joined #openttd
19:29:55 *** eirc has joined #openttd
19:30:13 *** Progman has joined #openttd
19:30:13 *** HerzogDeXtEr has joined #openttd
19:30:13 *** nielsm has joined #openttd
19:30:13 *** tokai|noir has joined #openttd
19:30:13 *** crem has joined #openttd
19:30:13 *** planetmaker has joined #openttd
19:30:13 *** TrueBrain_ii has joined #openttd
19:30:13 *** ericnoan has joined #openttd
19:30:13 *** argoneus has joined #openttd
19:30:13 *** V453000 has joined #openttd
19:30:13 *** Yexo has joined #openttd
19:30:13 *** SmatZ has joined #openttd
19:30:13 *** Ammler has joined #openttd
19:30:13 *** luaduck has joined #openttd
19:30:13 *** ZirconiumX has joined #openttd
19:30:13 *** SpComb has joined #openttd
19:30:13 *** Sacro has joined #openttd
19:30:13 *** dacia.oftc.net sets mode: +vov tokai|noir planetmaker planetmaker
19:30:27 *** argoneus_ has joined #openttd
19:30:36 *** sla_ro|master has quit IRC
19:30:36 *** Eddi|zuHause has quit IRC
19:30:36 *** Yotson has quit IRC
19:30:36 *** Xaroth has quit IRC
19:30:36 *** FLHerne has quit IRC
19:30:36 *** XeryusTC has quit IRC
19:30:36 *** Osai has quit IRC
19:30:36 *** Terkhen has quit IRC
19:30:36 *** ^Spike^ has quit IRC
19:30:36 *** Hirundo has quit IRC
19:30:36 *** Markk has quit IRC
19:30:36 *** zuzak has quit IRC
19:30:36 *** Exec has quit IRC
19:30:36 *** MasseR has quit IRC
19:30:36 *** tyteen4a03 has quit IRC
19:30:36 *** KenjiE20 has quit IRC
19:30:36 *** orudge has quit IRC
19:30:36 *** DorpsGek_II has quit IRC
19:30:36 *** ericnoan has quit IRC
19:30:37 *** luaduck has quit IRC
19:30:46 *** orudge has joined #openttd
19:30:57 *** crem1 has joined #openttd
19:31:01 *** SpComb^ has joined #openttd
19:31:05 *** orudge has quit IRC
19:31:07 *** duck_ has joined #openttd
19:31:07 *** sla_ro|master has joined #openttd
19:31:07 *** Yotson has joined #openttd
19:31:07 *** Xaroth has joined #openttd
19:31:07 *** FLHerne has joined #openttd
19:31:07 *** XeryusTC has joined #openttd
19:31:07 *** Osai has joined #openttd
19:31:07 *** Terkhen has joined #openttd
19:31:07 *** ^Spike^ has joined #openttd
19:31:07 *** Hirundo has joined #openttd
19:31:07 *** Markk has joined #openttd
19:31:07 *** orudge has joined #openttd
19:31:07 *** coulomb.oftc.net sets mode: +ovov Terkhen Terkhen orudge orudge
19:31:07 *** zuzak has joined #openttd
19:31:07 *** Exec has joined #openttd
19:31:07 *** KenjiE20 has joined #openttd
19:31:07 *** DorpsGek_II has joined #openttd
19:31:07 *** MasseR has joined #openttd
19:31:07 *** tyteen4a03 has joined #openttd
19:31:09 *** orudge` has joined #openttd
19:32:13 *** argoneus has quit IRC
19:32:26 <DorpsGek_II> [OpenTTD/OpenTTD] andythenorth commented on issue #4115: Default company color setting https://git.io/fhcfh
19:32:32 *** HerzogDeXtEr has quit IRC
19:32:32 *** tokai|noir has quit IRC
19:32:37 *** V453000 has quit IRC
19:32:40 *** crem has quit IRC
19:32:42 *** SmatZ has quit IRC
19:32:43 *** andythenorth has joined #openttd
19:32:47 *** orudge has quit IRC
19:32:52 *** Yotson has quit IRC
19:32:54 *** SpComb has quit IRC
19:32:57 *** Progman has quit IRC
19:32:57 *** Yexo has quit IRC
19:33:02 *** planetmaker has quit IRC
19:33:56 *** Eddi|zuHause2 is now known as Eddi|zuHause
19:34:27 <andythenorth> o/
19:35:29 *** ericnoan has joined #openttd
19:35:37 *** V453000 has joined #openttd
19:35:59 *** planetmaker has joined #openttd
19:35:59 *** ChanServ sets mode: +o planetmaker
19:36:07 *** SmatZ has joined #openttd
19:36:37 *** Yexo has joined #openttd
19:37:55 *** Yotson has joined #openttd
19:40:18 <andythenorth> I did a terrible thing
19:41:08 <Samu> to repent, test my pr's
19:41:24 <Eddi|zuHause> how could you!
19:41:51 <andythenorth> I went onto LinkedIn
19:41:57 *** Progman has joined #openttd
19:42:28 <andythenorth> then...I messaged Yexo in it
19:43:00 <LordAro> :o
19:43:03 <andythenorth> peter1138: yo
19:43:22 <LordAro> andythenorth: any particular purpose?
19:43:28 <andythenorth> LordAro: none at all
19:43:46 <andythenorth> my favourite things to do have no purpose
19:44:09 <nnyby> haha same i feel
19:47:09 <LordAro> andythenorth: excellent
19:48:42 <Samu> i have some patches here that i'm scared to PR
19:48:56 <Samu> because I know already they're not gonna be accepted
19:49:03 <Samu> but they are done :(
19:50:25 <peter1138> Yo?
19:50:56 <Samu> https://github.com/OpenTTD/OpenTTD/compare/master...SamuXarick:DistanceTransportedGoodsIncome
19:51:05 <Samu> for example that one
19:52:44 <andythenorth> peter1138: open source clone of Chocks Away? I could ask him if he wants to help.... https://www.linkedin.com/in/andrew-hutchings-8820346/
19:53:19 <nielsm> some of the code this compiler has generated is completely baffling... "and al, 0FFh"
19:53:19 <peter1138> Requires me to sign in.
19:53:32 <nielsm> al is a byte register, and'ing it with FFh is a no-op
19:53:41 <peter1138> nielsm, sets CPU registers though, no?
19:53:58 <nielsm> touching al should not touch ah
19:54:01 <peter1138> Dunno though.
19:54:06 <andythenorth> nielsm: LinkedIn such very evil
19:54:07 <nielsm> though it should clear the top 16 bits of eax
19:54:20 * andythenorth wonders if MS will merge LinkedIn and github
19:54:26 <andythenorth> it's the obvious step
19:54:46 <nielsm> GitIn
19:55:00 <peter1138> nielsm, I mean the FLAGS register. I dunno if it does.
19:55:05 <andythenorth> free recruiter spam with every PR
19:55:21 <nielsm> yeah no, the next thing it does it pushing ax to set up a function call
19:56:19 <dwfreed> nielsm: https://stackoverflow.com/a/45362396
19:57:11 <Samu> theres microphone support on openttd now=
19:58:01 <Samu> something from X Audio?
19:58:51 <nielsm> dwfreed: honestly I should just stop being shocked that a C compiler from 1994 (or earlier) generates bad code
20:00:07 <nielsm> Samu: no, xaudio is only used for sound out, as an alternative to dsound on windows
20:00:22 <nielsm> (because it makes it easier to port to UWP or something)
20:03:39 <Samu> Severity Code Description Project File Line Suppression State
20:03:39 <Samu> Warning C4146 unary minus operator applied to unsigned type, result still unsigned (compiling source file ..\src\map.cpp) openttd d:\openttd\openttd github\openttd\src\core\math_func.hpp 85
20:03:53 <Samu> this wasn't here yesterday
20:05:35 <Samu> gonna try rebuild all
20:05:42 <Samu> getting weird errors
20:07:22 <Samu> identifier "uint" is undefined?
20:08:49 <Samu> it built now
20:08:58 <Samu> sorry all, false alarm
20:13:17 *** reldred has quit IRC
20:13:17 *** heffer has quit IRC
20:13:17 *** ToBeFree has quit IRC
20:13:17 *** Smedles has quit IRC
20:13:17 *** APTX has quit IRC
20:13:17 *** techmagus has quit IRC
20:13:17 *** k-man has quit IRC
20:13:17 *** daspork has quit IRC
20:13:17 *** snail_UES_ has quit IRC
20:13:17 *** cHawk has quit IRC
20:13:17 *** Maarten has quit IRC
20:13:17 *** HeyCitizen has quit IRC
20:13:17 *** Vadtec has quit IRC
20:13:17 *** Antheus has quit IRC
20:13:17 *** dwfreed has quit IRC
20:13:17 *** Laedek has quit IRC
20:13:17 *** acklen_ has quit IRC
20:13:17 *** AKTheKnight has quit IRC
20:13:17 *** wodencafe has quit IRC
20:13:17 *** jinks has quit IRC
20:13:17 *** rocky11384497 has quit IRC
20:13:17 *** greeter has quit IRC
20:13:17 *** quiznilo has quit IRC
20:13:17 *** innocenat_ has quit IRC
20:13:17 *** ttech2 has quit IRC
20:13:17 *** Extrems has quit IRC
20:13:17 *** erani has quit IRC
20:13:17 *** colde has quit IRC
20:13:17 *** murr4y has quit IRC
20:13:17 *** ccfreak2k has quit IRC
20:13:17 *** nnyby has quit IRC
20:13:17 *** TinoDidriksen has quit IRC
20:13:17 *** mikegrb has quit IRC
20:13:17 *** duncan has quit IRC
20:13:17 *** ST2 has quit IRC
20:13:30 *** snail_UES_ has joined #openttd
20:13:30 *** cHawk has joined #openttd
20:13:30 *** Maarten has joined #openttd
20:13:30 *** HeyCitizen has joined #openttd
20:13:30 *** Vadtec has joined #openttd
20:13:30 *** Antheus has joined #openttd
20:13:36 *** TinoDidriksen has joined #openttd
20:13:36 *** murr4y has joined #openttd
20:13:36 *** colde has joined #openttd
20:13:36 *** ST2 has joined #openttd
20:13:36 *** duncan has joined #openttd
20:13:36 *** ccfreak2k has joined #openttd
20:13:36 *** mikegrb has joined #openttd
20:13:36 *** erani has joined #openttd
20:13:36 *** Extrems has joined #openttd
20:13:36 *** ttech2 has joined #openttd
20:13:36 *** innocenat_ has joined #openttd
20:13:36 *** quiznilo has joined #openttd
20:13:36 *** greeter has joined #openttd
20:13:36 *** rocky11384497 has joined #openttd
20:13:36 *** jinks has joined #openttd
20:13:36 *** nnyby has joined #openttd
20:13:36 *** wodencafe has joined #openttd
20:13:36 *** AKTheKnight has joined #openttd
20:13:36 *** acklen_ has joined #openttd
20:13:36 *** Laedek has joined #openttd
20:13:36 *** dwfreed has joined #openttd
20:13:36 *** daspork has joined #openttd
20:13:36 *** Smedles has joined #openttd
20:13:36 *** APTX has joined #openttd
20:13:36 *** techmagus has joined #openttd
20:13:39 <Samu> i failed to do a push --force
20:13:45 <Samu> bah
20:13:54 <Samu> became a merge
20:14:07 *** heffer has joined #openttd
20:14:07 *** ToBeFree has joined #openttd
20:14:07 *** reldred has joined #openttd
20:16:48 <Wolf01> I failed to raise my kitten, became a dog :D
20:16:55 <andythenorth> fair comment
20:17:10 <andythenorth> so...Horse
20:17:27 <andythenorth> EMUs: same speed as DMUs, or same speed as electric pax engines?
20:17:43 <andythenorth> [Horse has two speed classes - normal and express]
20:17:54 <Wolf01> No, for real, it brings back what you throw and can be brought outside with a leash
20:19:25 <andythenorth> ha
20:19:26 <nielsm> EMUs same speed as DMUs but better acceleration
20:19:38 <andythenorth> nielsm: yeah that's what I coded
20:19:47 *** k-man has joined #openttd
20:19:51 <andythenorth> ok
20:20:46 <Samu> how do i do a git push --force on visual studio?
20:21:03 <Samu> team explorer
20:21:28 <Samu> Sync wasn't it, turned out it was a merge
20:23:47 * andythenorth builds in a BAD EGG
20:23:52 <andythenorth> it's like a BAD FEATURE
20:25:28 *** gelignite has joined #openttd
20:29:13 <Samu> how do i delete a branch and leave no trace about it?
20:29:22 <andythenorth> branch -D generally
20:29:29 <andythenorth> but read the scm pages first
20:29:31 <Samu> i was only experimenting
20:29:38 <andythenorth> https://git-scm.com/doc
20:29:58 <Samu> now i see some of my old deleted branches still listed as "deleted"
20:30:26 <andythenorth> dunno
20:30:30 <andythenorth> :)
20:38:28 <Samu> github.com doesn't really delete my stuff
20:38:52 <andythenorth> branch -D, force push
20:38:55 <andythenorth> usually considered rude
20:38:56 <andythenorth> but eh
20:38:57 <Samu> it leaves it hiden somewhere, allowing me to restore later
20:39:26 <Samu> it's stuff already implemented, so i dont need to keep these branches
20:40:12 <Samu> Team Explorer on visual studio apparently deletes them for good
20:43:00 <Samu> https://github.com/SamuXarick/OpenTTD/branches/all?page=1 good, they're gone
20:49:14 *** GroovyNoodle has quit IRC
20:52:54 <Samu> always commits ahead and commits behind :(
20:53:17 <Samu> do I have to rebase everyday force -push all the time?
20:54:23 <DorpsGek_II> [OpenTTD/OpenTTD] LordAro approved pull request #6784: Ship cpu hog workaround for #6145 https://git.io/fhcqA
20:55:16 <LordAro> Samu: in practice, you only need to rebase when something else interferes with something that you've done
20:55:37 <Samu> wow there's more ppl working on ship stuff
20:55:55 <Samu> ah, i see
20:56:15 <LordAro> i.e. if misc_gui.cpp has been modified in master, and you've been fiddling with pathfinders, they're unlikely to interfere
20:56:52 <LordAro> but these interactions aren't easy to see in advance, so it's best practice to rebase often
20:57:10 <DorpsGek_II> [OpenTTD/OpenTTD] LordAro merged pull request #6784: Ship cpu hog workaround for #6145 https://git.io/vpxjO
20:57:23 *** Wormnest has joined #openttd
20:57:28 <DorpsGek_II> [OpenTTD/OpenTTD] LordAro commented on issue #6145: High CPU usage for ships with empty orders https://git.io/fhcmI
20:57:29 <DorpsGek_II> [OpenTTD/OpenTTD] LordAro closed issue #6145: High CPU usage for ships with empty orders https://git.io/fhcmL
20:57:43 <Samu> those changes look scary as heck
20:57:45 <Samu> rip ships
20:57:51 <LordAro> haha
20:57:58 *** GroovyNoodle has joined #openttd
20:58:44 <LordAro> as an example, the above will definitely interfere with the stuff you've been playing with :)
20:59:04 <glx> and you also rebase if you need to add something to the PR, but rebase just to rebase is useless
20:59:51 <Samu> if (v->dest_tile == 0 || DistanceManhattan(tile, v->dest_tile) > SHIP_MAX_ORDER_DISTANCE + 5) { using distance manhattan like this is gonna be a disaster waiting to happen, but let me test
21:00:24 <glx> "add something" as a new commit, or an modified commit
21:00:32 <LordAro> Samu: why do you think so?
21:00:41 <LordAro> distance manhattan is a very simple calculation
21:00:58 <Samu> the pathfinder may find a path that makes the ship move the opposite direction
21:01:15 <glx> yes if it's shorter
21:01:17 <Samu> if the distancemanhattan check triggers.... rip ship
21:03:22 <LordAro> it was discussed in the PR (or possibly here) - you already can't set orders further than SHIP_MAX_ORDER_DISTANCE apart, so it shouldn't make any difference
21:04:13 <LordAro> but you're welcome to test these things
21:04:29 <LordAro> (or indeed, comment on PRs)
21:04:59 <andythenorth> but the video here is awesome https://github.com/OpenTTD/OpenTTD/issues/6145#issuecomment-379453516
21:05:54 <LordAro> hehe
21:06:20 <LordAro> i am actually curious what would happen if you try to send to depot when the nearest depot is > 130 tiles away
21:07:07 <andythenorth> easy to test
21:07:37 <LordAro> *hopefully* it will say "cannot find depot", rather than just stopping the ship
21:07:47 *** GroovyNoodle has quit IRC
21:17:00 *** GroovyNoodle has joined #openttd
21:17:50 <andythenorth> BAD EASTER
21:18:00 * andythenorth realises simple things aren't simple :P
21:18:10 <andythenorth> cb36 loops are banned for obvious reasons
21:22:11 *** Wormnest has quit IRC
21:33:52 *** GroovyNoodle has quit IRC
21:35:39 <DorpsGek_II> [OpenTTD/OpenTTD] J0anJosep updated pull request #7056: Change #6060: Allow drawing dropdown lists with scrollbars above and fix scrolling movement https://git.io/fhnon
21:36:48 <DorpsGek_II> [OpenTTD/OpenTTD] J0anJosep commented on pull request #7056: Change #6060: Allow drawing dropdown lists with scrollbars above and fix scrolling movement https://git.io/fhc3S
21:38:30 <DorpsGek_II> [OpenTTD/OpenTTD] LordAro commented on pull request #7056: Change #6060: Allow drawing dropdown lists with scrollbars above and fix scrolling movement https://git.io/fhc3F
21:40:14 <DorpsGek_II> [OpenTTD/OpenTTD] LordAro commented on pull request #7056: Change #6060: Allow drawing dropdown lists with scrollbars above and fix scrolling movement https://git.io/fhcsI
21:43:03 *** GroovyNoodle has joined #openttd
21:46:52 *** frosch123 has joined #openttd
21:56:05 <andythenorth> quak
21:56:16 <LordAro> quark
21:56:19 <frosch123> moo
21:58:57 *** GroovyNoodle has quit IRC
22:15:31 *** DorpsGek has joined #openttd
22:15:31 *** ChanServ sets mode: +o DorpsGek
22:17:51 *** gelignite has quit IRC
22:27:57 <glx> ok mingw-w64 command line limit is 32000, the depand command with args but without source files is 8312, source files list is 25155
22:28:14 <glx> not surprising the command line is too long
22:29:25 <glx> and I filtered out all non -D from CFLAGS and CXXFLAGS
22:30:06 *** Eddi|zuHause2 is now known as Eddi|zuHause
22:30:22 <Eddi|zuHause> why would you even build a command line this huge and expect it to work?
22:30:33 <glx> makefile does it
22:30:40 <LordAro> glx: i've not seen anything like that, how long are your paths?
22:30:57 <glx> D:/developpement/GitHub/glx22/OpenTTD/src/
22:31:11 <glx> not short
22:31:42 *** Gja has quit IRC
22:31:51 <glx> 399 files in the list ;)
22:31:59 <Eddi|zuHause> not short, but also not excessively long
22:32:19 <Eddi|zuHause> my "ancient DOS tricks" tells me you might want to try "subst" :p
22:33:03 <glx> I think I can use $(words) and friends to split in smaller parts
22:33:26 <glx> depend seems to have a -a flag for appending
22:34:52 *** Thedarkb2-T60 has quit IRC
22:35:30 <Eddi|zuHause> i would put my effort in trying to reduce the number of arguments
22:35:47 <glx> not possible
22:35:49 <Eddi|zuHause> like calling it in a loop
22:35:56 <Eddi|zuHause> once for each file
22:35:57 <Eddi|zuHause> or something
22:36:08 <nielsm> xargs does this afaik?
22:36:25 <glx> ha yes that's why I intended to use $(word) and $(wordlist)
22:36:49 <Eddi|zuHause> i don't know what abyss you're delving into, though
22:36:57 <glx> something like http://softwareswirl.blogspot.com/2009/10/gnu-make-trick-for-handling-long-lists.html
22:37:17 <LordAro> depend may want altering to use a file listing inputs or something
22:37:51 <Eddi|zuHause> yeah, put the names into a file, and read that?
22:38:14 <LordAro> it's the less hacky solution, anyway
22:38:17 <LordAro> imo
22:41:17 *** Progman has quit IRC
22:45:05 <glx> modifying depend could work, but as it's also possible to use makedepend it's not the solution
22:45:49 *** APTX_ has joined #openttd
22:47:06 *** APTX has quit IRC
22:50:05 *** Wolf01 has quit IRC
22:50:37 *** Thedarkb2-T60 has joined #openttd
22:54:44 *** frosch123 has quit IRC
22:55:34 <Samu> just tested
22:55:42 <Samu> it's not good
22:56:36 <Samu> distance manhattan is the reason why pathfinders get lost
22:57:00 <Samu> this ship i'm testing is currently not invoking the pathfinder
22:57:12 <Samu> it is a miracle it still finds its way to destination
22:58:00 <Samu> goes forward, reaches the map border, makes some turns, reaches the other map border, and it finally gets moving in a direction that will make the pathfinder be invoked again
22:58:22 <nielsm> someone should be using more buoys
22:58:24 <Samu> then it gets to its destination, after doing some weird turns
22:59:45 <LordAro> mm
23:00:17 <Samu> i'm not sure, it doesn't feel right
23:00:50 <Samu> but yeah, buoys being the solution for ships :(
23:04:16 <Samu> buoys could be abused :( but i kind of like the idea of buoys being a guidance for pathfinders
23:06:04 <Samu> gonna try making buoys a negative penalty, essentially turning them into a bonus
23:07:08 <LordAro> that's unlikely to improve pathfinder performance, if that's what you're trying
23:08:46 <Samu> let me test
23:11:52 <Samu> oh, it's a npf exclusive feature
23:11:55 <Samu> very well
23:12:04 <Samu> i thought yapf had it
23:13:48 <Samu> doesn't let me add negative values
23:13:50 <Samu> boo
23:14:28 <LordAro> heh
23:15:43 <Samu> cost -= _settings_game.pf.npf.npf_buoy_penalty; // A small /*penalty */ bonus for going over buoys
23:15:52 <Samu> let's see
23:16:04 <nielsm> oh, I think I'm almost code complete for the adlib music decoder, except for a bunch of static tables I need to copy over
23:17:42 <Samu> doesn't work
23:18:21 <Samu> aystar asserts warning me that new_g > 0 failed
23:18:36 <milek7> hm
23:18:40 <milek7> i commited git merge
23:18:42 <milek7> and now i want to undo it and perform conflict resolution of single file again
23:20:11 <milek7> but reset will obviously throw away all changes
23:20:36 <LordAro> rebase!
23:20:48 <Eddi|zuHause> yeah, modifying commits is rebase
23:20:52 <LordAro> alternatively, reset --soft
23:21:07 <LordAro> if the commit is still local
23:21:13 <Samu> i use the recycle bin
23:21:18 <Samu> and clone again
23:21:22 <Samu> works everytime
23:21:30 <LordAro> good ol' Samu
23:21:57 <Samu> if i want to go back to stuff I had, i take it back from recycle bin
23:22:47 <milek7> ok, maybe reset to before merge, start merge, checkout good files from new commit, resolve bad file and commit
23:23:30 <LordAro> milek7: that's probably what i'd do
23:28:31 <Eddi|zuHause> you don't need reset if you rebase
23:29:05 <Eddi|zuHause> just carefully consider what the target of the rebase is
23:29:07 <LordAro> Eddi|zuHause: except in this case you're literally removing a commit, rebase isn't the right solution
23:29:34 <Eddi|zuHause> in a rebase you can drop a commit
23:30:01 <LordAro> you can, but eh
23:33:39 <peter1138> Evenig
23:33:50 <Samu> hi
23:34:05 <LordAro> o/
23:34:08 <peter1138> 22:20 < milek7> but reset will obviously throw away all changes
23:34:12 <peter1138> ^ it doesn't
23:36:25 <milek7> it won't allow me to use merge with dirty working tree after soft/mixed, and i wanted to get file with conflict markers again
23:39:08 *** andythenorth has quit IRC
23:39:23 <nielsm> will it crash or burn, or will sound actually be produced???
23:39:26 <nielsm> time to try it
23:39:55 <nielsm> nothing happens :D
23:40:02 <nielsm> at least nothing audible or visual
23:40:11 <peter1138> Samu, I didn't aim to improve pathfinder performance because that's a hard task. I aimed to prevent some situations that cause massive CPU usage from occuring. (But not all)
23:42:16 <nielsm> yeah I forgot to call Start on the driver :P
23:42:24 <peter1138> Heh
23:42:40 <LordAro> heh
23:45:08 <Samu> just decreate max number of nodes
23:45:45 <Samu> it's defaulted to 10000, maybe 5000? dunno
23:45:54 <LordAro> "just"
23:46:01 <Samu> :p
23:46:34 <Samu> or maybe, an idea
23:46:45 <Samu> have the pathfinder invoked on order insertion
23:47:09 <Samu> let it decide whether destination is too far
23:48:15 <Samu> hmm
23:49:39 <Samu> would kill opf
23:49:59 <LordAro> few would mourn its loss
23:50:52 <peter1138> So there is a remaining CPU hog issue.
23:51:23 <peter1138> Trying to find a path to a tile that is within the max distance but actually not reachable causes a hitch.
23:52:24 <LordAro> presumably because it's searching the whole map?
23:52:34 <peter1138> I wonder how many new bug reports #6784 will cause :D
23:52:42 <LordAro> ono
23:52:59 <peter1138> Not the whole map but enough. And it'll happen on every new tile.
23:53:16 <LordAro> oof
23:53:28 <peter1138> Well, that's why ship pathfinding already sucks.
23:53:31 <peter1138> It happens on every new tile.
23:53:41 <peter1138> Hence I have a patch to cache paths, but it's very much WIP.
23:53:45 <LordAro> that does seem inefficient
23:54:09 <LordAro> i was thinking that it should cache paths, then follow them until there's something in the way
23:54:23 <peter1138> Yup.
23:55:00 <peter1138> https://github.com/OpenTTD/OpenTTD/commit/b98887c4a014d5bc193b0c1089b3ac0334187775 < "solves" a lot
23:55:02 <nielsm> if it's within range but no path could be found, set a counter that indicates "temporarily lost" and random walk until that counter reaches zero?
23:55:10 <nielsm> and/or send a news message
23:55:41 <LordAro> would still cause a hitch every n tiles
23:55:43 <peter1138> It spreads the load out, so you don't get 5000 pathfinding attempts in one tick.
23:56:00 <LordAro> some sort of limit on the pathfinder would work
23:56:14 <peter1138> There's a distance limit already, iirc.
23:56:26 <peter1138> Or at least, there is now :)
23:56:29 <Samu> have you tried my ship pathfinding depot stuff yet?
23:56:36 <Eddi|zuHause> the main problem with the ship pathfinder is the large number of near-identical paths
23:57:03 <peter1138> Hmm, yes, if it's with-in range, I'm not sure how far the pathfinder will actually go.
23:57:06 <Eddi|zuHause> the second problem is that it is repeated on every tile, as every tile is a junction
23:57:33 <LordAro> peter1138: yeah, referring to your "within range but unreachable" case
23:57:41 <peter1138> Yeah, sorry, sidetracked.
23:58:01 <peter1138> Hmm, we could do with a way to cancel a "Manage list" -> "Send to Depot" command.
23:58:01 <Eddi|zuHause> and "no path exists" is always the worst case for a pathfinder
23:59:58 <peter1138> I think my changes my scupper Samu's testing :p