Config
Log for #openttd on 7th June 2020:
Times are UTC Toggle Colours
00:03:46  <DorpsGek_III> [OpenTTD/OpenTTD] LordAro commented on pull request #8196: Fix: Adjust .gitignore to CMake build system. https://git.io/JfMs4
00:04:30  <DorpsGek_III> [OpenTTD/OpenTTD] LordAro approved pull request #8184: Cleanup: More code comment and doxygen fixes. https://git.io/JfMsB
00:04:45  <DorpsGek_III> [OpenTTD/OpenTTD] LordAro merged pull request #8184: Cleanup: More code comment and doxygen fixes. https://git.io/JfXst
00:10:05  *** blathijs has quit IRC
00:16:12  *** blathijs has joined #openttd
00:23:20  *** GT has joined #openttd
00:25:28  <GT> make: *** No targets specified and no makefile found.  Stop.
00:25:28  <GT> So how do I compile? I did a git pull and gmake like in the old days. Also cmake. .configure is gone.
00:26:24  <glx> there's a readme, but basically it's "mkdir build; cd build; cmake ..; make"
00:29:16  <GT> well, the readme is also gone, but I'll try this
00:31:44  <GT> CMake Error: The source directory ... OpenTTD" does not appear to contain CMakeLists.txt.
00:32:20  <GT> ls
00:33:50  <glx> ah yes the "readme" is COMPILING.md
00:35:27  <GT> find . -name COMPILING.md
00:35:42  <GT> ~/ottdsvn/trunk/OpenTTD $
00:36:45  <GT> no readme, no COMPILING.md
00:37:44  <DorpsGek_III> [OpenTTD/OpenTTD] glx22 commented on pull request #8196: Fix: Adjust .gitignore to CMake build system. https://git.io/JfMGu
00:38:21  <glx> https://github.com/OpenTTD/OpenTTD/blob/master/COMPILING.md <-- but there is one GT
00:43:19  <GT> git reset --hard
00:44:02  <GT> ~/ottdsvn/trunk/OpenTTD $  cd build; cmake ..; make
00:44:03  <GT> -- The C compiler identification is GNU 8.2.0
00:44:03  <GT> -- The CXX compiler identification is GNU 8.2.0
00:44:03  <GT> -- Check for working C compiler: /usr/bin/cc
00:44:03  <GT> -- Check for working C compiler: /usr/bin/cc -- works
00:44:04  <GT> -- Detecting C compiler ABI info
00:44:04  <GT> -- Detecting C compiler ABI info - done
00:44:06  <GT> -- Detecting C compile features
00:44:06  <GT> -- Detecting C compile features - done
00:44:08  <GT> -- Check for working CXX compiler: /usr/bin/c++
00:44:08  <GT> -- Check for working CXX compiler: /usr/bin/c++ -- works
00:44:10  <GT> -- Detecting CXX compiler ABI info
00:44:10  <GT> -- Detecting CXX compiler ABI info - done
00:44:12  <GT> -- Detecting CXX compile features
00:44:12  <GT> -- Detecting CXX compile features - done
00:44:14  <GT> -- Detecting Personal Data directory - .openttd
00:44:14  <GT> -- Detecting Shared Data directory - (not set)
00:44:16  <GT> -- Detecting Global Data directory - /usr/local/share/games/openttd
00:44:16  <GT> -- Looking for pthread.h
00:44:18  <GT> -- Looking for pthread.h - found
00:44:18  <GT> -- Looking for pthread_create
00:44:20  <GT> -- Looking for pthread_create - not found
00:44:20  <GT> -- Looking for pthread_create in pthreads
00:44:22  <GT> -- Looking for pthread_create in pthreads - not found
00:44:22  <GT> -- Looking for pthread_create in pthread
00:44:32  <glx> use a paste service next time
00:44:40  <glx> but cmake seems to work
00:45:18  <GT> Seems I messed up my local repo. git reset --hard did the trick
00:50:22  *** blathijs has quit IRC
00:50:42  <GT> [ 98%] Linking CXX executable openttd
00:50:42  <GT> [ 98%] Built target openttd
00:50:42  <GT> Scanning dependencies of target regression_files
00:50:42  <GT> [ 98%] Copying regression/info.nut regression file
00:50:42  <GT> [ 98%] Copying regression/main.nut regression file
00:50:44  <GT> [ 98%] Copying regression/require.nut regression file
00:50:44  <GT> [ 98%] Copying regression/result.txt regression file
00:50:46  <GT> [100%] Copying regression/test.sav regression file
00:50:46  <GT> [100%] Copying stationlist/info.nut regression file
00:50:48  <GT> [100%] Copying stationlist/main.nut regression file
00:50:48  <GT> [100%] Copying stationlist/result.txt regression file
00:50:50  <GT> [100%] Copying stationlist/test.sav regression file
00:50:50  <GT> [100%] Copying stationlist/test.sav regression
00:50:52  <GT> Yes, that's a lot better
00:51:33  <glx> and you don't need to run cmake each time
00:51:49  <glx> it's like configure
00:53:22  <dwfreed> if it's more than 3-5 lines, please for the love of everything, use a pastebin
00:54:06  <GT> You're right, I messed up. Sorry about that.
00:55:51  <GT> I think the openttd target is now also in the build dir. It used to be in the bin dir, so I guess if I replace the build in the commands above by bin, things are like they used to be again?
00:57:26  <glx> we should document about that I guess
00:57:40  *** GT has quit IRC
00:57:54  <glx> but you can run build/openttd from bin
00:58:03  <glx> and he's gone
01:05:05  *** Progman has quit IRC
01:06:54  *** blathijs has joined #openttd
01:15:48  *** Wormnest has quit IRC
01:18:29  *** Wormnest has joined #openttd
01:19:43  *** Gustavo6046 has quit IRC
01:21:04  *** Gustavo6046 has joined #openttd
01:21:58  <supermop_Home_> helicopters are back
01:27:32  *** blathijs has quit IRC
01:42:56  <DorpsGek_III> [OpenTTD/OpenTTD] techgeeknz commented on pull request #8184: Cleanup: More code comment and doxygen fixes. https://git.io/JfMnv
02:14:11  <DorpsGek_III> [OpenTTD/OpenTTD] glx22 updated pull request #8196: Fix: Adjust .gitignore to CMake build system. https://git.io/JfMLt
02:37:16  *** blathijs has joined #openttd
02:37:58  *** adikt has quit IRC
02:38:11  *** debdog has joined #openttd
02:41:35  *** D-HUND has quit IRC
02:43:35  *** tyteen4a03 has quit IRC
02:47:50  *** blathijs has quit IRC
02:50:48  *** Flygon has joined #openttd
02:53:55  *** namad7 has joined #openttd
02:55:21  *** namad7 has quit IRC
03:02:49  *** spnda has joined #openttd
03:04:33  <spnda> might be a little late, ik, but i am trying on my NRS patch again. So, anyone know why when I use DrawNewGRFTileSeqInGUI(x, y, dts, view, palette);, and view is a uint8 between 0-5, that each sprite is offset by 2, so that I get sprite IDs for 49, 51, 53, 55, 57, 59 instead of 49, 50, 51, 52, 53, 54?
03:04:55  <spnda> This has been bugging me quite a bit and I just am completely clueless on why this is happening and I really want to finish of my NRS patch.
03:20:11  *** tyteen4a03 has joined #openttd
03:28:25  *** glx has quit IRC
03:31:02  *** blathijs has joined #openttd
03:39:03  *** Speeder_ has quit IRC
03:41:48  *** Wormnest has quit IRC
03:44:30  *** spnda has quit IRC
03:56:10  *** blathijs has quit IRC
05:39:57  *** blathijs has joined #openttd
06:49:10  *** blathijs has quit IRC
06:55:23  *** Gustavo6046 has quit IRC
06:59:44  *** blathijs has joined #openttd
07:05:41  *** Progman has joined #openttd
07:28:19  *** Wormnest has joined #openttd
07:37:29  *** Smedles_ has quit IRC
07:37:44  *** andythenorth has joined #openttd
07:37:47  <andythenorth> yo
07:38:33  *** Smedles has joined #openttd
08:20:58  *** Wormnest has quit IRC
08:26:48  *** Gustavo6046 has joined #openttd
08:53:33  *** mobajl has joined #openttd
08:54:48  *** mobajl has quit IRC
09:00:27  <andythenorth> FLHerne FIRS parameter to adjust base primary production amounts?  I think it's probably quite easy to do
09:03:40  <nielsm> that would make sense yes
09:08:26  <andythenorth> not sure what bounds to give it, 0-100% is easy for reduction, but there would have to be an upper limit for increase
09:08:56  <nielsm> why would there?
09:09:11  <nielsm> if players want to challenge themselves with transporting absurd amounts of cargo let them
09:09:25  <andythenorth> well practically I have to define one in action 14
09:09:49  <andythenorth> it's not a gameplay issue, just implementation detail
09:10:20  <nielsm> just go for 64x
09:11:59  <nielsm> 64x, 32x, 24x, 16x, 12x, 8x, 6x, 4x, 3x, 2x, Standard, 3x/4, 2x/3, x/2, x/3, x/4, x/6, x/8
09:12:10  <nielsm> I'd like that list
09:12:12  <nielsm> :P
09:15:32  <andythenorth> seems plausible
09:15:38  <andythenorth> not sure the reductions are fine-grained enough
09:16:11  <andythenorth> I wonder if some would want 7/8 or so
09:16:23  <nielsm> or just a scale figure, default 100, min 8, max 6400
09:17:13  <andythenorth> also works
09:17:36  <nielsm> the actual production isn't perfectly scaleable anyway, since you can only produce whole units of cargo
09:18:23  <nielsm> so you have some quantisation going on that could also eventually cause a non-zero production scale to produce zero
09:20:15  <andythenorth> yes
09:21:12  <andythenorth> I should write this into my FIRS 'to do' notes
09:21:25  <andythenorth> if it's written down, it might get done :)
09:23:25  <andythenorth> 55 years into Steeltown game
09:24:04  <andythenorth> still got 4 cargo connections to make
09:26:00  <andythenorth> connections get dense https://dev.openttdcoop.org/attachments/download/9696/Teddybottom%20Transport,%2009-01-1978%232.png
09:26:55  <andythenorth> https://dev.openttdcoop.org/attachments/download/9697/Teddybottom%20Transport,%2009-01-1978%233.png
09:27:52  <andythenorth> boats are saviour :P
09:43:38  <_dp_> hm... I have a suspicion that clients sometimes don't fully sync command queue when connecting, but I don't see why.
09:44:36  <_dp_> e.g. I have a desync where client didn't get stations that were built while he was downloading the map
10:00:06  *** EER has quit IRC
10:00:27  *** gelignite has joined #openttd
10:11:07  <DorpsGek_III> [OpenTTD/OpenTTD] fsimonis opened pull request #8198: Fix: [CMake] Error when SDL2 provides SDL2Config https://git.io/JfM61
10:16:18  *** EER has joined #openttd
10:19:25  *** EER has quit IRC
10:19:26  <DorpsGek_III> [OpenTTD/OpenTTD] fsimonis opened pull request #8199: CMake always export compile commands https://git.io/JfM6x
10:19:28  *** EER has joined #openttd
10:24:22  *** WormnestAndroid has quit IRC
10:24:38  *** WormnestAndroid has joined #openttd
10:38:34  *** AndroUser has joined #openttd
10:46:45  <DorpsGek_III> [OpenTTD/OpenTTD] glx22 approved pull request #8198: Error when SDL2 provides SDL2Config https://git.io/JfMi4
10:55:09  <DorpsGek_III> [OpenTTD/OpenTTD] fsimonis opened issue #8200: Consider upgrading to C++17 https://git.io/JfMiD
10:55:50  *** arikover has joined #openttd
10:59:09  *** AndroUser has joined #openttd
10:59:23  <arikover> Hi!
11:00:10  <andythenorth> hi
11:02:17  *** AndroUser has quit IRC
11:02:58  <arikover> I noticed the CMake branch was merged to master. Nice! I gave it a try.
11:03:28  <arikover> Compiles well, except for some reason I have no sound effects. MIDI works fine though.
11:04:28  <arikover> I'm sure there is some parameter for cmake to be entered, but which?
11:04:48  <arikover> (I run Ubuntu 18.04)
11:05:16  <nielsm> depends on how you're testing (running the built program), the search locations for baseset data might be different
11:05:29  <nielsm> since the output files are placed in different directories
11:07:33  <andythenorth> hmm
11:07:43  * andythenorth curious
11:07:54  <andythenorth> what if there was a framework like GS, but in newgrf?
11:08:30  *** frosch123 has joined #openttd
11:09:11  *** Samu has joined #openttd
11:09:39  <Samu> hi
11:11:49  <Samu> this cmake thing creates a lot of files
11:12:06  <Samu> github desktop catches 1329 changes
11:12:12  <nielsm> you don't have to look at all the files
11:12:16  <arikover> nielsm: Thank you!
11:12:47  <nielsm> there's an updated .gitignore file on the way that should ignore all the generated "junk"
11:13:16  <Samu> oh, nice to know
11:14:18  <Samu> how do i build openttd with zlib png etc support
11:14:30  <andythenorth> hmm, what if I actually just learnt GS :P
11:15:07  <nielsm> andythenorth: that might be an idea
11:15:36  <nielsm> the issue with GRF is that the language and machine it executes is weird and impractical
11:15:54  <andythenorth> I got disillusioned with GS when I worked on Busy Bee with alberth
11:16:15  <nielsm> and otherwise you'd just be embedding squirrel code textually in the GRF
11:18:31  <andythenorth> I found I was committing state-destroying bugs to the repo with no clue that would happen
11:18:40  <andythenorth> and no real way to test
11:18:59  <andythenorth> it's almost impossible to commit those kind of bugs in newgrf
11:19:36  <andythenorth> can reload anything any time except cargo IDs
11:19:40  <DorpsGek_III> [OpenTTD/OpenTTD] fsimonis opened issue #8201: Consider upgrading CMake to latest release https://git.io/JfMP8
11:19:56  <andythenorth> and no need to handle saveload in newgrf
11:20:35  <nielsm> I think GS would be able to handle saveload easily, if you're careful how you design your internal data
11:20:38  <andythenorth> I don't expect a solution to that, GS is programming where newgrf just isn't
11:20:50  <andythenorth> newgrf is basically markup
11:22:08  <Samu> is there an updated guide to build openttd with lzma zlib, png support, im still unable to do it
11:22:23  <nielsm> not yet no
11:22:43  <andythenorth> somewhat I think I want to combine Silicon Valley and Busy Bee
11:22:53  <andythenorth> and generate it as part of the FIRS compile
11:23:16  <andythenorth> arbitrary goals about specific cargos and industries
11:23:27  <Samu> can't even load savegames :|
11:25:22  <DorpsGek_III> [OpenTTD/OpenTTD] LordAro commented on issue #8201: Consider upgrading CMake to latest release https://git.io/JfMP8
11:26:09  <nielsm> I think the issue is setting the correct VCPKG_TARGET_TRIPLET variable in the CMakeSettings.json
11:26:14  <nielsm> here's my settings: https://gist.github.com/nielsmh/290dd99611576f4f0cc8fb56fd6565c4
11:27:19  <nielsm> but I also remember messing around a lot with vcpkg itself, but maybe that was only to get clang-cl working (and that's a silly experiment not necessary for anything)
11:29:58  <nielsm> also, after changing the cmake settings you may need to clear the cache and stuff (right-click CMakeLists.txt in the solution explorer in visual studio)
11:33:37  <DorpsGek_III> [OpenTTD/OpenTTD] embeddedt commented on issue #8200: Consider upgrading to C++17 https://git.io/JfMiD
11:35:04  *** EER has quit IRC
11:37:00  <DorpsGek_III> [OpenTTD/OpenTTD] nielsmh merged pull request #8198: Error when SDL2 provides SDL2Config https://git.io/JfM61
11:39:11  <andythenorth> hmm sandbox mode would also solve a cargodist problem
11:42:05  *** frosch123 has quit IRC
11:42:10  *** Wolf01 has joined #openttd
11:42:39  <andythenorth> currently, in cdist game, it takes ~12 months for cargo to be assigned when a 2nd route is added to a station
11:42:54  <andythenorth> so I tend to run the game on ffwd, then reset the year back 12 months
11:43:15  <andythenorth> with sandbox, I could just skip resetting the date back
11:55:10  <Samu> i think it works now
11:55:43  <DorpsGek_III> [OpenTTD/OpenTTD] LordAro commented on pull request #8196: Fix: Adjust .gitignore to CMake build system. https://git.io/JfMXs
11:55:51  <Samu> VCPKG_TARGET_TRIPLET had x64-windows, i changed to x64-windows-static
11:56:02  <Samu> building to see
11:57:32  <andythenorth> these trains should have crashed https://dev.openttdcoop.org/attachments/download/9698/no_crash.png
11:57:43  <andythenorth> due to 'mistakes were made' by me
11:57:48  <andythenorth> they didn't, which is interesting
11:58:30  <Samu> confirmed, main menu savegame was loaded
11:58:32  <Samu> thx
12:07:56  <Wolf01> So... if I still use VS2017, what do I need to compile OTTD?
12:09:15  <nielsm> cmake
12:10:35  <Wolf01> Extension or something I need to download and install from some third party?
12:11:29  <nielsm> it's a program that will load the CMakeLists and associated config and generate VS project files from it
12:11:49  <nielsm> there might also be an extension to VS 2017 that streamlines things
12:12:02  <LordAro> is there any particular reason you wouldn't be able to upgrade to VS2019?
12:12:12  <Wolf01> SSD space
12:12:39  <Wolf01> Also I don't know if 2019 still support the old SDK version I use for windows 10 mobile
12:12:56  <LordAro> that's fair
12:13:00  <LordAro> also, windows mobile? ouch
12:13:08  *** glx has joined #openttd
12:13:08  *** ChanServ sets mode: +v glx
12:13:52  <Wolf01> Heh... I still use it and will do until I'll switch to the next surface duo (not sure I will buy the first batch of devices)
12:14:55  <Wolf01> Hmmm, the only extensions which seem related are a cmake project wizard and a vc solution to cmake (which seem the opposite of what I need)
12:16:03  <glx> too old VS ?
12:16:16  <Wolf01> 2017
12:16:35  <glx> cmake is included in 2017
12:16:43  <Wolf01> Hmm
12:17:05  <glx> maybe needs to be enabled in VS installer
12:17:11  <glx> (not sure)
12:17:13  *** sla_ro|master has joined #openttd
12:17:16  <Wolf01> I'll try
12:17:46  <Wolf01> Maybe I didn't enable it when I installed the C++ components
12:18:02  <glx> https://devblogs.microsoft.com/cppblog/cmake-support-in-visual-studio-the-visual-studio-2017-rc-update/
12:19:10  <glx> and that was in RC
12:20:49  <glx> https://docs.microsoft.com/fr-fr/cpp/build/cmake-projects-in-visual-studio?view=vs-2017
12:20:55  <glx> official doc :)
12:21:44  <Wolf01> Oook, it was deselected
12:23:05  <Wolf01> Yep, works now
12:23:52  <Wolf01> 1>   LZO not found; compiling OpenTTD without LZO is strongly disencouraged
12:24:34  <Wolf01> Hmmm, PNG and ZLIB too
12:24:48  <glx> ha yes you need to add stuff to the settings
12:25:03  <Wolf01> Oh, yes.. I had the old vcproj.user
12:25:14  <Wolf01> I think it's not valid anymore
12:25:17  <LordAro> glx: have you updated/rewritten the compile instructions on the wiki yet?
12:26:09  <glx> no, and I think the VCPKG_TARGET_TRIPLET trick is not in COMPILING.md either
12:27:19  <glx> Wolf01: VS probably have created a CMakeSettings.json file in openttd root
12:27:28  <nielsm> is it possible to set something in CMakeLists.txt to set a default VCPKG_TARGET_TRIPLET for windows?
12:27:58  *** EER has joined #openttd
12:28:28  <Wolf01> No json files there :(
12:28:28  <glx> if not set it defaults to <arch>-windows
12:28:43  <glx> ok manage configurations
12:29:23  <glx> oh there's a cmake menu in 2017
12:30:19  <glx> https://docs.microsoft.com/fr-fr/cpp/build/cmake-projects-in-visual-studio?view=vs-2017#cmake-configure-step
12:31:26  <glx> https://docs.microsoft.com/fr-fr/cpp/build/customize-cmake-settings?view=vs-2017
12:31:31  <glx> this link is better
12:33:24  <glx> so in the json you need to add a variable
12:33:56  <Wolf01> And change the build/install paths too, I don't want them in my user folder
12:34:07  <glx>       "variables": [
12:34:07  <glx>         {
12:34:07  <glx>           "name": "VCPKG_TARGET_TRIPLET",
12:34:08  <glx>           "value": "x64-windows-static",
12:34:08  <glx>           "type": "STRING"
12:34:09  <glx>         }
12:34:09  <glx>       ]
12:38:20  <glx> ha yes in 2019 it defaults to out\build and out\install in project root
12:41:19  *** EER has quit IRC
12:42:09  <Wolf01> I must go now, I'll try to fix it later
12:42:38  *** EER has joined #openttd
12:59:47  *** EER has quit IRC
13:00:50  <DorpsGek_III> [OpenTTD/OpenTTD] bl501 opened issue #8202: Crashes before opening on mac https://git.io/JfM1N
13:02:49  <DorpsGek_III> [OpenTTD/OpenTTD] LordAro commented on issue #8202: Crashes before opening on mac https://git.io/JfM1N
13:02:49  <DorpsGek_III> [OpenTTD/OpenTTD] LordAro closed issue #8202: Crashes before opening on mac https://git.io/JfM1N
13:03:04  <DorpsGek_III> [OpenTTD/OpenTTD] nielsmh commented on issue #8202: Crashes before opening on mac https://git.io/JfM1N
13:03:13  <nielsm> oh well
13:03:18  <LordAro> too slow :p
13:03:38  <nielsm> I went and did some bookeeping on #8066 as well
13:03:55  *** EER has joined #openttd
13:05:01  <glx> 10.12.8 ?
13:05:50  <LordAro> .6, yes
13:06:17  <DorpsGek_III> [OpenTTD/OpenTTD] bl501 commented on issue #8066: 1.10.2 crashes on start in OS X 10.12.6 https://git.io/JvA3B
13:16:48  *** virtualrandomnumber has joined #openttd
13:16:55  *** virtualrandomnumber has quit IRC
13:21:03  <DorpsGek_III> [OpenTTD/OpenTTD] glx22 opened pull request #8203: Fix: Minor changes in bundle generation https://git.io/JfMMu
13:23:28  <glx> oups I made a silly error
13:24:32  <LordAro> glx: is there a particular issue with generating an installer for nightlies?
13:25:31  <glx> not really but I think installer are better for stable release only
13:26:32  <LordAro> ¯\_(ツ)_/¯
13:29:22  <DorpsGek_III> [OpenTTD/OpenTTD] glx22 updated pull request #8203: Fix: Minor changes in bundle generation https://git.io/JfMMu
13:34:26  *** spnda has joined #openttd
13:42:13  <DorpsGek_III> [OpenTTD/OpenTTD] LordAro approved pull request #8203: Fix: Minor changes in bundle generation https://git.io/JfMDT
13:54:51  <michi_cc> LordAro: I think a nightly installer would actually not work properly at all, otherwise there wouldn't be a need to bump nstall.nsi each time.
13:55:18  <glx> we removed install.nsi
13:56:25  <michi_cc> Didn't check that yet. But still, how would the nightly a release track NSIS versions be distinguished?
14:02:09  <glx> and I think we don't set any "version", installer always use default 0.1.1
14:02:59  <michi_cc> Unless cmake/cpack does some behind-the-scenes magic, that should brake update installations as they depend on the installer/app version.
14:11:13  <spnda> anyone up to help debugging something with my NRS patch rendering seemingly random sprites?
14:11:17  <supermop_Home_> curfew lifted
14:13:29  <DorpsGek_III> [OpenTTD/OpenTTD] glx22 dismissed a review for pull request #8203: Fix: Minor changes in bundle generation https://git.io/JfMDT
14:13:29  <DorpsGek_III> [OpenTTD/OpenTTD] glx22 updated pull request #8203: Fix: Minor changes in bundle generation https://git.io/JfMMu
14:28:48  <DorpsGek_III> [OpenTTD/OpenTTD] glx22 approved pull request #8199: CMake always export compile commands https://git.io/JfMSm
14:31:56  <supermop_Home_> andythenorth https://www.flickr.com/photos/scottishlineside/30986315796/in/photostream/
14:32:36  <TrueBrain> michi_cc: as a FYI, and if nothing changed in the last year in regards to how CMake uses NSIS, there is no "update" functionality. You install what-ever version you install, and the latest you install, is the one that is on your disk :) In result, the NSIS "version" doesn't matter as such
14:33:21  <TrueBrain> so possibly a better word would be: a self-extractor
14:34:08  <TrueBrain> the reason we used to bump the version in the installer.nsi, as far as I am aware, was just so the right-click -> info tab shows the right version
14:34:40  <michi_cc> Okay, because I think NSIS could also give a warning when e.g. installing an older version over a newer version, but if we don't make use of that the version really doesn't matter that much.
14:34:50  <glx> TrueBrain: we also prevented installing over a more recent
14:34:56  <TrueBrain> no, we never used these things in NSIS, as far as I know :)
14:35:13  <glx> I remember seeing the message box
14:35:15  <TrueBrain> at least, during CMake development, I installed many different versions over and over and over and over again :P Never got a warning :D
14:35:34  <TrueBrain> but, my info is more than a year old, so much might have changed :P
14:35:39  *** heffer has quit IRC
14:35:49  *** heffer has joined #openttd
14:36:00  <andythenorth> supermop_Home_ +1
14:36:18  <TrueBrain> so yeah, I think a nightly NSIS version would be possible; even better if you allow both stable + nightly on your system ;) Would be more accessiable :)
14:36:20  *** tyteen4a03 has quit IRC
14:36:50  *** tyteen4a03 has joined #openttd
14:37:05  <TrueBrain> the other way would be to check NSIS and see if it indeed (can) warn(s) about older/newer versions :D
14:37:23  <TrueBrain> but NSIS is such a piece of crap ... wait, did I say that out loud? :P
14:38:17  <glx> https://github.com/OpenTTD/OpenTTD/blob/56d54cf60eb5814f77dfcce91cf12879f01e1d1b/os/windows/installer/install.nsi#L735 ;)
14:38:46  <TrueBrain> glx: did that make it into CMake?
14:39:17  <glx> no, NSIS template doesn't have that
14:39:35  <TrueBrain> that explains why I never saw that :P
14:39:47  <TrueBrain> I honestly also think it is bullshit
14:39:54  <TrueBrain> if you want to downgrade, who is the installer to tell you not to
14:40:36  <michi_cc> Is the "copy TTD data from CD" option also gone then?
14:40:43  <glx> yes
14:40:46  <TrueBrain> yes; also the download opengfx part
14:40:48  <michi_cc> Not sure if anyone used it.
14:40:59  <TrueBrain> (as the bootstrap takes care of that)
14:41:46  <TrueBrain> with OpenGFX, I also think it is not the preferred method anymore :)
14:42:20  <TrueBrain> "try to find a CD which you won't have a drive for anymore .. or .. "buy" the game from an illegal website that makes money on distributing old games for money" .. not a fan :D
14:43:40  <supermop_Home_> andythenorth could go for one of these: http://www.touch-rail.com.tw/product/detail/id-150
14:44:14  <andythenorth> supermop_Home_ is that Z scale?
14:45:02  * andythenorth wonders when the original base set copyright expires :P
14:45:04  <spnda> I need some serious help with drawing sprites. I'm using DrawCommonTileSeqInGUI. From the values I read in the VS Debugger, my sprites are properly passed and it doesn't look faulty. Then somewhere past DrawSprite *some* of my sprites get offset for some magic reason. Is there anything I need to know about DrawSprite?
14:45:07  <andythenorth> will it be before I'm dead?
14:45:17  <milek7> probably no
14:45:18  <supermop_Home_> i think it is N andy
14:46:12  <supermop_Home_> I have a push toy E200 i bought in Taipei in 2018
14:46:20  <supermop_Home_> very chibi
14:48:45  <supermop_Home_> http://www.touch-rail.com.tw/product/detail/id-13
14:50:24  <supermop_Home_> a Japanese gauge N layout would be nice - maybe add Taiwanese, Korean, trains
14:52:09  <supermop_Home_> probably only have room for this: https://www.amazon.com/T-Gauge-Model-Trains-Scale-Kansai/dp/B071LP1G4Y/ref=psdc_3244728011_t3_B0723C39S9
14:54:52  <EER> spnda: I don't have time today, but if you can describe it in a bit more detail I can try to dive into it somewhere in the upcoming week? I'm not that well versed in newgrf, but I don't give up easily so happy to dive into the deep end :)
15:00:11  * andythenorth BIAB
15:00:14  *** andythenorth has quit IRC
15:08:06  <DorpsGek_III> [OpenTTD/OpenTTD] Nik-mmzd opened issue #8204: cmake: make install DESTDIR="something" ignores GLOBAL_DIR option https://git.io/JfM9j
15:14:17  <nielsm> this looks problematic: https://0x0.st/iVP2.jpg
15:18:04  <supermop_Home_> haha
15:18:12  <glx> as long as they're attached together it should be ok :)
15:25:01  *** Wormnest has joined #openttd
15:43:57  <spnda> so after 3 months of not finding the issue i finally fixed my NRS sprite loading... One step closer to NewGRF Roadstops
16:00:51  <EER> \o/
16:11:53  <DorpsGek_III> [OpenTTD/OpenTTD] SHADOW-XIII opened issue #8205: Vehicles not sorted by cargo capacity when filtering specific cargo https://git.io/JfM74
16:17:26  *** andythenorth has joined #openttd
16:25:06  <DorpsGek_III> [OpenTTD/OpenTTD] SHADOW-XIII opened issue #8206: Vehicle lists "Manage list" options inconsistent https://git.io/JfM79
16:26:01  <andythenorth> nielsm yugo cars on that wagon? o_O
16:28:49  <nielsm> it's the only model of passenger automobile that exists in derail valley
16:32:55  <DorpsGek_III> [OpenTTD/OpenTTD] SHADOW-XIII commented on issue #8206: Vehicle lists "Manage list" options inconsistent https://git.io/JfM79
16:33:10  <Wolf01> Back
16:36:11  <DorpsGek_III> [OpenTTD/OpenTTD] glx22 commented on pull request #8197: Fix: CPack source package creation https://git.io/JfM5e
16:58:02  <DorpsGek_III> [OpenTTD/OpenTTD] telk5093 opened pull request #8207: Add: 'cheat' console command to open the cheat window https://git.io/JfM57
17:03:40  <DorpsGek_III> [OpenTTD/OpenTTD] James103 commented on pull request #8207: Add: 'cheat' console command to open the cheat window https://git.io/JfMdT
17:04:51  *** qwebirc71220 has joined #openttd
17:11:24  *** qwebirc71220 has quit IRC
17:21:16  *** Flygon has quit IRC
17:21:27  <Wolf01> Hmmm, no compile errors but says it can't load the title game because ZLIB is not available, I installed all the packages with vcpkg for the correct architecture
17:22:08  <glx> you cleared cmake cache ?
17:22:39  <Wolf01> Yes, it compiled without the old errors about libraries not available, maybe I should redo it again
17:22:51  <glx> and vcpkg packages are the same as before cmake switch
17:23:19  <glx> so if they worked before they should work now
17:26:58  <Wolf01> Cleaned the cmake cache: 1> -- Could NOT find ZLIB (missing: ZLIB_LIBRARY ZLIB_INCLUDE_DIR)
17:27:02  <Wolf01> Etc
17:27:40  <glx> you added the VCPKG_TARGET_TRIPLET variables ?
17:27:43  <Wolf01> Yes
17:28:00  <glx> for all configurations ?
17:28:02  <Wolf01> 1> CMake Warning:
17:28:02  <Wolf01> 1>   Manually-specified variables were not used by the project:
17:28:02  <Wolf01> 1>
17:28:02  <Wolf01> 1>     VCPKG_TARGET_TRIPLET
17:28:29  <Wolf01> I only ran debug x64
17:30:01  <glx> ah, I think for 2017 you also need to add CMAKE_TOOLCHAIN_FILE pointing to "<vcpkg-dir>/scripts/buildsystems/vcpkg.cmake"
17:30:29  <Wolf01> As another variable?
17:30:32  <glx> yes
17:30:55  <glx> 2019 adds it implicitely
17:32:27  *** adikt has joined #openttd
17:32:35  <Wolf01> 1> CMake Warning:
17:32:35  <Wolf01> 1>   Manually-specified variables were not used by the project:
17:32:35  <Wolf01> 1>
17:32:35  <Wolf01> 1>     CMAKE_TOOLCHAIN_FILE
17:35:06  <glx> paste your CMakeSettings.json somewhere, there should be something wrong in it
17:36:00  <Wolf01> https://pastebin.com/iD9GdCKS
17:39:24  <glx> json is correct
17:44:33  <andythenorth> hmm
17:44:40  <andythenorth> I should do bigger industries
17:45:03  <andythenorth> wouldn't look right though, TTD style is about 5x4 or so
17:47:53  *** Vadtec has quit IRC
17:57:02  <glx> Wolf01: maybe replace all / with \
17:57:47  *** frosch123 has joined #openttd
17:59:05  <glx> but both should work, they are mixed in the command generated by VS for me
18:00:56  <Wolf01> I just tried with /, before they were all \
18:02:12  <Wolf01> vcpkg packages are there, but it seem it doesn't find them
18:08:20  *** Tirili has joined #openttd
18:21:05  <Wolf01> Do I need to have vcpkg in path?
18:23:37  <TrueBrain> glx: nightly failed :(
18:26:29  <Wolf01> Yes, it was path, now it compiled fine
18:27:10  <Wolf01> Git shows a lot of changes, most of them should be ignored, if not all
18:27:19  <spnda> oh yes the NotRoadStops patch works now. Ayyy
18:28:20  <andythenorth> :)
18:30:37  *** Tirili has quit IRC
18:34:06  <Wolf01> spnda: pics or didn't happen :P
18:36:44  *** Speeder has joined #openttd
18:37:56  <Speeder> how popular are stockpiling style industries?
18:38:04  <Speeder> specially ones that block excessive deliveries
18:41:07  <nielsm> I don't think anyone has numbers on popularity like that
18:52:30  <Speeder> changing the question then... does it break the game badly industries that have delivery limit?
18:54:44  <nielsm> I don't consider it breaking the game, but it does change some core mechanics and players not used to it will have to re-learn some things
18:57:02  <Speeder> I never played with stuff like that myself, so... what sort of things change? for example, how you change your trains orders so they don't freakout at the situation?
18:58:48  <frosch123> i doubt people who care about that would play with such industries
18:59:14  <frosch123> i think they are more a thing for model railway people
19:01:08  <Speeder> frosch123, what y ou mean?
19:02:25  <frosch123> https://github.com/OpenTTD/OpenTTD/blob/master/CONTRIBUTING.md#project-goals <- some years ago i wrote an essay about 4 types of ottd players
19:02:55  <frosch123> it's the second itemization in that section
19:03:01  <michi_cc> PBI used to be quite popular, but probably not by people focused on optimizing their free-flowing, no-stopping super-mainline.
19:04:00  <Speeder> ok, got it a bit better what you mean, still not understanding it completely
19:04:33  <andythenorth> I enjoyed PBI
19:04:51  <frosch123> andythenorth: even the limited livespan of mines?
19:04:54  <andythenorth> somewhat
19:04:54  <Speeder> so to explain my goal first... I am trying to make a map that is a part of Brazil, but where most of the population live. (I think the map has about a third of Brazil's area, and something like 80% of the population)
19:05:01  <andythenorth> but FIRS was initially a collaborative project, and was oriented to coop style play
19:05:11  <Speeder> the scenario will start in 1700, and as it advances industries will be built in their historic locations
19:05:21  <andythenorth> frosch123 I wouldn't play it now, but it's nice that changing content keeps the game fresh
19:05:35  <andythenorth> there's no ultimate OpenTTD game mechanic :)
19:05:41  <frosch123> Speeder: did you ever play in 1700?
19:05:57  <Speeder> frosch123, I did some test runs of my map, and played a bit with the intended NewGRFs on a random map :)
19:06:10  <Speeder> on my map it was quite fun  with sailing ships available
19:06:16  <Speeder> because the map is river-heavy
19:06:37  <frosch123> sure, but isn't it enough to start in 1850 and have > 50 years of that?
19:07:23  <Speeder> I found it fun in this case, beacuse of drastic economic changes that happened, yet in a way that 1700 left a lasting legacy
19:08:09  <Speeder> brazil 1700 to 1850 resemble a lot the "in a hot country" economy of firs
19:08:57  <Speeder> but the 1950+ one resemble a lot "steeltown" Iwould say
19:08:57  <spnda> Wolf01: https://imgur.com/a/TMLVAHm
19:09:07  <Speeder> yet... Brazil still exports heavily, same thing it did in 1700
19:09:13  <Speeder> I found that fascinating
19:09:20  <spnda> I have a few other screenshots. Also trams and lorries are also working fine.
19:09:25  <spnda> I've also added a few extra neat features
19:09:32  <spnda> One of them is yet to be fully finished
19:09:37  <spnda> It allows for one way stations
19:09:53  <spnda> So I am really hyped when this comes out
19:09:58  <spnda> What kind of GRFs people will make
19:10:46  *** Vadtec has joined #openttd
19:11:23  <spnda> Also I have a bool value that tells the game if it should render the roads or not, so that should allow for people to make some non-road stops, if they want.
19:11:29  <spnda> or some special roads.... who knows
19:12:59  <spnda> Also here for the trams: https://imgur.com/a/alaR2cb (yes the scrollbar is broken, ik)
19:13:58  *** Vadtec has quit IRC
19:18:00  <Speeder> can someone explain to me how production_rate from nml5 works?
19:18:01  <glx> Wolf01: ah I don't have vcpkg in my path, but I used "vcpkg integrate install" which should have a similar effect
19:18:05  <glx> TrueBrain: how ?
19:18:05  <Speeder> the wiki is unclear
19:20:35  *** Vadtec has joined #openttd
19:24:38  <Wolf01> glx: I did that too, but it only started to work after adding vcpkg to path
19:25:55  <Wolf01> spnda: nice :D
19:31:16  <DorpsGek_III> [OpenTTD/OpenTTD] nielsmh commented on pull request #8207: Add: 'cheat' console command to open the cheat window https://git.io/JfMA8
19:32:31  <spnda> Could it be, that "RoadTypeIsRoad()" only works for custom NRT roadtypes?
19:39:10  <DorpsGek_III> [OpenTTD/OpenTTD] ldpl commented on pull request #8207: Add: 'cheat' console command to open the cheat window https://git.io/JfMA2
19:45:38  <spnda> huh the check for RoadTypeIsTram works, but it doesn't for RoadTypeIsRoad
19:45:50  <spnda> Is this some issue?
19:46:31  <Wolf01> spnda: I think it has a specific usage
19:47:05  <spnda> I'm using it the same way as in StationPickerDrawSprite for example. You can look at it in station_cmd.cpp#3059
19:47:07  <Wolf01> As always no documentation about it
19:47:15  <spnda> The if (RoadTypeIsTram(roadtype)) works
19:47:25  <spnda> The following (RoadTypeIsRoad(roadtype)) does not.
19:48:06  <Wolf01> The functions are really similar, they return inverted result
19:48:44  <spnda> Yes I know
19:49:02  <spnda> ROADTYPE_BEGIN is not a road apparently
19:49:06  <spnda> ROADTYPE_TRAM is a tram
19:49:09  <spnda> So tram checks work
19:49:31  <spnda> why is it ROADTYPE_BEGIN anyway...
19:49:43  <Wolf01> ROADTYPE_BEGIN means no road at all iirc
19:49:51  <spnda> huh
19:49:52  <DorpsGek_III> [OpenTTD/OpenTTD] twpol commented on issue #8095: Feature suggestion: option to automatically space out vehicles in a shared order https://git.io/JfIUi
19:49:56  <spnda> yeah there's ROADTYPE_ROAD
19:50:04  <Eddi|zuHause> BEGIN/END is for for-loops
19:50:09  <spnda> both ROADTYPE_BEGIN and ROADTYPE_ROAD are 0
19:50:11  <spnda> Well yes
19:50:28  <Eddi|zuHause> you shouldn't use them anywhere else
19:50:36  <spnda> But I just took "_cur_roadtype" from the road_gui.cpp
19:50:37  <Wolf01> Does the grf redefine standard road?
19:50:40  <spnda> and that gave me ROADTYPE_BEGIN
19:50:51  <spnda> Nope, it only defines roadstops
19:51:01  <Wolf01> Yeah, with enums it returns the first occurrence
19:51:05  <Eddi|zuHause> you should read that as ROADTYPE_ROAD
19:51:43  <spnda> I never changed that
19:51:59  <spnda> one second
19:52:15  <Wolf01> You have other nrt grfs?
19:52:30  <spnda> Using NRT it works just fine
19:52:36  <spnda> Just if I don't use any NRT GRFs it breaks
19:52:44  <spnda> I'm gonna check if the latest master has this
19:53:54  <spnda> Yeah it does
19:53:59  <spnda> I never changed this
19:54:12  <spnda> but the default roadtype that the road guy gets is ROADTYPE_BEGIN and not ROADTYPE_ROAD
19:54:17  <spnda> gui not guy lol
19:54:51  <Wolf01> Yes, that's known, it's for every enum with duplicated values
19:55:15  <spnda> well how am I gonna get ROADTYPE_ROAD then
19:55:20  <spnda> Because i obviously need that
19:55:27  <Eddi|zuHause> BEGIN and ROAD is the same value, the debugger is just confused which one of those it should display
19:55:36  <Wolf01> You don't, you can just write 0
19:57:00  <spnda> huh
19:57:04  <spnda> ok that wasn't that
20:00:53  *** frosch123 has quit IRC
20:16:53  *** Vadtec has quit IRC
20:29:00  *** Vadtec has joined #openttd
20:36:57  *** Vadtec has quit IRC
20:43:58  *** virtualrandomnumber has joined #openttd
20:49:30  *** Vadtec has joined #openttd
20:50:02  <DorpsGek_III> [OpenTTD/OpenTTD] techgeeknz commented on issue #8095: Feature suggestion: option to automatically space out vehicles in a shared order https://git.io/JfIUi
20:52:14  <arikover> I'm having problems with CMake... I can compile without problem, except there is no sound effects ingame (MIDI works though). I tried installing Allegro and the sound was here, but the performances were far better with SDL2. So it's either "no sound" or "sluggish".
20:52:37  *** Vadtec has quit IRC
20:52:42  <arikover> I'm clearly missing something here.
20:56:47  <milek7> is this related to cmake?
21:01:23  <arikover> I think so, because I did not have the problem with the configure script.
21:02:51  <arikover> I'm pretty sure it is trivial to solve, but I clearly suck at this.
21:08:06  <nielsm> collect your cmake logs and the generated configuration files, maybe we can diagnose it with that
21:09:45  *** Vadtec has joined #openttd
21:13:52  <DorpsGek_III> [OpenTTD/OpenTTD] JGRennison commented on issue #8095: Feature suggestion: option to automatically space out vehicles in a shared order https://git.io/JfIUi
21:23:10  <spnda> Also, when and how will I be able to edit the wiki to add this roadstop documentation?
21:27:31  <FLHerne> spnda: What stops you from editing the wiki?
21:28:15  <FLHerne> spnda: I guess you'd edit it ASAP after it's merged
21:28:36  <andythenorth> there is a known problem for newgrf with no solution currently
21:28:56  <andythenorth> no wiki docs means nobody knows what the feature is supposed to do
21:29:03  <andythenorth> so it doesn't get tested
21:29:14  <andythenorth> and it can't go in the wiki until it's merged
21:29:23  <andythenorth> but it can't be merged until it's tested
21:29:57  <FLHerne> Speeder: What's unclear about the wiki?
21:30:02  <spnda> FLHerne: Does everyone have permission? Oh that makes it quite a bit easier
21:31:19  <andythenorth> maybe we could solve this with 'draft' wiki pages? but most patches don't go anywhere
21:31:33  <andythenorth> or we could have docs attached to the PR in wiki format
21:31:41  * andythenorth dunno :)
21:31:44  <Speeder> FLHerne, the initial value is same as what you set, but then change with production... if that is literal, it means the other part of the wiki is wrong, where it says what you set as production is multiplied by the prod level
21:33:10  <andythenorth> Speeder eh what? :)
21:33:18  <andythenorth> which version of the spec are you using?
21:33:38  <FLHerne> production_rate("STUF") tells you the amount of STUF currently being produced from produce_256_ticks, AIUI
21:33:53  <FLHerne> Speeder: production_level is something completely different
21:34:08  <andythenorth> there are multiple confusing terms historically
21:34:15  <andythenorth> prod level, prod multiplier etc
21:34:30  <andythenorth> they're all different things
21:34:51  <andythenorth> but defining the actual production is simple
21:36:24  <michi_cc> Also, in terms of specs, the authoritative wording is usually supposed to be in the "NewGRF Specs" part, not the "NML Specs" part. Of course, in an ideal world you're not going to find a discrepancy between them.
21:37:28  <andythenorth> nml support tends to run behind nfo in timing
21:38:33  *** sla_ro|master has quit IRC
21:38:53  <Speeder> For the given cargo label, amount of output cargo that is produced every 256 ticks. Initial value from the cargo_types property, but it will change accordingly when the production level changes. Returns 0..255. Example:
21:39:46  <andythenorth> probably (prod_multiplier / 16) * prod_level
21:39:49  <andythenorth> iirc
21:40:02  <andythenorth> openttd changes prod_level
21:40:06  <Speeder> produce_cargo("GOOD", 4) specifies the industry produces GOOD at a rate of 4 every production tick (256 game ticks), this production rate is scaled by the industry's production level.
21:40:09  <andythenorth> when depends on economy seting
21:40:19  <andythenorth> and what the newgrf does
21:40:42  <FLHerne> michi_cc: The NML specs are authoritative for what nmlc is supposed to do?
21:40:43  <michi_cc> "The properties specify the amount produced at default production level, they are scaled equally on production changes."
21:40:49  <nielsm> but if the industry has the periodic production callback defined then the normal production rules don't matter
21:40:53  <Speeder> to me these two phrases I understand as: first time you read "production_rate" it will mean in the example, 4
21:41:00  <Speeder> but when you double production levle, it will return 8
21:41:03  <andythenorth> yes
21:41:14  <Speeder> but since production level default is 16, production level now will be 32
21:41:18  <andythenorth> if it helps, read about the monthly / random production change cbs
21:41:25  <andythenorth> cbs = callbacks
21:41:28  <andythenorth> in the nfo docs
21:41:49  <Speeder> but doens't this mean production will scale up exponentially?
21:41:55  <nielsm> yes
21:42:05  <Speeder> so "good" for example, start producing 4*16
21:42:06  <nielsm> the original production change rules are x2 x2
21:42:08  <Speeder> then if you double production
21:42:13  <Speeder> it will produce 8*32
21:42:30  *** Wolf01 has quit IRC
21:42:31  <andythenorth> smooth economy was an attempt to address this
21:42:37  <michi_cc> FLHerne: No, but if the description for e.g. when a callback is called differs between the NML wiki part and the GRF wiki part, I'd believe the GRF part first.
21:42:44  <andythenorth> the grf part is canon
21:42:53  <andythenorth> nml docs often aren't accurate even for nml
21:43:04  <andythenorth> they tend to be a complete PITA to maintain
21:43:11  <michi_cc> And most NML props and callback map directly to GRF without any pre-processing.
21:43:17  <andythenorth> frankly I'm amazed they're as good as they are, thanks to those who did them :)
21:45:12  <Speeder> so... does "doubling" production level actually quadruples output?
21:45:19  <FLHerne> > but since production level default is 16, production level now will be 32
21:45:23  <FLHerne> Why?
21:45:47  <Speeder> FLHerne, what doubling production  level variable do?
21:46:11  <Speeder> for example CB_RESULT_IND_PROD_DOUBLE
21:47:36  <michi_cc> If you start with 4*16, it will be 4*32 after.
21:47:52  <FLHerne> Ok, I see what you mean, but still don't really understand your point
21:48:14  <FLHerne> If you repeatedly double the production level it'll be exponential, yes
21:48:54  <FLHerne> But you could also increment it, or set it to a specific value calculated in some other way
21:49:15  <FLHerne> And I don't see how production_rate is relevant here at all
21:49:43  <FLHerne> It's just a way to check the result of what you've already done
21:50:25  <FLHerne> CB_RESULT_IND_PROD_MULTIPLY_BY_32 <- that would be seriously exponential
21:50:44  * FLHerne wonders if any grf has ever used that, and why :p
21:52:08  *** Samu has quit IRC
21:55:50  * andythenorth has not :D
21:59:33  <Speeder> that is not what I mean
21:59:35  <spnda> from where are tiles rendered?
21:59:38  *** virtualrandomnumber has quit IRC
21:59:42  <Speeder> what I mean is the other variable, that returns 4 at first
21:59:52  <spnda> like from where are roadstops as a tile rendered
21:59:55  <Speeder> if you double prod level, it goes from 16 to 32
22:00:01  <Speeder> but the other variable goes from 4, to 8
22:00:07  <Speeder> thus you actually quadrupled production
22:01:04  <michi_cc> No, if the production level changes, the production multiplier does not. The resulting production changes.
22:02:36  <Speeder> what production multiplier?
22:02:53  <michi_cc> Your 4.
22:04:13  <michi_cc> And of course all this only applies if you use default production behaviour. If a production callback us used, none of that matters.
22:05:51  *** Progman has quit IRC
22:06:20  <Speeder> michi_cc, so, production_rate 	cargo label from the cargotable 	NML 0.5 For the given cargo label, amount of output cargo that is produced every 256 ticks. Initial value from the cargo_types property, but it will change accordingly when the production level changes. Returns 0..255. Example: production_rate("SUGR").
22:06:22  <Speeder> this line is wrong?
22:08:08  <Eddi|zuHause> which part of that should be wrong?
22:08:47  <michi_cc> I don't know offhand which VA2 variable that maps to, but I'm quite sure that returns the resulting production, i.e. multiplier * level.
22:09:43  <michi_cc> This is not the same as the value from the produce_cargo property.
22:09:44  <Speeder> Eddi|zuHause, it says two things: 1. it will return the initial value at first (so for my example earlier, 4), and  then that it will return later, the value changed as production level changes.
22:10:26  <michi_cc> production = multiplier * level / 16. Default for level is 16.
22:10:48  <FLHerne> Speeder: production_rate tells you what the current production rate *is*
22:10:54  <FLHerne> It doesn't set it
22:11:15  <michi_cc> The one thing wrong in this line is that a callback exists that allows to change the inital level from 16 to something else.
22:12:01  <glx> production_rate is given by openttd, you don't change it yourself
22:12:20  <glx> well you don't modify it directly
22:12:58  <Speeder> so step by step: 1: produce_cargo("GOOD", 4) 2: production_rate("GOOD") returns 4, production_level is 16. 3: a callback returns CB_RESULT_IND_PROD_DOUBLE, production_rate("GOOD") returns 8, production_level is 32
22:13:53  <FLHerne> That sounds right
22:13:56  <FLHerne> I think
22:14:25  <Speeder> FLHerne, this is what I understood from the wiki. thing is, doing this way it means doubling production level, results in 4x output, not 2x
22:14:35  <Speeder> get it now?
22:14:38  <FLHerne> And now you've lost me again
22:14:50  <FLHerne> production has gone from 16 to 32
22:14:55  <FLHerne> it's doubled
22:14:56  <Speeder> I will try again my step by step
22:15:00  <michi_cc> The 8 IS the production.
22:15:05  <Speeder> 1: produce_cargo("GOOD", 4)
22:15:19  <glx> 8 is 2*4, so doubled
22:15:30  <Speeder> 2: production_rate("GOOD") returns 4, production_level variable is 16. Thus actual output is 4*16
22:15:45  <FLHerne> So far, so good
22:15:55  <glx> 4*16/16 ;)
22:16:05  <Speeder> 3: a callback retruned CB_RESULT_IND_PROD_DOUBLE
22:16:24  <Speeder> 4: production_rate("GOOD") returns 8, production_level variable is 16. Actual output is 8*32
22:16:39  <Speeder> 4: production_rate("GOOD") returns 8, production_level variable is 32. Actual output is 8*32
22:16:58  <glx> no it's 4*32/16
22:17:18  <Speeder> glx, what is 4*32/16?
22:17:22  <Speeder> the output?
22:17:31  <FLHerne> Speeder: > 4: production_rate("GOOD") returns 8, production_level variable is 16. Actual output is 8*32 is wrong
22:17:41  <Speeder> FLHerne, that line was a typo
22:17:46  <Speeder> I mean the one right after it
22:17:50  <glx> production_rate is the actual output
22:18:01  <FLHerne> Speeder: That one is also wrong
22:18:14  <Speeder> glx, so the initial value is NOT, what you set?
22:18:26  <FLHerne> Speeder: Again, > production_rate tells you what the current production rate *is*, it doesn't set it
22:18:37  <andythenorth> var not prop
22:18:39  <FLHerne> Speeder: It's a variable, you read it
22:18:43  <Speeder> FLHerne, I don't understand why you keep saying that
22:18:53  <FLHerne> It tells you how much cargo the industry is producing
22:19:02  <Speeder> I never used that to set anything
22:19:03  <FLHerne> The value isn't fed back into anything
22:19:10  <Speeder> I used produce_cargo to set
22:19:19  <FLHerne> Ten why are you saying " 8*32"?
22:19:23  <michi_cc> Speeder: production_rate("GOOD") is the value AFTER production_level is applied, not before.
22:19:23  <FLHerne> *then
22:19:26  <andythenorth> I had this *exact* conversation with dalestan when I started FIRS :P
22:19:27  <FLHerne> It's still 4
22:19:52  <FLHerne> You haven't changed the produce_cargo
22:20:02  <Speeder> michi_cc, so... when it says the INITIAL VALUE, is whatever you set using produce_cargo
22:20:35  <andythenorth> are you just saying production_rate has a bug Speeder? :)
22:20:36  <Speeder> it means produce_cargo value is fudged before saving?
22:20:45  <Speeder> andythenorth, I am trying to understand the wiki
22:20:54  <Eddi|zuHause> you're not making any sense
22:21:00  <michi_cc> produce_cargo is a NewGRF property, not something that is stored in any savegame.
22:21:08  <Eddi|zuHause> "initial value" usually comes from some property, and some callback can change it
22:21:17  <andythenorth> nml or nfo wiki?
22:21:24  <Speeder> from wiki: production_rate: Initial value from the cargo_types property, but it will change accordingly when the production level changes.
22:21:46  <Speeder> so in cargo_types you used: produce_cargo("GOOD", 4)
22:21:48  <FLHerne> ...yes?
22:22:03  <Speeder> thus production_rate("GOOD") will return 4?
22:22:04  <andythenorth> when game starts
22:22:22  <andythenorth> production rate is (prod_multiplier / 16) * prod_level
22:22:24  <FLHerne> Because production_rate is based on both the multiplier and the level
22:22:25  <michi_cc> For an industry directly after construction.
22:22:29  <andythenorth> and prod_level is 16 at game start
22:22:58  <Speeder> what multiplier?
22:23:06  <michi_cc> Again, your 4.
22:23:22  *** mobail has joined #openttd
22:23:30  *** gelignite has quit IRC
22:23:37  <andythenorth> I would *always* use this page https://newgrf-specs.tt-wiki.net/wiki/Action0/Industries#Production_multipliers_.2812.2C_13.29
22:23:39  <michi_cc> produce_cargo("GOOD", 4) IS NOT the production_rate.
22:23:43  <glx> multiplier is produce_cargo
22:23:46  <andythenorth> you can't learn any actual coding from the nml docs
22:24:06  <Speeder> michi_cc, production rate "initial value" then refers to WHAT ?
22:24:14  <Speeder> it says it is intial from "cargo_types"
22:24:16  <michi_cc> (prod_multiplier / 16) * prod_level
22:24:29  <Speeder> then the wiki is wrong
22:24:33  <andythenorth> no
22:24:40  <andythenorth> but don't use the nml wiki
22:24:42  <michi_cc> With inital value of prod_level being 16.
22:24:48  *** mobail has quit IRC
22:24:58  <andythenorth> nml wiki is just for looking up names of action 0 / varaction 2 / callbacks
22:25:08  <andythenorth> (imho)
22:25:12  <andythenorth> others may disagree
22:25:29  <andythenorth> use the actual spec
22:25:39  <andythenorth> this for vars https://newgrf-specs.tt-wiki.net/wiki/VariationalAction2/Industries
22:25:50  <andythenorth> this for props https://newgrf-specs.tt-wiki.net/wiki/Action0/Industries
22:25:52  <FLHerne> Speeder: The value returned by production_rate is initially the same as you set in cargo_types
22:26:03  <Eddi|zuHause> it heavily depends whether you want a specification or an explanation. the two things are often not identical
22:26:08  <FLHerne> When you change the production_level, it isn't the same anymore
22:26:43  <Eddi|zuHause> an explanation tends to simplify things, while a specification must be as detailed as possible
22:26:47  <Speeder> FLHerne, so it IS, or NOT, initially, the same as "produce_cargo" ?
22:27:03  <FLHerne> But that doesn't affect the value you set in cargo_types
22:27:06  <glx> initialy it's the same
22:27:23  <FLHerne> Are you confused about the definition of "initially" ?
22:27:27  <Speeder> why it is the same?
22:27:34  <Speeder> what is the actual formula then?
22:27:40  <andythenorth> as posted several times above
22:27:48  <glx> because prod_level start value is 16
22:27:49  <Eddi|zuHause> the formula was written like 4 times already
22:27:51  <andythenorth> (prod_multiplier / 16) * prod_level
22:28:26  <andythenorth> I was really confused by prod_multiplier and prod_level when I started FIRS
22:28:39  <andythenorth> and that was prior to nml
22:28:48  <andythenorth> nml makes it worse by renaming the concepts
22:29:05  <Speeder> so is this line in the wiki, that is ambiguous: produce_cargo("GOOD", 4) specifies the industry produces GOOD at a rate of 4 every production tick (256 game ticks), this production rate is scaled by the industry's production level.
22:29:06  <andythenorth> otoh, the original names aren't always great
22:29:18  <michi_cc> Technically, the NML wiki is indeed wrong, because it ignores the existence of callback 0x15F, which may be used the change the "initial value" of prod_level from 16 to something else.
22:29:32  <andythenorth> Speeder the line is 100% true but not easy to read
22:29:57  <FLHerne> Hm, I think it's "this production rate" that's confusing
22:30:07  <Speeder> that line implies final result is whatever you set * 16 (since elsewhere it says that is the initial production level)
22:30:11  <FLHerne> "this production rate" has nothing to do with the production_rate variable
22:30:47  <michi_cc> Speeder: No, because production_level is a fixed point value with 4 fractional bits.
22:31:02  <andythenorth> michi_cc :P
22:31:03  <Speeder> michi_cc, O.O
22:31:33  <andythenorth> it can be 16, 1/16, or 16 * 16
22:31:33  <michi_cc> Which is why people have repeatedly wrote about "/ 16".
22:31:59  <andythenorth> Speeder it *is* confusing yes
22:32:02  <andythenorth> stick with it
22:32:05  <andythenorth> you'll get there
22:32:09  <Speeder> that is what I mean, the /16 is not mentioned in the wiki
22:32:13  <andythenorth> yes
22:32:21  <andythenorth> I looked it up in openttd src
22:32:29  <michi_cc> But it is, just indirectly by the word "scaled".
22:32:38  <andythenorth> I quite often ignore the newgrf docs and read the src in industry_cmd.cpp
22:32:39  <Speeder> michi_cc, thus why I said that thing is ambiguous
22:33:09  <glx> it's implicit because production can be halved too
22:33:18  <Eddi|zuHause> Speeder: imagine it like %. if you give a factor of 5, the result will be 500%
22:33:22  <glx> your initial 4 can be 2
22:33:33  <andythenorth> speeder's mind is blow :)
22:33:36  <andythenorth> blown *
22:33:50  <glx> or 8 depending on production level evolution
22:33:52  <andythenorth> irc is hard medium to get taught with
22:34:21  <Eddi|zuHause> i still have no real clue which part he's struggling with
22:34:36  <andythenorth> conceptually understanding what is going on
22:34:37  <michi_cc> "scaled" means "is proportional to", not "is multiplied with". Thus, the inital default of the production level is irrelevant.
22:34:57  <Speeder> Eddi|zuHause, it is the /16 formula is not mentioned on the wiki
22:35:05  <andythenorth> we could change that
22:35:07  <Speeder> michi is correct
22:35:09  <andythenorth> it may not help :)
22:35:16  <Speeder> but for a non-english speaker that might not be 100% obvious
22:35:19  <Eddi|zuHause> why does the wiki have to mention the /16?
22:35:24  <Speeder> changing "scaled" to "proportional" for example would help
22:36:06  <Speeder> Eddi|zuHause, because the way the wiki is written implies production_rate is the same as the multiplier
22:36:12  <Speeder> when it isn't
22:37:24  <michi_cc> I'd say it exactly does not imply that: " Initial value from the cargo_types property, but it will change accordingly when the production level changes."
22:38:05  <michi_cc> "will change accordingly" is to me quite clearly saying that if production level e.g. doubles, production rate doubles.
22:41:02  <FLHerne> michi_cc: But the cargo types array paragraph says "...this production rate is scaled by..." when describing the multiplier
22:43:02  <michi_cc> Which I would not read as equivalence either.
22:44:51  <FLHerne> michi_cc: It's very confusing to describe the multiplier as "this production rate" when production_rate has a completely different meaning and the multiplier isn't the production rate :p
22:44:55  <Speeder> FLHerne, well, you got what my gripe with the wiki is :D
22:46:15  <michi_cc> But is is the initial production rate unless you use callback 0x15F to change the initial production level.
22:46:25  <supermop_Home_> andythenorth these Scottish 37s are very pretty
22:46:43  <supermop_Home_> but like do they have no other locomotives up there?
22:46:53  <michi_cc> NML seems to call that CB build_prod_change
22:47:01  <FLHerne> michi_cc: Not really
22:47:17  <andythenorth> supermop_Home_ it's a very specific requirement for high power, low axle load on that route
22:47:23  <glx> https://newgrf-specs.tt-wiki.net/wiki/Action0/Industries#Input_cargo_multiplier_list_.2828.29 <-- when you don't understand something in nml, always check on nfo
22:47:25  <andythenorth> most locomotives can't do it
22:47:28  <FLHerne> It's initially *equal to* the production rate, but it's semantically a different thing
22:47:34  <glx> The properties specify the amount produced at default production level, they are scaled equally on production changes.
22:47:45  *** EER has quit IRC
22:48:03  <FLHerne> And it stops being equal whenever the production level changes, which is what makes it a semantically different thing
22:48:12  <andythenorth> supermop_Home_ this though :P https://www.youtube.com/watch?v=FYGJhhec-pc
22:52:37  <andythenorth> oof sleeping time
22:52:38  *** andythenorth has quit IRC
22:54:18  <FLHerne> Oh, good plan
23:02:28  *** cHawk has joined #openttd
23:24:29  <arikover> nielsm: Thank you for your quick answer, and sorry, I dozed off. I'll be posting the logs tomorrow...
23:24:41  <arikover> Bye, good night!
23:24:44  *** arikover has quit IRC
23:24:48  *** spnda has quit IRC

Powered by YARRSTE version: svn-trunk