Times are UTC Toggle Colours
00:27:03 *** Progman has quit IRC 01:16:51 *** glx has quit IRC 01:51:03 *** tokai|noir has joined #openttd 01:51:03 *** ChanServ sets mode: +v tokai|noir 01:57:43 *** tokai has quit IRC 02:06:10 *** WormnestAndroid has quit IRC 02:07:07 *** WormnestAndroid has joined #openttd 02:33:26 *** D-HUND has joined #openttd 02:34:31 *** Zathras has joined #openttd 02:36:46 *** godbed has quit IRC 02:36:56 *** debdog has quit IRC 03:21:51 *** Flygon has joined #openttd 03:29:43 *** snail_UES_ has quit IRC 03:33:43 *** Tirili has quit IRC 05:27:23 *** nielsm has joined #openttd 06:23:42 *** Wolf01 has joined #openttd 06:48:12 *** andythenorth has joined #openttd 06:55:10 *** Compu has joined #openttd 07:12:01 *** tokai has joined #openttd 07:12:01 *** ChanServ sets mode: +v tokai 07:18:55 *** tokai|noir has quit IRC 08:08:42 *** andythenorth has quit IRC 08:17:24 *** andythenorth has joined #openttd 08:20:14 *** andythenorth has joined #openttd 08:29:28 *** andythenorth has quit IRC 08:48:47 *** Progman has joined #openttd 09:19:47 <DorpsGek> [OpenTTD/master-server] TrueBrain opened pull request #46: Fix: server-info was missing the new gamescript entries https://git.io/JWXsV 09:23:59 *** tokai|noir has joined #openttd 09:24:00 *** ChanServ sets mode: +v tokai|noir 09:25:44 *** andythenorth has joined #openttd 09:25:53 <andythenorth> yo 09:27:34 <Wolf01> o/ 09:28:17 <DorpsGek> [OpenTTD/master-server] TrueBrain merged pull request #46: Fix: server-info was missing the new gamescript entries https://git.io/JWXsV 09:28:24 <DorpsGek> [OpenTTD/master-server-web] TrueBrain opened pull request #33: Add: show in the server list and server detail if/what GameScript a server uses https://git.io/JWXcT 09:30:45 *** tokai has quit IRC 09:32:36 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain approved pull request #9397: Feature: Persistant rotation of numbered autosave after restart https://git.io/JWXC2 09:33:11 <DorpsGek> [OpenTTD/master-server-web] TrueBrain updated pull request #33: Add: show in the server list and server detail if/what GameScript a server uses https://git.io/JWXcT 09:34:19 <DorpsGek> [OpenTTD/master-server-web] TrueBrain merged pull request #33: Add: show in the server list and server detail if/what GameScript a server uses https://git.io/JWXcT 09:34:50 <DorpsGek> [OpenTTD/master-server] TrueBrain created new tag: 1.2.3 https://git.io/JWXWo 09:36:55 <TrueBrain> now I have to wait 15 minutes till I can release the new frontend ... I am not that good in waiting :D 09:47:19 * andythenorth wonders about faking random more 09:47:33 <andythenorth> so that it's "what people think random means" not "what random means" 09:51:45 <DorpsGek> [OpenTTD/master-server-web] TrueBrain created new tag: 1.2.1 https://git.io/JWX04 09:57:12 *** Samu has joined #openttd 09:57:44 * andythenorth going to have adventures in analysing compile-time correctness 09:57:59 <andythenorth> specifically referring to vars that won't be in scope for current object 09:58:07 <andythenorth> that's 'incorrect' 10:02:39 <Wolf01> Just do stuff every n-prime numbers, like 3-7-11-17 and it's "random" enough for most people 10:03:45 <andythenorth> in Flash games I used to fake random a lot 10:04:22 <andythenorth> e.g. 'random' enemy characters in a shoot em up, if they are truly random people complain about getting a run of same 10:05:21 <andythenorth> so we solve that by having a list of n different items, then randomising the order they're popped 10:05:36 <andythenorth> and maybe we need 10 enemies, but the list contains 12 10:05:47 <andythenorth> 3 of each type 10:06:06 <andythenorth> OpenTTD context is industries 10:06:15 <andythenorth> I just got a map with 6 coke ovens and 1 coal mine 10:06:30 <andythenorth> as the coke oven, needs coal, that map is just...non-viable :D 10:06:32 <andythenorth> happens a lot 10:07:42 <andythenorth> I have to do 'newgame' about 30 times to get a viable FIRS map 10:10:34 <Wolf01> Yup, that's a problem, I don't think there is as solution without changing the map generator to ensure proper balance for every chain 10:10:53 <andythenorth> there is a newgrf callback for industry probability 10:11:12 <andythenorth> but I haven't figured out how to use it for this whilst avoiding deadlocks 10:11:20 <andythenorth> ideally OpenTTD would do it 10:12:24 <Wolf01> But it's still a probability, if your chain is 4:2:1 you might end up with 1 mine instead of 4 which should be the minimum 10:14:02 <DorpsGek> [OpenTTD/master-server-web] TrueBrain opened pull request #34: Add: show "Unknown" if we don't know the server uses a gamescript https://git.io/JWXVN 10:14:33 <Wolf01> And now I'm an idiot... I upgraded vehicles for a low profit route and now I'm struggling with running costs on that route... yes I earn twice as before, but also pay sixfold 10:14:47 <Wolf01> And the old vehicles are out of production 10:19:05 *** tokai has joined #openttd 10:19:05 *** ChanServ sets mode: +v tokai 10:19:25 <andythenorth> date cheat 10:20:21 <DorpsGek> [OpenTTD/master-server-web] TrueBrain merged pull request #34: Add: show "Unknown" if we don't know the server uses a gamescript https://git.io/JWXVN 10:20:40 <DorpsGek> [OpenTTD/master-server-web] TrueBrain created new tag: 1.2.2 https://git.io/JWXrw 10:20:46 <Wolf01> Nope, transport fever, it's already a good thing there is daylength (with date pause) 10:20:57 <DorpsGek> [OpenTTD/py-protocol] TrueBrain opened pull request #11: Fix: GC_LISTING couldn't send servers with no gamescript https://git.io/JWXrX 10:22:26 <DorpsGek> [OpenTTD/py-protocol] TrueBrain merged pull request #11: Fix: GC_LISTING couldn't send servers with no gamescript https://git.io/JWXrX 10:22:48 <DorpsGek> [OpenTTD/py-protocol] TrueBrain created new tag: 0.4.1 https://git.io/JWXo8 10:25:55 *** tokai|noir has quit IRC 10:26:05 <DorpsGek> [OpenTTD/game-coordinator] TrueBrain opened pull request #22: Update: bump openttd-protocols to fix not showing servers without gamescript https://git.io/JWXKW 10:28:12 <DorpsGek> [OpenTTD/game-coordinator] TrueBrain merged pull request #22: Update: bump openttd-protocols to fix not showing servers without gamescript https://git.io/JWXKW 10:28:35 <DorpsGek> [OpenTTD/game-coordinator] TrueBrain created new tag: 0.3.1 https://git.io/JWX6k 10:48:38 <DorpsGek> [OpenTTD/OpenTTD] glx22 closed issue #9396: Rotation of numbered autosaves is confusing https://git.io/JnQ0a 10:48:41 <DorpsGek> [OpenTTD/OpenTTD] glx22 merged pull request #9397: Feature: Persistant rotation of numbered autosave after restart https://git.io/JndWW 10:59:37 <andythenorth> hmm 10:59:44 <andythenorth> maybe I need to learn to tokenise 10:59:53 <andythenorth> I have a long python string (of nml) 11:00:14 <andythenorth> I want to see if if contains matches to e.g 'foo__' or 'bar__' 11:00:49 <andythenorth> which are substrings of identifiers in the form 'foo__farm' or 'foo_coal_mine' or 'bar__factory' etc 11:01:07 <andythenorth> I need to yield the entire identifier if the substring is found 11:01:40 <Eddi|zuHause> do you want to learn about AST? :p 11:01:50 <andythenorth> or I could maybe do it with split and rsplit 11:02:23 <andythenorth> the context is I am calling nml procedures 11:02:37 <andythenorth> but only certain industry are allowed to call specific procedures 11:02:54 <andythenorth> the results will be junk / nonsense if used by the wrong industry type 11:03:42 <andythenorth> and I need to enforce this at compile time, not run time (run time I know how to do, but errors could ship in released grfs and only be found in prod) 11:03:57 <Eddi|zuHause> assuming you use generated code, my initial thought would be to go earlier in the generation process to verify correctness, instead of trying to split it apart later 11:04:16 <andythenorth> I can do it trivially if I template the procedure names in 11:04:23 <andythenorth> but it makes for ugly code 11:04:43 <andythenorth> I'm trying to replace that :) 11:05:05 <Eddi|zuHause> you need a cleaner code generator then :) 11:06:42 <Eddi|zuHause> aannyway, sounds like you need a type system. 11:07:27 <Eddi|zuHause> and rather than solve that problem, you try to annotate your identifiers with type information 11:07:43 <Eddi|zuHause> which was tried many times before, and never quite worked out 11:08:27 <andythenorth> yeah I was against that idea 11:08:34 <andythenorth> it always runs into edge cases 11:09:45 <andythenorth> fundamentally the problem is I'm trying to violate scopes 11:10:07 <andythenorth> the procedure results are only valid in the scope of specific industry types 11:10:18 <Eddi|zuHause> i'm sure there are more layers of deeper problems :p 11:10:21 <andythenorth> but I'm dumping them into the global scopes as procedures 11:10:27 <andythenorth> global scope * 11:10:55 <andythenorth> I'm doing that to get easier to read templates 11:10:57 <andythenorth> and faster compiles 11:11:05 <andythenorth> but then I don't want to pay the price on invalid results 11:12:02 <Eddi|zuHause> that's why i said it's better to enforce that in earlier stages of code generation, where you still have this scope information, which will be lost on NML level, because NML doesn't have scpoes 11:13:44 <Eddi|zuHause> (at this abstraction level, "scope" and "type" are pretty much synonymous) 11:14:37 <andythenorth> there would be procedures for both get and set 11:14:46 <andythenorth> they all map to permanent storage (town or industry) 11:14:55 <andythenorth> templating 'get_foo' is trivial 11:15:10 <andythenorth> templating 'set_foo', plus a bunch of nml to get the value to set 11:15:13 <andythenorth> not trivial 11:15:45 <andythenorth> all signs are that I shouldn't be doing this :D 11:17:57 <Eddi|zuHause> yes, that needs some thought to get solved properly 11:18:32 <Eddi|zuHause> otherwithe you end up with an unmaintainable layering of hacks upon hacks 11:25:02 <andythenorth> splits on a predictable identifier format seems to work 11:25:15 <andythenorth> it will inevitably introduce a new problem, but what doesn't? 11:25:24 <andythenorth> 'goes it replace nml' is not a today thing 11:37:35 <Eddi|zuHause> it's not NML that you're looking at replacing, it's your templating engine that needs replacing with a proper compiler (which can still output NML as intermediate code) 11:47:37 <andythenorth> goes it design a templater? 11:47:59 <andythenorth> is there any point outputting NML? 11:50:34 <andythenorth> hmm, wrong question 11:50:41 <andythenorth> it's irrelevant what it outputs 11:50:58 <andythenorth> output is transformable 11:51:20 <andythenorth> real question is input 11:51:33 <andythenorth> how to replace everything NML can do, but in templates, and without using NML 11:51:39 * andythenorth way too hard for me 11:57:05 *** andythenorth has quit IRC 11:59:37 *** andythenorth has joined #openttd 12:11:21 *** glx has joined #openttd 12:11:21 *** ChanServ sets mode: +v glx 12:16:00 <andythenorth> this would be better if compile time wasn't a factor 12:16:10 <andythenorth> I could just scope the procedures to the industry 12:16:28 <andythenorth> but then it's num_procedures * num_industries 12:20:42 *** Progman has quit IRC 12:21:41 <andythenorth> oh nml can declare arbitrary parameters 12:22:31 <andythenorth> might be constant, not parameter 12:23:00 *** jottyfan has joined #openttd 12:23:23 <andythenorth> is this documented? 12:24:31 * andythenorth is confusing parameters, constants, and global vars 12:24:32 <andythenorth> nvm 12:24:49 <glx> it's variables, well named action D 12:25:20 <glx> you just need to do "something = value" in global scope 12:26:14 <glx> same as param[x] = value, without having to remember x 12:34:13 <andythenorth> how many can I declare? 12:34:55 * andythenorth reading https://newgrf-specs.tt-wiki.net/wiki/ActionD for the limit 12:35:29 <glx> limit in nml is smaller IIRC 12:35:46 <glx> because some IDs are reserved for parameters 12:35:56 <andythenorth> yeah I don't want to collide 12:36:02 <andythenorth> I have a solution in templater now 12:36:07 <glx> https://github.com/OpenTTD/nml/pull/149/files 12:36:25 <glx> that's a PR changing the limit ;) 12:36:31 <andythenorth> Eddi|zuHause was approximately correct, having the templater check before compiling is easier than trying to validate output, or at run time 12:37:06 <andythenorth> thanks though glx :) 12:37:21 <glx> but it shows the limit :) 12:56:36 <glx> so 128 in total, with 64 reserved 13:02:39 <andythenorth> ha I have crashed nmlc 13:02:51 <andythenorth> (AssertionError) 13:03:19 <andythenorth> isolating the trigger for this might be hard :) 13:03:49 <glx> if you give me the assert I may find it 13:04:29 <andythenorth> it's line 458, in get_action2 13:04:46 <andythenorth> triggered by replacing LOAD_PERM(foo) with a procedure call load_perm__foo() 13:05:22 <andythenorth> I can paste the whole FIRS nml, but it's big :P 13:06:25 <glx> seems to be a get_action2() without a set_action2() 13:09:03 <glx> but I don't see how it's possible 13:11:52 <glx> unless feature for procedure is not feature of caller 13:12:01 <glx> (but not sure) 13:14:03 <glx> in NFO procedures are "featureless", but nml doesn't really understand that 13:16:08 <andythenorth> it's in a produce block 13:16:39 <andythenorth> https://gist.githubusercontent.com/andythenorth/2b01dc0719d964ced2fccde0203fb317/raw/19e8e5817e6043e186db2de8ad786d96fdc4d096/gistfile1.txt 13:17:02 <andythenorth> maybe that's not valid? 13:18:50 <glx> should work I think, what's the feature used for the procedure ? 13:20:05 <andythenorth> FEAT_INDUSTRIES 13:20:26 <andythenorth> I can work around this in FIRS, it's just interesting when I break nmlc 13:21:11 <glx> yeah same feature, then it's probably because feature for produce block is defined later (but I need to check) 13:26:58 <glx> I can reproduce it in a modified industry_example.nml 13:29:05 <andythenorth> \o/ 14:00:29 <glx> oh I'm blind, the issue is displayed in front of me before the crash: nmlc warning: ".\example_industry.nml", line 43: Block 'load_temp' is not referenced, ignoring. 14:00:49 <glx> so of course no action2 is assigned 14:04:10 <andythenorth> :) 14:07:29 *** roadt_ has joined #openttd 14:09:06 <glx> oh it can't work def collect_references(self): return [] 14:09:23 <glx> references are not collected for produce blocks 14:09:36 <glx> should be fixable 14:10:46 <DorpsGek> [OpenTTD/game-coordinator] TrueBrain opened pull request #23: Feature: collect very basic statistics about Coordinator usage https://git.io/JW17o 14:10:48 <TrueBrain> OMG I ADDED TELEMETRY 14:11:07 <glx> let's fork to remove them 14:12:10 <LordAro> D: 14:14:19 *** roadt__ has quit IRC 14:14:49 <DorpsGek> [OpenTTD/OpenTTD] LordAro commented on issue #9399: Track 00 of the "All" programme in the jazz jukebox doesn't play https://git.io/Jnbz7 14:14:52 <DorpsGek> [OpenTTD/OpenTTD] LordAro closed issue #9399: Track 00 of the "All" programme in the jazz jukebox doesn't play https://git.io/Jnbz7 14:15:36 <LordAro> TrueBrain: you get to deal with any internet fallout :p 14:16:06 <TrueBrain> I guess I shouldn't mention we also process access-logs? :P 14:17:41 <DorpsGek> [OpenTTD/game-coordinator] TrueBrain merged pull request #23: Feature: collect very basic statistics about Coordinator usage https://git.io/JW17o 14:17:54 <DorpsGek> [OpenTTD/OpenTTD] LordAro approved pull request #9393: Fix #9392: Return a valid value with GetBuildWithRefitCapacity when AIs are maxed out in vehicles https://git.io/JW1Fh 14:23:04 <DorpsGek> [OpenTTD/OpenTTD] LordAro closed issue #9337: Pressing a station name in the station list doesn't move you to the correct station https://git.io/JGDBu 14:23:07 <DorpsGek> [OpenTTD/OpenTTD] LordAro commented on issue #9337: Pressing a station name in the station list doesn't move you to the correct station https://git.io/JGDBu 14:23:45 <glx> ok, progress, I now get an nml error 14:26:12 <DorpsGek> [OpenTTD/game-coordinator] TrueBrain created new tag: 0.3.2 https://git.io/JW1A7 14:26:44 <glx> oh I can't do switch(FEAT_INDUSTRIES, SELF, load_temp, index, LOAD_TEMP(index)) { return; } 14:26:56 <glx> LOAD_TEMP wants a constant 14:30:27 <LordAro> malloc(): unaligned tcache chunk detected 14:30:31 <LordAro> well i wasn't expecting that 14:31:43 <TrueBrain> what did you try? :P 14:31:48 <LordAro> turning breakdowns on 14:32:06 <TrueBrain> bad LordAro :P 14:33:06 <LordAro> specifically, it's crashing when trying to save the setting "server_name" 14:33:34 <LordAro> i do not understand the error message 14:33:47 * LordAro tries recompiling 14:33:56 <LordAro> s/ message// 14:37:07 <TrueBrain> how unusual 14:38:06 <LordAro> well it's still crashing 14:38:10 <andythenorth> oh that's interesting 14:38:13 <LordAro> guess i'll actually have to work out what's going on 14:38:20 <andythenorth> procedure call exceeds the number of varact2 IDs 14:38:26 <TrueBrain> LordAro: gdb? 14:38:28 <andythenorth> but STORE_PERM does not 14:38:54 <TrueBrain> and I guess you are trying a MSYS build? 14:39:00 <LordAro> nope, linux 14:39:42 <TrueBrain> hmm .. even more odd :s 14:39:54 <LordAro> https://pastebin.com/VuqpjFjM 14:39:55 <andythenorth> I guess I run out of procedures, amongst other things 14:40:12 <andythenorth> hmm 14:40:26 <TrueBrain> I wonder what changing that setting has to do with the pathfinder :P 14:40:54 <LordAro> pathfinder? 14:40:56 <TrueBrain> you just open the game, go to Settings, change Vehicle Breakdown, and it crashes? 14:41:02 <LordAro> yup 14:41:05 <TrueBrain> "tcache" is a pathfinder variable 14:41:15 <LordAro> oh no, that is coming from malloc itself 14:41:17 <TrueBrain> hmm, works here .. so that is good and bad at the same time :P 14:41:24 <TrueBrain> ah :D 14:41:37 <LordAro> it is any setting though 14:41:45 <LordAro> gdb suggests that it's saving "server_name" 14:41:59 <LordAro> perhaps my config is "invalid" and it's handling it poorly? 14:42:15 <TrueBrain> found the issue: src/settings.cpp:666 :P :P :P (sorry, that was a troll) 14:42:40 <TrueBrain> sounds like it has something to do with std::string 14:42:47 <LordAro> that would be my guess 14:42:49 <LordAro> but it looks fine 14:43:26 <TrueBrain> starting with "./openttd -x -c empty.cfg", does it still crash? 14:44:05 <TrueBrain> next is without the "-x" 14:44:16 <LordAro> it does not 14:44:32 <LordAro> also defaulted to abase, which is strange 14:44:51 <TrueBrain> yeah, I have the same .. when using -x -c, it seems to pick the first base graphics it can find 14:44:54 <LordAro> no crash without -x either 14:44:56 <TrueBrain> and .. "a" wins :P 14:45:00 <Samu> damn it, i hate it when on load it randomizes ai settings 14:45:08 <TrueBrain> okay, that suggests it indeed is your config 14:45:21 <glx> andythenorth: the limit for procedures (and any other action 2) is 256 (0-255) 14:45:27 <andythenorth> yup 14:45:39 <andythenorth> I have too many procedures 14:46:16 <LordAro> ...i crashed it on startup this time with -d1 14:46:20 <LordAro> completely different error 14:46:23 <LordAro> terminate called after throwing an instance of 'fmt::v7::format_error' 14:47:16 <TrueBrain> backtrace? 14:47:42 <LordAro> somewhere in the fluidsynth music driver 14:48:26 <LordAro> Debug(driver, 1, "Fluidsynth: sf {}", sfont_name); 14:48:29 <LordAro> sfont_name is null 14:48:41 <glx> oups :) 14:48:55 <TrueBrain> well, at least that is unrelated :) 14:49:46 <LordAro> TrueBrain: https://gist.github.com/LordAro/c58c70a0fb788c1c28ca011256bf88ac have a config 14:50:06 <TrueBrain> the code that crashes is a ctor, so that is .. special 14:50:24 <LordAro> i'm suspecting some previous corruption 14:50:26 <LordAro> to valgrind! 14:50:32 <glx> no it tries to do a string(nullptr) 14:50:53 <TrueBrain> Error: Cannot open file 'TRG1R.GRF' 14:50:55 <TrueBrain> with your config :P 14:51:12 <TrueBrain> who uses original_windows? :P 14:51:13 <glx> LordAro: your config contains private stuff ;) 14:51:44 <LordAro> i think you can manage to change the baseset yourself :p 14:51:46 <LordAro> glx: oh no 14:51:52 <TrueBrain> LordAro: crashes for me too with your config 14:52:00 <LordAro> well that's something 14:52:01 <TrueBrain> heap-use-after-free 14:52:32 <TrueBrain> it is the migration of private info to other ini-files 14:53:23 <TrueBrain> seems my attempt in writing a solid RemoveItem didn't work 14:53:42 <glx> musicdriver is not set so it tries autodetect 14:54:04 <TrueBrain> Ini-shit could really use some nice C++-ification 14:55:12 <DorpsGek> [OpenTTD/nml] glx22 opened pull request #225: Fix: Procedure calls reference counting https://git.io/JWMLZ 14:57:21 <LordAro> glx: looks like a perfect opportunity for list comprehensions 14:59:16 <LordAro> TrueBrain: incidentally, presumably changing baseset does not trigger a config save 14:59:47 <TrueBrain> last_item in an IniGroup is a pointer to a place where you can store the next item in the group 14:59:51 <TrueBrain> it is NOT the last item of the group 14:59:59 <TrueBrain> (it points to the "real list item"->next) 15:00:36 <andythenorth> so more switches? 15:00:44 <andythenorth> change action2 IDs to a dword? :P 15:02:50 <Samu> I keep stumbling on this bug 15:03:36 <andythenorth> hmm 15:03:37 <Samu> #7486 15:03:40 <andythenorth> I have tripped "Variable parameter must be a constant number" 15:03:47 <andythenorth> can I patch nmlc to give me a line number? 15:04:01 <andythenorth> it's L444, method is parse_variable() 15:04:08 <andythenorth> in action2var.py 15:05:53 <glx> hmm in SpriteLayout example (in doc), I can see it may be possible for it to use procedure calls (which would mean another counting bug) but I should try first 15:06:18 <glx> andythenorth: it's supposed to give a line number, but somehow the data is not set 15:07:01 <andythenorth> today is all the breaking :) 15:07:24 <glx> I guess you are doing LOAD_TEMP(something) or STORE_TEMP(expr, something) with something being a procedure parameter 15:08:06 <glx> [16:26:45] <+glx> oh I can't do switch(FEAT_INDUSTRIES, SELF, load_temp, index, LOAD_TEMP(index)) { return; } <-- it triggered the same error 15:09:14 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain opened pull request #9445: Fix 75b6051b: removing items from the ini could leave the group in a bad state https://git.io/JWM3v 15:09:14 <TrueBrain> LordAro: ^^ should fix it 15:09:41 <TrueBrain> code was broken in more than one way :) 15:09:45 <TrueBrain> no clue how it passed review :P :P :P 15:09:54 <andythenorth> got a line number 15:10:03 <andythenorth> I changed to expr.pos 15:10:31 <andythenorth> glx yes 15:10:44 <DorpsGek> [OpenTTD/nml] planetmaker approved pull request #225: Fix: Procedure calls reference counting https://git.io/JWM32 15:11:00 <DorpsGek> [OpenTTD/nml] planetmaker merged pull request #225: Fix: Procedure calls reference counting https://git.io/JWMLZ 15:11:11 <andythenorth> I am doing https://gist.githubusercontent.com/andythenorth/b0fd5fe8e337c55fe165181d1b5205fa/raw/f6804904cff446b1a77fc33f613707ca74a15256/gistfile1.txt 15:11:24 <glx> not allowed 15:11:27 <andythenorth> not allowed 15:11:51 <TrueBrain> LordAro: your ini-file had "last_joined" as last entry, which was being moved, causing the issue :) Funny ... and happy you ran into it, before we make a release :D 15:12:02 * andythenorth trying to find ways around 255 limits :P 15:12:09 <LordAro> TrueBrain: i do my best 15:12:15 <glx> maybe it could, but needs work 15:13:10 <TrueBrain> just confirmed having an item that is being moved as first item also works :P 15:13:50 <LordAro> TrueBrain: fix confirmed 15:14:06 <DorpsGek> [OpenTTD/OpenTTD] LordAro approved pull request #9445: Fix 75b6051b: removing items from the ini could leave the group in a bad state https://git.io/JWMGf 15:14:09 <TrueBrain> \o/ 15:14:30 <TrueBrain> I leave the "not saving on changing graphicsets" to you to fix :P 15:15:09 <LordAro> probably part of #9208 15:16:08 <TrueBrain> yeah 15:23:22 <TrueBrain> MSYS CI is fucking slow :P 15:23:34 *** sla_ro|master has joined #openttd 15:23:44 <LordAro> not the CI :p 15:23:46 <LordAro> just MSYS 15:23:53 <LordAro> (or Windows as a whole) 15:25:02 <TrueBrain> why did we add it to the CI again? :P 15:25:09 <LordAro> because you kept breaking it :p 15:25:12 <Samu> I would like to reopen #7486, it bothers me 15:25:32 <TrueBrain> yeah, as nobody should be using it :@ 15:25:37 <LordAro> :o 15:25:55 <TrueBrain> MSYS should die a peaceful death already :P 15:26:09 <TrueBrain> but okay, no, it is fair .. we would keep breaking it if it wasn't in the CI :) 15:26:19 <DorpsGek> [OpenTTD/OpenTTD] LordAro opened pull request #9446: Fix: Crash with debug output enabled https://git.io/JWMWI 15:26:53 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain merged pull request #9445: Fix 75b6051b: removing items from the ini could leave the group in a bad state https://git.io/JWM3v 15:27:28 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain commented on pull request #9446: Fix: Crash with debug output enabled https://git.io/JWMWS 15:28:38 <TrueBrain> and maybe a slightly better commit message? "Fix: crash with debug output for fluidsynth"? Or "Fix: [Fluidsynth] Crash with debug output enabled"? 15:29:02 <TrueBrain> (as not everyone has fluidsynth enabled ;) ) 15:29:37 <glx> yesterday I wanted to test #9444 on XP, but there's no way to build a runnable version 15:30:08 <TrueBrain> glx: good news, we don't support WinXP anyway :) 15:31:22 <glx> mingw requires at least vista (well pthread requires it) 15:38:23 <andythenorth> glx this compiles, but do you think it will work? :P https://gist.githubusercontent.com/andythenorth/94c43cd686dc7701ff568a0bdd94f35c/raw/97d4e1ab1a16af2a6c371a159643d7a655c469d6/gistfile1.txt 15:38:25 <glx> and I don't have VC2017 dlls on the xp VM 15:39:32 * andythenorth thinks that nml is broken 15:39:39 <andythenorth> in the paste 15:40:26 <andythenorth> I don't think it will return the value 15:40:43 <andythenorth> maybe I can do a recursive ternary 15:41:12 <glx> default returns storage_number 15:41:40 <glx> for other cases it should be ok 15:42:49 <andythenorth> runs out of varact2 IDs :) 15:57:38 <glx> andythenorth: it's really not possible to not use a constant as register index 15:57:55 <andythenorth> makes sense :) 15:58:05 *** D-HUND has quit IRC 15:58:18 <andythenorth> can't it deadlock if it's a variable? 15:58:22 <andythenorth> it could just recurse? 15:58:56 <glx> limitation is NFO 0E s or sto [1] var7D[val2] = val1, result = val1 Supported by OpenTTD 0.6 15:59:04 <glx> var7C for persistant 15:59:41 <glx> only option to modify val2 is action6, but that can't work at runtime 16:00:13 <glx> so no way to use a dynamic index 16:00:43 <glx> same for LOAD, as it's a standard var60+x access 16:02:12 <glx> but if you really just do LOAD_PERM in your procedure, the procedure is useless and it's better to use LOAD_PERM directly 16:03:07 <andythenorth> yes 16:03:16 <andythenorth> I have replaced it 16:03:52 <andythenorth> I was hoping to use procedures so that I could load/store town and industry registers freely without having to think about the scope 16:04:07 <andythenorth> the procedure would know the scope, I just want the result 16:04:38 <andythenorth> I think I can force this with big generated switches, and storing the register number in temp storage 16:07:02 <andythenorth> nope, can't do that :) 16:22:18 *** Wuzzy has joined #openttd 16:36:57 <andythenorth> glx ha, I don't understand why this compiles? :) https://github.com/andythenorth/firs/blob/master/src/templates/randomise_primary_production_on_build.pynml#L17 16:37:13 <andythenorth> has been that way since last week, compiles and works no error 16:38:08 <glx> I don't think it should compile 16:38:26 <glx> unless randomise_primary_production_on_build is not referenced 16:38:59 <andythenorth> it is 16:39:06 <andythenorth> and the register is set correctly 16:39:15 <andythenorth> seems odd, given the findings above 16:45:26 <glx> yeah code is weird, I guess it works by luck 16:45:43 <glx> can you show the corresponding NFO ? 16:45:46 <andythenorth> I've just tested it elsewhere 16:45:51 <andythenorth> I'll paste some things 16:46:57 <andythenorth> this is an explicit test https://gist.githubusercontent.com/andythenorth/4151bc2b48a29fce13e8f4c64de592f1/raw/adb2bfaacb069646f676c96e9863b4d9d16cb96c/gistfile1.txt 16:47:04 <andythenorth> I'll generate the NFO for that now 16:49:15 <andythenorth> glx https://gist.github.com/andythenorth/4151bc2b48a29fce13e8f4c64de592f1#gistcomment-3816378 16:51:06 <glx> ah yes it's correct indeed 16:51:47 <glx> so yeah only LOAD can't be dynamic 16:53:28 <andythenorth> interesting :) 16:54:06 <andythenorth> I'm going to make use of that 16:55:17 <andythenorth> TL;DR I prefer to work with (register, value) instead of (value, register) for STORE_TEMP 16:55:21 <andythenorth> so I can write my own :) 16:58:55 <glx> yeah I find silly the value,register choice :) 16:59:21 <glx> but it can't be changed now 16:59:31 <andythenorth> procedure :P 16:59:38 <andythenorth> STORE_TEMP_ALT 16:59:52 <andythenorth> STORE_PERM_ALT in fact 17:00:05 * andythenorth brain fail 17:03:21 <andythenorth> procedures are so cool :D 17:07:15 *** gelignite has joined #openttd 17:07:25 *** jottyfan has quit IRC 17:17:29 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain opened pull request #9447: Feature: allow the use of TURN to connect client and server together https://git.io/JWDeR 17:18:40 *** Wormnest has joined #openttd 17:18:50 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain updated pull request #9447: Feature: allow the use of TURN to connect client and server together https://git.io/JWDeR 17:19:27 <LordAro> TrueBrain: i wonder if it's possible to have some sort of "approval" for TURN connections 17:19:44 <TrueBrain> what use-case are you trying to cover? :) 17:20:03 <LordAro> to avoid some potential abuse scenarios 17:20:43 <TrueBrain> like? 17:20:51 <TrueBrain> (I already covered many, so I am curious which you see :D) 17:21:33 <LordAro> deliberately screwed up networking/hacked client&server to force TURN connections, which then cost us money 17:22:01 <TrueBrain> yeah, that is absolutely possible .. but I also don't really see a way to avoid that, honestly 17:22:24 <TrueBrain> it comes in the territory of embedding a certificate during Release builds which you need to use TURN :P 17:23:06 <TrueBrain> I doubt we want DorpsGek to announce when someone wants to use TURN and we need to manually approve it or something :D 17:23:15 <LordAro> not really, no 17:23:44 <TrueBrain> I kinda initially want to run TURN on AWS 17:23:50 <TrueBrain> but if it is too costly, we just spin up an OVH instance for it 17:23:54 <TrueBrain> that at least is a fixed-fee 17:24:07 <LordAro> i'm imagining that a user has exhausted all other possibilities, asks us for help, so we whitelist an IP range 17:24:15 <LordAro> yeah 17:24:20 <LordAro> ¯\_(ツ)_/¯ 17:24:33 <TrueBrain> yeah, that smiley face kinda covers it :) 17:25:16 <DorpsGek> [OpenTTD/OpenTTD] LordAro updated pull request #9446: Fix: Crash with debug output enabled https://git.io/JWMWI 17:25:27 <TrueBrain> and I agree with your wariness here 17:25:34 <TrueBrain> what we can do, is just try it out, see how it goes 17:25:37 <LordAro> mm 17:25:40 <TrueBrain> we can always turn it off (hihi) 17:25:51 <TrueBrain> or start to include/exclude lists, etc 17:25:59 <LordAro> will the TELEMETRY be output anywhere? 17:26:04 <LordAro> ideally with nice fancy graphs 17:26:07 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain approved pull request #9446: Fix: Crash with debug output enabled https://git.io/JWDJT 17:26:17 <TrueBrain> LordAro: if you build the fancy graphs, sure 17:26:20 <TrueBrain> I have a JSON endpoint for you 17:26:56 <LordAro> could build it into master-server-web ? 17:27:10 <TrueBrain> sure, go for it :D 17:27:38 <glx> scaled graph, but hide the real values ;) 17:27:56 <glx> only percentage 17:28:19 <TrueBrain> https://server.coordinator.openttd.org/stats is the endpoint .. bucket is "days since 1970", it keeps 30 days 17:28:35 <TrueBrain> TURN is not in there ofc, but that will also track bytes relayed, and stuff 17:28:47 <LordAro> :) 17:28:59 <TrueBrain> (not in there YET, to be clear) 17:29:10 <TrueBrain> so if you feel up for it, make something pretty :) 17:29:39 <TrueBrain> values are strings, but they really are integers .. redis makes everything strings :P 17:29:49 <TrueBrain> I might fix that in the API ... 17:30:26 <DorpsGek> [OpenTTD/nml] glx22 opened pull request #226: Fix: Use a most likely defined position when reporting error https://git.io/JWDU2 17:30:26 <peter1138> This beer is going down quickly, I might need to chill another. 17:33:25 <LordAro> peter1138: me too pls 17:33:35 <peter1138> :) 17:33:39 <LordAro> i do need to pop out to get some milk and things... 17:42:16 <andythenorth> mmm 17:42:18 <andythenorth> thirsty 17:46:25 <DorpsGek> [OpenTTD/nml] LordAro approved pull request #226: Fix: Use a most likely defined position when reporting error https://git.io/JWDtv 17:46:51 <DorpsGek> [OpenTTD/nml] LordAro commented on pull request #224: Fix: Reject empty arrays of expressions https://git.io/JWDtO 17:47:01 <andythenorth> hmm 17:47:41 <DorpsGek> [OpenTTD/nml] glx22 merged pull request #226: Fix: Use a most likely defined position when reporting error https://git.io/JWDU2 17:48:32 <glx> LordAro: issue is it's impossible to test for failure in current workflow 17:48:43 <LordAro> ah 17:48:53 <LordAro> maybe you should make a new workflow :p 17:49:39 <glx> regression just checks the output doesn't change 17:53:48 <andythenorth> hmm 17:54:08 <andythenorth> can I call a procedure on PARENT and yield a result? 17:54:23 <glx> yes 17:54:30 <andythenorth> I have a switch that returns fine, but using it as procedure with parameter doesn't yield 17:54:51 <glx> procedure uses feature of the caller, but can access SELF or PARENT 17:54:51 <andythenorth> unless I just forgot to refresh the industry window :P 17:54:56 <andythenorth> sometimes it paints, sometimes it doesn't 17:55:06 <andythenorth> 'aids debugging greatly' 17:55:21 <andythenorth> (industry debug window) 17:59:41 <andythenorth> nope, can't call a procedure that is scoped to PARENT and get a result 18:00:57 <andythenorth> maybe it's not the scope 18:02:52 *** Flygon has quit IRC 18:04:20 <andythenorth> maybe can't call a parameterised procedure as an argument to a parameterised procedure 18:04:52 * andythenorth guesses that's probably noted above if I read up far enough :P 18:16:24 * andythenorth such adventures 18:25:44 <andythenorth> yeah this works 18:25:46 <andythenorth> STORE_TEMP(LOAD_PERM_TOWN_test(), 11), 18:25:46 <andythenorth> STORE_PERM_ALT(62, LOAD_TEMP(11)), 18:25:52 <andythenorth> this does not STORE_PERM_ALT(62, LOAD_PERM_TOWN_test()), 18:26:16 *** Wormnest has quit IRC 18:29:06 <LordAro> peter1138: i have returned from the shop 18:29:09 <LordAro> ...without milk 18:29:12 <LordAro> because i'm an idiot 18:29:23 <peter1138> Milk in beer seems wrong anyway. 18:29:37 <LordAro> it goes better with weetabix 18:37:27 <DorpsGek> [OpenTTD/OpenTTD] rubidium42 commented on pull request #9447: Feature: allow the use of TURN to connect client and server together https://git.io/JWDCH 18:41:15 *** Zathras has quit IRC 18:50:15 <DorpsGek> [OpenTTD/OpenTTD] DorpsGek pushed 1 commits to master https://git.io/JWD81 18:50:16 <DorpsGek> - Update: Translations from eints (by translators) 19:08:02 <glx> andythenorth: it does, but only if LOAD_PERM_TOWN_test() return value doesn't change between STORE_TEMP and the next LOAD_TEMP ;) 19:08:13 *** D-HUND has joined #openttd 19:10:59 <glx> hmm misunderstood 19:11:09 <andythenorth> happens to me a lot :D 19:11:44 <glx> anyway it should work, unless something is wrong in your procedure 19:13:16 <glx> a call is just "evaluate first arg and store the result in temp", "evaluate second arg...", do the call 19:13:33 <glx> store the result in temp (for future use) 19:15:23 <andythenorth> maybe something over-writes temp? 19:16:11 <glx> it's tested by 033.nml 19:16:22 <glx> and NFO looks right there 19:17:48 <andythenorth> I could maybe isolate a test case :) 19:18:37 <andythenorth> the procedure reads from town so different scope 19:18:47 <andythenorth> can't remember if I tried same scope 19:20:04 <glx> 036.nml does like 033 but with different scopes 19:23:33 <andythenorth> maybe the procedure is weird 19:33:00 *** WormnestAndroid has quit IRC 19:33:16 *** WormnestAndroid has joined #openttd 19:37:39 <glx> usually nfo helps to spot an issue 19:46:18 *** HerzogDeXtEr has joined #openttd 19:57:02 * andythenorth making nfo 19:58:48 *** Progman has joined #openttd 19:59:21 <andythenorth> glx L44 and L53 https://gist.github.com/andythenorth/df51f3b8fa7bce212a87604702fb836c 19:59:52 <andythenorth> unless I read the nfo wrong :P 20:01:49 <glx> LOAD_PERM_TOWN default return is storage_number (but should not be a problem here) 20:02:16 <andythenorth> I've added the nml in a comment also 20:02:33 <andythenorth> if I'm doing bad nml, I can change it :) 20:13:55 <glx> nfo seems fine, I don't see overwrite of registers 20:24:50 <glx> really can't find an issue in the nfo, it should work 20:31:42 <glx> oh found it 20:35:10 <glx> it's a bug with how I manage the temp variables 20:35:38 <glx> now I need to remember where I do it 20:35:39 <andythenorth> this stuff is so cool :) 20:36:02 <andythenorth> much more interesting than css 20:36:19 <glx> I commented on your gist 20:36:42 <glx> the bug should be obvious and I totally missed it 20:41:45 *** nielsm has quit IRC 20:46:06 <andythenorth> I should get a job in QA :) 20:48:37 <glx> at least regression test for that already exists 20:48:53 <glx> it's just based on broken nfo output :) 21:06:11 *** sla_ro|master has quit IRC 21:20:25 *** Samu has quit IRC 21:30:32 *** Tirili has joined #openttd 21:37:27 *** D-HUND has quit IRC 21:46:15 *** D-HUND has joined #openttd 21:47:09 *** andythenorth has quit IRC 22:20:17 <TrueBrain> Hmm .. seems I pissed off our redis .. oom :D 22:32:34 <TrueBrain> restarted the redis instance in an attempt to recover 22:32:37 *** gelignite has quit IRC 22:32:40 <TrueBrain> not really an idea what is going on :P 22:36:02 *** Wolf01 has quit IRC 22:40:50 <DorpsGek> [OpenTTD/nml] glx22 opened pull request #227: Fix f2cab72: Called procedures may receive wrong values in parameters https://git.io/JWyIz 22:43:04 <DorpsGek> [OpenTTD/OpenTTD] TrueBrain commented on pull request #9447: Feature: allow the use of TURN to connect client and server together https://git.io/JWyLT 22:43:07 <DorpsGek> [OpenTTD/nml] glx22 updated pull request #227: Fix f2cab72: Called procedures may receive wrong values in parameters https://git.io/JWyIz 22:43:22 <glx> I always forget black and flake 22:44:02 <TrueBrain> in positive news, the way I made the deployments on AWS are indeed self-healing :D 22:44:35 <TrueBrain> all keys were evicted from the redis instance, and still it didn't have enough free memory to resume operation ... not sure what is eating up the memory :) 22:44:38 <TrueBrain> I need to do some testing for that .. 22:45:16 <glx> always better when a(n auto)restart is enough to fix things 22:45:58 <glx> until the next one 22:49:31 *** Progman has quit IRC 22:58:58 <TrueBrain> @calc 10 * 60 * 24 * 7 22:58:58 <DorpsGek> TrueBrain: 100800 23:18:48 *** HerzogDeXtEr has quit IRC 23:26:47 <DorpsGek> [OpenTTD/game-coordinator] TrueBrain opened pull request #24: Fix: gc-stream wasn't given a limit correctly, causing it to grow infinite https://git.io/JWysz 23:26:50 <DorpsGek> [OpenTTD/master-server] TrueBrain opened pull request #47: Fix: gc-stream wasn't given a limit correctly, causing it to grow infinite https://git.io/JWysg 23:27:10 <TrueBrain> well, found the issue :P 23:27:48 <DorpsGek> [OpenTTD/game-coordinator] TrueBrain merged pull request #24: Fix: gc-stream wasn't given a limit correctly, causing it to grow infinite https://git.io/JWysz 23:27:53 <DorpsGek> [OpenTTD/master-server] TrueBrain merged pull request #47: Fix: gc-stream wasn't given a limit correctly, causing it to grow infinite https://git.io/JWysg 23:28:43 <DorpsGek> [OpenTTD/master-server] TrueBrain created new tag: 1.2.4 https://git.io/JWysy 23:28:46 <DorpsGek> [OpenTTD/game-coordinator] TrueBrain created new tag: 0.3.3 https://git.io/JWysS 23:47:09 <DorpsGek> [OpenTTD/OpenTTD] glx22 commented on pull request #9447: Feature: allow the use of TURN to connect client and server together https://git.io/JWyZj