IRC logs for #openttd on OFTC at 2019-04-28
⏴ go to previous day
00:10:00 <DorpsGek_II> [OpenTTD/OpenTTD] PeterN requested changes for pull request #7485: Add: Dropdown build menus from toolbar have icons https://git.io/fjGm6
00:10:50 <pnda> peter1138 what changes have occured in the current master to DropDownList?
00:13:27 <peter1138> See PopupMainToolbMenu() in src/toolbar_gui.cpp
00:14:15 <DorpsGek_II> [OpenTTD/OpenTTD] PeterN commented on pull request #7485: Add: Dropdown build menus from toolbar have icons https://git.io/fjGmP
00:14:37 <peter1138> (And yea, ditch those blank newlines)
00:15:02 <pnda> So just ->push_back was replaced with .emplace_back?
00:15:55 <pnda> Well thanks, I'll update that
00:24:08 <pnda> So I've changed the stuff and built the project. But I am still 38 commits behind master. Does that matter?
00:31:32 <pnda> So like what is this, a Fix, Add, Change, Update?
00:33:15 <peter1138> Does not need to change?
00:39:16 <pnda> So I just amended my latest commit "Codechange: Set default values to 0 for air and water". Is that ok?
00:39:31 <peter1138> Squash it all together?
00:43:13 *** Elon_Satoshi has joined #openttd
00:47:08 <DorpsGek_II> [OpenTTD/OpenTTD] spnda dismissed a review for pull request #7485: Add: Dropdown build menus from toolbar have icons https://git.io/fjGIK
00:47:09 <DorpsGek_II> [OpenTTD/OpenTTD] spnda updated pull request #7485: Add: Dropdown build menus from toolbar have icons https://git.io/fjtIt
00:47:31 <peter1138> Heh, you didn't ditch the blank lines
00:47:50 <pnda> Ohhh I forgot to do that
00:48:00 *** arikover has joined #openttd
00:48:13 <pnda> I did that before rebasing and changes went away... I'll redo this now
00:48:24 <peter1138> "changes went away" ... um..
00:48:39 <pnda> Yeah like I had to stash them
00:48:53 <peter1138> The great thing about git is commits are easy ;)
00:49:22 <peter1138> (Not like svn, where it goes off to the server and they're rather final...)
00:49:27 <pnda> I just did git commit --amend is that enough for git to pick up the changes?
00:51:30 <peter1138> You still need to pick the files you want to add.
00:52:27 <pnda> So git commit --amend -a will do the job right
00:54:49 <DorpsGek_II> [OpenTTD/OpenTTD] spnda updated pull request #7485: Add: Dropdown build menus from toolbar have icons https://git.io/fjtIt
00:58:22 *** Thedarkb-T60 has joined #openttd
02:19:05 *** arikover` has joined #openttd
02:22:40 *** Gustavo6046 has joined #openttd
02:28:59 <DorpsGek_II> [OpenTTD/OpenTTD] PeterN opened pull request #7549: Fix: Clicking on scrollbar 'thumb' moved position up instantly. https://git.io/fjGOQ
02:29:34 <Samu> oh crap, my ai suffered an humilating defeat
02:33:53 <Elon_Satoshi> oof ouch owie AI hurting juice
02:39:20 <Elon_Satoshi> What do I do when my ratings drop to atrocious in a city?
02:41:12 <Elon_Satoshi> what do you mean?
02:43:49 <_dp_> Elon_Satoshi, planting trees increases rating
02:44:21 <_dp_> Elon_Satoshi, or if you're not in mp just enable magic bulldozer
02:45:24 <_dp_> hm, though I guess bulldozer won't help when rating is already bad...
02:45:57 <_dp_> so, that leaves trees and bribes
02:46:43 <_dp_> enabling bulldozer just allows to avoid dealing with that nonsense in future
02:46:58 <Elon_Satoshi> you mean i could just bulldoze the town away?
02:47:48 <Elon_Satoshi> i wonder what happens if i try to carry passengers n' stuff with a helicopter to and from the town that rates me atrocious
02:47:48 *** Supercheese has joined #openttd
02:48:05 <Elon_Satoshi> Btw is multiplayer good for low bandwidth internet and high latency?
02:48:21 * Elon_Satoshi uses satelite internet and only plays chess
02:48:39 <_dp_> Elon_Satoshi, helicopters or not doesn't matter, any active station increases rating, any inactive decreases
02:48:39 <peter1138> You need bandwidth initially to download the map from the server.
02:49:08 <peter1138> And then any action you perform goes via the server, so high latency is... not too fun.
02:49:21 <_dp_> but server usually can't :(
02:51:47 <Elon_Satoshi> Ugh why aren't there any high latency friendly games?
02:52:46 <peter1138> I remember play-by-mail games back in the 80s and 90s :-)
02:52:50 <peter1138> Super high latency...
02:53:07 <peter1138> And yes, that was sending a floppy disk in the post, not email :-)
02:53:36 * Elon_Satoshi wonders if play-by-mail games are cross compatible with IP over avian carrier
03:02:02 * Elon_Satoshi surrounds Highland Hills with so many trees they'll never see the horizon again
03:04:28 <Elon_Satoshi> wow they love me now
03:09:51 <Elon_Satoshi> Is OpenTT educational at all?
03:25:31 <peter1138> Programming it certainly is.
04:00:55 <Eddi|zuHause> people have said they used it in education
04:02:55 <Eddi|zuHause> one would imagine turn-based games, like, say magic, would be good for high latency. but the modern online versions of those are probably still coded to kick you if you didn't respond in X seconds
04:06:29 <supermop_Home> tho kgs its hard to find matches for untimed games
04:06:49 <Elon_Satoshi> What parts of OpenTTD have to be live?
04:07:30 <Eddi|zuHause> Elon_Satoshi: if you place a rail tile, every client in your game must place that rail tile in the exact same tick
04:08:19 <Eddi|zuHause> Elon_Satoshi: so if you click on a tile to build, first this build attempt is sent to the server, the server verifies it, and sends it out to all clients with a tick number when it should happen
04:08:48 <Eddi|zuHause> Elon_Satoshi: your game must pause until that message arrives
04:14:25 <Eddi|zuHause> the client always lags slightly behind the server for this reason, which is in itself not the problem. high latency will increase this lag, so a) you will have to wait some time for your click to result in an action, and b) the game state on the server might be different from the state that you see, because other people (or town growth, or whatever) might have changed the area you are building in
04:14:55 <Eddi|zuHause> so you might frequently run into situations where your actions fail
04:15:21 <Eddi|zuHause> because something appeared to have been buildable for you, but on the server it failed
04:16:45 <peter1138> 03:08 < Eddi|zuHause> Elon_Satoshi: your game must pause until that message arrives
04:17:05 <Eddi|zuHause> peter1138: i was maybe being overly simplifying
04:17:54 <Eddi|zuHause> peter1138: but my understanding is that the server sends out a heartbeat a la "it is now safe to proceed to tick <X>"
04:19:58 <Elon_Satoshi> If my client locks up such that not even the cursor moves, is that because of server lag or client lag? It seems like a client lag thing though
04:20:06 <peter1138> The client always lags behind the server because the server is authoritative and must execute all commands first.
04:20:40 <peter1138> The cursor doesn't move then it's probably trying to catch up with the server.
04:21:18 <Eddi|zuHause> if you have a high latency, then all the server's "proceed now to tick <X>" messages will probably arrive in bulk
04:21:24 <Eddi|zuHause> and the client has to catch up
04:22:13 <Eddi|zuHause> so you will have a stop-and-go game
04:23:02 <Elon_Satoshi> not even that, "Your computer took too long to join the server"
04:23:07 <Eddi|zuHause> that even the mouse locks up is a result of the very 90s architecture of the game core, where GUI and game logic aren't properly separated
04:23:36 <Eddi|zuHause> yeah, you need a specially configured server with higher lag timeouts
04:27:35 <Eddi|zuHause> Elon_Satoshi: joining a game is particularly problematic, because while you're downloading the map, the server already moves on, so when you finish downloading the map, you will also have to rush ahead to the current state of the server
04:28:11 <Eddi|zuHause> Elon_Satoshi: it helps if the server is paused
04:29:12 <Elon_Satoshi> maybe i'll just play singleplayer
04:29:25 <Eddi|zuHause> that is probably better :)
04:29:40 <Elon_Satoshi> unless you need someone to help test experimental high latency multiplayer
04:29:54 <Elon_Satoshi> I offer 600ms ping time
04:30:08 <Eddi|zuHause> Elon_Satoshi: there once were a bunch of people who played a savegame for 10 years, then passed it around to the next person :)
04:30:29 <Elon_Satoshi> 10 years gametime or real time?
04:31:14 <Eddi|zuHause> which is like 2 hours of playtime
04:31:41 <Eddi|zuHause> (not counting pause)
04:32:01 <Elon_Satoshi> I think I'm gonna urge hyperrogue to make their network multiplayer latency friendly if they ever decide to add such a feature
04:32:49 <Elon_Satoshi> I wonder how well battle of wesnoth is with latency
04:33:41 <Eddi|zuHause> maybe you should stick to turn based games ;p
04:33:52 <Eddi|zuHause> have you tried CIV? :)
04:35:24 <Elon_Satoshi> you mean openciv?
04:35:28 <Elon_Satoshi> or was it freeciv?
04:35:56 <Eddi|zuHause> uhm, that, or regular iv :p
04:55:42 <DorpsGek_II> [OpenTTD/OpenTTD] PeterN commented on pull request #7546: Fix #6507: Don't try to load invalid depots from older savegames https://git.io/fjG3H
06:42:01 *** sla_ro|master has joined #openttd
06:44:19 *** tokai|noir has joined #openttd
06:44:19 *** ChanServ sets mode: +v tokai|noir
07:18:02 *** Supercheese has joined #openttd
08:36:09 *** andythenorth has joined #openttd
08:47:42 *** sla_ro|master has joined #openttd
09:12:58 *** andythenorth has joined #openttd
09:54:15 *** andythenorth has joined #openttd
10:28:23 <V453000> got conflicting answers so far :D
10:36:25 *** Progman has joined #openttd
10:59:22 *** Progman has joined #openttd
10:59:51 *** gelignite has joined #openttd
12:12:09 <Wolf01> Meh, snowing at 60km from here
12:16:23 *** andythenorth_ has joined #openttd
12:16:50 <andythenorth_> so if we had arbitrary tracks on road tiles
12:17:03 <andythenorth_> I could do really big mining trucks
12:17:11 <andythenorth_> single one-way track
12:18:36 <andythenorth_> and feldbahn could have 4 tracks on a tile
12:19:55 <andythenorth_> cargo transport rate per tile is key game mechanic :D
12:25:20 *** frosch123 has joined #openttd
12:30:01 *** andythenorth_ has joined #openttd
12:30:34 *** Alberth has joined #openttd
12:30:34 *** ChanServ sets mode: +o Alberth
12:36:20 *** Speedy` has joined #openttd
13:08:03 <peter1138> So a road type lists what lane combos it supports?
13:08:54 <frosch123> merging rail and roadtypes into one?
13:09:30 <peter1138> Ideas for more than just two lanes.
13:10:03 * Wolf01 with Eddi's voice: state machine
13:10:20 <peter1138> Yes, that's lovely.
13:10:26 <peter1138> Guess what. That's what we need to define.
13:10:35 <peter1138> Just saying "state machine" doesn't make it happen.
13:11:11 <Wolf01> I would make one way roads make use of both lanes first
13:11:18 <frosch123> i guess then we need extra-zoom for world coordinates
13:11:42 <peter1138> Wolf01, that's pretty orthogonal to this.
13:12:21 <peter1138> frosch123, possibly, possibly not.
13:12:23 <Wolf01> Yes, you need to change the same bits of code
13:12:44 <peter1138> Wolf01, yeah, so you'd be doing it twice.
13:14:08 <peter1138> Wolf01, but without thinking ahead as to the final solution, you end up with a half-assed interim that limits your final solution, or at least requires a load of otherwise unnecessary conversion.
13:14:27 <Wolf01> Yes, that's what happened with NRT
13:14:32 <peter1138> So you might have a good solution that works, only for it to be ripped out again.
13:16:13 <Wolf01> We need to define a fully flexible system which also allow dedicated lanes and how to assign them, the interface might be really complicate
13:19:12 <Wolf01> And, which will be the target? From 1 lane per tile to 4 lanes per tile?
13:22:18 <peter1138> frosch123, current lanes are at position 5 and 9, that leaves some room.
13:23:25 <frosch123> you have less room on horizontal and vertical tracks or curves
13:23:59 <frosch123> but i see andy's strategy to draw less pixels :p
13:43:32 <peter1138> There's just enough room for 'curves'
13:53:45 <peter1138> Wolf01, any further thoughts on that?
13:53:59 *** chomwitt has joined #openttd
13:58:07 * Artea invites peter to try year 3001 and 818,100,000 euros loan
13:59:39 <Wolf01> Different speed limits per lane
14:00:11 *** andythenorth_ has joined #openttd
14:02:12 <Wolf01> Also... diagonal roads, while we are at it
14:03:00 <Wolf01> Only introduced by grfs
14:39:34 <peter1138> The issue with diagonal roads is the transitions.
14:41:11 *** HerzogDeXtEr has joined #openttd
14:42:28 *** Thedarkb-T60 has joined #openttd
14:43:18 <peter1138> Bah, managed to get a blister on my hand from 40 minutes work :p
14:43:29 *** andythenorth has joined #openttd
14:46:40 <andythenorth> so the problem is how to define a list of directed edges between points on a tile?
14:47:07 <andythenorth> isn't defining vectors on a 2D plane a well solved problem?
14:47:58 <andythenorth> where would we even start to define tracks?
14:48:02 <andythenorth> how are they currently defined?
14:48:49 <peter1138> I love it when people suggest random things and say it's solved.
14:51:37 <andythenorth> usually I say it, and Eddi tells me why I'm wrong
14:51:52 <andythenorth> then sometimes we make progress :P
14:53:35 <andythenorth> so roadveh_movement.h has a load of pairs defined for stuff
14:53:45 <andythenorth> am I starting in a roughly correct place?
15:08:35 <Eddi|zuHause> that's the current hardcoded state machines
15:09:10 <peter1138> So a new "state machine" needs to know how to go from lane A to lane B.
15:09:27 <Eddi|zuHause> these probably need ripping out and redoing with the hypothetical new state machine engine
15:09:28 <peter1138> It needs to know what lanes are available.
15:09:41 <peter1138> And that is about it :p
15:10:21 <peter1138> If someone wants to tackle converting TILE_SIZE from 16 to 64, that's... a big job.
15:11:14 <peter1138> How many lanes do you get on diagonal roads? o_O
15:11:31 <andythenorth> diagonal roads are scary
15:11:41 <peter1138> Easy, diagonal roads can't have junctions.
15:11:51 <peter1138> So only 2 trackbits can be set.
15:12:06 <peter1138> If it has 4 trackbits set, it's a 4-way junction.
15:12:06 <Eddi|zuHause> that's quite some limitation
15:12:17 <peter1138> Disturbs me very sprites.
15:12:17 <andythenorth> I can't even begin to imagine how diagonal roads look like to build
15:13:05 <peter1138> Let's see if I can complete MAP07 without dying. I am... using save/load, though.
15:16:21 <Eddi|zuHause> we currently have 4 trackbits, diagonal would add 8 more? (4 tile edges)x(3 exit directions)
15:18:22 <peter1138> I think trackbits would stay the same
15:18:27 <Eddi|zuHause> road vehicle movement would have some defined width, which imposes an effective minimum spacing of parallel lanes, but if there's nothing to stop you from setting the lane offsets narrower, the pathfinding needs ways to handle this
15:19:01 <Eddi|zuHause> peter1138: i can't imagine how that works
15:19:14 <peter1138> Current 4 trackbits control 2 lanes.
15:19:28 <peter1138> 4 trackbits can thus be used to control 1, 2, 3 or whatever lanes.
15:20:01 <peter1138> A trackbit effectively means road exits that edge.
15:21:07 <Eddi|zuHause> so the trackbit gets ways to define not only lane offset, but also lane direction?
15:21:42 <Eddi|zuHause> how would it then allow diagonal road bits?
15:21:48 <peter1138> exits perhaps not the right word? road enters/exits/
15:22:24 <peter1138> You just have a state machine (lol) that moves vehicles diagonally instead of around a corner. And then show that... er... visually.
15:23:33 <Eddi|zuHause> there's two problems with that: a) people will want predefined state machines for the most common situations, and b) you need to combine the state machines from the 4 road bits somehow
15:23:36 <DorpsGek_II> [OpenTTD/OpenTTD] LordAro commented on pull request #7546: Fix #6507: Don't try to load invalid depots from older savegames https://git.io/fjGW7
15:24:08 <peter1138> There won't be anything other than predefined 'state machines'
15:24:32 <Eddi|zuHause> that's quite some limitation
15:24:49 * andythenorth wonders when the world will invent the irc collaborative equivalent of whiteboards, or fag packets in the pub
15:25:01 <andythenorth> it will be carnage, but often words don't cut it :P
15:25:17 <peter1138> NewGRF airports got stuck on state machine definition. Why would we want to get stuck again?
15:25:29 <peter1138> andythenorth, discord or slack probably has them.
15:25:44 <andythenorth> also, how else can keep up the required rate of rage quits?
15:25:54 <andythenorth> other than over-reaching and making people grumpy and stressed :P
15:26:38 <andythenorth> what's the worst thing we can do?
15:27:12 <Eddi|zuHause> peter1138: iirc the problem with airport state machines was allowing a way to write them (in NewGRF) while preserving the author's sanity
15:27:25 <peter1138> Yes. What's the difference?
15:27:47 <andythenorth> what are the available options?
15:27:58 <andythenorth> [newgrf defined state machines | pre-defined state machines]
15:28:04 <Eddi|zuHause> maybe this is where truebrain comes in and tell us we're thinking too closely in existing solutions? :)
15:28:33 <Eddi|zuHause> over the jordan?
15:30:05 <andythenorth> possibly not that extreme
15:30:28 <Eddi|zuHause> (does that even translate?)
15:36:56 <andythenorth> if you mean 'is TB dead?' then yes
15:37:32 <Alberth> I think you can compute them, but it's far from standard practice
15:40:07 <Alberth> basically model what can happen, and where the decision points are, then compute where stuff goes wrong and chop off that part of behavior at the decision point before it
15:43:19 <Eddi|zuHause> andythenorth: yes, that's the meaning i intended. my 30 seconds of googling only came up with origin explanations that i'd file under "bullshit"
15:43:40 <Eddi|zuHause> so i wasn't sure how "international" it is
15:43:55 <andythenorth> yeah I googled to check, but I'd heard it before
15:54:54 <andythenorth> turns out 60w is a lot more than 30w when it comes to USB-C PD
15:55:12 <andythenorth> 30w reduces the rate of battery consumption, 60w charges it quickly :P
15:55:31 <peter1138> It's almost double!
15:56:30 * andythenorth can only think in terms of lightbulbs
15:56:39 <andythenorth> very confusing comparing lightbulbs to laptops
15:56:58 <Eddi|zuHause> one lightbulb equals 10 LEDs
16:05:30 *** supermop_Home has joined #openttd
16:23:20 <Wolf01> Rise to ruins is giving me headaches
16:46:29 <Artea> MU Online just made me mad
16:46:35 <Artea> died in Devil's Square :(
16:59:54 *** Wormnest has joined #openttd
17:03:41 <peter1138> We didn't get far. NRT is still unmerged.
17:17:16 <peter1138> Ok, how many lanes should be permitted?
17:22:52 *** sla_ro|master has joined #openttd
17:26:43 *** D-HUND is now known as debdog
17:26:53 <Artea> I can see someone already asked for mp3/ogg player
17:30:32 <peter1138> Nah, 7 different lanes.
17:30:52 <peter1138> Then it's possible to have 3 centred.
17:31:13 <peter1138> Of course more than 4 at one time would be a little... cramped.
17:32:13 <peter1138> Also means you can have 1 centred lane.
17:33:11 <Artea> <andythenorth_> bbl, phone irc :p
17:34:43 <andythenorth> but it would be weird to use all 7 :P
17:34:50 <Artea> readling logs is funny sometimes
17:34:52 <andythenorth> 2, 3, or 4 on differing offsets :P
17:36:00 <peter1138> So current roads would be lanes 2 and 4
17:40:00 <Eddi|zuHause> i think you should be able to give each lane any exit point along the edge
17:41:36 <Eddi|zuHause> so, existing roads would have the lane configuration like {(5,NE),(9,SW)}
17:42:42 <Eddi|zuHause> generating a state machine on any random combination might be a pain
17:43:30 <Eddi|zuHause> and then we still haven't tackled overtaking
17:49:39 <DorpsGek_II> [OpenTTD/OpenTTD] YJSoft commented on issue #7511: Loading font from game folder not works at some windows version https://git.io/fjG4Y
17:51:24 *** Thedarkb-T60 has joined #openttd
17:54:11 <Eddi|zuHause> michi_cc: not quite. what i have in mind right now, is that the NewGRF provides a list of lane patterns, and the 4 road bits on the tile each specify which list entry they are referring to. the tile must then come up with a state machine connecting the 4 road bits
17:54:38 <michi_cc> But traffic lights :D
17:54:49 <peter1138> Yikes, how large do you think our map array is?
17:56:13 <Eddi|zuHause> peter1138: how else are you going to have transition tiles?
17:58:23 <Eddi|zuHause> (also, we will need to double that, as road and tram can have different lane patterns)
18:02:07 <Eddi|zuHause> the other option is prefab transition and crossing tiles ("traffic objects"), then with NewGRF state machine support.
18:03:32 <Eddi|zuHause> which will be subject to serious combinatorial explosion
18:03:48 <peter1138> And this is why we need limits.
18:04:05 <peter1138> Otherwise you end up with 1KB per map tile...
18:04:17 <peter1138> But at least it's a solved problem!
18:05:05 <Artea> (wondering if peter likes Brutal DooM)
18:06:51 *** Thedarkb-T60 has joined #openttd
18:06:52 <Eddi|zuHause> if you allow 2^X lane patterns per road type, you need X*4*2 map bits
18:07:12 <Eddi|zuHause> with X=4 that's 32bits
18:07:55 <peter1138> And that is not happening.
18:08:06 <Eddi|zuHause> just supporting the current one-way roads would already be 4 lane patterns
18:10:59 <Eddi|zuHause> i'm having trouble imagining another system that is flexible enough to be useful
18:11:14 <Eddi|zuHause> maybe you should explain your thoughts then?
18:11:24 <V453000> lesson learned: don't ask people if you want a decisive answer :D
18:11:32 <V453000> what's the opinion here?
18:11:35 <peter1138> Who on IRC prefers the first one?
18:11:53 <peter1138> And i@ve not seen anything about it here.
18:11:57 <V453000> is 2nd one that much better?
18:12:08 <LordAro> i prefer the first one
18:12:29 <peter1138> Eddi|zuHause, prefabs
18:12:31 <Eddi|zuHause> i would consider a 3rd option
18:12:48 <Eddi|zuHause> having the outer engines "rounded", and the middle ones "blocky"
18:13:16 <V453000> but yeah that would probably be nicest
18:13:47 <Eddi|zuHause> it's an easy check whether a vehicle is the first or the last in the chain, to switch graphics :p
18:14:12 <V453000> yes I already do that in many places
18:14:49 <V453000> I just can't say I want to draw a middle sprite version for every rounded train I have at the moment :D
18:15:18 <V453000> Also the 2nd option would probably be quite weird with 6 engines
18:15:26 <V453000> though, how often do you really build 4, or even 6
18:16:02 <Eddi|zuHause> if you don't know, then how would i? :p
18:16:43 <peter1138> Remind me what the axonometric grid angles should be?
18:16:46 <Eddi|zuHause> if the vehicles are non-articulated, you can let the user handle it by ctrl+click flipping
18:16:48 *** gelignite has joined #openttd
18:17:25 <DorpsGek> Eddi|zuHause: 0.463647609001
18:17:31 <Eddi|zuHause> @calc atan(1/2)*180/pi
18:17:31 <DorpsGek> Eddi|zuHause: 26.5650511771
18:17:50 <Eddi|zuHause> is that what you were asking?
18:18:07 <peter1138> Bah, Inkscape rounds it to 26.57
18:18:25 <Eddi|zuHause> probably close enough :p
18:19:25 <frosch123> V453000: second one is way better
18:20:34 <frosch123> engines can be either /¯\ or /¯¯, but not /¯/¯
18:23:08 <pnda> How do I draw a Button inside a Window?
18:23:53 <peter1138> You add a button to the nested widget list.
18:24:10 <V453000> ok, 2nd one wins with overwhelming force :) thank you very much :)
18:24:18 <V453000> now I have to rewrite how it draws (:
18:24:33 * V453000 has the code generated from python :))))
18:25:09 <frosch123> do you use andy horse stuff
18:25:14 <frosch123> or invent your own magic?
18:25:56 <V453000> no not that much andy
18:26:01 <V453000> it's not that complicated
18:26:24 <V453000> I only use python to generate the first version and then fix bugs manually usually
18:26:31 <V453000> also the unique switches I write manually
18:26:35 <frosch123> yeah, i expected it to be easier to write your own magic nistead of using someone else's magic
18:26:58 <V453000> so it's just helpful for mass things, but it's not like I press 1 button and everything generates itself and compiles
18:27:01 <frosch123> uh, you edit the generated stuff?
18:27:14 <V453000> if something is a PITA to add to the code
18:27:24 <pnda> What's the button thingy for NWidget?
18:27:32 <V453000> but of course I try to avoid having to edit it at all
18:27:32 <Eddi|zuHause> thats sounds like an antipattern
18:28:13 <V453000> well no Eddi, it's just trying to be reasonably time efficient. I don't need the generation script to be absolutely perfect to every detail and edge case, like if the first switch would end up with 0..0 or something
18:28:16 <Eddi|zuHause> i think the usual approach is to have some way to funnel the potential later edits into the generation process
18:28:20 <V453000> but yes the latest version generates a perfect thing atm
18:29:02 <Eddi|zuHause> well, the idea is to have the edits not lost if you run the generation again
18:29:09 <V453000> that's the perfect world yes Eddi but then you can spend a lot of time on details to perfectionalize the generator
18:29:30 <V453000> again, in a perfectly full-scale generated thing yes
18:29:34 <V453000> and I agree it's a nice thing
18:29:44 <Eddi|zuHause> like in CETS i have a way to include hand-written switches from a separate file
18:30:32 <Eddi|zuHause> like, if the generic articulation callback doesn't give the right result, i have a file with a custom one, and that gets used instead
18:31:14 <V453000> well of course my setup isn't nearly as perfect
18:32:42 <V453000> it's just a different approach :P
18:42:30 <pnda> I don't really understand how to use a Button in a Window. Can anyone give some examples/help?
18:43:11 <Eddi|zuHause> look for an existing window with a button?
18:43:25 <pnda> I did but implementing what I saw there crashed the game
18:43:37 <Eddi|zuHause> maybe tell us more what you did?
18:43:59 <Eddi|zuHause> especially, what you did, and what you think you did.
18:45:08 <pnda> NWidget(WWT_PUSHTXTBTN, COLOUR_GREY) is what I had. Thought it would add a Button. Also didn't see the function that gets executed when pressing from the windows I looked at.
18:46:34 <Eddi|zuHause> i imagine there's a constructor somewhere that does things like specify which text is displayed, and which function is called
18:50:02 <Eddi|zuHause> pnda: the examples of WWT_PUSHTXTBTN have another parameter to NWidget
18:50:22 <Eddi|zuHause> and if you follow that parameter, you should find things
18:50:37 <pnda> Which window did you look at?
18:51:41 <Eddi|zuHause> none, just typed "grep WWT_PUSHTXTBTN src/*"
18:56:30 <pnda> Ah so I can just have a enum for widgets in my header file and then reference it from OnClick and in the WWT_PUSHTXTBTN?
19:35:56 <Samu> round 12 will be toyland
19:36:10 <Samu> who can provide the openttd.cfg?
19:36:15 <Samu> so that it's not always me
19:39:51 * andythenorth should read back
19:40:06 <andythenorth> automate everything!
19:41:25 <andythenorth> V453000: option 1 vs 2 is potato / potato
19:42:21 <andythenorth> V453000: make it realistic!
19:42:27 <andythenorth> I find you a RL picture
19:43:17 * Artea is curious about peter's opinion about Brutal DooM
19:49:55 <DorpsGek_II> [OpenTTD/OpenTTD] nielsmh commented on pull request #7546: Fix #6507: Don't try to load invalid depots from older savegames https://git.io/fjGB7
19:51:57 <DorpsGek_II> [OpenTTD/OpenTTD] LordAro commented on pull request #7546: Fix #6507: Don't try to load invalid depots from older savegames https://git.io/fjGBN
19:55:33 <DorpsGek_II> [OpenTTD/OpenTTD] PeterN commented on pull request #7546: Fix #6507: Don't try to load invalid depots from older savegames https://git.io/fjGBh
19:57:00 <DorpsGek_II> [OpenTTD/OpenTTD] PeterN approved pull request #7542: Fix #7255: Prevent crashlog corruption by only printing the 32 most recent news messages https://git.io/fjGRv
19:57:34 <peter1138> Artea, been busy... playing it with NJDoom2
19:58:51 *** Supercheese has joined #openttd
19:59:41 <Artea> I used to play in Zandronium
20:00:43 <peter1138> It's an ancient WAD that I used to play back in the day.
20:01:09 <peter1138> Got Hell Revealed II but that's way too hard, even without Brutal Doom.
20:02:22 <Artea> I used to play HR II in ZDaemon
20:03:42 <andythenorth> V453000: just do realism
20:03:50 <V453000> realizm is already implemented, that's simple
20:03:51 <peter1138> Never got very far with Evilution and the Plutonia stuff.
20:03:56 <V453000> alternating is just tiny bit more code
20:04:10 <andythenorth> I always random if 2 equal choices :P
20:07:04 <peter1138> That doesn't look fun :p
20:08:10 <pnda> Do I have to make a comment describing every function even if it's a function used before in a window? e.g. DrawWidet(), OnClick()
20:08:52 <V453000> andythenorth: random is of course another option but in this case I rather wouldn't do that
20:09:01 <V453000> not to mention that it's handled by a rather long series of switches
20:12:12 <Artea> and so awesome having Lufia Song in DooM
20:13:07 <Eddi|zuHause> ... it would probably take me hours to go through that slaughterfest thing
20:15:20 <Artea> takes alot of time to kill them all
20:18:47 <Wolf01> So, 7 lanes, one-way/no-entry bits for every lane, point-to-point exit or point-to-multipoint (and reverse)?
20:20:17 <Wolf01> For example, 3 entry points with 4 exits
20:22:58 <Wolf01> Access ramps too or it's out of scope?
20:24:00 <peter1138> Whatever I think of, Eddi|zuHause comes along and comes up with something way more flexible which just needs about 32 bytes per tile or something.
20:24:54 <nielsm> which could indicate that the problem is either in the timing or in the sleeping
20:27:51 <pnda> So if I remove the position of a string somewhere and reuse it somewhere else, so from one window to another. Should I rename the string in every language to fit the new name or should I leave it as is (which could confuse some)?
20:30:54 <nielsm> how much movement is it?
20:31:21 <andythenorth> Eddi|zuHause came up with many problems for NRT :)
20:31:28 <andythenorth> but 2 types per tile was 'enough' :)
20:32:04 <pnda> STR_ABOUT_MENU_SCREENSHOT to idk, STR_SCREENSHOT_SCREENSHOT
20:33:06 <nielsm> if you're moving an option out of a menu you should definitely rename the string and physically move it somewhere else in english.txt
20:33:20 <pnda> Ok, only in english.txt?
20:33:25 <nielsm> since the menus often implicitly use series of strings
20:33:40 <Eddi|zuHause> pnda: generally, you only change the english.txt file
20:33:43 <nielsm> well either delete or rename+move it in the other languages too
20:34:40 <peter1138> Well anyway, we don't have 32 free bits.
20:35:00 <Eddi|zuHause> peter1138: clearly, we need a more flexible map system :p
20:35:48 <andythenorth> this is only worth doing if it's fun
20:36:45 <milek7> 38fps still seems too slow with these timings
20:38:44 <pnda> Will I have to edit strings.h or is that auto generated?
20:39:54 <andythenorth> 38fps on any decent mac is frigging slow
20:40:20 <andythenorth> I can push through 2000fps easy
20:40:31 <andythenorth> different OS though
20:40:58 <pnda> I'm always at 40fps, Fast Forward sometimes over 10000
20:43:20 <nielsm> milek7 yeah it's way too slow but at least it proves that it should be capable of outputting more frames per second than it does in non-ffwd
20:48:53 *** Supercheese has joined #openttd
20:53:16 <andythenorth> I can't do it now, but I can upgrade an external boot drive to 10.14 and test
20:54:47 *** Wormnest has joined #openttd
20:55:22 <pnda> I can't see how to change the font colour for a NWidget(WWT_PUSHTXTBTN). Does anyone know?
20:56:05 <nielsm> tried putting colour codes in the string in english.txt?
20:57:39 <pnda> Can I add a string myself right now for english.txt? I know other files have to be done through the webtranslator, but this is not translating
20:58:28 <nielsm> yes just add new strings to english.txt when necessary
21:06:29 <pnda> Where are the strings for the help dropdownlist defined? I can't find them
21:06:57 <nielsm> probably right next to STR_ABOUT_MENU_SCREENSHOT
21:07:45 <pnda> Using search all files I can only find that string inside of the language txt files
21:07:59 <nielsm> oh you mean where in the code the menu is generated?
21:08:33 <pnda> toolbar_gui.cpp:185 is the general function that gets used
21:08:52 <nielsm> PopupMainToolbMenu(w, WID_TN_HELP, STR_ABOUT_MENU_LAND_BLOCK_INFO, _settings_client.gui.newgrf_developer_tools ? 13 : 10);
21:09:16 <nielsm> the first string id in the menu, and then the count of consecutive string ids to use for the menu
21:09:40 <nielsm> which is why you need to move the original string away if you're removing the item from the menu
21:09:43 <pnda> Because STR_ABOUT_MENU_LAND_BLOCK_INFO gets +1 for each item in the menu
21:25:05 <nielsm> lets them stretch to fit width
21:27:23 <nielsm> (and it's important to put it on everything, since some translations may have unexpectedly long or short strings for some things :)
21:27:35 <nielsm> (unless of course the thing should not stretch)
21:58:58 <Samu> need a openttd cfg for round 12
21:59:18 *** Wormnest has joined #openttd
22:01:52 * peter1138 should... something?
22:06:10 <V453000> getbits(extra_callback_info1, 8, 8) this is what does layer drawing stuff?
22:06:13 <andythenorth> and await bug reports
22:06:30 <andythenorth> sunglasses emoticon? o_O
22:06:40 <andythenorth> that's layers bollocks yes
22:06:49 <andythenorth> I draw pantographs separate layer
22:07:20 <V453000> I had some completely batshit thing there that frosch showed me, but I don't even pretend to know what it was supposed to do back in the day
22:07:47 <V453000> probably for some incredibly hideous plan I Had
22:09:11 <V453000> also andythenorth [22:06] <@Happpy> Hi v no pax ships what the hell
22:12:17 <V453000> unsinkable sam has no passengers ships?
22:12:26 <V453000> anyway, it keeps drawing a single layer for me :(
22:13:09 <glx> nielsm: seems macos and allegro both use gettimeofday to get ticks
22:13:41 <andythenorth> V453000: there's a thing with register 101 iirc
22:13:45 <andythenorth> has frosch gone?
22:13:58 <andythenorth> if register 101 is used elsewhere, layers fail
22:14:01 * andythenorth would have to check that
22:14:19 <nielsm> glx yeah, I suspect it might lack precision for whatever reason
22:14:33 <V453000> what do you mean register 101
22:16:48 <V453000> well I was using item ID 101 but no that didn't help :)
22:17:25 <andythenorth> I am trying to find the docs
22:17:47 <glx> and man page for gettimeofday says it's obsolete
22:18:20 <V453000> well I do vaguely remember I was trying to make an experiment with NUTS and layering earlier and it did not work for reasons I didn't discover ... the layering switch seems identical to what doesn't work for me today as well.
22:18:33 <andythenorth> ok so XXX_FLAG_SPRITE_STACK
22:18:48 <andythenorth> means using temp storage 0x100
22:19:22 <andythenorth> if anything else uses 0x100, sprite layers fail V453000
22:19:31 <andythenorth> took me frigging ages to debug that one night
22:19:42 <V453000> but what does any of thise mean
22:19:44 <andythenorth> it's documented though
22:19:52 <V453000> and where do I see 0x100 :D
22:19:53 <andythenorth> that enables sprite layers
22:20:04 <V453000> it's a flag in the item?
22:20:04 <andythenorth> paste your code?
22:21:31 <V453000> ooh found this in my old prototype misc_flags: bitmask(TRAIN_FLAG_SPRITE_STACK);
22:24:16 <V453000> misc_flags: bitmask(TRAIN_FLAG_SPRITE_STACK, TRAIN_FLAG_FLIP, TRAIN_FLAG_2CC);
22:24:22 <V453000> doesn't seem to work yet
22:35:32 <andythenorth> getbits(extra_callback_info1, 8, 8) is the var for count of layers
22:35:55 <andythenorth> so I use 3 layers there
22:36:26 <andythenorth> if it's layer 0 or 1 it keeps going up the graphics chain to another switch
22:36:38 <andythenorth> if it's layer 2, it switches to draw rear lights
22:36:59 <andythenorth> broke my brain making the pantograph stuff :|
22:39:48 <V453000> I pasted some bits from your thing
22:39:51 <V453000> not so easily I guess :)
22:42:08 <V453000> which looks nasty but does seem to connect a lot of the things I see around
22:43:23 <V453000> I was just missing the flag
22:43:39 <andythenorth> frosch's thing makes total sense
22:43:52 <V453000> yeah it makes the absolute definition of sense to me
22:44:12 <DorpsGek_II> [OpenTTD/OpenTTD] PeterN dismissed a review for pull request #7485: Add: Dropdown build menus from toolbar have icons https://git.io/fjGm6
22:44:15 <V453000> but it works :) can fully implement tomorrow
22:44:24 <andythenorth> counts up to 4, then stops
22:44:28 <andythenorth> and you haz 4 layers
22:44:50 <V453000> so if I were using 2 layers, I'd put <2 there instead
22:51:28 <V453000> I'll try tomorrow :) thing works with 4 now, got it commited, saved :) I'll try to make it work with 2 or 3 layers tomorrow :) thank you super much andy
22:51:32 <V453000> this stuff is bonkers wtf for me
23:03:48 *** Wormnest has joined #openttd
23:35:33 *** andythenorth has left #openttd
continue to next day ⏵