IRC logs for #openttd on OFTC at 2016-09-12
            
00:30:27 *** Mazur has quit IRC
00:34:08 *** keoz has quit IRC
00:39:45 <Wolf01> 'night
00:39:48 *** Wolf01 has quit IRC
00:44:28 *** Mazur has joined #openttd
01:02:15 *** Mazur has quit IRC
01:15:54 *** glx has quit IRC
01:25:15 *** supermop__ has joined #openttd
01:28:39 *** sim-al2 is now known as Guest120
01:28:40 *** sim-al2 has joined #openttd
01:31:05 *** supermop has quit IRC
01:34:38 *** Guest120 has quit IRC
01:35:57 <Samu_> once i place a buoy on water, i have to move mouse cursor around for it to be drawn
01:37:32 *** supermop has joined #openttd
01:37:52 <Samu_> happens more often at zoom x2 and x4
01:43:39 *** supermop___ has joined #openttd
01:43:42 *** supermop__ has quit IRC
01:44:40 <Samu_> https://bugs.openttd.org/task/6508
01:44:53 <Samu_> why don't you fix bugs?
01:45:02 <Samu_> at least those minor ones
01:45:22 *** supermop__ has joined #openttd
01:47:20 *** supermop____ has joined #openttd
01:50:07 *** supermop has quit IRC
01:51:42 *** supermop___ has quit IRC
01:53:23 *** supermop__ has quit IRC
01:58:14 *** supermop has joined #openttd
01:58:53 *** Gja has quit IRC
02:00:35 *** supermop__ has joined #openttd
02:04:05 *** supermop____ has quit IRC
02:06:17 *** supermop has quit IRC
02:16:42 *** Samu_ has quit IRC
02:27:38 *** supermop has joined #openttd
02:32:17 *** supermop___ has joined #openttd
02:33:47 *** supermop__ has quit IRC
02:33:53 *** supermop__ has joined #openttd
02:38:45 *** supermop has quit IRC
02:40:20 *** supermop___ has quit IRC
02:42:55 *** HerzogDeXtEr1 has quit IRC
02:56:04 *** JezK has joined #openttd
03:00:00 *** Flygon_ has joined #openttd
03:06:20 *** Flygon has quit IRC
03:29:05 *** efess has quit IRC
03:30:12 *** JezK has quit IRC
03:38:08 *** JezK has joined #openttd
04:09:48 *** supermop has joined #openttd
04:13:19 *** Eddi|zuHause has joined #openttd
04:13:50 *** supermop___ has joined #openttd
04:16:12 *** supermop__ has quit IRC
04:19:52 *** supermop has quit IRC
04:22:59 *** JezK has quit IRC
04:31:01 *** JezK has joined #openttd
04:33:51 *** supermop has joined #openttd
04:35:04 *** supermop_ has quit IRC
04:40:10 *** supermop___ has quit IRC
04:56:03 *** supermop_ has joined #openttd
05:02:14 *** supermop has quit IRC
05:23:54 *** Snail has quit IRC
05:53:07 *** Mazur has joined #openttd
06:24:21 *** supermop has joined #openttd
06:30:12 *** supermop_ has quit IRC
06:50:42 *** keoz has joined #openttd
08:00:34 *** Biolunar has joined #openttd
08:22:39 *** Flygon_ has quit IRC
08:22:41 *** keoz has quit IRC
08:22:54 *** Flygon has joined #openttd
09:06:46 *** supermop_ has joined #openttd
09:11:12 <argoneus> good morning train friends
09:12:57 *** supermop has quit IRC
09:31:44 *** Progman has joined #openttd
09:53:57 *** keoz has joined #openttd
10:01:11 *** JezK has quit IRC
10:02:40 *** Wolf01 has joined #openttd
10:02:56 <Wolf01> o/
10:15:14 *** Progman has quit IRC
10:22:39 *** sla_ro|master has joined #openttd
10:42:15 *** Supercheese has quit IRC
11:22:40 *** FLHerne has joined #openttd
11:27:16 *** supermop has joined #openttd
11:33:45 *** supermop_ has quit IRC
11:39:21 *** supermop_ has joined #openttd
11:45:47 *** supermop has quit IRC
12:15:27 *** Samu has joined #openttd
12:47:04 <Samu> I still don't know how when to use /* FALL THROUGH */ or break;
12:49:28 <Wolf01> Is that a question? If you don't know the implications you really should give a look at the manual
12:54:33 <Samu> sorry
12:55:27 <Samu> im looking at my old code of last year
12:55:47 <Samu> https://paste.openttdcoop.org/pzbhgrhma - trying to understand why did i use fall through and not break
12:56:32 <Samu> lines 23-26 was added
12:56:45 <Samu> original trunk only has line 22
12:57:58 <Samu> oh, line 27 was also added, the blank line
12:59:15 <Samu> if the station is dock
12:59:36 <Samu> it does if (IsDockTile(tile) && !HasTileWaterGround(tile)) {                             if (c != NULL) c->infrastructure.station += 2;                         }
12:59:46 <Samu> if (GetWaterClass(tile) == WATER_CLASS_CANAL) { if (c != NULL) c->infrastructure.water++; } break;
12:59:52 <Samu> and that too?
13:04:16 <Samu> makes sense then
13:04:31 <Samu> fall through is needed
13:05:11 <Samu> it looks odd that it's the only fall through in this part of the code
13:09:46 <Samu> if it is the other dock tile, the change to infrastructure.station is 0
13:09:57 <Samu> but will still look if the water is canal
13:10:13 <Samu> just as I intended
13:10:21 <Samu> i see, fall through makes sense then
13:10:39 <Samu> ty Wolf01
13:22:43 *** Snail has joined #openttd
13:28:19 <Samu> i need to make a list of companies
13:29:30 <Samu> in hex, in dec, and in bin
13:29:38 <Samu> so that i dont get confused
13:37:02 *** Snail has quit IRC
13:37:40 <Samu> there are 19 entities
13:37:56 <Samu> 1-15 real companies
13:38:08 <Samu> 16 town, 17 none, 18 water, 19, deity
13:38:16 <Samu> 16 town, 17 none, 18 water, 19 deity
13:39:17 <Samu> i only got 4 bits to store owners of stuff in the tile
13:39:51 <Samu> 17 and 18 have to be stored in some manner
13:40:07 <Samu> but if 19 is also needed to be stored... then i got a huge problem
14:00:53 *** FLHerne has quit IRC
14:01:02 *** FLHerne has joined #openttd
14:07:16 <Samu> what can be built on water tiles of waterclass canal
14:08:35 <Samu> in other words, what tiles have waterclass
14:09:14 *** sla_ro|master has quit IRC
14:11:31 <Samu> 5 station, 6 water, 8 industry, A object
14:17:20 *** Gja has joined #openttd
14:18:29 *** Gja has quit IRC
14:39:31 *** heffer has quit IRC
14:40:32 *** heffer has joined #openttd
14:52:23 *** supermop has joined #openttd
14:58:37 *** supermop_ has quit IRC
15:02:41 *** Gja has joined #openttd
15:08:34 *** Flygon has quit IRC
15:08:59 *** Flygon has joined #openttd
15:10:51 *** sla_ro|master has joined #openttd
15:13:29 *** Flygon has quit IRC
15:30:31 *** Flygon has joined #openttd
16:05:19 <supermop> yo
16:09:39 *** TheMask96 has quit IRC
16:14:17 *** TheMask96 has joined #openttd
16:29:53 <Samu> what can game scripts build?
16:30:10 <Samu> can they build canals?
16:30:19 <Samu> how do I find out?
16:32:44 *** Mazur has quit IRC
16:34:36 <Samu> https://nogo.openttd.org/api/ think i found it, gonna investigate
16:35:47 <supermop> i think gs can do whatever an ai can?
16:38:24 <Samu> real question is... do they build as OWNER_DEITY?
16:38:37 <Samu> or do they switch into someones company and build for them?
16:39:12 <Samu> my only concern is canals
16:39:44 <Samu> if canals are built as OWNER_DEITY, I'm ruined
16:47:21 <Samu> alright, so they got to switch into a company to build as them
16:47:36 <Samu> what about towns?
16:50:10 <Samu> does anyone know of a GS that builds water stuff?
16:50:31 <Samu> i need a way to verify something I'm doing
16:55:13 <Samu> there is an assert(o != OWNER_WATER); on MakeCanal
16:55:36 <Samu> that means there's still 18 owners to deal with
16:56:03 *** ricus has quit IRC
16:56:36 <Samu> of which 15 are real companies
16:56:40 <Samu> 3 remain
16:57:37 <Samu> OWNER_TOWN, OWNER_NONE, OWNER_DEITY
17:04:16 <Samu> i dont know who to ask
17:04:54 <Samu> who's a game script expert? how does a gs build canals? what companies are valid to build canals as?
17:08:52 *** Alberth has joined #openttd
17:08:52 *** ChanServ sets mode: +o Alberth
17:09:01 <Alberth> hi hi
17:09:10 <Samu> hi Alberth can you help?
17:09:27 <Alberth> I quite doubt it :)
17:09:40 <Samu> you made game scripts
17:09:53 <Alberth> true
17:09:54 <Samu> which companies can build canals as a GS?
17:10:37 <Alberth> don't know
17:10:41 <Alberth> but my guess is all
17:11:15 <Samu> does that include OWNER_TOWN? OWNER_NONE? OWNER_DEITY?
17:11:46 *** ricus has joined #openttd
17:13:11 <Alberth> https://nogo.openttd.org/api/trunk/classGSMarine.html#cd73f694892f7d73091b20c30098e148 <-- it says a valid comapny
17:13:31 <Alberth> and town and deity is not a company
17:13:56 <Samu> oh, nice to hear that
17:14:14 <Alberth> but just try it :)
17:14:40 <Alberth> I never tried doing anything with companies with GS, so no experience here
17:15:33 <Samu> i'm not creating a GS, I was worried that they could build canals as towns or as none or as deity
17:15:54 <Samu> i got 4 bits to store 16 owners
17:16:26 <Samu> but there's 19 entities
17:16:38 <Alberth> did you check the conditions of the command? that should also state what is allowed, or at least in the code :)
17:17:07 <Samu> code has an assert for OWNER_WATER only
17:17:41 <Samu> that's still 18 to store
17:17:44 <Alberth> does a canal even have an owner?
17:17:59 <Samu> yes
17:18:08 <Alberth> ie if you build one, and you query it, does it say it's yours?
17:18:16 <Samu> yes it says so
17:18:22 <Alberth> spiffy
17:19:07 <Samu> deity is excluded if GS can't build them
17:19:14 <Samu> so I'm at 17
17:19:38 <Samu> towns themselves, can they build canals?
17:20:19 <Alberth> i doubt it
17:20:30 <Alberth> at least they never do anything with water
17:20:43 <Alberth> except building a bridge over it
17:22:21 <Alberth> could be fun, "oh we need more space, let's extend our land" :)
17:23:15 <_dp_> I bet only 16 owners are stored everywhere, not special ones
17:26:18 <Samu> i think roads can store 3 owners
17:26:58 <Samu> canals can store 1 owner, but i'm trying to store 2
17:28:28 <Samu> never really played with roads + trams + rails
17:28:48 <Samu> gonna try
17:32:07 <Samu> road rail tram crossing, yikes, scary
17:35:31 <Samu> m3 bits 7..4: owner of road type 1 (tram); OWNER_NONE (10) is stored as OWNER_TOWN (0F)
17:36:17 <Samu> wwell
17:36:28 <Samu> that's what i had in mind
17:36:54 <Samu> OWNER_NONE stored as OWNER_TOWN for canal
17:50:27 <Samu> list of stuff that will store 2
17:51:00 <Samu> dock (on water part)
17:51:21 <Samu> buoy - i'm not sure yet
17:51:31 <Samu> ship depot
17:52:25 <Samu> oilrig (station)
17:53:20 <Samu> lock - i'm uncertain
17:53:41 <Samu> canal
17:54:13 <Samu> industry tile type
17:54:21 <Samu> objects
17:54:41 <Samu> objects worry me a lot too, but... hopefully it's not gonna be hard
17:55:02 <Samu> it's too abstract, i have no real idea what's going on there
18:06:01 <Alberth> think "eye-candy"
18:15:14 <Samu> locks will look different on the minimap
18:15:18 <Samu> i bet
18:17:20 <Samu> MakeLock will be skipped, it will call MakeLockTile directly
18:30:50 *** Flygon_ has joined #openttd
18:37:45 *** Flygon has quit IRC
18:55:06 <Samu> Severity Code Description Project File Line Suppression State Error C2678 binary '&=': no operator found which takes a left-hand operand of type 'Owner' (or there is no acceptable conversion) (compiling source file ..\src\depot.cpp) openttd d:\openttd\trunk\src\core\bitmath_func.hpp 62
18:55:13 <Samu> what is this?
18:55:28 <Samu> 276 errors
18:56:43 <Alberth> Trying to perform & on an owner?
18:57:28 <Samu> i copy pasted adf88 code, doesn't like it
18:57:50 <Samu> https://www.tt-forums.net/viewtopic.php?p=1143683#p1143683
18:58:32 <Samu> i got these bits free
18:58:39 <Samu> m6 bit 7 and 6, then 1 and 0
18:58:53 <Samu> but got to split
18:59:15 <Samu> what can i do
19:00:26 <Samu> let me copy paste my code
19:00:52 <Samu> https://paste.openttdcoop.org/pghr7xyan
19:00:55 *** Mazur has joined #openttd
19:13:19 *** glx has joined #openttd
19:13:19 *** ChanServ sets mode: +v glx
19:22:29 <Samu> how do i make a byte 4 bits? or whatever... i dunno what to do
19:24:30 <Samu> uint4
19:24:35 <Samu> does not exist, what can i do
19:24:55 <Alberth> just also keep the other 4
19:25:11 <Alberth> simply don't look at them
19:25:13 *** Flygon has joined #openttd
19:25:39 <Alberth> or don't tore them, or whatever you do with the byte
19:29:18 <Alberth> *store
19:31:06 *** Flygon_ has quit IRC
19:41:30 <Samu> damn asserts, i hate them
19:46:56 <Samu> GetCanalOwner returned 192 Owner
19:46:59 <Samu> this is bad
19:49:00 <glx> asserts are your friends
19:49:20 <glx> they tell you something wrong was avoided
20:09:08 *** andythenorth has joined #openttd
20:09:13 <Wolf01> o/
20:09:18 <Samu> interesting issue with locks
20:09:37 <andythenorth> o/
20:09:51 <Samu> when they are placed, they don't build the canal under the upper and lower parts
20:10:10 <Samu> when they are removed, the MakeWaterKeepingClass builds them
20:11:13 <Samu> so much fakeness going on with locks
20:13:07 *** frosch123 has joined #openttd
20:14:04 <andythenorth> quak
20:14:38 <andythenorth> locks are dreadful Samu ;)
20:15:31 <Samu> prices are simulated on placement
20:15:47 <Samu> canals are built for free when removing lock
20:16:18 <frosch123> hoi
20:16:23 <Alberth> hola
20:16:59 *** HerzogDeXtEr has joined #openttd
20:18:16 <Samu> lock functions need a rework
20:18:31 <Samu> i'd even say all of them
20:18:46 <Samu> let's see what i can do
20:19:29 <Samu> for now, i'm skipping locks
20:19:36 <Samu> gonna work on ship depot
20:22:43 * andythenorth can’t do anything until buses / trams are sorted :P
20:22:49 <andythenorth> current latest obsession
20:23:26 *** aard has joined #openttd
20:24:18 <V453000> :)
20:25:18 <Wolf01> Quak
20:25:25 <V453000> yo
20:25:29 <V453000> biters ded yet?
20:25:48 <Wolf01> Biters die really fast with a swarm of destroyers
20:26:03 <V453000> yep, once you have the capability to produce a fuckload of them, they do
20:26:14 <V453000> which is good
20:26:50 <Wolf01> Also tanks are the most useless thing right now
20:27:38 <Wolf01> Maybe with the new grid for equip... but I don't want to mod right now
20:28:08 <Wolf01> Or I'll end up with ion cannons again
20:29:52 <V453000> XD
20:29:53 <frosch123> is there already a moo2-combat-style mod? :p
20:31:20 <andythenorth> how big are the buses in factorio? o_O
20:31:59 <frosch123> they are 50% longer in vertical direction or so
20:35:02 <frosch123> https://forums.factorio.com/viewtopic.php?f=16&t=22972 <- see, people are already complaining about size relations
20:35:07 *** umgeher_ has joined #openttd
20:36:04 <Wolf01> But that's right, the car inventory is really too big
20:36:44 <andythenorth> how many pax? o_O
20:36:52 <Wolf01> 1?
20:37:33 <Wolf01> It would be really cool with 2 pax, one which drives and the other one obliterates the biters in multiplayer
20:37:52 <andythenorth> hmm
20:38:02 <andythenorth> no answers there for my road hog problem
20:38:04 <Wolf01> So the driver can focus on not crashing on the rocks
20:38:12 <andythenorth> I have no solution :P
20:38:19 <andythenorth> should I abandon Road Hog?
20:38:25 *** umgeher has quit IRC
20:38:26 <andythenorth> the ‘running away’ solution to problems
20:39:05 <Wolf01> If is finished just keep it bug-free
20:39:21 <andythenorth> not finished :P
20:43:28 *** aard_ has joined #openttd
20:46:07 *** Progman has joined #openttd
20:48:16 <Wolf01> Also... destroyer turret mod, feed destroyers to a turret and let they wipe out any enemy on the area for 2 minutes
20:49:12 <Wolf01> And minefield turrets too, I don't want to replace all the mines by hand :P
20:49:32 <Wolf01> V453000, are these possible with mods?
20:50:16 *** aard has quit IRC
20:51:45 <V453000> it's not like construction robots don't replace them :P
20:52:03 <Wolf01> Too much outside the building area
20:52:12 <V453000> destroyer turrets exist, see klonans mod
20:52:23 <V453000> forgot the name but something with robot unit army or something
20:52:31 <Wolf01> :D
20:54:48 <Wolf01> Also I'm reading a complaint about the play style imposed by the game: walling in
20:56:28 <Wolf01> I think you should do something in future to be able to not always wall in everything of your factory, maybe just the core and the outpost and not every single piece of rail around the map
20:58:24 <V453000> yeah that is easy to say
20:59:02 <Alberth> make them smart, tunneling under the wall, and dynamiting the walls :p
20:59:07 <V453000> there are many such complaints
20:59:13 <V453000> but many people who defend it, too
20:59:35 <V453000> tbh, I think the previous mechanic which motivated you to leave random buildings in a pattern to prevent spawning is outright wrong
20:59:39 <Wolf01> Yes, nobody said that if you play aggressively you shouldn't need to wall in
20:59:45 <Wolf01> I don't mean to remove walls
20:59:51 <V453000> I believe the current method is good, but there should be special worms which are able to bypass defenses
21:00:12 <V453000> basically a walking/tunneling spawner
21:00:17 <V453000> which isn't impossible to happen
21:00:21 <V453000> spoilers :>
21:00:29 <Wolf01> And what about if I would like to play without any wall?
21:00:47 <Wolf01> With a real sandbox I should be able to do it
21:02:38 <V453000> well the worms would be very weak to direct combat
21:02:55 <V453000> they just make sure that you need to have safety measures in all of your base
21:02:57 <V453000> not just wall
21:03:16 <V453000> note, it's my concept, not official at all :) random thoughts therefore
21:05:16 <Wolf01> It's like playing Starcraft with huminz and wall in with supply depots
21:05:38 <Wolf01> Blizzy reduced the minerals patches to force you to move your lazy ass
21:06:08 <Wolf01> Also, if you wall in, you don't have enough minerals to build marines
21:19:13 *** aard_ has quit IRC
21:22:13 <Samu> help, how do i read 4 bits, split into 2 part?
21:22:18 <Samu> i tried this Owner o = (Owner)(GB(_me[t].m6, 0, 2) | GB(_me[t].m6, 6, 2));
21:22:59 <Alberth> merging the bits on top of each other?
21:23:07 <Samu> i want to read bits on position 7610 like they're 3210
21:23:51 <Alberth> so shift the high bits by 2 bits
21:24:14 <Alberth> GB always shifts them down so the lowest is at bit 0
21:25:41 <Samu> how to shift?
21:26:17 <Samu> GB(_me[t].m6, 6, 2) and shift 2 bits to the right?
21:29:18 <Samu> Owner o = (Owner)(GB(_me[t].m6, 0, 2) | GB(_me[t].m6, 6, 2) << 2);is this it?
21:30:16 <Samu> let me test
21:31:03 <Alberth> it needs parentheses around the <<
21:31:32 <Alberth> (and << shifts to the left :) )
21:31:39 <supermop> andythenorth: understated response in firs thread
21:32:14 <supermop> you should upload all of the firs PNGs as 32bpp but otherwise unchanged
21:33:18 <Alberth> I considered answering in that direction, but the OP clearly has no clue how 32bpp and 8bpp are related
21:33:57 *** sla_ro|master has quit IRC
21:33:59 <Alberth> so he has a different meaning attached to "32bpp"
21:34:00 <Samu> testing Owner o = (Owner)(GB(_me[t].m6, 0, 2) | (GB(_me[t].m6, 6, 2) >> 2));
21:34:11 <Alberth> Samu: << is good
21:34:27 <Alberth> GB gives an answer in bits 0 and 1
21:35:15 <Alberth> it always shifts the result down to the low bits, so you need to shift it up again (down=right, up=left)
21:40:10 <Samu> Owner o = (Owner)(GB(_me[t].m6, 0, 2) | (GB(_me[t].m6, 6, 2) << 2));
21:40:23 <Samu> nice, nice thx
21:40:32 <Samu> i got company #5
21:40:48 <Samu> built canals, built a ship depot over it
21:40:52 <Samu> removed it
21:41:04 <Samu> and got the canals back to company 5
21:41:31 <Alberth> modern c++ does static_cast, as in static_cast<Owner>(GB(_me[t].m6, 0, 2) | (GB(_me[t].m6, 6, 2) << 2)); but yours works too
21:42:40 <Samu> got to try different companies, see if it does what i want
21:42:58 <Alberth> #5 is a bad test, as it 0101 so even if you swap the bits, you won't see it
21:43:40 <Samu> think i screwed up
21:43:57 <Samu> Owner: someone = that is bad, right?
21:44:37 <Alberth> not sure what you're trying to do there
21:44:37 *** Mazur has quit IRC
21:44:54 <Alberth> make a variable "someone" of type "Owner" ?
21:45:09 <Alberth> thats Owner someone = ...
21:45:18 <Alberth> just like int i = 4
21:45:36 <Alberth> type, variablename = value
21:46:31 <andythenorth> supermop: no over-explanation ;)
21:47:18 <Samu> lol, i mean when querying the tile it says Owner: someone
21:47:24 <Samu> someone is bad
21:47:28 <Alberth> switching to 32bpp is also a lot of effort :p
21:48:28 <Alberth> :o never seen that result, so yeah, it may be a wrong owner value indeed :)
21:49:03 <frosch123> Wolf01: have you tried using a deconstruction planner on a biter nest?
21:49:04 <Samu> https://paste.openttdcoop.org/p4zzsjzk5 - changed a bit of the code, now it looks like that
21:49:12 <Wolf01> No
21:49:50 <frosch123> me neither, but would be funny if it works :p
21:53:59 *** FLHerne has quit IRC
21:54:10 *** FLHerne has joined #openttd
21:54:56 *** Supercheese has joined #openttd
21:58:53 *** andythenorth has quit IRC
22:00:07 *** frosch123 has quit IRC
22:19:20 *** gelignite has joined #openttd
22:22:16 *** andythenorth has joined #openttd
22:30:05 *** Supercheese has quit IRC
22:33:58 *** Alberth has left #openttd
22:44:59 *** gelignite has quit IRC
23:11:15 *** andythenorth has left #openttd
23:45:18 <Eddi|zuHause> "deconstruction planner" sounds like a euphemism