Back to Home / #openttd / 2012 / 02 / Prev Day | Next Day
#openttd IRC Logs for 2012-02-02

---Logopened Thu Feb 02 00:01:05 2012
00:16-!-tokai|noir [] has joined #openttd
00:16-!-mode/#openttd [+v tokai|noir] by ChanServ
00:22-!-tokai|mdlx [] has quit [Ping timeout: 480 seconds]
00:29-!-DayDreamer [~DayDreame@] has joined #openttd
00:50-!-DayDreamer [~DayDreame@] has quit [Read error: Connection reset by peer]
00:56-!-Eddi|zuHause [] has quit []
00:56-!-Eddi|zuHause [] has joined #openttd
01:01-!-NullByte [] has quit [Quit: Leaving]
01:13-!-NullByte [] has joined #openttd
01:15-!-roboboy [] has joined #openttd
01:24-!-KouDy [~KouDy@] has quit [Quit: Leaving.]
01:25-!-KouDy [~KouDy@] has joined #openttd
01:32-!-NullByte [] has left #openttd []
01:38-!-roboboy [] has quit [Ping timeout: 480 seconds]
01:38-!-KouDy1 [~KouDy@] has joined #openttd
01:41-!-JVassie [~James@] has joined #openttd
01:43-!-KouDy [~KouDy@] has quit [Ping timeout: 480 seconds]
01:53-!-Cybertinus [] has joined #openttd
02:00-!-JVassie [~James@] has quit [Ping timeout: 480 seconds]
02:11-!-sla_ro|master [~slaco@] has joined #openttd
02:18-!-DDR [~chatzilla@] has joined #openttd
02:28-!-sla_ro|master [~slaco@] has quit [Quit: - free first person shooter based of c&c 3]
02:29-!-theholyduck [~holyduck@] has quit [Ping timeout: 480 seconds]
02:31-!-MJP [] has joined #openttd
02:45-!-tty234_ [] has joined #openttd
02:46-!-Progman [] has joined #openttd
02:47-!-tty234 [] has quit [Ping timeout: 480 seconds]
02:56-!-andythenorth [] has joined #openttd
02:59-!-Rhamphoryncus [] has joined #openttd
03:04-!-theholyduck [~holyduck@] has joined #openttd
03:14-!-Prof_Frink [] has quit [Ping timeout: 480 seconds]
03:18<dihedral>o dear lord, what a terrible backlog :-P
03:20<Rhamphoryncus>You just can't shut me up!
03:22<Elukka>so many sprites to draw
03:24<Rhamphoryncus>so many codes to write
03:25<Elukka>many a thing
03:26-!-sla_ro|master [~slaco@] has joined #openttd
03:26<Elukka>24 sprite angles and asymmetric wagons ;_;
03:29<Eddi|zuHause>just make the symmetric wagons, and add the braker's cab later?
03:34<Rhamphoryncus>Eddi|zuHause: On further thought you were right about not checking vehicles still loading at the previous station
03:36*andythenorth ponders
03:36<Elukka>well, the wagon body is usually shorter at the end with the platform/cab
03:36<andythenorth>can my python script import nmlc and build the grf?
03:36<Elukka>on the next wagon i'm gonna see if i can get away with a symmetric one though
03:36-!-DayDreamer [~DayDreame@] has joined #openttd
03:36-!-DayDreamer [~DayDreame@] has left #openttd []
03:38-!-tensai_cirno [~cirno@] has joined #openttd
03:44-!-MJP [] has quit [Ping timeout: 480 seconds]
03:59-!-kkb110 [~kkb110@NYUFGA-WLESSAUTHCLIENTS-01.NATPOOL.NYU.EDU] has quit [Ping timeout: 480 seconds]
03:59<andythenorth>nmlc is not in my system path for modules
03:59*andythenorth is just stabbing at this :P
04:03-!-TGYoshi [~TGYoshi@] has joined #openttd
04:12<Rhamphoryncus>What the.. you can have a shared order list of only one vehicle? o.O
04:15<andythenorth>pool of one
04:15<andythenorth>shared order list is just a set
04:18-!-KouDy1 [~KouDy@] has quit [Read error: Connection reset by peer]
04:18-!-KouDy [~KouDy@] has joined #openttd
04:22-!-pjpe [] has quit [Quit: ajax IRC Client]
04:25<Rhamphoryncus>Heh. Got some mysterious extra debugging prints. They were from the loadscreen game ;)
04:50-!-theholyduck [~holyduck@] has quit [Ping timeout: 480 seconds]
04:54-!-DDR [~chatzilla@] has quit [Quit: ChatZilla 0.9.88 [Firefox 9.0.1/20111221202647]]
04:55-!-chester [] has joined #openttd
04:56<chester>hi all, do graphviz work in ottd wiki or what?
04:58-!-andythenorth [] has quit [Quit: andythenorth]
04:59-!-MINM [] has joined #openttd
05:02<Eddi|zuHause>i don't think anybody ever tried that yet
05:03<Eddi|zuHause>probably you need to bug someone to enable an extension for that
05:04-!-MNIM [] has quit [Ping timeout: 480 seconds]
05:06<chester>it is ncluded
05:06<chester>and Talk:Cargo has it
05:07<Eddi|zuHause>right... problem solved then :(
05:07<chester>but i cant make any other graph
05:08<chester>furthermore when i change 1 letter in original one, it doesnt show
05:09<Eddi|zuHause>maybe it doesn't trigger generating the image?
05:09<chester>how to make it show then
05:09<Eddi|zuHause>dunno, that is outside my area of expertise
05:10<Eddi|zuHause>my "area of expertise" generally ends with "there exists a solution" :)
05:10<chester>is there any flag or smth forcing rendering
05:11<chester>-are you expert in SQL? -no -nevermind, wright 'expert in NoSQL'
05:12<Eddi|zuHause>i try to avoid SQL as good as i can, but that's probably not what you mean :p
05:12<chester>it was a citation from some comics
05:13<chester>wikimedia says nothing abt this, i can only get graphs @my local pc
05:14<chester>i dont even know which version is included there and options avail
05:22-!-sla_ro|master [~slaco@] has quit [Quit: - free first person shooter based of c&c 3]
05:53-!-Progman [] has quit [Remote host closed the connection]
05:54-!-Progman [] has joined #openttd
05:55*Rhamphoryncus ponders a helper function to make next_shared/previous_shared cyclic, so he can reorder, then make it acyclic again
06:00<Eddi|zuHause>don't you just need a flip() function?
06:01<Eddi|zuHause>and add a NextSharedCyclic() and PrevSharedCyclic()?
06:01-!-mahmoud [] has joined #openttd
06:02<Rhamphoryncus>I was writing out all the branches for updating the previous/next/first/last pointers and it's ending up as 4 cases of 6 lines each. Plus a check that there's at least 3 vehicles to swap
06:06<Rhamphoryncus>down to a total of 3 lines, plus a call to MakeCyclic/MakeAcyclic at the top and bottom of the function
06:06<Rhamphoryncus>Actually, those helpers are only 2 lines each, plus 2 assertions. I could just as well merge them in.
06:07<Eddi|zuHause>keep them separate and make them inline
06:07<Rhamphoryncus>static inline void
06:08<Eddi|zuHause>something like that, yes
06:08<Rhamphoryncus>Now I just need to make C++ accept them :P
06:18<Rhamphoryncus>... I can't have a static inline method in a .cpp file and if I put it in the header I don't have the right other headers pulled in x_x
06:21<Rhamphoryncus>nor can I include vehicle_base.h since it's already including order_base.h
06:23<Eddi|zuHause>why shouldn't you have static inline function in the .cpp file?
06:24<Eddi|zuHause>of course, "static" means something completely different inside a class
06:24<Rhamphoryncus>static inline *functions* are fine. Methods it chokes on because they're not declared in the class
06:25<Rhamphoryncus>interesting point though, I had blindly copied the static keyword in to the class for the declaration. When I later tried to move the whole definition there I removed it, but I never tried the declaration without it.
06:26<Rhamphoryncus>Nope, that chokes too
06:26<Rhamphoryncus>/home/rhamph/src/openttd/easyschedule.hg/src/order_cmd.cpp:523:42: error: cannot declare member function ‘void OrderList::MakeCyclic()’ to have static linkage [-fpermissive]
06:26-!-DayDreamer [~DayDreame@] has joined #openttd
06:34-!-andythenorth [] has joined #openttd
06:48<Rhamphoryncus>Looks like C++ won't do what I want. Either I use a private inline method or a static inline non-method
07:11-!-cmircea [~cmircea@] has joined #openttd
07:36<dihedral>looks like you want to do something you should not want to do :-P or you are thinking too complicated
07:40<Rhamphoryncus>It'd be good coding style in C. In C++ it seems to be "eh, don't bother"
07:40<Eddi|zuHause>it's inherently difficult to make methods inline
07:40<Eddi|zuHause>because they could be overridden and stuff
07:40<Eddi|zuHause>so you need to make them private
07:41<Rhamphoryncus>But there's two reasons for it in C: one is to avoid name conflicts, the other is actually be private. C++ doesn't seem to actually allow the latter :P
07:55-!-roboboy [] has joined #openttd
07:58-!-DayDreamer [~DayDreame@] has quit [Quit: Leaving.]
08:11<Eddi|zuHause>hm... can we have a string-code "{SPRITE}"?
08:13<andythenorth>where is it needed?
08:13*andythenorth explores os.subprocess as a way to call nmlc from a python script
08:13<Eddi|zuHause>can't you "import nmlc"?
08:15<andythenorth>probably, if I set my search path
08:16<andythenorth>I guess it's not currently in my python module search paths
08:16<andythenorth>let's see
08:17-!-roboboy [] has quit [Ping timeout: 480 seconds]
08:18<andythenorth>apparently not
08:18<andythenorth>nmlc is aliased from /opt/local/bin/
08:18<andythenorth>I've added sys.path.append('/opt/local/bin/')
08:18<andythenorth>but nmlc is not found
08:19<Eddi|zuHause>well, it'll only search for .py files
08:19<Eddi|zuHause>you'll need to import
08:21<Eddi|zuHause>actually, if you "make install"-ed it, you should be able to do "from nml import main"
08:21<andythenorth>I didn't
08:21<andythenorth>I don't trust things too well where I have to sudo
08:22<andythenorth>makes me itch every time
08:22<andythenorth>I've aliased it currently
08:22<andythenorth>if I set the actual path to nml src, I can import
08:22<Eddi|zuHause>well, then you have to set the path
08:22<andythenorth>that's kind of local to me though :P
08:22<andythenorth>bad pattern
08:25-!-TheMask96 [] has quit [Ping timeout: 480 seconds]
08:27<Eddi|zuHause>after you "from nml import main"-ed, you'll probably want to run "main.main(args)"
08:28<andythenorth>what should args be? :)
08:29<Eddi|zuHause>an array of what you would give after nmlc
08:30-!-TheMask96 [] has joined #openttd
08:30<Eddi|zuHause>so if you'd write "nmlc --nfo cets.nfo cets.nml" then you'd call "main.main(['--nfo','cets.nfo','cets.nml'])"
08:31<Eddi|zuHause>like "cmdline.split(' ')[1:]" (roughly)
08:33<Eddi|zuHause>if you'd call nmlc like usual, it would pass "argv[1:]" to main()
08:39<Eddi|zuHause>@calc 78/16
08:39<@DorpsGek>Eddi|zuHause: 4.875
08:39<Eddi|zuHause>@calc 78/3
08:39<@DorpsGek>Eddi|zuHause: 26
08:59-!-cmircea [~cmircea@] has quit [Read error: Connection reset by peer]
09:00-!-cmircea [~cmircea@] has joined #openttd
09:07-!-cmircea [~cmircea@] has quit [Read error: Connection reset by peer]
09:12-!-Pulec [] has quit [Ping timeout: 480 seconds]
09:12-!-glx [glx@2a01:e35:2f59:c7c0:e8ac:5296:6042:37e7] has joined #openttd
09:12-!-mode/#openttd [+v glx] by ChanServ
09:13-!-bondmain_ [] has quit [Read error: Connection reset by peer]
09:13-!-cmircea [~cmircea@] has joined #openttd
09:13-!-bondau [] has joined #openttd
09:20<Elukka>ugh. there was a very nice company color replacement grf+patch somewhere in the forums recently but i can't for the life of me find it now
09:22-!-expekt [] has joined #openttd
09:23<expekt>Hi! I have some problems with Saved Game Manager. I cant open any save gamed?
09:25-!-bondau [] has quit [Read error: Connection reset by peer]
09:26<Eddi|zuHause>what's a saved game manager?
09:26<Eddi|zuHause>and what error message do you get?
09:26-!-bondmain_ [] has joined #openttd
09:29<expekt>the program dosen't find the saved game
09:29<expekt>it it also the same problem with TTD Alter and TTDX Editor
09:30<Eddi|zuHause>i don't think they were everintended to work with openttd savegames
09:34-!-andythenorth is now known as Guest1329
09:34-!-andythenorth_ [] has joined #openttd
09:34-!-andythenorth_ is now known as andythenorth
09:34-!-andythenorth_ is "(unknown)" on (unknown)
09:34-!-Guest1329 [] has quit [Read error: Connection reset by peer]
09:46<Eddi|zuHause>hm... do articulated parts issue effect vehicles?
09:47<andythenorth>not for RVs
09:47<Eddi|zuHause>hm... i do remember it steaming from 3 places in the original dummy vehicle
09:47<andythenorth>Eddi|zuHause: can you figure out passing args to the python script from makefile? Based on reading tutorials I have
09:47<andythenorth>but it seems to be failing
09:48<Eddi|zuHause>wrong place
09:48<Eddi|zuHause>must be behind the "python" line
09:48<Eddi|zuHause>the "GENERATE=" line is only the dependencies
09:49<Eddi|zuHause>also make sure the makefile doesn't try to expand the ${} sections
09:50<andythenorth>:Q seems to stop that
09:52<Eddi|zuHause>i mean more like enclose it in '' or so
09:52*andythenorth has been trying to figure out what I need to google for this
09:53<andythenorth>search strings like 'pass command line args from makefile' get me 10 million results about passing command line args *to* makefile :P
09:54<andythenorth>'' works
10:04*andythenorth explores
10:05<andythenorth>doesn't look very maintained though
10:06<Elukka>i've been using long vehicles v4 since forever
10:06<Elukka>are there any alternative road vehicle sets that are maybe a bit more useful than vanilla vehicles and a bit more real looking than them or grvts?
10:08<andythenorth>highway robbery
10:08<andythenorth>Elukka: can you draw trucks?
10:08<Elukka>posssssibly but i already have way too many wagons to draw and i'm getting them done way too slowly :P
10:08<Eddi|zuHause>he must first draw wagons :p
10:09<andythenorth>in that case he can stop playing the game anyway
10:09<andythenorth>and draw
10:09*andythenorth reads docs for codecs
10:09<Eddi|zuHause>anyone split off the horse carriages from eGRVTS yet?
10:10<andythenorth>Eddi|zuHause: presumably to avoid unicode sadface? ^^
10:10<Elukka>hungarian set
10:10<andythenorth>also writing streams and such
10:10<Elukka>looks very nice
10:10<Eddi|zuHause>Elukka: germanrv is nice, but unfortunately the trucks aren't done yet
10:11<Elukka>aw, and hungarian set only starts in 1950
10:12<Eddi|zuHause>why did you link that thread? now i'm getting a petert flashback...
10:12<andythenorth>Eddi|zuHause: you never hang out in #openttdcoop.devzone?
10:13<Eddi|zuHause>andythenorth: no, why would i?
10:13<andythenorth>you see the CETS commits somewhere else? or you don't care?
10:13-!-bondmain_ [] has quit [Read error: Connection reset by peer]
10:13<Elukka>is there a juicy story i don't know
10:14<Eddi|zuHause>andythenorth: i wanted the commits per email, but apparently nobody figured that out yet... Ammler?
10:14<andythenorth>rss to email?
10:15<andythenorth>or your mail reader can read rss in some cases
10:15<Eddi|zuHause># sie müssen erst den nippel durch die lasche ziehn
10:15<Eddi|zuHause># und an der kleinen kurbel ganz nach oben drehn
10:16<Eddi|zuHause># dann erscheint sofort ein pfeil, da drücken sie dann drauf
10:16<Eddi|zuHause># und dann, geht die tube auf...
10:16<andythenorth>definitely english :P
10:18<Eddi|zuHause>according to mr-english-only, it's ok if it's quotes or music :p#
10:20<andythenorth>or if it's spanish
10:20<andythenorth>or python, or c++ or nfo or nml
10:23<Eddi|zuHause>anyway, it's a song about how things are totally overcomplicated
10:24<andythenorth>first [blah blah] put the small thing [blah] etc
10:24<andythenorth>I think I've murdered cpp in BANDIT
10:24<andythenorth>not sure how to test
10:25<Eddi|zuHause>@calc 265*255
10:25<@DorpsGek>Eddi|zuHause: 67575
10:25<Eddi|zuHause>@calc 256*255
10:25<@DorpsGek>Eddi|zuHause: 65280
10:25<Eddi|zuHause>@calc 16*255
10:25<@DorpsGek>Eddi|zuHause: 4080
10:26<Eddi|zuHause>@calc 256*255/74
10:26<@DorpsGek>Eddi|zuHause: 882.162162162
10:26<Ammler>andythenorth: nobody wants commits per mail ;-)
10:26*Eddi|zuHause misses a right-click->slap button...
10:27-!-sla_ro|master [~slaco@] has joined #openttd
10:31<andythenorth>forums [code] block strips \ from \n
10:31<Eddi|zuHause>tried \\?
10:33<Eddi|zuHause>both the '' and the \\ are reflex-solutions i always try before asking anybody else for help :)
10:34<Ammler>someone already "played" with phase on hg 2.1?
10:35-!-KouDy [~KouDy@] has quit [Quit: Leaving.]
10:35*andythenorth wonders how to patch makefile to avoid cpp
10:40-!-expekt [] has quit [Quit: ajax IRC Client]
10:43-!-tensai_cirno [~cirno@] has quit [Quit: Leaving]
10:54-!-Twofish [] has quit [Quit: Leaving]
10:54-!-kkb110_ [] has joined #openttd
10:58-!-sla_ro|master [~slaco@] has quit [Quit: - free first person shooter based of c&c 3]
11:04-!-MINM [] has quit [Read error: Connection reset by peer]
11:14-!-cmircea [~cmircea@] has quit [Ping timeout: 480 seconds]
11:24-!-tokai|mdlx [] has joined #openttd
11:27<Ammler>andythenorth: CC=""
11:29-!-sla_ro|master [~slaco@] has joined #openttd
11:30-!-tokai|noir [] has quit [Ping timeout: 480 seconds]
11:37-!-theholyduck [~holyduck@] has joined #openttd
11:43*andythenorth needs a basic valid NML project
11:43<andythenorth>for example purposes
11:45-!-sla_ro|master [~slaco@] has quit [Quit: - free first person shooter based of c&c 3]
11:48-!-ABCRic [] has joined #openttd
11:50-!-sla_ro|master [~slaco@] has joined #openttd
11:55-!-Brianetta [] has joined #openttd
12:02-!-Brianetta [] has quit [Quit: Tschüß]
12:23-!-Prof_Frink [] has joined #openttd
12:33<andythenorth>do I need to call close() on a a file I've opened as read only (python)
12:34<Mazur>In the interest of clean programming, I'd say yes.
12:35-!-peteris [~peteris@] has joined #openttd
12:38<SpComb>andythenorth: you can also do `with open(...) as myfile: ...`
12:38<SpComb>and if you do something like `data = open(...).read()` there's not really any need to explicitly close() it
12:39<SpComb>but if you do `self.thatfile = open(..)`, then yes, do explicitly close it and clear the reference
12:39<SpComb>python refcounting guarantees you that the file object will be closed once you drop all references to it
12:41<Eddi|zuHause>i'd have some reservations towards relying on refcounting
12:47-!-TWerkhoven[l] [] has joined #openttd
12:50-!-frosch123 [] has joined #openttd
12:53<Eddi|zuHause>you're a guinea pig now?
12:57-!-|Jeroen| [] has joined #openttd
13:08-!-itp [] has joined #openttd
13:13<andythenorth>writing tutorials is surprisingly hard work
13:13<andythenorth>even when they're not that good
13:13*andythenorth could never be a teacher
13:14*andythenorth looks for a collaborator :P
13:14<andythenorth>Terkhen: how is your python?
13:16-!-Brianetta [] has joined #openttd
13:16*andythenorth needs someone who knows some NML but limited python
13:17<@Terkhen>worse than my free time :P
13:17<Rhamphoryncus>"with open(...) as myfile:" is definitely the preferred way as it guarantees it's closed, but otherwise it's not worth the trouble unless you're doing it in a loop and something like java might run out of file handles before it triggers a collection
13:17<Rhamphoryncus>Or you're on windows and file locks prevent other work
13:17<@Terkhen>right now I have to fix FS#5039
13:18-!-MJP [] has joined #openttd
13:20-!-ABCRic [] has quit [Remote host closed the connection]
13:34-!-|Jeroen| [] has quit [Quit: oO]
13:34-!-Alberth [] has joined #openttd
13:34-!-mode/#openttd [+o Alberth] by ChanServ
13:45<CIA-1>OpenTTD: translators * r23875 /trunk/src/lang/ (dutch.txt french.txt lithuanian.txt):
13:45<CIA-1>OpenTTD: -Update from WebTranslator v3.0:
13:45<CIA-1>OpenTTD: dutch - 3 changes by Parody
13:45<CIA-1>OpenTTD: french - 53 changes by OliTTD
13:45<CIA-1>OpenTTD: lithuanian - 21 changes by Stabilitronas
14:00-!-Cybertinus [] has quit [Remote host closed the connection]
14:05-!-Cybertinus [] has joined #openttd
14:09-!-HerzogDeXtEr [~Flex@] has joined #openttd
14:10<@Terkhen>even with the fix, industry subsidies are quite rare
14:12<andythenorth>NewSubsidy framework!
14:12<andythenorth>newgrf subsidies!
14:12-!-Kurimus [] has quit [Ping timeout: 480 seconds]
14:12<andythenorth>all of them!
14:12-!-Wolf01 [] has joined #openttd
14:13<@Alberth>new, better, plus!
14:13<@Alberth>hi Wolf01
14:14<@Terkhen>yeah, I suppose that NoGo is the real fix for that :)
14:14<@Alberth>Terkhen: not enough opportunities at the right distance?
14:15<@Alberth>ie compared with towns, industries are quite picky about who they want to share cargo with :)
14:15-!-HerzogDeXtEr1 [] has quit [Ping timeout: 480 seconds]
14:16-!-itp [] has left #openttd []
14:17<@Terkhen>yes :)
14:17-!-Cybertinus [] has quit [Remote host closed the connection]
14:18-!-itp [] has joined #openttd
14:20-!-KenjiE20 [] has quit [Remote host closed the connection]
14:21-!-Cybertinus [] has joined #openttd
14:21-!-KenjiE20 [] has joined #openttd
14:25-!-KritiK [] has joined #openttd
14:25-!-KenjiE20 [] has quit [Read error: Connection reset by peer]
14:25-!-Kurimus [] has joined #openttd
14:27-!-itp [] has left #openttd []
14:29-!-Jensen1986 [] has joined #openttd
14:29<Jensen1986>Can someone please help me with a problem?
14:31<CIA-1>OpenTTD: terkhen * r23876 /trunk/src/subsidy.cpp: -Fix (r23408) [FS#5039]: Generate industry subsidies again. (Emmeran)
14:31<@Terkhen>@get -1
14:31<@DorpsGek>Terkhen: English only
14:31<@Terkhen>@get -2
14:31<@DorpsGek>Terkhen: 'Latest' is not a valid version, ever
14:31<@Terkhen>Jensen1986: just ask your question
14:31<Jensen1986>how do i take control of an AI company in TTD?
14:32<@Terkhen>activate cheats and move yourself to the AI company
14:32<@Terkhen>that can be done in OpenTTD, no clue about TTD
14:32<Jensen1986>not by buying their shares. I mean to take control and rearrange busses ect.
14:33<@Alberth>In OpenTTD, like Terkhen says
14:33<Jensen1986>The difference between OpenTTD and TTD is?
14:33<@Alberth>different games?
14:34<Rhamphoryncus>One has been worked on this millenium? ;)
14:34<@Alberth>25 years?
14:34*andythenorth ponders
14:34<Rhamphoryncus>Alberth: eh?
14:34<@Alberth>Rhamphoryncus: wasn't it 1984?
14:35<Rhamphoryncus>I was including windows versions
14:35<Jensen1986>I'm using TTDX editor... Is that the same?
14:35<Rhamphoryncus>And as long as it hasn't been touched in 2001 or later my statement is right
14:35<@Alberth>Jensen1986: not even close
14:35*Alberth believes Rhamphoryncus
14:36<@Alberth>Jensen1986: both games may look the same, but internally they are totally different
14:36<Jensen1986>hehe. You wouldn't believe me if i told you ive been playing this game for 10 years or so with my knowledge of it
14:36<@Alberth>yeah, it's addictive :)
14:37<@Alberth>wait until you try OpenTTD, and find all the nice additions that were made ;)
14:37<Jensen1986>I dont want to start a new game over again :(
14:38-!-theholyduck [~holyduck@] has quit [Ping timeout: 480 seconds]
14:38<@Alberth>OpenTTD is quite compatible, I would not be surprised if your game loaded
14:38<Jensen1986>really? If i try loading it and it doesnt work will the saved game still work in TTD?
14:39-!-Cybertinus [] has quit [Remote host closed the connection]
14:39<@Alberth>I would expect so, unless you save a new version over it
14:39<Rhamphoryncus>Alberth: wikipedia says 94 and deluxe in 95
14:39<@Alberth>but make a copy beforehand, just to be safe
14:40<@Alberth>Rhamphoryncus: Ah, I was only 10 years off :D Thanks for looking it up
14:40*Alberth wonders what game was in 1984 then :p
14:40<@Alberth>evenink planetmaker
14:40<@planetmaker>Jensen1986: you'll surely want to keep a copy of the original savegame, don't you?
14:41<Jensen1986>I better
14:42-!-theholyduck [~holyduck@] has joined #openttd
14:42<Jensen1986>Can i change the same thing in OpenTT as with TTDX editor?
14:43*andythenorth ponders a nap
14:44<@Alberth> <-- that's what the wiki has on scenario editors, about 10 lines :p
14:45<@Alberth>but yes, I think you can. I have never done much with the editor though, but on general, OpenTTD is expanding on functionality, and very reluctant on throwing stuff out
14:47-!-itp [] has joined #openttd
14:47-!-itp [] has left #openttd []
14:47<Jensen1986>nice. Gotta try that. I know this has been debated over and over. But why is it you cant have more than 4.3 billion in cash. Why dont the rewrite the game to 64 bit`?
14:48<@Alberth>it compiles and runs at 64bit
14:49<Jensen1986>but you still cant have more than 4.3 billion? I thought it had something to do with that?
14:49<@Alberth>'billion' is about 1,000,000,000 ?
14:49<@Alberth>oh, in that case, OpenTTD can do approximately:
14:49<@Alberth>@calc 2^60
14:49<@DorpsGek>Alberth: Error: Something in there wasn't a valid number.
14:49<@Alberth>@calc 2**60
14:49<@DorpsGek>Alberth: 1152921504606846976
14:49<@Alberth>give or take a few bits :)
14:50<Jensen1986>yes it is. so in OpenTT you can have much more money`?
14:50<@Alberth>it's OpenTTD (with a D at the end), but yeah
14:51<@Alberth>I never even got at 2**32 though
14:51-!-Rhamphoryncus [] has quit [Read error: Operation timed out]
14:52<Jensen1986>With my current game its not a problem. But one i used to play made me 3 billion a year. So i had to go to the edtitor and set my money to 0 in order to keep playing.
14:52<@Alberth> <-- stuff that OpenTTD can do
14:52-!-valhallasw [~valhallas@] has joined #openttd
14:53<@Alberth>@calc 1152921504606846976 / 3000000000
14:53<@DorpsGek>Alberth: 384307168.203
14:53<@Alberth>enough to keep playing for the 5,000,000 years that OpenTTD allows :p
14:53-!-Rhamphoryncus [] has joined #openttd
14:54-!-KenjiE20 [] has joined #openttd
14:54<Jensen1986>wow. I'll bet someone did. What a nerd:)
14:55<@Alberth>@calc 5000000 * 13 / 60 / 24
14:55<@DorpsGek>Alberth: 45138.8888889
14:55<@planetmaker>well. also then you can continue to play. Just the year won't advance ;-)
14:55<@Alberth>@calc 45138 / 365
14:55<@DorpsGek>Alberth: 123.665753425
14:56<@Alberth>kind of old nerd :p
14:56<andythenorth>planetmaker: is it an easy change for me to disable cpp step of makefile?
14:56<andythenorth>(to see what happens)
14:56<@Alberth>'touch' the generated output file?
14:57-!-kkb110_ [] has quit [Quit: Leaving]
14:57<@Alberth>although 13 minutes is somewhat optimistic, in reality a game year takes a bit longer
14:57<@planetmaker>well... the dependency also relies on it. But you can edit-out that step. And you'll have to rewrite the rule for the nml file which uses cpp to generated it from the pnml file
14:57<andythenorth>I should learn how to do that anyway
14:57<andythenorth>it's good for me :P
14:57-!-Cybertinus [] has joined #openttd
14:57<@Alberth>make -n ? then copy/paste what you want to run
14:58<Jensen1986>how long is a year in TTD ?
14:58<@planetmaker>~calc 30 * 74 / 60
14:58<@planetmaker>@calc 30 * 74 / 60
14:58<@DorpsGek>planetmaker: 37
14:58<@Alberth>I don't know about TTD
14:58<@Alberth>the number of ticks/day is probably different
14:58<@planetmaker>@calc 0.03 * 74 * 365
14:58<@DorpsGek>planetmaker: 810.3
14:58<@planetmaker>@calc 0.03 * 74 * 365 / 60
14:58<@DorpsGek>planetmaker: 13.505
14:59<@planetmaker>^ minutes in OpenTTD
14:59<@planetmaker>TTD might be 10% faster
14:59-!-Elukka [] has quit []
14:59<Jensen1986>ok. But thanks for all your help. Gotta go.
15:02*andythenorth adventures in makefile
15:02<andythenorth>it's pretty impressive
15:03-!-Jensen1986 [] has quit [Quit: ajax IRC Client]
15:05<@Alberth>You are at a rule that depends on another rule, what do you want to do?
15:12-!-Neon [] has joined #openttd
15:20<@Alberth>planetmaker: how is the closebox X defined in big GUI?
15:20<@Alberth>In the code, it computes maxdim(GetStringBoundingBox(STR_BLACK_CROSS), GetStringBoundingBox(STR_SILVER_CROSS)); as size, while the sticky box does maxdim(GetSpriteSize(SPR_PIN_UP), GetSpriteSize(SPR_PIN_DOWN));
15:20<@Alberth>It looks like the text-sizes are still not functioning
15:20<@Alberth>(while sprites do work)
15:22<@peter1138>i have a wip patch for all that stuff...
15:22*Rubidium wonders what made Jensen think OpenTTD "only" supports 2**32 in money
15:22<@Alberth>he plays TTD ?
15:22<@peter1138>text-sizes are always based on the specified size, not the size of sprites
15:22<@Alberth>(and thinks both games are the same :) )
15:22<@Rubidium>Alberth: in TTD it was 2**31 (you can have negative money as well)
15:23<@planetmaker>Alberth: it's a font sprite iirc
15:24<@planetmaker>the text size calculation might ignore the special chars
15:24<@planetmaker>and... tbh, Alberth, IMHO the X for windows should be a normal sprite, not a font sprite
15:24<@planetmaker>would make it much easier
15:24<@peter1138>it never calculates height
15:25<@Alberth>planetmaker: that also holds for the arrows imho
15:25<@peter1138>problem with making it a sprite is it has a shadow
15:25<@peter1138>and it is recoloured for the news window
15:25<@peter1138>however, i did make all the arrows sprites
15:25<@planetmaker>Alberth: maybe... but the funny thing is: it's not always broken. Like for the sprite picker (newgrf debug)
15:25<@peter1138>"i have a patch for that...."
15:26<@planetmaker>peter1138: the adv. settings currently look ugly with it
15:26<@peter1138>it's never "broken"
15:26<@peter1138>for the windows where it's different, it's always because they have other buttons as well
15:26<@peter1138>so not so "funny"
15:27<@Alberth>planetmaker: it has a sticky button
15:27<@Alberth>planetmaker: I removed the sticky button from the airport toolbar, and it failed
15:28<@Alberth>ie the big size of the sticky button forces the whole titlebar to be high
15:30<@Alberth>(mostly as someone made the X not larger than the pin :p )
15:31-!-JVassie [~James@] has joined #openttd
15:32-!-pjpe [] has joined #openttd
15:38-!-tensai_cirno [~cirno@] has joined #openttd
16:17*andythenorth dismisses XML as a good data format :P
16:17<@Alberth>oh, for machines, it's very good :)
16:17<@Alberth>problem is that people think they are machines too :)
16:17<@Rubidium>for machines it's bad
16:18<andythenorth>needless parsing
16:18<andythenorth>machines like name / value pairs, without endless scaffolding :P
16:18<Rhamphoryncus>How hard is it to add new windows and buttons and such?
16:18<andythenorth>very very very hard
16:18<andythenorth>for me
16:18<@Rubidium>for communication between independently developed systems that needs easy extensibility it's something else
16:19<Rhamphoryncus>andythenorth: you have a lot of experience in openttd innards?
16:19<andythenorth>only the industry bits
16:19<andythenorth>otherwise not
16:19<@Alberth>Rhamphoryncus: new windows (ie making a new unique combinations of buttons and such that fills a rectangle) not so difficult
16:19<Rhamphoryncus>Alberth: *nods*
16:19<andythenorth>XML as an input to newgrf templating would be bonkers
16:19<andythenorth>I'd just end up templating it :P
16:20<@Alberth>making a new button itself is harder, internally lots of size computations are performed
16:20<@Alberth>although for elementary things like a close box it is pretty simple too :)
16:20<@Alberth>as they have a fixed size :)
16:20<Rhamphoryncus>So I have it in for myself
16:21<@planetmaker>Rhamphoryncus: how hard is it to solve \int_{-\infty}^\infty e^{-x^2} dx ?
16:21*Rubidium smells somewhat of a desync
16:21*andythenorth ponders JSON
16:21-!-Brianetta [] has quit [Quit: Tschüß]
16:21<Rhamphoryncus>planetmaker: well that doesn't render in xchat, so I'd say pretty hard is a safe bet ;)
16:21<@planetmaker>it's very hard for most people, I assume. But a minority will find it easy. Maybe a majority here
16:21<@Rubidium>Rhamphoryncus: it renders nicely ;)
16:22<@Rubidium>and it's easy to solve
16:22<@Rubidium>if you know the right tools
16:22*Rubidium points at tungsten
16:22<@Alberth>it looks like something that is most likely easy :)
16:22<Rhamphoryncus>related: loading old savegames is critical, but otherwise it is possible to change what gets saved?
16:23<@Alberth>Rhamphoryncus: that's what savegame versions are for :p
16:23<@planetmaker>that's what savegame versions are for. yes
16:24<Rhamphoryncus>I worry I'd have to overcome a lot of inertia if I overhaul how orders/timetables are managed, since there's so much history in ttd
16:25<@Alberth>oh, it's -(x^2) and not (-x)^2, that makes it much easier :)
16:26<andythenorth>this could use an update :|
16:26<@Rubidium>oh come on... still not pasted in wolfram?
16:27<Rhamphoryncus>Couldn't remember the name, heh
16:28<@Rubidium>it's easy to remember
16:29<@Rubidium>want to see the light? -> old lamps were made with tungsten aka wolfram
16:29<@planetmaker>Alberth: not really nicer. But more often used ;-)
16:29<Rhamphoryncus>Oh is that what it's named after..
16:31<@Alberth>Rhamphoryncus: what kind of new button do you have in mind?
16:31<Rhamphoryncus>Alberth: all of them :P
16:32<andythenorth>hmm interesting:
16:32<andythenorth>so why would that fail to return a result?
16:32<andythenorth>or rather, why would that return 0xFF?
16:32<Rhamphoryncus>I haven't fully decided yet. I've been playing with different approaches to maintaining a schedule
16:32<@planetmaker>0xFF is no valid CB result, andy
16:32<@planetmaker>use the in-built constants
16:32<andythenorth>wonder where I got that from :o
16:33<@planetmaker>like CB_FAILED
16:33<Rhamphoryncus>But I need to handle the current timing in a different way, so I can easily compare across different points in the order list
16:33<@Alberth>Rhamphoryncus: with "button" I mean a really new type of button, like a maximize button or so. If you want variations of existing buttons (eg one with a different text), that's what I consider 'window'
16:34<andythenorth>also it's just bad logic no?
16:34<andythenorth>a graphics chain should always end on graphics
16:34<Rhamphoryncus>New elements might include a way to pick out delays with the mouse, rather than having to enter text for the number of days
16:34<Rhamphoryncus>Mostly just window right now though
16:35<andythenorth>but why would cargo_classes not return a result in range 0-255?
16:35<@Rubidium>you can already set the times without the keyboard
16:35<@Rubidium>(the physical keyboard that is)
16:35<@planetmaker>andythenorth: still, then return the default graphics
16:35<andythenorth>I changed it
16:35<andythenorth>just curious
16:35<andythenorth>it's only happening for Wool cargo
16:36<andythenorth>wondered if the class bitmask was somehow odd?
16:36<Rhamphoryncus>Rubidium: click order, click change time, click...
16:36<@planetmaker>depends on what you want to check, andythenorth
16:36<@planetmaker>if you want to check PAX, rather use
16:36<@planetmaker>cargo_classes & bitmask(CC_PASSENGERS)
16:37<@planetmaker>and then check for 1 and 0 (as default)
16:37<andythenorth>ok so that's the equivalent of an nfo mask?
16:37<@planetmaker>it's simply how boolean logic works in... python
16:40-!-Chris_Booth[ph] [] has joined #openttd
16:40-!-pugi [] has joined #openttd
16:41<andythenorth>if I want to check a range of classes, can I & with a list? :P
16:41*andythenorth guesses not
16:42<@Rubidium>depends whether the classes are a bitmask or not
16:43<@Rubidium>a & b simply returns the intersection of the bits, so you can then relatively easy check whether no bits intersect, at least one bit intersects or all bits intersect
16:44<@Alberth>andythenorth: iirc 'bitmask' is a function that takes a list of bit numbers, and produces a mask
16:44<@Rubidium>(all set bits that is, of 'a' or 'b')
16:44*andythenorth explores NML docs more
16:44*andythenorth guesses that bitmask(list) might be the case
16:45*Alberth wonders how to create a bitmask with a one-liner in Python
16:48<andythenorth>Alberth: are you playing the one line python game? :P
16:48<andythenorth>doesn't always end well
16:48<andythenorth>"just because you could, doesn't mean you should" :)
16:49<@Alberth>at IRC, everything is allowed :p
16:49<andythenorth>feel free then
16:49<andythenorth>Alberth: try rewriting my build script in one line?
16:49-!-TWerkhoven[l] [] has quit [Quit: He who can look into the future, has a brighter future to look into]
16:49<andythenorth>probably possible
16:50<andythenorth>might violate PEP 8 horribly :P
16:50<@Alberth>reduce(lambda x,y:x+y, [1 << n for n in bit_list], 0)
16:50<@Alberth>IRC line length is not sufficient :p
16:52<@Alberth>also I have not really looked at what you are writing, as it constantly says "skip this if you know it already" :)
16:52<andythenorth>allowing for imports to be on another line, I think a grf can be templated and built with one line
16:52<andythenorth>I keep trying not to do tutorial, then I do
16:53<andythenorth>the actual build_script for BANDIT is here:
16:53<Rhamphoryncus>Alberth: is this something a set would solve?
16:54-!-Chris_Booth[ph] [] has quit [Quit: Colloquy for iPhone -]
16:55<@Alberth>Rhamphoryncus: 'this' ?
16:56<Rhamphoryncus>I don't fully understand the discussion so I'm just throwing that out there
16:56<@Alberth>bitmasks are sets in fact, conveniently stored in an integer
16:56<@Alberth>so computers can easily work with it, move it around, etc
16:57<Rhamphoryncus>that I know
16:57<Rhamphoryncus>But you're talking about how to do it in python
16:57-!-frosch123 [] has quit [Remote host closed the connection]
16:58<@Alberth>if you want to go to NFO, you eventually have to go to integer format anyway
16:59<@Alberth>besides, also in Python, integers are faster than generic sets of arbitrary objects
16:59<Rhamphoryncus>of course
16:59<@Alberth>andythenorth: os.path.join(currentdir, "sprites/nml") ---> os.path.join(currentdir, "sprites", "nml") / placement is exactly what os.path.join is for :)
17:00<andythenorth>I should replace those then?
17:00<@Alberth>if (len(sys.argv) > 1): <-- no parentheses around conditions, they are not needed
17:01<andythenorth>oh yes
17:01<andythenorth>I pasted that from an example :P
17:01*andythenorth ducks blame
17:01<andythenorth>is this ok? sys.path.append('sprites/nml') # add to the module search path
17:01-!-Neon [] has quit [Quit: Python is way too complicated... I prefer doing it quickly in C.]
17:01<andythenorth>seems to work
17:01<@Alberth>lines 25/27 have different indent than 30+
17:01<@Alberth>it is however very much not recommended
17:02<@Alberth>you should do it with PYTHONPATH outside the script
17:02<andythenorth>I'm mixing 2s and 4s on spaces. dunno why
17:03<andythenorth>PYTHONPATH -> command line args -m ?
17:03<@Alberth>python 2 or 3 ?
17:03<andythenorth>2.6.x for me
17:04<@Alberth>never used -m
17:04<andythenorth>think I'm reading the docs wrong
17:04<@Alberth>class Trailer: <-- needs inheriting from object then class Trailer(object):
17:05<@Alberth>['refittable_classes'] = standard_class_refits['default']['allow'] <-- why not simple instance vars? self.refittable_classes = ... ?
17:06<@Alberth># used for the purchase menu <-- triple-quoted doc-strings?
17:07<andythenorth>doc-strings for defs?
17:07*Alberth uses epydoc standard for that
17:07<@Alberth>usually the text is longer than the code :)
17:07<andythenorth>I'll read epydoc
17:08<andythenorth>why not simple instance vars? <- for convenience when using them in the template
17:08<andythenorth>it (nearly) everything is in, it's easier
17:08<andythenorth>it / if /s
17:08<@Alberth>vehicles = [Truckid=i,properties=j for i,j in vehicles_dict.iteritems()]
17:08<@Alberth>oh missing parentheses with Truck, sorry
17:09<andythenorth>oh the one line game :)
17:09<andythenorth>let's use a comprehension :P
17:09<andythenorth>they always make me feel smart
17:09<@Alberth>imho these cases make sense
17:09-!-TGYoshi [~TGYoshi@] has quit [Quit: Popidopidopido]
17:10<andythenorth>class Trailer: <-- needs inheriting from object then class Trailer(object) <- this is the only thing I didn't understand so far...?
17:11<@Alberth>you could make constants TRUCK_CAPACITY = 'truck_capacity' and use the upper-case constant everywhere
17:11<andythenorth>I could
17:12<andythenorth>it's worth considering
17:12<@Alberth>class Trailer: is an old-style class, obsolete since 2.0 iirc class Trailer(object): is a new-style class. It behaves nicer
17:12<andythenorth>so it's just explicit what it inherits from?
17:13<@Alberth>no, it is really different, old-style don't inherit from object at all
17:14<@Alberth>in python3, 'object' inheriting is default I think, so there it is "classTrailer:" again :) (but you need to check that, I am not sure)
17:16<@Alberth>your paths at the end also have /-es in them, which should be composed by os.path.join instead (so win* users also have good paths)
17:17<@Alberth>yw, if you want I can take another look at it this weekend or so; this was a quick one
17:17<@Alberth>just let me knwo
17:17<Rhamphoryncus>Augh, FormatString is recursive? And not just one way but multiple ways? I can already hear the headache sneaking up on me
17:17<andythenorth>ok thanks
17:17<@Alberth>time to go to bed :)
17:18<@Alberth>Rhamphoryncus: just make nice strings like in src/lang/english.txt :)
17:18<@Alberth>no need to dig in the details of rendering characters
17:18<@Alberth>good night all
17:19<Rhamphoryncus>I was just exploring how the API works. "a calls b, b calls c, c, calls d, d calls b, b calls b..."
17:19<Rhamphoryncus>Actually that skips several steps I don't understand yet :P
17:19-!-sla_ro|master [~slaco@] has quit [Quit: - free first person shooter based of c&c 3]
17:19<@Alberth>which 'the' API? I am sure there are more than one :)
17:20-!-DDR [~chatzilla@] has joined #openttd
17:21-!-Alberth [] has left #openttd []
17:22<andythenorth>good night
17:22*andythenorth just thought of something truly horrible
17:23<andythenorth>write globals to a file while running the script, then have the templates import them :o
17:23<@Terkhen>going to sleep is not that horrible
17:23<andythenorth>that's disgusting
17:23*andythenorth will go to sleep and stop thinking of python abuses
17:24-!-andythenorth [] has quit [Quit: andythenorth]
17:27<Rhamphoryncus>If you're using exec you can inject them directly, no need for an external file
17:30<valhallasw>why use exec if you have globals()?
17:30<valhallasw>and locals(), but in any case - you have a dict representing all local/global variables
17:33-!-MJP [] has quit [Ping timeout: 480 seconds]
17:36-!-Wolf01 [] has quit [Quit: Once again the world is quick to bury me.]
17:36-!-chester [] has quit [Read error: Connection reset by peer]
17:37<Rhamphoryncus>exec lets you load the templates as a separate file
17:37<@Terkhen>good night
17:40-!-JVassie [~James@] has quit [Ping timeout: 480 seconds]
17:50<Rhamphoryncus>Which "the" API would be whatever timetable_gui.cpp is using.. DrawString, SetDParam, that stuff
17:52-!-Progman_ [] has joined #openttd
17:57-!-Progman [] has quit [Ping timeout: 480 seconds]
17:57-!-Progman_ is now known as Progman
18:12-!-tensai_cirno [~cirno@] has quit [Quit: Leaving]
18:16-!-Cybertinus [] has quit [Remote host closed the connection]
18:21-!-Delirus [] has joined #openttd
18:26-!-Progman [] has quit [Remote host closed the connection]
18:29-!-MNIM [] has joined #openttd
18:35-!-Delirus [] has quit []
18:40-!-pugi [] has quit []
18:58-!-Brianetta [] has joined #openttd
19:06-!-pjpe [] has quit [Ping timeout: 480 seconds]
19:13-!-DOUK [] has joined #openttd
19:13-!-mahmoud [] has quit [Ping timeout: 480 seconds]
19:24-!-pjpe [] has joined #openttd
19:24-!-DOUK [] has quit [Ping timeout: 480 seconds]
19:35-!-peteris [~peteris@] has quit [Quit: Ex-Chat]
19:38-!-cornjuliox [cornjuliox@] has quit [Ping timeout: 480 seconds]
20:15-!-Snail_ [] has joined #openttd
20:35-!-KouDy [~KouDy@] has joined #openttd
20:39-!-Prof_Frink [] has quit [Ping timeout: 480 seconds]
20:39-!-KouDy [~KouDy@] has quit [Read error: Connection reset by peer]
20:39-!-[1]Mark [] has joined #openttd
20:39-!-Mark is now known as Guest1387
20:39-!-[1]Mark is now known as Mark
20:40-!-KouDy [~KouDy@] has joined #openttd
20:40-!-Brianetta [] has quit [Quit: Tschüß]
20:44-!-VIPStephan [] has joined #openttd
20:44<VIPStephan>hi there, anybody awake?
20:47*VIPStephan yawns
20:47<Rhamphoryncus>Unfortunately, but I'm about to fix that. Good night ;)
20:47-!-Rhamphoryncus [] has quit [Quit: Rhamphoryncus]
20:48-!-VIPStephan [] has quit []
20:52-!-Prof_Frink [] has joined #openttd
20:53-!-KritiK [] has quit [Quit: Leaving]
21:48-!-glx [glx@2a01:e35:2f59:c7c0:e8ac:5296:6042:37e7] has quit [Quit: bye]
21:58-!-Hawson [] has quit [Quit: and the slicehost goes down]
22:08-!-perk11 [~perk11@] has joined #openttd
22:18-!-kkb110 [] has joined #openttd
23:19-!-KouDy1 [~KouDy@] has joined #openttd
23:24-!-KouDy [~KouDy@] has quit [Ping timeout: 480 seconds]
23:36-!-cmircea [~cmircea@] has joined #openttd
23:56-!-cmircea [~cmircea@] has quit [Ping timeout: 480 seconds]
23:58-!-perk11 [~perk11@] has quit [Quit: Miranda IM! Smaller, Faster, Easier.]
---Logclosed Fri Feb 03 00:00:08 2012