IRC logs for #opendune on OFTC at 2010-07-12
            
03:14:05 *** glx has quit IRC
03:38:27 *** smoothie has quit IRC
04:07:40 *** smoothie has joined #openDune
05:23:34 *** TrueBrain has quit IRC
05:35:09 *** TrueBrain has joined #openDune
05:35:13 *** ChanServ sets mode: +o TrueBrain
06:17:28 *** tneo has quit IRC
06:17:57 *** tneo has joined #openDune
06:20:27 *** SmatZ- has joined #openDune
06:23:27 *** pm has joined #openDune
06:23:27 *** ChanServ sets mode: +v pm
06:23:48 *** planetmaker has quit IRC
06:23:56 *** SmatZ has quit IRC
06:28:20 *** pm is now known as planetmaker
07:10:58 *** SmatZ- is now known as SmatZ
07:56:58 *** fjb has joined #openDune
07:58:22 <fjb> Moin.
07:59:22 <SmatZ> hello fjb
07:59:40 <fjb> :-)
07:59:50 <TrueBrain> *poing* *poing*
08:00:49 <fjb> Moin TrueBrain my friend.
08:01:42 <TrueBrain> have been up for an hour ... weird ... never been up so early in months :p
08:02:14 <fjb> Me too.
08:02:21 <fjb> Way too early.
08:03:15 <planetmaker> at these temperatures? Rather not. I tend to think I should reverse my day-night cycle
08:04:23 <fjb> Good idea. Thought about the same last night. Sleeping when it is too hot to do anything useful.
08:07:42 <TrueBrain> and I am fucking bored
08:07:43 <TrueBrain> it is terrible
08:09:52 <fjb> You are always bored...
08:10:15 <TrueBrain> well, only when I talk :D
08:10:18 <fjb> Make a bridge over flat station tiles feature. :-)
08:10:32 <TrueBrain> if I would, it wouldn't be accepted
08:10:36 <TrueBrain> so why would I? :)
08:11:10 <fjb> Why would it not be accepted? Would you vote against it?
08:11:16 <TrueBrain> yes :)
08:12:04 <TrueBrain> I don't like that _m has to grow for features that are only used by a handful of people, while all others have to pay the price
08:12:35 <fjb> Is the high not codes anywhere yet?
08:12:40 <TrueBrain> for the same reason I don't like to see things like head-to-head, cargodist/cargodest or IS in trunk :)
08:13:12 <TrueBrain> sorry? Couldn't parse that sentence :)
08:13:32 <fjb> Cargo* is a great feature with the airport noise feature. Also airports start to become useless.
08:14:07 <fjb> Is the high of the things on the map not coded anywhere yet?
08:15:51 <planetmaker> TrueBrain, but none of those features require(s/ed) the map array to grow...
08:16:36 <TrueBrain> fjb: height :)
08:16:41 <planetmaker> besides... if you're bored, you could re-write bananas :-P
08:16:55 <planetmaker> so that it actually becomes possible to have multi-user access to entries
08:16:58 <fjb> Ah, yes, stupid english.
08:16:59 <TrueBrain> fjb: check the _m usage; you will see that there is no room for bridge information on a station tile :)
08:17:31 <TrueBrain> planetmaker: my criteria was not grwoing of map, my criteria is that it becomes bigger/slower for a feature only a handful will use/will like
08:17:38 <TrueBrain> better known as: bloatware
08:17:54 <fjb> Does every tile with a bridge over it have a brigdge bit set?
08:18:28 <planetmaker> probably :-)
08:18:53 <planetmaker> TrueBrain, how can one add features without adding complexity?
08:19:24 <fjb> Modules. Invent lodable modules. :-)
08:19:38 <planetmaker> dll/so support? :-P
08:19:44 <TrueBrain> fjb: dunno really
08:19:50 <TrueBrain> planetmaker: modularity is one solution, yes
08:20:03 <TrueBrain> but the thing I have been saying for years now, what OpenTTD needs, is a way to switch 'gamemodes'
08:20:09 <TrueBrain> where you can select what kind of game you want
08:20:16 <planetmaker> hm
08:20:17 <TrueBrain> from classic, to new shit, and new gameplays
08:20:25 <TrueBrain> I don't like that the old has to die for new
08:20:30 <fjb> Interesting idea.
08:20:34 <planetmaker> that means some fundamental re-write of some common concepts
08:20:39 <TrueBrain> yes
08:21:06 <planetmaker> and it means to exactly do that what this dll guy proposes: to add hooks in zillion of places
08:21:18 <TrueBrain> that would be terrible slow
08:21:18 <planetmaker> which manage a list of routines which hook in there and get used
08:21:28 <TrueBrain> libgpmi is 1 solution to solve it, but it already got thrown out once :p
08:21:29 <planetmaker> e.g. the path finding
08:21:44 <TrueBrain> but yeah, OpenTTD needs modularity
08:21:49 <planetmaker> etc... but difficult to see where to distinguish
08:21:54 <TrueBrain> the one thing I always vouched for, and always tried to write towards
08:21:57 <planetmaker> TrueBrain, in what way conceptually?
08:22:14 <TrueBrain> NoAI is a nice example of modularity in OpenTTD
08:22:25 <TrueBrain> it has very few hooks in the code, just because it has to
08:22:30 <TrueBrain> but it is a seperated process, attached on OpenTTD
08:23:20 <TrueBrain> modularity btw doesn't imply dlls. DLLs are bad, and a cross-platform hell
08:23:49 <TrueBrain> good other example: video/, sound/, music/, blitter/
08:24:06 <TrueBrain> (happens to be stuff I put there :p As I said I always wrote towards that goal ;))
08:24:38 <planetmaker> :-)
08:25:24 <TrueBrain> so, in my opinion, something like cargodist/cargodest will only work when it is attached to OpenTTD, and not part of OpenTTD
08:25:56 <planetmaker> but... how would that work?
08:26:01 <fjb> Will that not end in a synchronisation hell?
08:26:07 <planetmaker> I understand NoAI being separate
08:26:08 <TrueBrain> fjb: does NoAI?
08:26:17 <planetmaker> It's after all some kind of client-interface with the server
08:26:27 <planetmaker> But to modularize the core components?
08:26:31 <TrueBrain> well, not really, it really attaches itself to OpenTTD
08:26:44 <TrueBrain> for cargodist/cargodest it should not be that hard
08:26:52 <TrueBrain> it is just a matter of minimalizing the impact on the current code
08:27:02 <TrueBrain> add 2 hooks: addCargo / removeCargo
08:27:06 <TrueBrain> or I dunno
08:27:14 <TrueBrain> from which it runs in cargodist/cargodest code, which does what ever
08:27:27 <planetmaker> hm...
08:27:31 <TrueBrain> and not like YAPF for example is, tons of hooks all over the place to make it work
08:27:44 <TrueBrain> and yes, it is a painful road
08:27:45 <planetmaker> yes, that's the problem I see.
08:28:03 <TrueBrain> I remember clearly when I started on NoAI, and wanted to remove all old AI stuff ... took me days to find all places
08:28:11 <TrueBrain> kept finding sneaky stuff hidden and tucked away
08:28:12 <TrueBrain> pffff
08:28:15 <planetmaker> how would one reasonably modularize the PF. Which would btw be a good example for a thing easily modularized
08:28:33 <TrueBrain> I would write an API for all pathfinders
08:28:35 <TrueBrain> find their common ground
08:28:38 <TrueBrain> generalize the API
08:28:42 <TrueBrain> and attach the PFs to it
08:28:53 <planetmaker> hm
08:29:09 <TrueBrain> a hell, because the NTP attaches completely different than the YAPF
08:29:16 <TrueBrain> but some goes, for example, for acceleration control
08:29:36 <planetmaker> what does acc have to do with PF?
08:29:47 <TrueBrain> nothing, but it is also something that should be modulair
08:29:54 <planetmaker> or was no such connection implied? :-) Ah
08:30:03 <TrueBrain> some = same
08:30:05 <TrueBrain> lol
08:30:33 <planetmaker> let me guess: you already discussed all this in openttd(.42)?
08:30:46 <TrueBrain> nope
08:30:50 <TrueBrain> haven't done any OpenTTD in ages
08:30:50 <planetmaker> oh?
08:30:55 <planetmaker> well...
08:30:56 <TrueBrain> these ideas are long-standing for me
08:31:17 <planetmaker> But if no one knows about them, how would they know and agree?
08:31:20 <TrueBrain> at some point in the past, I told them all once in one form or another
08:31:24 <planetmaker> and possibly share the vision?
08:31:48 <TrueBrain> first, there are enough clever minds in #openttd to come up with them :p I truly doubt I will be the only one :)
08:31:54 <TrueBrain> second, it will be a pain ass job to do some of them
08:32:05 <TrueBrain> and very ungreatful, as nobody notice the changes :)
08:32:08 <fjb> I find that ideas reasonable.
08:32:35 <TrueBrain> but in all software development: modularize as much as possible, as often as possible :)
08:32:44 <fjb> People will start to notice when new pathfinders etc will arrive after such an interface exists.
08:32:49 <TrueBrain> http://hg.openttd.org/openttd/trunk.hg/raw-file/32cae6a6f788/docs/landscape.html <- fjb: Road, m6 bit 7..6
08:33:01 <TrueBrain> fjb: but do we want yet another pathfinder? :)
08:33:19 <fjb> A good one for ships.
08:33:26 <TrueBrain> I personally btw would start with the console
08:33:40 <TrueBrain> and attach a scripting language to it :)
08:34:04 <planetmaker> TrueBrain, you may not be the only bright mind around
08:34:25 <TrueBrain> fjb: m6 bit 7..6 are free for stations, so yeah, bridges over stations should be easy
08:34:30 <planetmaker> But excellence usually lives better in a communicative environment where ideas are exchanged and developed jointly
08:34:54 <TrueBrain> planetmaker: okay, let me rephrase: I should not be doing anything OpenTTD, else I will lose my social life for good :p
08:35:04 <planetmaker> meh
08:35:11 <planetmaker> That's why you started opendune? ;-)
08:35:16 <fjb> I guess I saw a patch from Peter with bridges over stations once.
08:35:24 <TrueBrain> planetmaker: fair point :)
08:36:24 <planetmaker> honestly your idea about the modularization sound reasonable. And you seem to have an idea how to go for it
08:36:36 <planetmaker> It sounds like something the project could very well profit from mid-term
08:36:53 <planetmaker> (as it clearly is no short-term visible gain)
08:37:03 <planetmaker> similar to Alberth's gui re-vamp
08:37:41 <TrueBrain> well, the GUI stuff is a clear example of adding good modularity :)
08:37:50 <planetmaker> yep
08:37:51 <TrueBrain> but really, I talked about these idea for .. 4 years now? No, 3 I think ..
08:38:00 <planetmaker> :-)
08:38:13 <planetmaker> "Gut Ding will Weile haben" is a German saying
08:38:14 <TrueBrain> as said, I even at one point added libgpmi to the code, which allows exactly this kind of modularity .. although a bit too heavy for OpenTTD :p
08:38:22 <planetmaker> "Good things need time" the approx. translation
08:38:27 <TrueBrain> yup :)
08:38:32 <TrueBrain> brilliant things are instant ;)
08:40:08 <planetmaker> he... so libgpmi was NoAi 0.1? :-)
08:40:25 <TrueBrain> well, a base for it, yes
08:57:06 <TrueBrain> still bored
09:02:05 <planetmaker> have a banana :-P
09:02:19 * planetmaker whistles innocently
09:02:35 <planetmaker> banana split... hmmm
09:03:31 <TrueBrain> hmm
09:03:33 <TrueBrain> sounds like a good idea
10:13:47 *** TB has joined #openDune
10:14:38 *** TrueBrain is now known as Guest2798
10:14:38 *** TB is now known as TrueBrain
10:15:34 *** Guest2798 has quit IRC
12:08:32 *** glx has joined #openDune
12:08:32 *** ChanServ sets mode: +o glx
12:08:49 <glx> hello
12:08:53 <Xaroth|Work> o/
12:31:59 <TrueBrain> damn, f__06F7_0008_0018_D7CD is huge ..
12:35:48 <glx> oh you're back on the code?
12:36:44 <TrueBrain> yeah, slowly getting my free time back :)
12:38:43 <glx> wrapper around damages it seems
12:39:17 <TrueBrain> it seems to walk all units and do something ...
12:39:22 <TrueBrain> just going to C-ifiy it :p
12:39:54 <glx> called by many unknown functions :)
12:47:17 <TrueBrain> some kind of explosion function of some kind
12:47:31 <TrueBrain> all units within a certain distance get damage porpotional to their distance
12:47:36 <TrueBrain> Unit_Damage(u, emu_si >> (loc1E >> 2), 0);
12:47:44 <TrueBrain> where loc1E is distance, and emu_si most likely the 'base' damage
12:50:43 <TrueBrain> 10 lines of code for non-AI ..
12:50:50 <TrueBrain> then a very big blob of AI related code .. blegh
13:33:29 <TrueBrain> hmm
13:33:34 <TrueBrain> if your harvester is standing still
13:33:38 <TrueBrain> euh, no
13:33:42 <TrueBrain> if the AI harvester is standing still
13:33:48 <TrueBrain> and you shoot at it as something that he can drive over
13:33:51 <TrueBrain> he starts to move to you
13:34:00 <TrueBrain> never noticed that
13:35:29 <Xaroth|Work> you didn't?
13:35:33 <Xaroth|Work> best way to get rid of enemy harvester
13:35:41 <Xaroth|Work> get trooper, shoot it, run away to a deserted corner
13:35:43 <Xaroth|Work> let it walk over unit
13:35:44 <planetmaker> <TrueBrain> he starts to move to you <--- yes. Nasty
13:35:48 <Xaroth|Work> harvester trapped
13:35:52 <TrueBrain> lol
13:35:53 <planetmaker> for troopers on sentry
13:35:53 <TrueBrain> nice
13:36:19 <TrueBrain> hmm .. this is odd:
13:36:30 <TrueBrain> - emu_lfp(&emu_es, &emu_bx, &emu_get_memory16(emu_ss, emu_bp, -0x10));
13:36:31 <TrueBrain> - emu_al = emu_get_memory8(emu_es, emu_bx, 0x8);
13:36:32 <TrueBrain> - emu_ax = (int8)emu_al;
13:36:34 <TrueBrain> - emu_cmpw(&emu_ax, emu_get_memory16(emu_ds, 0x00, 0x3A38));
13:36:35 <TrueBrain> - if (emu_ax != emu_get_memory16(emu_ds, 0x00, 0x3A38)) goto l__00EB;
13:36:37 <TrueBrain> - goto l__02EE;
13:36:38 <TrueBrain> (..)
13:36:40 <TrueBrain> -l__0248:
13:36:41 <TrueBrain> (..)
13:36:46 <TrueBrain> - emu_lfp(&emu_es, &emu_bx, &emu_get_memory16(emu_ss, emu_bp, -0x10));
13:36:47 <TrueBrain> - emu_al = emu_get_memory8(emu_es, emu_bx, 0x8);
13:36:49 <TrueBrain> - emu_ax = (int8)emu_al;
13:36:50 <TrueBrain> - emu_cmpw(&emu_ax, emu_get_memory16(emu_ds, 0x00, 0x3A38));
13:36:52 <TrueBrain> - if (emu_ax == emu_get_memory16(emu_ds, 0x00, 0x3A38)) goto l__027D;
13:36:55 <TrueBrain> sometimes, the game is silly
13:37:01 <Xaroth|Work> er o_O
13:37:10 <Xaroth|Work> they failed to take the KISS approach?
13:44:53 <TrueBrain> weird, AIs only hunt you when they are on guard, when they are set there by scenario
13:46:16 <TrueBrain> if (u->targetAttack == 0 || u->actionID != ACTION_HUNT) {
13:46:18 <TrueBrain> if (u->targetAttack != 0) continue;
13:46:19 <TrueBrain> wtf ....
13:46:40 <Xaroth|Work> optimization+++?
13:49:05 <TrueBrain> - if (u->targetMove != 0x0 && u->actionID == 0xB) goto l__029B;
13:49:06 <TrueBrain> - if (u->targetMove != 0x0) continue
13:49:08 <TrueBrain> -l__029B:
13:56:35 <TrueBrain> okay, enough for now :p Ghehe
13:57:06 <Xaroth|Work> heh
19:47:32 *** smoothie has quit IRC
20:41:27 *** Osai^2 has joined #openDune
20:43:15 *** Osai has quit IRC
23:58:34 *** fjb has quit IRC