IRC logs for #openttd on OFTC at 2016-07-10
            
00:14:19 *** FLHerne has quit IRC
00:14:26 *** FLHerne has joined #openttd
00:43:26 <Samu> 2024
00:49:16 *** Progman has quit IRC
01:17:37 *** Arveen has quit IRC
01:18:36 *** Biolunar has joined #openttd
01:21:43 *** FLHerne has quit IRC
01:26:23 *** Gja has quit IRC
01:55:38 *** tokai|noir has quit IRC
02:10:36 *** Mazur has quit IRC
02:11:18 *** DDR has quit IRC
02:11:55 *** Myhorta has quit IRC
02:13:38 *** Biolunar has quit IRC
02:24:05 *** Samu has quit IRC
02:27:32 *** tokai has joined #openttd
02:27:32 *** ChanServ sets mode: +v tokai
02:39:36 *** DDR has joined #openttd
03:03:41 *** Mazur has joined #openttd
04:38:32 *** Myhorta has joined #openttd
04:48:13 *** Myhorta has quit IRC
04:52:41 *** gelignite_ has joined #openttd
05:00:04 *** gelignite has quit IRC
05:05:07 *** gelignite_ has quit IRC
05:21:31 *** glx has quit IRC
06:18:27 *** HerzogDeXtEr has quit IRC
08:03:02 *** pereba has quit IRC
08:19:21 *** Alberth has joined #openttd
08:19:22 *** ChanServ sets mode: +o Alberth
08:20:52 *** andythenorth has joined #openttd
08:27:20 *** Biolunar has joined #openttd
08:27:54 <andythenorth> o/
08:34:42 <andythenorth> VisibleCargos or VisibleCargo
08:34:43 <andythenorth> ? :P
09:03:55 *** Arveen has joined #openttd
09:04:32 *** sla_ro|master has joined #openttd
09:11:35 *** efess has quit IRC
09:41:34 <Alberth> for what? :)
09:42:01 <Alberth> hi hi btw
09:52:27 *** Progman has joined #openttd
09:57:53 <andythenorth> class name
09:58:02 <andythenorth> I solved it :P
10:03:48 *** tokai|noir has joined #openttd
10:03:48 *** ChanServ sets mode: +v tokai|noir
10:03:52 *** srhnsn has joined #openttd
10:10:44 *** tokai has quit IRC
10:28:25 <Alberth> classname was clear, the question was, what is in it? :)
10:34:35 <andythenorth> configuration for drawing + displaying cargo(s)
10:35:23 <andythenorth> “English words that can be plural or singular”
10:43:26 *** frosch123 has joined #openttd
10:44:53 <Alberth> hola
10:45:06 <frosch123> moin :)
10:45:41 <Alberth> ah yes, I tend to ignore such english words, and pretend they're singular without an 's', and plural with an 's' :)
10:46:28 <frosch123> holas and moins?
10:46:48 <Alberth> no, cargo vs cargos
10:47:01 <frosch123> isn't "cargos" an abbreviation for "cargotypes"?
10:47:29 <Alberth> never looked at it that way
10:47:52 <Alberth> but seems a possible interpretation indeed
10:52:15 <Alberth> frosch123: all WIP, but made a little progress on fios puzzle http://devs.openttd.org/~alberth/diffs/fios_rewrite
10:52:29 <Alberth> not entirely sure how to go from here
10:53:55 <Alberth> hmm, files don't open in my browser?
10:54:06 <Alberth> must save them to disk :(
11:00:13 <andythenorth> ach
11:00:18 <andythenorth> refactoring without tests :P
11:01:28 *** Leanden has quit IRC
11:01:55 <Alberth> yep :)
11:02:14 <Alberth> useful if you don't even know where to go :)
11:02:59 <frosch123> i have a browser addon that allows me to display anything as text content :)
11:03:15 <andythenorth> ‘anything’
11:03:43 <frosch123> ok, doesn't work for my lunchbox
11:05:25 *** efess has joined #openttd
11:05:48 <frosch123> 40 looks scary :)
11:08:58 <frosch123> +void FileToSaveLoad::SetMode(FiosType ft) { <- 50: missing \n
11:11:31 <andythenorth> this got shorter :P http://dev.openttdcoop.org/projects/road-hog/repository/revisions/e26243b3df93/diff/src/road_vehicle.py?utf8=%E2%9C%93&type=inline
11:12:20 <frosch123> 70: i do quite see the point of clear+compact. maybe remove FreeFiles and just call Clear?
11:12:27 <frosch123> *i do not
11:12:29 *** Myhorta has joined #openttd
11:14:29 <Alberth> 40 is very scary indeed, I tested both conditions with every load I could think of, and it came out equal
11:15:11 <Alberth> ie a literal assert(cond1 && cond2) || (!cond1 && !cond2));
11:15:13 <frosch123> afterload.cpp also uses _file_to_saveload.filetype, so 40 is fine :)
11:16:33 <Alberth> _file_to_saveload is also used a couple of lines up from there, which is how I got the idea
11:19:15 <Alberth> andythenorth: :) s/i/unit_row/ ?
11:19:25 <frosch123> 100 looks wrong to me
11:19:36 <frosch123> - const FiosItem *item = GetFiosItem(file);
11:19:37 <frosch123> + FileList file_list;
11:19:39 <frosch123> + const FiosItem *item = file_list.GetItem(file);
11:19:53 <frosch123> doesn't "file_list" need to be a static module variable within console_cmds?
11:20:07 <frosch123> what does GetItem do for a freshly constructed list?
11:20:09 <Alberth> it switches from _fios_items to a local variable
11:20:39 <Alberth> GetItem builds list of files, and then finds one (or not)
11:20:57 <frosch123> oh, GetItem builds a list :o
11:21:01 <Alberth> before it did that on _fios_items
11:21:40 <Alberth> FindFile would be better name :)
11:22:40 <frosch123> turning _saveload_mode into a parameter seems to be the next step?
11:23:07 <Alberth> I did drop invalidating the load/save gui, and setting the _saveload_mode somewhat in 100, I think
11:23:38 <frosch123> i think GetItem should not call BuildFileList
11:24:01 <frosch123> that should be a separate call
11:24:32 <Alberth> yep, different name, or separating the calls would be +1
11:24:37 <frosch123> the console command should also only call it, if the list has not been constructed yet
11:25:00 <frosch123> for example, if ConPrintWorkingDirectory was called before, it should not rebuild it
11:25:09 <frosch123> GetItem allows to use numbers for indexing the list
11:25:16 <Alberth> as it is now, each command has its own list
11:25:20 <frosch123> which you get from the previous call to ConPrintWorkingDirectory
11:25:28 <frosch123> it's weird if it renumbers the list inbetween
11:25:58 <frosch123> so, i prefer separating the calls over renaming the function :)
11:26:02 <Alberth> so some static data for the file list for commands?
11:26:08 *** Quatroking has joined #openttd
11:26:24 <andythenorth> Alberth: changed ‘i’ :P
11:26:25 <andythenorth> ta
11:26:32 <Alberth> yw :)
11:26:38 <frosch123> well, the console stuff is a bit contradicting :)
11:26:48 <frosch123> when using numbers to refer to files, you do not want to rebuild
11:26:56 <frosch123> when using the explicit name, you want to rebuild
11:27:04 <Alberth> haha :)
11:27:23 <frosch123> maybe the number stuff should be split off from getitem as well
11:27:31 <frosch123> it only applies to the console anyway
11:28:43 <Alberth> caching could be useful, although it then needs a "update the cache" command too
11:29:13 <Alberth> hmm, maybe keep a map of last printed names vs numbers?
11:29:37 <Alberth> so using numbers doesn't give surprises
11:30:56 <Alberth> ok, thanks for the quick check
11:33:48 <frosch123> the queue looks quite nice :)
11:35:18 *** Supercheese has quit IRC
11:35:26 *** aard has joined #openttd
11:37:02 <Alberth> I am quite glad I made some progress at all :)
11:40:22 *** mykoserocin has joined #openttd
11:40:45 *** AdmiralKew has joined #openttd
11:41:29 *** mykoserocin has left #openttd
11:45:06 <Alberth> hmm, dropping numbers, and using unique name prefix instead?
11:46:34 *** Wormnest has joined #openttd
11:48:15 <frosch123> aren't most files different by the postfix date/autosae number? :p
11:49:17 <frosch123> would have to ask server admins about that
11:49:31 * andythenorth wonders what to do next
11:49:52 <Eddi|zuHause> conquer the world, usually
11:51:08 <andythenorth> that’s tomorrow
11:51:17 <Alberth> any unique string in the name would be another option :)
11:52:38 <andythenorth> bah
11:52:51 <andythenorth> didn’t account for this when I wrote pixa cargo placement code :|
11:52:52 <andythenorth> http://dev.openttdcoop.org/projects/road-hog/repository/entry/src/graphics/brightling_0.png
11:52:53 <andythenorth> :P
12:01:57 <Alberth> 2 cargo placements?
12:06:09 <Eddi|zuHause> likely 2 layers of things being in front of each other
12:11:23 <andythenorth> it can be placed ok
12:11:28 <andythenorth> but I don’t have short enough cargos :P
12:11:34 <andythenorth> maybe I can just use the longer one
12:11:57 <andythenorth> the cargo is sandwiched between two repeated layers of the vehicle, with a mask
12:18:27 *** NoShlomo has joined #openttd
12:20:56 *** Samu has joined #openttd
12:20:59 <Samu> 2025
12:22:13 <andythenorth> graphics generation now takes about 1.5s :(
12:22:15 <andythenorth> that’s slow
12:23:29 <Eddi|zuHause> but think of the children in africa!
12:27:41 <andythenorth> it’s true
12:54:11 <andythenorth> ugh, graphics processing time increases quite horribly per vehicle
12:55:32 * andythenorth needs a hammer
12:55:33 <frosch123> the map generator is certainly one of the most frustaing things about factorio :/
12:57:24 * andythenorth hammers
13:09:59 <Eddi|zuHause> can't you mod it?
13:15:39 <frosch123> i can't even get the "print" method to work :p
13:23:33 *** gelignite has joined #openttd
13:27:04 *** sim-al2 is now known as Guest2486
13:27:05 *** sim-al2 has joined #openttd
13:30:15 <andythenorth> multiprocessing to the rescue :P
13:30:16 <andythenorth> always
13:30:22 <andythenorth> what could ever go wrong with that?
13:31:36 *** Guest2486 has quit IRC
13:51:02 <Alberth> lack of cpus? :)
13:53:48 <DorpsGek> Commit by fonsinchen :: r27611 trunk/src/linkgraph/mcf.cpp (2016-07-10 13:53:43 +0200 )
13:53:49 <DorpsGek> -Codechange: Cache the calculated value of CapacityAnnotation
13:57:19 <DorpsGek> Commit by fonsinchen :: r27612 /trunk/src/linkgraph (3 files) (2016-07-10 13:57:16 +0200 )
13:57:20 <DorpsGek> -Codechange: Replace three uses of std::list with std::queue/vector. (JGR)
14:03:25 <DorpsGek> Commit by fonsinchen :: r27613 trunk/src/linkgraph/mcf.cpp (2016-07-10 14:03:23 +0200 )
14:03:26 <DorpsGek> -Codechange: Use a flat vector instead of a map in FlowEdgeIterator. (JGR)
14:12:48 *** andythenorth has quit IRC
14:17:03 <DorpsGek> Commit by fonsinchen :: r27614 /trunk/src/linkgraph (refresh.cpp refresh.h) (2016-07-10 14:17:00 +0200 )
14:17:04 <DorpsGek> -Codechange: Use a fixed array instead of a map for link refresher cargo capacities. (JGR)
14:20:19 *** frosch123 has quit IRC
14:31:06 *** frosch123 has joined #openttd
14:34:48 *** roidal has joined #openttd
14:40:16 *** roidal has quit IRC
15:21:34 *** FLHerne has joined #openttd
15:41:47 *** FLHerne has quit IRC
15:43:47 *** FLHerne has joined #openttd
15:44:17 *** HerzogDeXtEr has joined #openttd
16:15:47 *** tag has joined #openttd
16:16:35 <tag> hello there, is here anyone who i can ask a few questions regarding developing openttd?
16:27:11 *** FLHerne has quit IRC
16:27:24 *** FLHerne has joined #openttd
16:28:44 <FLHerne> tag: Just ask them, certainly some people in here know all the answers
16:29:09 <FLHerne> "Don't ask to ask, just ask" is right up in the topic ;-)
16:32:02 <Alberth> nah, we mostly pretend to know answers :)
16:41:18 *** Eearslya has quit IRC
16:47:35 *** andythenorth has joined #openttd
16:55:59 *** sla_ro|master has quit IRC
17:16:37 *** glx has joined #openttd
17:16:37 *** ChanServ sets mode: +v glx
17:21:12 <tag> I wanted to chat in private with someone, im a newbie programmer and would ask for directions on how to start. eg. where is the main function in the soure since i couldnt find it, which files are responsible for the graphics, etc, unfortunately i couldnt figure it out on my own.
17:22:25 <Alberth> a channel gives much better answers than a 1-to-1 chat, in general, more people really do know more :)
17:23:53 <tag> yeah thats true, just wanted to embarass myself in front of fewer people than a whole channel :D
17:23:55 <Alberth> the main function is in the system-specific code, I think, and then jumps to somewhere in openttd.cpp(?)
17:24:18 <Alberth> no worries, lots of people ask questions here :)
17:24:52 <tag> what do you mean "system-specific code", could you give me a filename?
17:24:53 <Alberth> not sure how useful it is to start with main(), it's 300K lines of code :)
17:25:45 <tag> i dont know either, i just havent worked on a big project in my life, wanted to start somewhere, and since i like this game and its opensource seemed like a good starting point
17:26:51 <Alberth> src/os/windows/ seems like a point
17:27:19 <Alberth> do you have something you like to know, or want to do?
17:28:01 <glx> usually don't try to follow all the flow, concentrate on one part
17:28:05 <tag> i've seen an issue with icon sizes, wanted to look into that, but couldnt really figure out which files might be related.
17:28:38 <tag> and i used opengl a bit so wanted to check out the files that are responsible for the graphics
17:28:38 <glx> that should be in *_gui.h/cpp files
17:28:49 <glx> and we don't use opengl :)
17:29:04 <tag> oh, what does the game use then
17:29:16 <glx> gdi on windows, and sdl
17:29:29 <glx> pure old style 2D
17:29:30 <Alberth> src/openttd.cpp has int openttd_main(int argc, char *argv[]) around line 535 which is mostly a nice entry point
17:29:47 <Alberth> pushing lots of pixels to the screen :)
17:30:08 <andythenorth> I often use a lang string to find my way into the code
17:30:19 <andythenorth> or guessing :P
17:30:35 <tag> i see alberth, thank you!
17:30:49 <tag> so its pure SDL on linux?
17:31:01 <Alberth> yep
17:31:31 *** AdmiralKew has quit IRC
17:31:32 <Alberth> filenames also say a lot of their contents
17:31:52 <tag> i used sdl for a simple snake game once, but didn't think its possible to use it for graphics like this :)
17:32:20 <Alberth> if you're on linux, install "ag" (silversurfer package), or "ack" very good at finding matches in the source
17:32:36 <tag> well thank you all for the help, hope i can contribute one day ;D
17:32:45 <tag> sure, i'll look into it
17:33:24 <Alberth> you may think it's 3D, but the images are just weirdly shaped flat images (loads of them :) )
17:33:37 <glx> just blitted sprites :)
17:33:49 <Alberth> drawn at just the right spot :)
17:33:59 <tag> yea i actually figured that out,i found the image sources
17:34:01 <glx> and in the right order
17:34:38 <tag> but i thought the images are textures over objects
17:34:54 <tag> but they are just simple images moved around then
17:34:57 <tag> ;)
17:35:25 <Alberth> yes, game is from about 1990 or so, waaaay before textures and 3d video cards :)
17:36:37 <Samu> 2026
17:37:05 <Alberth> going backwards now? I thought you were around 2040+ somewhere
17:38:15 <Alberth> oh, for 1.6.1, I guess
17:44:21 <tag> by the way does anyone know how is it possible that they can use int openttd_main()... instead of main()? they wrote an own compiler or how?
17:47:28 <andythenorth> hmm
17:47:38 <andythenorth> all the work sorting out truck lengths paid off :)
17:47:50 <andythenorth> generating cargo sprites now really easy :)
17:49:10 <glx> tag: there's a platform dependant main() calling openttd_main()
17:49:46 <glx> main() is WinMain() for windows for example
17:50:50 <Alberth> ie os/unix/ has main for unix/linux, os/windows/ has main for windows, etc
17:53:21 <Alberth> a success, andy :)
17:54:50 <frosch123> tag: the main() you mean is in src/os/unix/unix.cpp:260
17:54:59 <frosch123> it does some platform specific things, then calls openttd_main
18:04:06 <tag> oh i see, thanks
18:13:28 *** tag has quit IRC
18:35:57 *** HerzogDeXtEr1 has joined #openttd
18:42:33 *** HerzogDeXtEr has quit IRC
19:07:27 *** aard has quit IRC
19:15:16 *** Biolunar has quit IRC
19:51:50 <Wormnest> Samu: If you like you can now test the fixed version of NoCAB. I released it as NoNoCAB :p
19:52:06 <Samu> oh nice :)
19:52:28 <Samu> may test it when i get all this upgraded to 1.6.1
19:53:35 <Wormnest> Still lots of things that could be improved but unless big problems show up I´ll probably leave it as is for now
19:55:23 <Samu> it seems to be advancing 4 years / day
19:55:37 <Samu> 2027
19:55:49 <Wormnest> for ships?
19:55:54 <Samu> yes, the last one
19:56:09 <Samu> NoCAB NPF ships, waiting for it
19:56:55 <Wormnest> I think that should be a lot improved now, at least most problems with lost ships are gone as far a i´m aware
19:58:27 <Samu> i estimate in 6 days it reaches 2051
19:59:14 *** cyrex has joined #openttd
19:59:22 <cyrex> hy
20:05:05 *** sim-al2 is now known as Guest2514
20:05:06 *** sim-al2 has joined #openttd
20:06:41 *** andythenorth has quit IRC
20:07:25 <cyrex> este cineva pe aici?
20:09:32 <FLHerne> cyrex: Yes
20:09:50 <cyrex> ro?
20:10:07 *** Guest2514 has quit IRC
20:10:17 <FLHerne> No (not me, anyway) :-(
20:17:28 <cyrex> ok
20:17:45 <cyrex> you?
20:23:16 *** sla_ro|master has joined #openttd
20:27:39 *** Taede has quit IRC
20:33:44 *** Taede has joined #openttd
20:37:37 * cyrex slaps sla_ro|master around a bit with a large fishbot
20:42:06 <Eddi|zuHause> sla_ro|master seems like a person who only says something every half year
20:45:22 <Eddi|zuHause> (but the last time is already a year ago... so make of that what you will...)
20:46:38 <Rubidium> that's what you get with a readonly account ;)
20:55:29 *** Bluelight has joined #openttd
21:00:22 *** cyrex has quit IRC
21:11:35 *** Bluelight has quit IRC
21:24:12 *** andythenorth has joined #openttd
22:09:36 *** Alberth has left #openttd
22:14:42 *** frosch123 has quit IRC
22:19:21 *** FLHerne has quit IRC
22:19:40 *** FLHerne has joined #openttd
22:22:07 *** ConductorCat has joined #openttd
22:25:17 *** andythenorth has left #openttd
22:26:55 *** ConductCat has quit IRC
22:54:41 *** Supercheese has joined #openttd
22:59:31 *** Arveen has quit IRC
23:15:18 *** Progman has quit IRC
23:23:48 <supermop_> yo
23:24:07 <supermop_> have used so much battery and data today
23:33:24 <Samu> gg portugal 1-0 we won
23:33:28 <Supercheese> poor France
23:34:01 <Samu> rip ronaldo anyway
23:34:57 <Samu> that guy never did anything for portugal, it was a good idea to have him replaced
23:35:33 *** pereba has joined #openttd
23:36:04 <Supercheese> winning goal scored by some random guy who played for Swansea a bit and never scored there
23:36:13 *** srhnsn has quit IRC
23:39:10 <ST2> well, even an OpenTTD community enbrace euro champion colours: http://openttd.btpro.nl/
23:39:20 <ST2> congrats to Portugal :)
23:41:07 *** Biolunar has joined #openttd
23:51:25 *** OsteHovel has quit IRC
23:51:37 *** OsteHovel has joined #openttd
23:53:20 *** Wormnest has quit IRC
23:54:20 *** gelignite has quit IRC