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

Powered by YARRSTE version: svn-trunk