IRC logs for #openttd on OFTC at 2016-05-16
            
00:07:18 *** FLHerne has quit IRC
00:07:37 *** FLHerne has joined #openttd
00:16:19 *** supermop has joined #openttd
00:21:35 <Samu> there are 3 types of GS's
00:22:16 <Samu> the (none) GS, the configured GS but not started, the configured GS but started
00:22:28 <Samu> i need a table... brb
00:23:04 <Samu> then there's the GS of the current game, and the GS of the save
00:36:11 <Samu> maybe 4 ways :(
00:50:00 *** Wormnest has quit IRC
00:58:26 *** Progman has quit IRC
01:07:08 *** keoz has quit IRC
01:15:55 *** Gja has quit IRC
01:30:33 <Samu> I give up
01:31:42 <Samu> couldn't come to any conclusion
02:07:37 *** JGR_ has joined #openttd
02:10:37 *** JGR has quit IRC
02:10:37 *** JGR_ is now known as JGR
02:24:05 *** Matombo has quit IRC
02:29:50 *** Quatroking has quit IRC
02:31:54 *** JezK has joined #openttd
02:33:40 *** Samu has quit IRC
02:47:39 *** Snail has joined #openttd
03:00:18 *** FLHerne has quit IRC
03:02:17 *** Wolf01 has quit IRC
03:09:01 *** Cybertinus has quit IRC
03:16:54 *** Cybertinus has joined #openttd
03:35:30 *** Kurimus_ has joined #openttd
03:40:56 *** Kurimus has quit IRC
04:18:26 *** chomwitt has quit IRC
04:59:56 *** glx has quit IRC
05:20:06 *** sim-al2 is now known as Guest987
05:20:06 *** [1]sim-al2 has joined #openttd
05:20:06 *** [1]sim-al2 is now known as sim-al2
05:24:45 *** Guest987 has quit IRC
05:57:12 *** supermop has quit IRC
06:06:10 *** ToneKnee_ has joined #openttd
06:08:12 *** ToneKnee has quit IRC
06:43:01 *** Supercheese has joined #openttd
06:44:14 *** Snail has quit IRC
07:24:20 *** Xal has quit IRC
08:07:27 *** sim-al2 has quit IRC
08:08:08 *** sim-al2 has joined #openttd
08:29:36 *** Progman has joined #openttd
08:31:30 *** Kurimus_ has quit IRC
08:50:08 *** Arveen has joined #openttd
09:12:37 *** efess has quit IRC
09:27:25 *** Kurimus_ has joined #openttd
09:39:09 *** sim-al2 has quit IRC
10:16:25 *** Myhorta has joined #openttd
10:23:51 *** JezK has quit IRC
10:59:27 *** Wormnest has joined #openttd
11:04:45 *** efess has joined #openttd
11:04:55 *** Myhorta has quit IRC
11:43:15 *** Cybertinus has quit IRC
11:44:42 *** Cybertinus has joined #openttd
11:52:50 *** frosch123 has joined #openttd
12:21:56 *** Hiddenfunstuff has joined #openttd
12:27:25 <argoneus> good morning train friends
12:27:55 <Hiddenfunstuff> day
12:28:38 *** Samu has joined #openttd
12:42:12 *** MonkeyDrone has quit IRC
12:45:58 <Samu> english question: widest refers to the largest width, ??? refers to the largest height. What is the word?
12:46:14 <Samu> heightest?, tallest?
12:46:29 <Samu> highest
12:58:38 <peter1138> highest
13:02:03 *** SpBot has quit IRC
13:10:07 <Samu> thank you
13:27:21 <Samu> 'void DrawSprite(SpriteID,PaletteID,int,int,const SubSprite *,ZoomLevel)': cannot convert argument 5 from 'int' to 'const SubSprite *' openttd D:\OpenTTD\trunk\src\ai\ai_gui.cpp 131
13:27:53 <Samu> what's wrong?
13:28:26 <Samu> it works somewhere else, but not here... t.t
13:29:45 <Samu> if (text == STR_AI_CONFIG_RANDOM_AI) DrawSprite(SPR_AICONFIG_RANDOM, PAL_NONE, r.left + WD_MATRIX_LEFT, r.left + WD_MATRIX_LEFT + GetSpriteSize(SPR_AICONFIG_RANDOM).width, y + rai_y_offset);
13:36:00 <peter1138> What?
13:36:24 <peter1138> It tells you what's wrong.
13:36:58 *** Myhorta has joined #openttd
13:37:47 *** Alberth has joined #openttd
13:37:47 *** ChanServ sets mode: +o Alberth
13:38:32 <Alberth> moin
13:40:24 <peter1138> hi
13:40:44 <Samu> it does not like the value of y
13:42:18 <peter1138> It does not say that.
13:48:07 <Samu> https://paste.openttdcoop.org/pcvfymzoe - line 77
13:49:56 *** marlinc has joined #openttd
13:50:15 <marlinc> Hey, is there a reason why the download speed of a map is limited to about 5-6 mbit/s?
13:50:27 <marlinc> Or is it some technical limit?
13:51:17 <Eddi|zuHause> that should be your network's limit somewhere on the way
13:51:47 *** Wolf01 has joined #openttd
13:51:50 <Wolf01> o/
13:54:18 <marlinc> Well, that's 1000 Mbit as its setting next to mne
13:54:19 <marlinc> Me
13:54:34 <Samu> compression level
13:55:27 <Samu> see if it helps https://wiki.openttd.org/Savegame_format
13:59:27 <Samu> i made some research about this a few weeks ago, let me find it
14:00:24 <peter1138> Samu, line 77 is the same line you pasted above.
14:00:53 <Samu> :( i don't know what to do there
14:00:53 <marlinc> Could it be related to CPU usage?
14:00:55 <peter1138> What part of "'void DrawSprite(SpriteID,PaletteID,int,int,const SubSprite *,ZoomLevel)': cannot convert argument 5 from 'int' to 'const SubSprite *'" means "it does not like the value of y" to you?
14:01:01 <marlinc> Its at about 36% at the moment with two players
14:01:48 <Eddi|zuHause> marlinc: could be CPU, or disk speed, or spam software, or whatever
14:02:15 <marlinc> Well its not the disk.. its sitting on my ZFS array..
14:02:39 <peter1138> Bah, wish this cloud would psis off
14:05:26 <Samu> marlinc: it's a research comparing several speeds of the different savegame formats https://onedrive.live.com/redir?resid=23B29F3DE45F6F1F!1271&authkey=!AAIUn3D6oXYFDM4&ithint=file%2cxlsx
14:05:40 <Samu> but for my cpu only :o
14:06:01 <marlinc> Lol, onedrive
14:06:08 <Samu> it compresses the map on the fly when sending it to another client
14:06:52 <marlinc> Thanks Samu, I'll take a look :)
14:07:39 <Samu> oh, and the map size used for that sample was 4096x4096 :p
14:08:18 <peter1138> Samu, the error is telling you the arguments you have supplied are wrong, and it tells you what it is expecting.
14:14:28 *** Quatroking has joined #openttd
14:29:08 *** Progman has quit IRC
14:32:01 *** Supercheese has quit IRC
14:32:35 *** Supercheese has joined #openttd
14:33:01 *** SpBot has joined #openttd
14:36:07 *** Snail has joined #openttd
14:51:33 *** Snail has quit IRC
15:03:48 *** tokai|noir has joined #openttd
15:03:48 *** ChanServ sets mode: +v tokai|noir
15:09:49 *** Arveen has quit IRC
15:10:44 *** tokai has quit IRC
15:12:38 *** sim-al2 has joined #openttd
15:30:54 *** MonkeyDrone has joined #openttd
15:52:45 *** supermop has joined #openttd
16:00:26 <supermop> yo
16:05:11 <Alberth> hi hi
16:20:43 <supermop> hows it going Alberth ?
16:21:47 <supermop> got a kgs account yet?
16:26:49 <Alberth> too busy, as always, when having a day off :p
16:41:51 <supermop> i understand that
16:42:18 <supermop> i ended up using 6 hours of my sunday on a 'fun' thing that was really just work related
16:49:53 <Alberth> clearly, work poses sufficient good challenges :p
16:51:00 <supermop> the problem with working in a field like mine,is that you can never really stop thinking about it, but you can't charge clients for all that 'work' you did laying in bed at night
16:53:49 <Alberth> ah, I have that too, but don't get paid overtime either :p
16:55:21 <Samu> http://i.imgur.com/FUkxaTb.png - it is correctly identifying the scripts which can be used as random.
16:55:55 <Samu> but i wanted to draw the randomai sprite instead
16:56:00 <Samu> and it doesn't let me
17:09:10 <Samu> i hate it that I did the same on the other function and it works there, and on this one, it doesn't...
17:09:57 <Alberth> "doesn't work" gives no clues what it actually does
17:10:08 <Alberth> the compiler produced an error, right?
17:10:17 <Samu> yes
17:10:23 <Samu> https://paste.openttdcoop.org/pcvfymzoe - line 77
17:10:30 <Alberth> so the logical course of action would be to solve that error, or not?
17:12:08 <Samu> y isn't accepted, I took y away, and ray_y_offset isn't accepted either
17:12:53 <michi_cc> Samu: Why should it, an integer isn't a SubSprite struct.
17:13:19 <Samu> yes, that , no idea what's a SubSprite struct
17:13:35 <Samu> i did very much the same on the config window, and it accepted y
17:13:48 <michi_cc> But I'm quite sure DrawSprite wants x and y, and not two x values. Looking up the function definition of DrawSprite (it has comments) should help.
17:13:49 <Samu> on the ai list window it doesn't want it
17:14:02 <michi_cc> Samu: You didn't, no matterwhat you think.
17:14:54 <Samu> hmm :(
17:16:26 <Samu> let me check this again
17:16:37 <michi_cc> Maybe random cargo-cult programming is inferior to trying to understand it first.
17:17:15 *** rahtgaz has joined #openttd
17:17:20 <Samu> crap :( i'm dumb
17:18:46 <Samu> i see what I did wrong
17:19:09 <Samu> DrawSprite isn't needing the right most side
17:20:17 <Samu> only DrawString needs that
17:20:35 <Samu> let's see now, it seems to compile
17:22:57 <Samu> yes yes it works! thx michi_cc
17:24:31 <Samu> http://i.imgur.com/i325eJY.png - looks better now, yay
17:24:39 <Samu> and it scrolls
17:25:59 <Alberth> no, just very stubborn in believing what you're doing is effective
17:26:23 <Alberth> ^ about "i'm dumb" comment
17:28:38 <Samu> it's strange, I worked with DrawSprite just a few days before
17:28:54 <Samu> i was supposed to know how to use it
17:29:03 <Samu> think i got alzheimer
17:29:39 <peter1138> you should've read the error message
17:29:45 <peter1138> it had all the info you needed
17:40:29 *** debdog has quit IRC
17:51:57 <Samu> just a few hours ago, had to fix part of the code I've already worked before. It was calculating the width of sprites to determine the highest one. That's not what I've thought I've done.
17:52:24 <Samu> now it really is calculating the height
17:53:42 <Samu> how I end up messing things up like that...
17:53:48 *** debdog has joined #openttd
17:54:02 <Samu> and my english sometimes is horrid
17:55:46 *** Eddi|zuHause2 has joined #openttd
17:56:51 *** debdog has quit IRC
17:59:59 *** Wormnest_ has joined #openttd
18:00:51 *** Eddi|zuHause has quit IRC
18:02:36 *** Gja has joined #openttd
18:06:29 *** Wormnest has quit IRC
18:08:49 *** rahtgaz has quit IRC
18:22:06 *** debdog has joined #openttd
18:32:21 *** HerzogDeXtEr1 has joined #openttd
18:38:24 *** HerzogDeXtEr has quit IRC
18:39:51 *** glx has joined #openttd
18:39:51 *** ChanServ sets mode: +v glx
18:53:43 *** Eddi|zuHause2 is now known as Eddi|zuHause
19:15:42 *** WegeClausen has joined #openttd
19:15:59 <WegeClausen> hi im running in a problem sometimes
19:16:26 <WegeClausen> Q ehat if i want to drop the fright and only load the station products
19:16:52 <WegeClausen> so the products i unloaded arend reloded
19:18:13 <Alberth> where do they go?
19:18:28 <Alberth> staying at the station, or accepted by industries?
19:18:50 <WegeClausen> Example train comes in and drops water foodl but then loads the same and the station goods and goes for plan
19:19:15 <WegeClausen> not accepted
19:19:45 <WegeClausen> i kmow its best to go for 2 trains
19:20:00 <Alberth> you force unload it?
19:20:07 <WegeClausen> yes
19:20:20 <Alberth> fruit is accepted?
19:20:21 <WegeClausen> but it reloads them
19:20:50 <Alberth> yes, you load either nothing or everything
19:21:14 <Alberth> unless you use cargo-dist, and provide other means to transport the unloaded cargo
19:21:16 <WegeClausen> no fruit is at the station it rights to a second station with corn then dets on to foodfactory with waterwell
19:21:37 <WegeClausen> ok i will get me 2 trains
19:22:02 <Alberth> or perhaps 2 stations?
19:22:33 <Alberth> force unloading unloads everything, you cannot force unload a single cargo
19:23:09 <Alberth> in general you should not need force unload at all
19:23:23 <Alberth> it exists mostly for fixing problems
19:23:52 <WegeClausen> ok
19:32:58 <WegeClausen> Gn8
19:33:03 *** WegeClausen has left #openttd
19:36:40 *** rahtgaz has joined #openttd
19:44:14 <Samu> how do I retrieve the width value of this text? const char *text = (*it).second->GetName();
19:45:25 <Alberth> afaik there is a function to get the width of a char * text
19:46:16 <Alberth> getting the width of a StringID uses it too
19:48:31 <Samu> ok, will look
19:48:44 *** mescalito has joined #openttd
19:49:49 *** roidal has joined #openttd
20:02:20 *** srhnsn has joined #openttd
20:21:12 *** andythenorth has joined #openttd
20:22:04 <andythenorth> o/
20:26:39 <Alberth> o/
20:37:21 *** Wormnest__ has joined #openttd
20:42:13 * andythenorth needs an offsider
20:42:18 <andythenorth> supermop o/
20:42:26 <supermop> yo
20:42:56 <andythenorth> played any more antelope game?
20:42:57 <andythenorth> o_O
20:44:22 *** Wormnest_ has quit IRC
20:45:26 <Samu> SetDParamStr(0, (*it).second->GetName()); uint text_width = GetStringBoundingBox(STR_JUST_RAW_STRING).width;
20:45:45 <Samu> this works, but is there a better way?
20:47:09 <andythenorth> hmm
20:47:17 * andythenorth wants ropeway transport
20:47:39 <Samu> i still don't fully understand pointers
20:48:15 <andythenorth> https://en.wikipedia.org/wiki/COMILOG_Cableway
20:48:18 <supermop> not yet, got sidetracked with tram cascading micromanagement and walked away from it
20:48:31 <supermop> andythenorth: i've drawn belt sprites
20:49:34 <andythenorth> ‘tram cascading micromanagement’ :D
20:49:47 <andythenorth> how did you manage that? o_O
20:50:10 <Alberth> secret firs parameter :)
20:53:33 <supermop> didn't manage, thats why i walked away. ended up with 6 trams that were superceded in every way in the city that became center of my network
20:53:52 <Samu> what if the AI name is translated?
20:53:57 <Samu> is that even possible?
20:54:11 <supermop> but they still had lots of life left, but the only place that made sense to use them was 100+ tiles away
20:54:41 *** ektor has joined #openttd
20:54:53 <andythenorth> with Road Hog?
20:55:11 <Samu> static_cast
20:55:12 <supermop> no non-absurd way to send trams to somewhere that far away, so thought about sending them to the outskirts of their current city
20:55:23 <supermop> andythenorth: 2cc set.
20:55:24 <Samu> if (static_cast<AIInfo *>((*it).second)->UseAsRandomAI()) DrawSprite(SPR_AICONFIG_RANDOM, PAL_NONE, r.left + WD_MATRIX_LEFT, y + rai_y_offset);
20:55:37 <andythenorth> I would have scrapped them :)
20:55:40 <Samu> i'm not sure what's static_cast, just that I had to use it
20:56:31 <supermop> but sending them to the other side of town involved sending them across a 4 track mainline with an antelope once every 10 days in each direction
20:56:43 <supermop> and these were 20kmh trams
20:56:56 <supermop> Eddi|zuHause suggested i play frogger with the trams
20:57:12 *** frosch123 has quit IRC
20:57:50 <Alberth> Samu: euhm, a static cast to test non-nullness?
20:58:24 <Alberth> oh, to use UseAsRandomAI()
20:58:25 <supermop> then we got distracted on irc and i haven't had a chance to revisit
20:59:26 <Alberth> still, static_cast is generally very wrong
21:00:15 <Samu> I copy pasted from somewhere further down in that function
21:00:36 <Samu> and addapted it to UseAsRandomAI()
21:00:42 *** Arveen has joined #openttd
21:05:07 <andythenorth> road vehicles are lame
21:05:10 <andythenorth> :P
21:05:47 <Alberth> samu: basically, static_cast means "shut up compiler, just take my word for it, I hereby declare it's a 'AIInfo *'"
21:06:20 <Alberth> ie a very big sledge hammer to prevent the compiler from checking things
21:06:57 <Samu> hehe
21:07:11 <Alberth> so duh, it compiles, as you told the compiler to stop complaining
21:09:00 <andythenorth> so….WaterTypes...?
21:09:06 * andythenorth has been thinking
21:09:40 *** Progman has joined #openttd
21:11:04 <Samu> Class 'ScriptInfo' has no member 'UseAsRandomAI'
21:11:07 <supermop> we already have that
21:11:25 <supermop> but if you give me a log flume i'll be ecstatic
21:12:04 <Samu> Class 'AIInfo' does
21:13:04 <Alberth> but that doesn't make a ScriptInfo* the same as a AIInfo*
21:18:39 *** roidal has quit IRC
21:19:18 <andythenorth> one of the (several) dumb things about ships is lack of variety in routing
21:19:29 <andythenorth> planes have helicopters / planes
21:19:37 <andythenorth> RVs have tram / road vehicle
21:19:45 <andythenorth> trains have 3 or 4 types by default
21:19:59 <andythenorth> ships, one type, blah
21:21:16 <Samu> I can't ask UseAsRandomAI to ScriptInfo t.t
21:21:57 <Samu> but the *it dude does have a 'use_as_random' for AIs, not for GSs though
21:21:59 <supermop> andythenorth: logs
21:22:25 <Samu> i don't know how it was even working for GSs
21:22:41 <andythenorth> supermop: eh?
21:23:00 <supermop> log flumes
21:23:42 <andythenorth> well :)
21:24:08 <andythenorth> that would be better as ‘one way unit cargo transport’
21:24:20 <andythenorth> or whatever we called it last time it was discussed :P
21:24:30 <andythenorth> pipelines, cableways, log flumes etc
21:26:04 <andythenorth> but for water I’m thinking a split of sea vs. canal/river
21:26:36 * andythenorth wonders what the gameplay implications would be
21:27:10 <Samu> andythenorth, i remember working with rivers and canals before
21:27:16 <Samu> last year
21:27:57 <Samu> not graphics, just the mechanics
21:28:49 <Samu> should be in the forums yet, sec, let me find
21:29:15 <Alberth> :o pipelines @ water?
21:29:57 <Samu> https://www.tt-forums.net/viewtopic.php?t=72691
21:30:32 <Samu> heh, revisiting the stuff I did last year
21:31:48 <Samu> i think I gave up when i was working on the code to allow bridges over locks
21:32:06 <Samu> couldn't draw the bridge ramp
21:32:23 <Samu> then i could, but the vehicles under the bridge were overlaping
21:32:32 <Samu> :(
21:33:08 <Samu> i had a very ambitious goal though
21:37:54 <Samu> Alberth the original code is then wrong?
21:38:33 <Samu> seems to be the case
21:39:04 <Samu> it treats GSs and AIs like they're alike
21:40:23 <Alberth> they are quite alike, both execute squirrel code
21:41:03 <Alberth> I didn't write AI or GS stuff, so I don't know how they are different
21:41:10 <Samu> if (this->selected == i - 1) selected_info = static_cast<AIInfo *>((*it).second);
21:41:23 <Samu> that's in there, sec, let me get a link
21:42:06 <Samu> https://git.openttd.org/?p=trunk.git;a=blob;f=src/ai/ai_gui.cpp;h=8944e8bc4f33f8187a50d9773078e21495e6bf6f;hb=HEAD#l143
21:42:19 <Samu> line 143
21:43:35 <Samu> i see most of the names there still mention AI, even though some of them are refering both AI and GS
21:44:05 <Samu> even the comments
21:59:06 *** rahtgaz has quit IRC
22:03:38 *** Alberth has left #openttd
22:10:21 *** Hiddenfunstuff has quit IRC
22:12:45 *** ToneKnee_ has quit IRC
22:21:30 *** andythenorth has quit IRC
22:24:52 *** rahtgaz has joined #openttd
22:40:45 <glx> I guess ai_gui.cpp:143 could use ScriptInfo as the used info are from the common part
22:40:48 *** Gja has quit IRC
22:41:12 *** Arveen has quit IRC
22:46:56 *** srhnsn has quit IRC
22:50:25 *** Supercheese has quit IRC
23:03:58 *** Progman has quit IRC
23:16:59 *** Wormnest_ has joined #openttd
23:23:54 *** Wormnest__ has quit IRC