IRC logs for #opendune on OFTC at 2011-08-20
⏴ go to previous day
08:41:15 *** Alberth has joined #openDune
08:41:16 *** ChanServ sets mode: +o Alberth
08:49:43 <Alberth> code makes so much more sense with useful variable names :p
11:23:26 <DorpsGek> SVN: truebrain (r2398) -Add: named all variables of Team
11:23:52 <TrueBrain> Team.targetTile is weird, as it is only used in a boolean kind of way
11:28:36 <Alberth> I think there are more such variables. They get increment, tested against 0, and reset to 0.
11:29:45 <TrueBrain> in this case it is either 0 or a valid tile
11:29:56 <TrueBrain> I assumed the tile was used for pathfinding, but that doesn't seem to be the case
11:30:04 <TrueBrain> I guess they never got that to work or what-ever :P
11:30:12 <TrueBrain> how do you call the remainder of a division?
11:30:51 <TrueBrain> but it has a name .. rfaction?
11:31:20 <Alberth> usually with real divisions only, otherwise remainder, I think
11:31:56 <Alberth> hmm, fraction could be good too
11:32:04 <Alberth> real as in non-integer
11:32:18 <TrueBrain> ah; in this case it is an float hiding as an integer
11:32:23 <Alberth> ie 2 / 3 versus 2.0 / 3
11:33:06 <Alberth> I usually call them whatever it represents with *256 or so base
11:33:56 <TrueBrain> that does not fit in a varaible name :D
11:34:18 <Alberth> that's why they invent doxygen :p
11:34:28 <TrueBrain> still doesn't help me :)
11:34:39 <TrueBrain> I can name it 'flippie' and make an awesome Doxygen comment .. but .. :P:D
11:34:56 <Alberth> but I would call that X, and in the comment describe the unit
11:35:17 <Alberth> ie no fraction_of_x or so
11:35:22 <TrueBrain> I did find out why houseID is stored twice in a Structure
11:35:25 <TrueBrain> in case it takes over :)
11:35:46 <DorpsGek> SVN: truebrain (r2399) -Add: named all variables in Structure
11:35:51 <TrueBrain> I just called the variable buildCostRemainder
11:35:53 <Alberth> ah, of course, so Atreides can build deviators :)
11:35:55 <TrueBrain> I think that is a very clear name :D
11:37:12 <TrueBrain> ugh, Unit has many unknowns .....
11:38:02 * Alberth is not yet accustomed to TrueBrain code conventions and names :)
11:38:35 <TrueBrain> yet you can read most of OpenTTD :D
11:42:02 <TrueBrain> euh ... "tile I am going to now"
11:42:07 <TrueBrain> currentTile is wrong
11:42:11 <TrueBrain> currentGotoTile is weird
11:42:19 <TrueBrain> currentGoal? Sounds odd
11:43:08 <Alberth> 'goal' is 'destroy the enemy' :p
11:43:31 <Alberth> oh, sorry, 'harvest the spice' of course :)
11:52:13 <SmatZ> who controls the spice, controls the universe
11:53:32 <TrueBrain> how are you doing? :)
11:53:49 <SmatZ> fine :) moved to a new flat, buying furniture and stuff :)
12:05:36 <TrueBrain> ugh, speed is weird ..
12:05:42 <TrueBrain> you get a value between 0 and 255
12:05:58 <TrueBrain> now the high 4 bits are shifted down, and you move this multiplied by 16 every time
12:06:01 <TrueBrain> that is perfectly fine
12:06:13 <TrueBrain> now the low 4 bits are shifted up, and it does something with this too ...
12:06:18 <TrueBrain> now that is a bit confusing :D
12:13:03 <Alberth> the compiler was sometimes a bit clever in combining certain values in a single register, I think. Addressing bits with /8 and %8 was also done in a complicated way
12:19:57 <TrueBrain> this seems to allow for slow and fast speeds
12:20:01 <TrueBrain> but it is a bit funny written
12:26:47 <DorpsGek> SVN: truebrain (r2400) -Add: named most variables in Unit. I failed to name one :'(
12:48:45 <DorpsGek> SVN: truebrain (r2401) -Add: named some variables in UnitInfo
12:48:59 <TrueBrain> the flags are annoying as fuck to name :P
12:49:39 <glx> especially the one used to determine in an unnamed variable must be set ?
12:53:26 <DorpsGek> SVN: truebrain (r2402) -Codechange: remove 'unknown' entries, as we now know they are 'notused'
12:53:31 <TrueBrain> I hope this commit works for MSVC glx
12:53:46 <TrueBrain> I now named all variables, except for 3, and a shitload of flags
12:53:50 <TrueBrain> hope that makes it easier to name functions :D
12:56:24 <DorpsGek> SVN: truebrain (r2403) -Codechange: Netbeans refuses to rename entries in a header file, as it doesn't see the two are linked :(
12:58:53 <DorpsGek> SVN: truebrain (r2404) -Fix (r2402): MSVC doesn't like it when you make an uint8 14 bits long; silly :D
12:58:59 <TrueBrain> that should fix it I assume :P
12:59:45 <glx> yes, but you used spaces instead tabs ;)
13:00:24 <DorpsGek> SVN: truebrain (r2405) -Fix (r2404): despite my best efforts, Netbeans always sees the need to replace tabs with spaces at random instances
13:02:28 <TrueBrain> a saboteur can walk over walls, kewl
13:07:08 <DorpsGek> SVN: truebrain (r2406) -Add: named some functions and variables because we know that a certain function is now SetSpeed
13:07:24 <TrueBrain> right, I also have a grasp on g_var_3A3E, it is a struct
13:09:30 <TrueBrain> going to fix that :D
13:11:34 <glx> I'd say [2 - 4] are uint8[6]
13:22:53 <TrueBrain> many are totally unused
13:25:34 <glx> maybe there are conversion errors too
13:42:49 <DorpsGek> SVN: truebrain (r2407) -Add: g_var_3A3E is in fact g_table_landscapeInfo, and a struct. Named as much as possible
13:49:08 <DorpsGek> SVN: truebrain (r2408) -Add: named flag which differs between structure that can and cannot be build on concrete (where concrete is in the latter group)
13:49:51 <DorpsGek> SVN: truebrain (r2409) -Codechange: forgot some documentation
13:53:09 <glx> g_table_landscapeInfo[LST_SPICE].radarColour = 0xD7;
13:53:09 <glx> g_table_landscapeInfo[LST_SPICE].spriteID = 0x35;
13:53:09 <glx> g_table_landscapeInfo[LST_THICK_SPICE].radarColour = 0xD8;
13:53:09 <glx> g_table_landscapeInfo[LST_THICK_SPICE].spriteID = 0x35;
13:53:20 <glx> we could just change the table indeed
13:53:26 <TrueBrain> somehow there is a need for that :(
13:53:46 <TrueBrain> but it is not important enough for me atm to worry about :)
13:53:49 <TrueBrain> too much unnamed shit :P
14:22:52 <TrueBrain> lol @ forum; "in my _original_ version of Dune2 I could skip the security question" (freely quoted)
14:22:58 <TrueBrain> you got to love "original" versions :D
15:23:26 <TrueBrain> doesn't taht go in the project properties? Odd :)
15:23:36 <TrueBrain> but yeah, go for it, if it helps :)
15:31:12 <DorpsGek> SVN: glx (r2410) -Add: enable memory leak detection in MSVC
18:50:01 <vb> where can i get the dune files i need for this mod?
18:51:05 <TrueBrain> he calls this a mod .. I am kinda offended now :D
18:51:12 <TrueBrain> you will need to go and buy Dune2 vb
18:51:54 <glx> it's not that hard to find them
18:52:24 <TrueBrain> any 1.07 will do for english :P
18:52:51 <TrueBrain> Dune2 is not available for free.
18:53:34 <TrueBrain> (well, not in any legal way)
18:53:51 <glx> and legally it's not available either ;)
18:54:22 <glx> unless you have luck in stores selling old stuff
18:57:34 <TrueBrain> most of them will do
18:57:50 <vb> that's not how i remember dune
18:58:06 <TrueBrain> I didn't write the past :)
18:58:22 <glx> opendune is dune2, not dune ;)
18:59:13 <TrueBrain> calling us a mod :( Pfff ...
18:59:19 <glx> he probably played the "RPG" version
continue to next day ⏵