Config
Log for #openttd on 19th June 2018:
Times are UTC Toggle Colours
00:27:05  *** snail_UES_ has joined #openttd
00:32:17  <ANIKHTOS> hello snail
00:47:08  *** KouDy has quit IRC
00:48:35  *** Cthulhux has quit IRC
00:50:02  *** tokai|noir has joined #openttd
00:50:02  *** ChanServ sets mode: +v tokai|noir
00:57:00  *** tokai has quit IRC
01:17:58  *** rocky1138 has quit IRC
01:27:38  *** Supercheese has quit IRC
01:46:22  <ANIKHTOS> i worte some code it compiled but the exe is not workign i get an error no available language packs
01:46:36  <ANIKHTOS> what i mess up??
01:57:58  *** KouDy has joined #openttd
02:05:30  <glx> you must be in /bin to run it
02:09:04  *** rocky1138 has joined #openttd
02:10:52  *** Supercheese has joined #openttd
02:12:05  *** supermop has joined #openttd
02:19:54  <ANIKHTOS> the code is goign back forth change files its hard to follow it
02:21:11  *** supermop has quit IRC
02:22:00  <ANIKHTOS> i am looking the  code in status bar to see how it format the date  from there i went to english.txt the language form there i went to strings.cpp
02:22:22  <ANIKHTOS> its in there that the game format the date to be displayed right??
02:36:40  *** supermop has joined #openttd
02:37:51  *** Supercheese has quit IRC
02:38:05  *** Supercheese has joined #openttd
02:39:18  *** muffindrake3 has joined #openttd
02:41:10  *** muffindrake2 has quit IRC
02:51:50  *** glx has quit IRC
02:52:58  <ANIKHTOS> getting closer :-)
03:02:14  *** ToffeeYogurtPots has quit IRC
03:02:43  *** ToffeeYogurtPots has joined #openttd
03:07:53  *** KouDy has quit IRC
03:19:35  *** Supercheese has quit IRC
03:19:51  *** Supercheese has joined #openttd
03:22:17  *** KouDy has joined #openttd
03:25:19  <ANIKHTOS> almostt there
03:28:35  *** KouDy has quit IRC
04:07:08  *** KouDy has joined #openttd
04:18:30  *** Flygon has joined #openttd
05:08:33  *** KouDy has quit IRC
05:09:52  <ANIKHTOS> i made it :-)
05:10:13  *** Wacko1976 has quit IRC
05:20:14  *** supermop has quit IRC
05:25:43  *** snail_UES_ has quit IRC
06:00:19  *** Cubey has quit IRC
06:06:48  *** andythenorth has joined #openttd
06:07:11  <ANIKHTOS> hello andy how are you??
06:07:38  *** KouDy has joined #openttd
06:13:01  *** Arveen2 has joined #openttd
06:13:01  *** rocky1138 has quit IRC
06:13:04  *** supermop has joined #openttd
06:14:51  *** andythenorth has quit IRC
06:17:30  *** Arveen3 has joined #openttd
06:17:40  *** Arveen has quit IRC
06:21:36  *** Arveen2 has quit IRC
06:26:02  *** andythenorth has joined #openttd
06:29:50  *** WWacko1976-work has joined #openttd
06:33:11  *** KouDy has quit IRC
06:43:14  *** supermop has quit IRC
07:02:18  *** KouDy has joined #openttd
07:06:21  *** Supercheese has quit IRC
07:09:59  *** iSoSyS has joined #openttd
07:12:27  *** RedJimi has quit IRC
07:14:59  *** KouDy has quit IRC
07:39:12  *** sim-al2 has quit IRC
07:58:06  *** iSoSyS has quit IRC
07:59:33  *** KouDy has joined #openttd
08:03:51  *** Laedek has quit IRC
08:06:11  *** andythenorth has quit IRC
08:13:05  *** supermop has joined #openttd
08:18:33  *** andythenorth has joined #openttd
08:21:07  *** supermop has quit IRC
08:29:18  *** Westie has joined #openttd
08:29:36  *** xorex has joined #openttd
08:41:28  <ANIKHTOS> andy i mange to change teh status bar to show the nomral days as time :-)
08:41:48  <ANIKHTOS> the only problem is that change all the dates to look like this !?!?!?
08:51:14  *** debdog has quit IRC
09:01:05  *** andythenorth has quit IRC
09:01:27  *** andythenorth has joined #openttd
09:08:46  *** andythenorth has left #openttd
10:12:05  *** iSoSyS has joined #openttd
10:12:56  *** ANIKHTOS has quit IRC
10:13:21  *** KouDy has quit IRC
10:14:53  *** KouDy has joined #openttd
10:23:50  *** ANIKHTOS has joined #openttd
10:25:45  *** ANIKHTOS has quit IRC
12:54:36  *** sim-al2 has joined #openttd
13:00:09  *** snail_UES_ has joined #openttd
13:07:00  <planetmaker> well... the date format is universal to a language. So yes, you change it once, you change it whereever it's used
13:07:16  <planetmaker> maybe there's one or two different date formats per language, I don't recall
13:07:18  *** supermop has joined #openttd
13:08:41  *** iSoSyS has quit IRC
13:10:10  *** snail_UES_ has quit IRC
13:36:46  *** Mahjong1 has quit IRC
13:37:12  *** Mahjong has joined #openttd
13:51:04  *** nielsm has joined #openttd
14:00:17  <peter1138> Why do I find terminals and vim much easier to develop OpenTTD in than VS 2017?
14:00:53  <peter1138> Maybe it's because it doesn't need a mouse.
14:01:02  <LordAro> because it is the best?
14:01:42  <peter1138> :D
14:06:04  *** Alberth has joined #openttd
14:06:04  *** ChanServ sets mode: +o Alberth
14:06:28  <Alberth> hi hi
14:08:08  <nielsm> oh wow
14:08:11  <nielsm> you know what?
14:08:22  <nielsm> OpenTTD has been running at 32.25 fps on windows the whole time
14:08:36  *** sim-al2 has quit IRC
14:09:03  <nielsm> I tried changing win32_v.cpp to use timeGetTime() and timeBeginPeriod(MILLISECONDS_PER_TICK) and now my fps display is showing 33.33
14:10:32  <LordAro> lol
14:11:10  <nielsm> juuuust gonna add a little additional change to my fps-meter branch
14:11:41  <Alberth> moaar  tweaks!
14:15:41  <LordAro> sounds like my branches :p
14:24:35  <peter1138> What happens with SDL on Windows?
14:24:42  <peter1138> Not that anybody uses it.
14:24:43  <nielsm> I don't have SDL handy
14:25:14  <peter1138> I did compile with it not that long ago when I was testing the mouse cursor glitching. Didn't make any difference to that so I dropped it.
14:25:48  <peter1138> Might try SDL in my VM, however since the last big Windows up that runs horribly slowly now :(
14:30:03  <LordAro> i could try sdl on my msys install later
14:30:12  <LordAro> actually, no, i'm going to the pub
14:43:12  <nielsm> made the vertical scaling variable!! http://0x0.st/sLGZ.png
14:45:48  *** sla_ro|master has joined #openttd
14:48:49  <peter1138> Those worst figures are suspiciously whole numbers...
14:50:10  *** Gja has joined #openttd
14:51:28  <nielsm> well yes those are single measurements, they don't come more accurate than ms (atm)
14:53:17  <LordAro> but "current" is sub-ms ?
14:54:46  <peter1138> ^
15:01:43  <nielsm> current is actually average of 8 measurements
15:02:24  <nielsm> I think I'll change the values to be averages over time instead of number of data points
15:02:52  <nielsm> so "current" is average over 0.2 s, "average" is over 10 sec
15:03:02  <nielsm> and just drop "worst"
15:03:14  <nielsm> (and instead adding a peak highlight to the graphs)
15:21:34  <peter1138> Use an HR timer :-)
15:22:16  <nielsm> I am actually using the QPC timer on windows now, but all the code already assumed milliseconds by the time I switched
15:23:33  <LordAro> std::chrono::high_resolution_clock
15:23:35  <LordAro> ftw
15:23:45  <nielsm> yeah maybe that'd be the better choice
15:24:00  <nielsm> and just hope everyone implements it :P
15:24:01  <LordAro> does mean actual c++11 tho :)
15:24:16  <LordAro> but it's about time someone made the leap
15:24:34  <Eddi|zuHause> no way, we never use modern language features... what would the world come to?!?
15:24:44  <LordAro> my msys fun has revealed just how much crap is left in to support ancient compilers
15:24:49  <planetmaker> our c++11 advocate hath spoken ;)
15:24:49  <Eddi|zuHause> where does it END???
15:24:50  <planetmaker> hihi
15:24:57  <LordAro> o/
15:26:21  <Eddi|zuHause> LordAro: what fun it was when we still supported GGC 2.ancient :p
15:26:23  <Alberth> o/
15:26:25  <Eddi|zuHause> GCC
15:26:49  *** Progman has joined #openttd
15:27:08  <nielsm> I am using "auto" types and anonymous functions in this code, in fact :3
15:27:17  <planetmaker> lol :D That was even before my time @ Eddi|zuHause :)
15:27:34  <planetmaker> and even then the hacks around gcc 3.x were ... scoleded upon
15:27:38  <Eddi|zuHause> when people insisted that MorophOS was some vivid community :p
15:27:57  <LordAro> Eddi|zuHause: nooo
15:29:08  <Eddi|zuHause> back when we dropped that, there were talks about *maybe* a new update for MorphOS that contains GCC4
15:29:23  <Eddi|zuHause> no idea whether that happened
15:31:01  <peter1138> Seems to be on 6.4.0 now.
15:31:19  <Eddi|zuHause> "(svn r4691) - Codechange: don't use unnamed unions as GCC 2.95.ancient won't compile it. Needed for our MorphOS user ;)"
15:31:21  <peter1138> Incidentally in September in 2013, they passed 2000 MorphOS registrations.
15:33:00  <Eddi|zuHause> i thought "that's something peter1138 would say", and then i looked at the other commit data :p
15:33:25  <nielsm> http://0x0.st/sLGJ.mp4
15:33:28  <nielsm> scaling in action
15:34:29  *** Thedarkb-X40 has quit IRC
15:35:31  <Eddi|zuHause> "(svn r16492) -Remove: support for gcc2. It hasn't been able to compile OTTD for months. All attempts to do another workaround failed."
15:35:38  <nielsm> (it's a debug build so performance is atrocious, intentional to show that the scaling actually works)
15:36:27  *** Cubey has joined #openttd
15:43:12  <LordAro> nice
15:43:21  <LordAro> Eddi|zuHause: ha
15:51:49  *** ANIKHTOS has joined #openttd
15:53:12  *** chomwitt has joined #openttd
15:54:03  *** TheMask96 has quit IRC
15:54:33  *** Gja has quit IRC
15:54:51  <ANIKHTOS> hello how are you??
15:55:09  *** TheMask96 has joined #openttd
15:59:29  <ANIKHTOS> alberth when you load ottd and you start a new game?? i have some new variable made the game will run the code and initialize them right??
15:59:56  *** Gja has joined #openttd
16:00:43  <ANIKHTOS> i am experience this behavior
16:02:54  <ANIKHTOS> when i load the game the game runs wronguntil it manage topass to the slow day. then if i start another game or  load a game the game works okey the odd behavior is that it autosave every nomrla day until the first slwo day pass
16:03:06  <ANIKHTOS> do you have any idea why it behaves like this???
16:08:21  <ANIKHTOS> i would apreciate if you try the patch and tell me if i break game meachanics thats what i am interest for   in this stage of developemnt
16:08:56  <ANIKHTOS> showing information will be corrected in phace 2 but most important is not to break the game
16:09:20  <Alberth> if you coded initialization, it will initialize
16:09:50  <ANIKHTOS> well i declare them and then i assign a value later on
16:10:16  <Alberth> hmm, there was some function for that, have to find that
16:15:43  <ANIKHTOS> oh well i am happy i dive in the code of ottd i went from statubar-gui.cpp >english.txt>strings.cpp back to english.cpp then to another 2 files but i made the changes to display the date with time indicator now you can see the normal days pass as time
16:16:11  <ANIKHTOS> you can change the factor of how slow it is inside the game seems to work with no problems!?!?!?
16:18:08  <Alberth> try it in a multi-player game :)
16:18:16  <Alberth> hmm, can't really find it
16:19:02  <Alberth> did you look what comes up if you look for startgame or newgame (with any case) ?
16:19:54  <Alberth> although there are only 4 likely options, StartGame Startgame NewGame Newgame
16:21:43  <Alberth> hmm, simple path is to check all places where the original date gets set??
16:22:28  <ANIKHTOS> in the window where yo create the game
16:22:37  <ANIKHTOS> how is this windows called??
16:22:57  <ANIKHTOS> genworld.cpp??
16:23:15  <ANIKHTOS> gneworld-guil.cpp??
16:23:16  <Alberth> find a string that is used in the window, in src/lang/english.lng
16:23:32  <Alberth> then look in the code for that string name
16:23:58  *** KouDy has quit IRC
16:24:08  <Alberth> I don't think we have windows with a name that ends in .cpp :p
16:24:48  <Alberth> nor any dashes in a filename
16:25:08  <ANIKHTOS> genworld_gui.cpp
16:25:18  <Alberth> that could work
16:25:23  <ANIKHTOS> there is this file is that when you start a new game??
16:25:48  <Alberth> but the gui is just a layer on top of the core simulation
16:27:04  <Alberth> it's just a load of code so you can tell the simulation what you want to happen
16:27:26  <Alberth> actually doing anything is not in gui, it's in *_cmd.cpp
16:27:30  *** KouDy has joined #openttd
16:28:08  <Alberth> but starting a new game is not in the simulation, since by definition you're not running one when you activate it
16:29:53  <ANIKHTOS> int x():if i write the code liek this one tutorial say it will give default value 0 is it correct??
16:31:33  <Alberth> I'd say that is a declaration of a function named x without parameters, returning an int
16:31:56  <Alberth> it does need a semicolon at the end though
16:32:55  <ANIKHTOS> ottd is c++11??
16:33:12  <Alberth> some parts of it
16:33:36  <Alberth> simpler solution is to just initialize explicitly, ie   int x=0;
16:33:57  <ANIKHTOS> i am ddoign that
16:34:51  <ANIKHTOS> line 35 declare the variable  line 74 asign a value
16:34:58  <ANIKHTOS> is the same??
16:36:14  *** HerzogDeXtEr has joined #openttd
16:44:08  <Alberth> line 35 of what?
16:44:46  <Alberth> there are around 300 lines 35 in openttd
16:45:02  <ANIKHTOS> in date.cpp i declare the varialbe in line 74 of the same file i asign the value 0
16:46:16  <Alberth> oh, you're speaking of modified files even, I don't have those
16:46:23  <ANIKHTOS> line 35 uint16 _dayn; line 74 _dayn=0;
16:46:32  <Alberth> ok
16:46:41  <ANIKHTOS> that count as intitilization right??
16:46:54  <ANIKHTOS> or you mean intitilize at declaration??
16:47:04  <Alberth> the latter does, the former I am not sure, I assume not
16:47:16  *** supermop has quit IRC
16:47:17  <ANIKHTOS> and amke line 35 uint16 _dayn=0;
16:47:57  <Alberth> how does that help?
16:48:26  <Alberth> no idea what happens at lines 36 to 73 btw
16:48:45  <ANIKHTOS> line 36 more variables declared
16:48:52  <Rubidium> 73 is in the middle of an enumeration (at least for me ;))
16:48:56  <ANIKHTOS> and line 75 i asign a value to a variable
16:49:13  <SpComb> sounds like this discussion should be happening on github
16:49:43  <Alberth> paste the relevant code part in a pastebin
16:50:02  <Alberth> you have a chat at github?
16:50:19  <SpComb> pull request review comments
16:51:21  <Alberth> that assumes I have an interest in longer game-play :p
16:51:31  *** Wolf01 has joined #openttd
16:51:36  <Alberth> I don't even manage to play the 150 years of the original :)
16:51:41  <Alberth> hi hi Wolf
16:51:48  <Wolf01> o/
16:51:57  <Alberth> less devastated today?
16:52:25  <Wolf01> Yes, a bit, still too much hot to be comfortable
16:52:30  *** KouDy has quit IRC
16:52:33  <SpComb> Alberth: not dedicated enough to put 100h+ into a single game of openttd? :)
16:52:35  <Wolf01> 32°C at 18.00
16:53:02  <ANIKHTOS> https://paste.openttdcoop.org/p71e4pnrl
16:53:04  <Alberth> nope, 40 game years is enough :)
16:53:49  <ANIKHTOS> 32c is not bad wolfi at least for my country
16:54:08  <Alberth> oh, code is not even executed together
16:54:53  <Wolf01> ANIKHTOS, yeah, but you are about 900km below me
16:55:33  <ANIKHTOS> so you are north around gemany location??
16:55:40  <SpComb> I see global variables with single-letter suffixes, so I'll just look away
16:55:42  <Wolf01> NE Italy
16:56:11  <ANIKHTOS> i was in berlin and they had heat wave with 20c lol
16:56:13  <ANIKHTOS> so funny
16:57:37  *** rocky1138 has joined #openttd
16:59:07  <ANIKHTOS> wolf01 will you test the code to see if i break game mechanics??
16:59:37  *** Wormnest has joined #openttd
17:00:32  <Wolf01> Maybe, if I'll find time to play
17:00:45  <ANIKHTOS> thank you
17:01:14  <ANIKHTOS> and hell wolf01 is when ti goes above 40c then everythign you touch is warm going its liek lviign in a sauna
17:01:56  <Wolf01> :)
17:02:07  <ANIKHTOS> a few years back we have 7 days at 45c and a fire in the outkirt of the town  to make thigns a bit worse :-) that was  awfull
17:03:37  <peter1138> Hmm, even with std::chrono::high_resolution_timer I'm still seeing more than 30ms per tick.
17:05:37  <nielsm> peter1138, using it for the main loop timing?
17:05:42  <peter1138> Oh. On the other hand, my FPS is showing as 33.33.
17:05:44  <peter1138> nielsm, yes.
17:06:34  <peter1138> Forgot I was editing in my PR branch of your fps patch, so I can just open the fps window :p
17:06:40  *** Thedarkb has joined #openttd
17:07:33  <peter1138> 18:03 < peter1138> Hmm, even with std::chrono::high_resolution_timer I'm still seeing more than 30ms per tick.
17:07:39  <peter1138> Well I take that back, it appears to work.
17:08:09  <peter1138> Although with that as the timing loop, maybe the drivers can be reorganised so the main game loop isn't actually in the drivers...
17:10:09  <nielsm> I think the system window interface would have to become more complicated then
17:10:13  <peter1138> 8.4 fps with that big Wentbourne save.
17:10:32  <nielsm> since it still needs to hook into a bunch of system things
17:12:59  <peter1138> It was a maybe ;)
17:22:23  *** synchris has joined #openttd
17:22:34  *** Flygon has quit IRC
17:22:47  <nielsm> slightly more fps-meter changes pushed... needless to say (?) I intend it all to be squashed before a merge ;)
17:23:01  <nielsm> except perhaps a change to main loop timing behavior
17:28:44  <LordAro> nielsm: there are some here who would prefer it not to be squashed into a single commit
17:29:20  <peter1138> Depends what it is.
17:29:26  <LANJesus> so link back to a branch that has the history?
17:29:31  <LANJesus> in the commit message
17:29:39  <peter1138> Sometimes all the history is not useful.
17:30:17  <LANJesus> indeed. a bunch of "whoops forgot X" "fix formatting" "center widget" "asdfasd"
17:30:22  <LANJesus> helps no one
17:30:56  <nielsm> yeah in this case most of the history is just experimenting with what is actually useful
17:31:17  <LANJesus> i need to get in the habbit of commiting to my personal private repos and squashing significant updates there
17:31:51  <LANJesus> i develop across multiple machines. committing and pushing frequently is a thing : |
17:36:49  *** gelignite has joined #openttd
17:46:42  *** planetmaker_ has joined #openttd
17:50:27  *** frosch123 has joined #openttd
17:57:37  <peter1138> Is a good thing.
18:08:44  <nielsm> working on making framerate_gui use microsecond precision
18:15:07  *** Gja has quit IRC
18:28:19  <nielsm> http://0x0.st/sLDL.png  <- looks a little smoother then
18:28:32  *** Gja has joined #openttd
18:36:02  <LANJesus> nielsm: any reason you don't use https links? for some reason your mp4 links don't work in standard http
18:36:27  <nielsm> because it's what the program I use to capture and upload with returns...
18:36:30  <nielsm> I'll check if I can reconfigure it
18:36:41  <LANJesus> ah ok
18:36:58  *** KouDy has joined #openttd
18:39:47  <peter1138> Looks better
18:40:33  <peter1138> Did you reuse any of the existing graph code?
18:40:43  <nielsm> nope
18:40:54  <nielsm> I tried reading it and just got confused, was faster to write my own
18:41:14  <Eddi|zuHause> i don't think the existing graphs are actually any good
18:49:45  <nielsm> funny thing is that I can't get the fps meter to show 33.33 any longer, after changing to microsecond precision
18:52:25  <nielsm> http://0x0.st/sLDJ.png  :angry:
18:53:32  <nielsm> also :puke: at the coding style of the STL included with MSVC, but that's another story
18:53:53  <LANJesus> stepping through their code?
18:53:59  <nielsm> just looking at it
18:54:05  <nielsm> to check what it actually does
18:54:08  <LANJesus> "Legacy"
18:57:58  *** glx has joined #openttd
18:57:58  *** ChanServ sets mode: +v glx
19:01:00  *** synchris has quit IRC
19:01:53  <nielsm> is this a good thing to add? http://0x0.st/sLDx.png
19:03:59  <Wolf01> Nice, I always wondered how fast was the FF on my systems
19:04:44  <LANJesus> yes nielsm. i like it
19:04:56  <LANJesus> some of these would be neat additions to the status bar
19:05:03  *** Supercheese has joined #openttd
19:06:36  <ANIKHTOS> very good nielsm
19:06:37  <nielsm> maybe the window should instead collapse to just a title bar showing gameloop fps and speed factor?
19:08:36  *** Wacko1976 has joined #openttd
19:11:13  <LANJesus> nielsm: or more, if there's width?
19:21:02  <Alberth> it's a game, not a "see how fast my computer is" display :p
19:21:54  *** sla_ro|master has quit IRC
19:21:59  *** Alberth has left #openttd
19:29:01  <LANJesus> ...
19:29:23  <LANJesus> i would be using it more for profiling bad (ill-performing) code
19:30:30  <nielsm> hmm, how does the GUI system respond to adding multiple controls with the same ID in a window?
19:36:17  *** KouDy has quit IRC
19:38:14  <peter1138> Pretty sure you can't.
19:42:28  <nielsm> https://0x0.st/sLDd.mp4   doing weird things...
19:43:07  <nielsm> I think I know what the mistake is
19:43:57  <peter1138> git definitely doesn't work right on my Windows install :S
19:44:16  <peter1138> git stash; git checkout master complains of changed files...
19:45:21  <nielsm> http://0x0.st/sLDn.png  http://0x0.st/sLD5.png
19:45:30  <nielsm> that's a fancy zoom!
19:46:12  <Eddi|zuHause> peter1138: nonnative eol? filename case mismatch?
19:47:25  <LordAro> at what point does the graph rendering take most of the cpu time?
19:47:53  <nielsm> when your CPU has a really bad FPU
19:47:56  <nielsm> is my guess
19:48:32  <nielsm> or is bad at handling 64 bit integers
19:48:52  <peter1138> graph rendering drops my FPS from around 850 to 500
19:48:56  <peter1138> So there is quite a hit :p
19:48:59  <Eddi|zuHause> i imagine it needs to have really not much to do else
19:49:31  <peter1138> Hmm, not enough measurements in FFWD :)
19:50:13  <nielsm> yeah 512 data points can become too little for 2 seconds of graphing
19:51:08  *** Montana has joined #openttd
19:54:10  <peter1138> 32.9 fps
19:54:12  <peter1138> Hmm.
19:54:27  <peter1138> So 33.33 exact was another rounding product? :D
19:54:38  *** KouDy has joined #openttd
19:54:39  <nielsm> I think? :(
19:57:56  <nielsm> question is if you want to add some kind of time compensation into the main loop to adjust for the slight falling behind, but somehow only when there's spare time
19:58:16  <ANIKHTOS> does anyone have any idea when i start ottd with my patch code the first game i play for the N days i have chosen to slow down i will get also autosave!!!! but that behavior happens only at the first game an donly for the first N factos days
19:58:28  <ANIKHTOS> if i start or load another game after that all works fine
19:59:09  <peter1138> Yeah, I can get it to 33.3x by just making it catch up.
20:00:06  <peter1138> next_tick = next_tick + MILLISECONDS_PER_TICK instead of next_tick = cur_ticks + MILLISECONDS_PER_TICK
20:00:31  <peter1138> Needs fixing FFWD :)
20:00:53  <nielsm> but if tick processing takes too long you need to adjust for that
20:01:07  <peter1138> Ish
20:01:09  <nielsm> I think that will break when the cpu can't keep up
20:02:34  <peter1138> Yes it needs tweaking for that, I wasn't suggesting it as a full solution.
20:02:53  <peter1138> Just a quick test to show that that is what stops 33.33 from being attained.
20:04:16  <nielsm> ahh, got the sizing of the micro-window fps display right now
20:04:27  <nielsm> was passing the wrong string id to GetStringBoundingBox
20:05:40  <nielsm> now if there was a neat way to get it sized the same as the status bar height, but still be draggable like a caption...
20:06:45  <peter1138> I think if you end up in the else condition of the timer loop, then it's fair to say you can play catch up.
20:07:07  <peter1138> If you don't hit the else, then there's no spare time.
20:07:32  <nielsm> and conversely, if cur_ticks > next_tick + MILLISECONDS_PER_TICK then you're definitely behind
20:07:59  <peter1138> that may be an easier test
20:09:13  <peter1138> next_tick = _fast_forward ? cur_ticks : (cur_ticks > next_tick ? cur_ticks : next_tick) + MILLISECONDS_PER_TICK;
20:09:16  <peter1138> kinda ugly :(
20:10:06  <peter1138> Oh, that doesn't wokr. Hm.
20:11:04  <peter1138> 			next_tick = _fast_forward ? cur_ticks : (next_tick + MILLISECONDS_PER_TICK);
20:11:05  <peter1138> 			if (cur_ticks > next_tick) next_tick = cur_ticks + MILLISECONDS_PER_TICK;
20:11:08  <peter1138> I guess.
20:14:22  <peter1138> Hmm, the _fast_forward bit isn't right.
20:15:27  <nielsm> in ffwd it should basically disregard next_tick entirely, right?
20:15:43  <nielsm> and just process a step every chance it gets
20:16:29  <peter1138> Best to keep the existing algorithm for it.
20:16:39  <peter1138> next_tick = (_fast_forward ? cur_ticks : next_tick) + MILLISECONDS_PER_TICK; should do the trick
20:17:39  <peter1138> Yeah, that works.
20:18:22  <peter1138> The main timer if condition already ignores the ticks, no need to change that.
20:20:44  *** Gja has quit IRC
20:26:39  <nielsm> I'd also be interested in how that plays together with the PR #6780 changes (Refactor window ticks into game ticks and realtime events)
20:26:59  *** sim-al2 has joined #openttd
20:27:00  <nielsm> would it let simulation run faster than graphics output i.e. skip frames?
20:27:34  <peter1138> It can do.
20:29:11  <peter1138> I still find the frames/s display takes longer than necessary to settle.
20:35:45  <nielsm> framerate_gui.cpp:94: if (now - _framerate_timestamps[elem][point] >= TIMESTAMP_PRECISION) break;
20:35:54  <nielsm> try changing to TIMESTAMP_PRECISON/5
20:36:02  <nielsm> so it bases on just 0.2 sec
20:36:50  *** Montana has quit IRC
20:36:57  *** iSoSyS has joined #openttd
20:41:50  <Wolf01> 'night
20:41:53  *** Wolf01 has quit IRC
20:42:07  <peter1138> Yeah that's far better.
20:42:21  <peter1138> Of course it fluctuates a little more.
20:45:42  <peter1138> Also, actually looking at the code rather than testing it's functionality...
20:47:06  <peter1138> 5 global arrays instead of structs is a bit weird.
20:47:25  <__ln__> https://www.nytimes.com/2018/06/19/climate/koch-brothers-public-transit.html
20:47:28  <nielsm> it started out with fewer ;)
20:47:38  <nielsm> yeah could take some cleanup
20:48:25  <peter1138> _framerate_durations[elem][_framerate_next_measurement_point[elem]] = end_time - start_time;
20:48:28  <peter1138> ->
20:48:43  <peter1138> this->durations[this->next_point] = end_time - start_time;
20:49:13  <peter1138> It's not very C++ as it is :-)
20:54:20  *** testuser123 has joined #openttd
20:55:00  <testuser123> Hey, has anyone an idea why my train stops at this path signal, saying "no paths" ? https://imgur.com/a/hwCd83l
20:55:15  <testuser123> Note that the depot on the left side is empty
20:55:51  <Eddi|zuHause> missing electrification?
20:57:25  <glx> you made transparent too many things
20:58:09  <testuser123> @Eddi|zuHause If I force it to pass the signal, it reaches Fahrberg (its next station)
20:58:47  <Eddi|zuHause> i think it's not actually a path signal
20:59:44  <glx> with the train it's hard to see the signal pole ;)
20:59:47  <testuser123> The question mark says it's a one-side path signal
21:00:10  <Eddi|zuHause> then turn on showing path reservations
21:00:27  <Eddi|zuHause> also, press Ctrl+X, make the houses invisible, and everything else visible
21:00:36  <glx> maybe a ghost reservation yes
21:00:45  <testuser123> oh, how do I show them?
21:01:02  <glx> it's somewhere in the settings
21:01:07  <Eddi|zuHause> i think it's in one of the advanced setting categories
21:01:35  <LANJesus> i tend to apply rules of three to ... things. three globals? shove those in a struct/class/state instance. three parallel arrays? put them in a struct or make an array of structs... bla bla bla
21:01:39  <__ln__> peter1138: https://github.com/OpenTTD/OpenTTD/issues/4449#issuecomment-396926629
21:03:12  <testuser123> "highlight reserved tracks"?
21:03:16  <Eddi|zuHause> yes
21:03:40  <Eddi|zuHause> exact wording might differ between languages
21:04:07  <Eddi|zuHause> __ln__: i think as long as it doesn't break anything, keep both as options?
21:04:37  <peter1138> Wut?
21:05:15  <testuser123> better image: https://imgur.com/a/5tg3JMF
21:06:55  <Eddi|zuHause> testuser123: difficult to see, but i still think it's missing electrification
21:07:00  <testuser123> reserved tracks are highlighted
21:07:41  <ANIKHTOS> change th e right singla to sstation to 1 way
21:07:42  <Eddi|zuHause> testuser123: there's a pylon on the right track after the first tile of the station, but none on the left track
21:07:59  <Eddi|zuHause> testuser123: so one of those seems to be missing electrification
21:11:51  <testuser123> I rebuilt all tracks that were suspicious of non electrified, but it did not help. I tried running another electriefied train there, it's all fine
21:12:23  <testuser123> Either I'm misunderstanding how you need to place path signals, or it's a bug
21:13:26  <Eddi|zuHause> open the "electrified rail" toolbar, press "convert", and drag&drop over the whole screen
21:14:48  *** gelignite has quit IRC
21:14:49  <Eddi|zuHause> next issue might be the signal at the other end of the platform. the path reservation might not recognize it as safe waiting spot
21:15:18  <ANIKHTOS> https://www.tt-forums.net/viewtopic.php?f=31&t=83388
21:15:20  *** Wormnest has quit IRC
21:15:25  <ANIKHTOS> do one of the changes in the signals
21:15:47  <Eddi|zuHause> the regular pathfinder ends its search at the station, but the path reservation wants to go on until it finds a signal to end on
21:15:53  <ANIKHTOS> either reverse the signla on top of the station or make the entry singla 1 way
21:16:26  <nielsm> peter1138: I'll look at code cleanup tomorrow
21:16:29  <glx> usually one-way signals should face the station
21:16:30  <nielsm> for now, good night :)
21:16:33  <__ln__> Eddi|zuHause: that's a reasonable solution for Windows, but the other option would be useless on at least OS X.
21:16:47  <ANIKHTOS> goo dnigh nielsm
21:17:04  <Eddi|zuHause> __ln__: well, hide the "useless" options on systems that don't support it, or are not implemented there
21:17:54  <Eddi|zuHause> ANIKHTOS: that forum post could use an explanation text for people who don't see this conversation
21:18:04  <__ln__> i also have my doubts how useful a "real" fullscreen is on linux... does it have an advantage?
21:18:07  <testuser123> Eddi|zuHause: it says no suited tracks for the whole map
21:18:21  <Eddi|zuHause> testuser123: then look at ANIKHTOS' picture
21:18:34  <Eddi|zuHause> testuser123: that signal that he circled is what i'm talking about
21:19:15  <ANIKHTOS> the path signals and stations are tricky  to use
21:19:23  <ANIKHTOS> or else traisn will nto enter or leave the station
21:19:44  <ANIKHTOS> either reverse the gignla show to be reversed or make the other signal 1 way
21:19:59  <Eddi|zuHause> imho, the back of such a one way signal should be treated like end of line, but the discussion about that went nowhere last time
21:20:38  <testuser123> ANIKHTOS: both of your suggestions let the train drive
21:20:57  <ANIKHTOS> i know i had problems in my stations
21:21:06  <ANIKHTOS> playcign path singal a specific way station works
21:21:10  <ANIKHTOS> othe rway not accessible
21:21:30  <peter1138> __ln__, yes, you can have the game at a different resolution to your desktop resolution.
21:21:31  <testuser123> Both is not what I wanted, but turning the right circled signal into a one-way path signal solves it
21:21:54  <peter1138> Not everyone cares about pixels being a 1:1 match
21:22:02  <ANIKHTOS> well change the top then
21:22:05  <testuser123> It looks like you always need enough one way path signals around stations
21:22:08  <Eddi|zuHause> testuser123: it really should be a path signal at the other end
21:22:15  <ANIKHTOS> the tracks will be  the same in fucntionality
21:22:27  <__ln__> peter1138: that's assuming there are other possible resolutions configured to the X server, which quite often isn't the case, i would say.
21:22:29  <peter1138> And many people seem to find proper fullscreen mode is faster. Maybe it's a low-end GPU thing. It probably affects compositing.
21:22:43  <Eddi|zuHause> testuser123: mixing path and block signals can have nasty side effects
21:22:54  <peter1138> No, pretty much all the standard old resolutions are autoconfigured in X anyway.
21:23:18  <testuser123> Eddi|zuHause: That works. I usually thought the rule of thumb was: any area of tracks where you can drive in with one path signal must be only accessible through path signals.
21:23:22  <peter1138> And also they are there in Windows too.
21:23:33  <testuser123> But this does not suffice here
21:23:54  <Eddi|zuHause> testuser123: yes, and that applies here. train can come from one side into the station through path signal, but from other side through block signal
21:24:31  *** nielsm has quit IRC
21:24:33  <__ln__> peter1138: yes, and switching to a low resolution on Windows messes up the taskbar, so it's not really a good idea.
21:24:47  <testuser123> Now that you say it...
21:24:53  <Eddi|zuHause> __ln__: on linux it messes your window positions
21:26:01  <__ln__> Eddi|zuHause: should we aim for a portable mess, where all the same things are messed on all platforms
21:26:12  <peter1138> Doesn't mess up my taskbar.
21:26:41  <Eddi|zuHause> __ln__: that seems like a total trump thing to do
21:27:14  <peter1138> SDL 1.2 is messed up anyway.
21:27:25  <peter1138> Wasn't there an SDL 2 patch somewhere?
21:28:20  <ANIKHTOS> eddi i need your expertise i am havign a strange bug with my code
21:28:31  <ANIKHTOS> and i do not know why i have this behavior
21:28:55  <Eddi|zuHause> how have i become the expert on terrible code?
21:29:11  <__ln__> peter1138: as you suggested "switching from fullscreen toggle to a tristate", can you elaborate what are the fullscreen mode state transitions when pressing Alt-Enter a few times?
21:29:48  <Eddi|zuHause> __ln__: windowed and <whichever fullscreen flavour was last used>
21:29:51  <peter1138> Depends what modes the backend supports.
21:30:12  <ANIKHTOS> when i start the pached ottd  it does nto matter if i load a game or start a new game, for the first N ftimes where n it th eslow tiem factor the game will autosave every day !?!?!??! after that it works normally, if i load another game or start  a new one there is no problem
21:30:32  <ANIKHTOS> its only when is tart the game and only for the first n days of the game
21:31:00  <ANIKHTOS> i can not grasp what is so special iin the first n days to amke game behave like this
21:31:07  <peter1138> __ln__, not really, I don't care about it enough to bother answering your passive-aggressive tone of questioning.
21:31:41  <peter1138> Seems to be a common feature of anything you say here.
21:31:49  <peter1138> Are you sure you are not Tron?
21:32:08  <Eddi|zuHause> now THAT would be a plot twist
21:32:13  <peter1138> Heh
21:32:32  *** Progman has quit IRC
21:35:45  <__ln__> well, see what happens when i get derailed to on-topic discussions.
21:36:01  *** HerzogDeXtEr has quit IRC
21:36:02  <__ln__> should definitely avoid that again.
21:39:32  <ANIKHTOS> anyone any idea???
21:42:10  *** __ln__ has left #openttd
21:46:27  *** frosch123 has quit IRC
21:56:38  *** Thedarkb has quit IRC
22:00:11  <ANIKHTOS> and eddi my code is nto bad :P
22:00:32  <ANIKHTOS> it is aawfull no dcoumentation codign style what ever
22:01:35  <LordAro> and yet you still can't get letters in the correct order
22:02:00  <ANIKHTOS> its th elaptop keyborad that is fuck up a bit
22:02:10  <ANIKHTOS> some keys are easy to click some not
22:02:19  <ANIKHTOS> old laptop
22:02:21  <LordAro> most people go back and correct typos
22:03:03  <glx> or slower typing :)
22:03:06  <ANIKHTOS> guilty lordara i will try to be better from now on
22:03:25  <ANIKHTOS> i will type slower to be sure i type correct
22:05:16  <ANIKHTOS> the date.cpp run all code and when it gets to the void IncreaseDate() it just loop inside this one???
22:16:18  *** Wacko1976 has quit IRC
22:35:36  *** planetmaker_ has quit IRC
22:37:15  *** chomwitt has quit IRC
22:37:46  <ANIKHTOS> silenceeeeeeeeeeee
23:14:50  <Eddi|zuHause> in the library
23:44:46  *** KouDy has quit IRC
23:59:49  <ANIKHTOS> good night all

Powered by YARRSTE version: svn-trunk