IRC logs for #opendune on OFTC at 2011-06-21
            
00:29:47 *** fjb is now known as Guest5382
00:29:49 *** fjb has joined #openDune
00:36:46 *** Guest5382 has quit IRC
01:34:38 *** glx has quit IRC
05:13:44 *** Xaroth|Work has quit IRC
05:14:17 *** Xaroth|Work has joined #openDune
05:14:17 *** ChanServ sets mode: +o Xaroth|Work
11:37:46 <DorpsGek> SVN: truebrain (r1842) -Add: named some ObjectInfo / UnitInfo variables
11:40:31 <DorpsGek> SVN: truebrain (r1843) -Fix: documentation glitches
11:43:54 <DorpsGek> SVN: truebrain (r1844) -Add: more naming of UnitInfo variables
11:59:24 <DorpsGek> SVN: truebrain (r1845) -Add: some more UnitInfo work
12:05:30 <DorpsGek> SVN: truebrain (r1846) -Add: move g_teamFindCount and g_teamFindArray out of g_global
12:07:57 <DorpsGek> SVN: truebrain (r1847) -Add: move g_scriptCurrentTeam out of g_global
12:08:30 <DorpsGek> SVN: truebrain (r1848) -Add: remove a now unused function
12:10:30 <DorpsGek> SVN: truebrain (r1849) -Add: move the team array to 32bit/64bit world
12:14:07 <DorpsGek> SVN: truebrain (r1850) -Add: move g_houseFindCount and g_houseFindArray out of g_global
12:14:11 *** glx has joined #openDune
12:14:12 *** ChanServ sets mode: +o glx
12:14:31 <glx> hello
12:14:35 <TrueBrain> morning
12:14:40 <TrueBrain> you interrupted my commit-spree :(
12:18:27 <DorpsGek> SVN: truebrain (r1851) -Add: move g_playerHouse out of g_global
12:19:11 <DorpsGek> SVN: truebrain (r1852) -Fix (r1849): forgot to cleanup an unused parameter
12:23:38 <TrueBrain> for some reason, all savegames have units with houseID=13 in them
12:24:39 <TrueBrain> a carry-all, it seems
12:26:01 <TrueBrain> hmm
12:29:27 <TrueBrain> I can ignore it while loading?
12:31:56 <TrueBrain> LOL! Okay ... think I found it :D
12:32:14 <TrueBrain> we already fixed that :D
12:40:40 <DorpsGek> SVN: truebrain (r1853) -Add: moved the house array to 32bit/64bit world, and fixed up some enhancement, because it had far-going consequences
12:40:42 <TrueBrain> there!! :D:D
12:41:57 <TrueBrain> all house, structure, unit and teams no longer have a csip :D
12:42:06 <TrueBrain> in fact, it no longer is POSSIBLE to use csips on them :D
12:45:09 <glx> nice
12:47:17 <TrueBrain> http://devs.opendune.org/~truebrain/temp.patch
12:47:25 <TrueBrain> what do you think about that? Should I solve it differently?
12:47:28 <TrueBrain> (ignoring global.h ;))
12:47:48 <TrueBrain> that array is only used there, so I dunno if I want to make it a global one
12:48:37 <TrueBrain> on the other hand, we might want to make a TeamActionTypeToString for debugging
12:48:39 <TrueBrain> hmm
12:49:03 <glx> can be local to team.c
12:50:54 <glx> as TeamAction should be in team.h and not unit.h ;)
12:52:55 <TrueBrain> reload
12:52:57 <TrueBrain> something like that?
12:54:44 <glx> looks better like that yes
12:55:22 <TrueBrain> reload again
12:55:36 <TrueBrain> to make clear what is in table/
12:55:51 <TrueBrain> owh, forgot g_ prefix
12:56:07 <TrueBrain> updated
12:58:28 <glx> cleaner yes
12:59:22 <DorpsGek> SVN: truebrain (r1854) -Add: moved g_table_teamActionName out of g_global, and cleaned up a few things related
13:01:50 <DorpsGek> SVN: truebrain (r1855) -Change: renamed tables dir to table
13:03:11 <glx> Erreur 1 error C2034: 'notused_0002' : type de champ de bits trop petit pour le nombre de bits d:\developpement\opendune\trunk\src\team.h 34
13:03:18 <glx> BITTYPE is uint8
13:04:06 <DorpsGek> SVN: truebrain (r1856) -Fix (r1854): MSVC wine wine
13:23:05 <glx> hmm I think I'll extract ActionInfo (this one is easy :) )
13:23:11 <DorpsGek> SVN: truebrain (r1857) -Fix: cleaned up the include tree. It is now a bit more readable. Also removed libemu.h where possible
13:23:23 <TrueBrain> I wonder how to do those Infos
13:23:25 <TrueBrain> in table?
13:23:27 <TrueBrain> or in an ini?
13:23:34 <TrueBrain> I kinda like table/, as then people can't just change it
13:23:50 <glx> table is better
13:24:16 <glx> and some info can be change via ini ;)
13:25:28 <TrueBrain> I am also thinking how to do saving
13:25:33 <TrueBrain> as now the struct is put in the savegame
13:25:42 <TrueBrain> which of course makes converting the csip to void * impossible
13:26:17 <glx> ha of course they are saved, as some objectinfo can change
13:26:30 <TrueBrain> owh, I meant Units
13:26:35 <TrueBrain> can Infos be changed on runtime?
13:26:47 <glx> availability
13:26:58 <TrueBrain> only Unit is saved in the savegame
13:27:00 <TrueBrain> UnitInfo is not
13:27:05 <TrueBrain> so I guess it is recalculated?
13:28:57 <glx> if (s->upgradeLevel >= upgradeLevelRequired) {
13:28:57 <glx> ui->o.available = 1;
13:29:15 <glx> in Structure_GetBuildable()
13:29:42 <TrueBrain> I know; but it doesn't seem to store this info on disk
13:30:13 <glx> no need to store as it's updated on demand
13:55:16 <TrueBrain> right, what-to-do-next
13:55:26 <TrueBrain> hmm .. Info stuff is kinda a bottleneck atm I guess :)
13:56:13 <TrueBrain> I am pretty sure the current layout won't change, only possible the names
13:56:32 <TrueBrain> so either we make a table that is unreadable (just a long matrix of data)
13:56:37 <TrueBrain> or we need a secondary format
13:56:43 <TrueBrain> well, we already said we wanted it in table/
13:56:48 <TrueBrain> so then matrix is best you can get
13:59:00 <glx> http://svn.opendune.org/~glx/temp.patch
13:59:07 <glx> ActionInfo is easy
14:00:14 <TrueBrain> why so many changes in the project?
14:00:18 <glx> dunno
14:00:24 <TrueBrain> anyway, what the issue is here, it is completely unknown what the numbers mean :P
14:00:34 <TrueBrain> I guess it needs comments of some kind
14:00:48 <TrueBrain> maybe move ActionInfo above it
14:00:52 <TrueBrain> and store it in table/actioninfo.h?
14:01:03 <TrueBrain> meh; dunno about that
14:01:04 <glx> Unknown 001 = 1
14:01:04 <glx> Name string reference = Attack
14:01:04 <glx> Action interrupt mode = 0 - Finish action cycle
14:01:04 <glx> Sidebar mode = Select target
14:01:04 <glx> Response sound = 21 - overout.voc
14:04:28 <TrueBrain> http://devs.opendune.org/~truebrain/temp.patch
14:04:32 <TrueBrain> would that be more readable?
14:05:52 <TrueBrain> euh, reload
14:05:54 <TrueBrain> new file was not there :D
14:06:43 <glx> ha yes it's better like that
14:07:02 <TrueBrain> and I would do it in table/actioninfo.h
14:07:10 <TrueBrain> just to not make piles and piles of files
14:07:12 <TrueBrain> euh
14:07:17 <TrueBrain> arrays in files
14:07:19 <TrueBrain> :D
14:07:30 <TrueBrain> going to try to do that for UnitInfo now
14:07:40 <glx> good luck :)
14:07:43 <TrueBrain> tnx
14:07:45 <TrueBrain> need it
14:07:50 <glx> I suggest StructureInfo (smaller)
14:07:57 <TrueBrain> objectInfo first ;)
14:08:11 <glx> OI is used in SI and UI
14:08:16 <TrueBrain> exactly ;)
14:09:28 <TrueBrain> sadly, I can't replace csip32 name with const char *name
14:09:31 <TrueBrain> meh
14:09:32 <TrueBrain> that is annoying
14:09:46 <TrueBrain> or we need to change Load/Save immediatly too
14:09:57 <TrueBrain> owh
14:09:59 <TrueBrain> nevermind
14:10:01 <TrueBrain> this is not saved
14:10:03 <TrueBrain> grr
14:10:06 <TrueBrain> I keep forgetting :D
14:18:02 <TrueBrain> that went pretty smooth tbh ... flags are a worse problem :D
14:19:04 <TrueBrain> what is our tab-size I wonder ... :D
14:20:48 <glx> mine is 4
14:22:14 <glx> http://svn.opendune.org/~glx/temp.patch
14:22:58 <TrueBrain> I like it :D
14:23:02 <TrueBrain> project changes do worry me
14:23:06 <TrueBrain> my next commit will most likely change it again
14:23:25 <TrueBrain> can you find out why they differ?
14:29:57 <glx> <Filter
14:29:57 <glx> Name="tables"
14:29:57 <glx> >
14:29:57 <glx> </Filter>
14:30:01 <glx> is the problem
14:30:06 <TrueBrain> AH!
14:30:09 <TrueBrain> so that was my mistake :D
14:30:26 <glx> should be </Filter> with one tab less
14:30:33 <TrueBrain> tables no longer exist ;)
14:31:07 <glx> so empty dir breaks generate
14:31:39 <glx> I'll check that later
14:32:19 <DorpsGek> SVN: truebrain (r1858) -Fix: wrong filename in doxygen comment
14:33:49 <TrueBrain> so you need to include the table in every file that needs it ..
14:33:50 <TrueBrain> meh
14:34:06 <TrueBrain> I don't like what you did in widget_draw.c btw
14:34:11 <TrueBrain> why move unit.h out of there?
14:34:26 <glx> unit.h must be before the table
14:34:34 <TrueBrain> so? :)
14:34:40 <TrueBrain> how about we add the tables at the bottom of the include list
14:34:45 <TrueBrain> like a newline, then all tables needed?
14:34:53 <glx> good idea
14:35:25 <TrueBrain> aren't the tables duplicated in the executable now?
14:35:58 <glx> they are static
14:36:15 <glx> so I hope the compiler is smart
14:36:51 <TrueBrain> I hope so too ... :D
14:37:53 <glx> without static they are redefined (and compile fails)
14:38:04 <glx> so seems right
14:44:06 <TrueBrain> woei, my table is accepted :D
14:47:13 <TrueBrain> now have to do StructureInfo too .. lol
14:47:15 <TrueBrain> owh well
14:47:19 <Xaroth> :o
14:48:28 <glx> hmm maybe g_actionInfo should be renamed ?
14:48:38 <glx> as it is in table now
14:48:50 <TrueBrain> g_table_ActionInfo
14:48:52 <TrueBrain> sure, go for it
14:50:32 <DorpsGek> SVN: glx (r1859) -Add: made a real table for ActionInfo
14:55:00 <glx> grr sleep.h must be included before math.h unless stdlib.h is included before math.h
14:55:12 <Xaroth|Work> hah, logic in includes!
14:55:15 <TrueBrain> stdlib should always be included before math.h :D
14:55:44 <glx> but stdlib.h is not needed in widget_click.h
14:55:52 <TrueBrain> ah; lol :D
14:56:03 <glx> it is just included via windows.h in sleep.h
14:56:07 <Xaroth|Work> any harm in including it anyhow? for consistency sake?
15:01:15 <glx> http://svn.opendune.org/~glx/temp.patch <-- that's another option
15:02:13 * TrueBrain likes
15:04:32 <Xaroth|Work> I'll follow the expert oppinion there
15:04:33 * Xaroth|Work likes
15:05:23 <TrueBrain> http://devs.opendune.org/~truebrain/temp.patch
15:05:25 <TrueBrain> my turn ;)
15:06:47 <DorpsGek> SVN: glx (r1860) -Fix: MSVC no longer wants sleep.h to be included before math.h
15:07:37 <TrueBrain> better version (refresh)
15:08:38 * Xaroth|Work wonders what g_global->variable_7FAE is for :P
15:08:55 <TrueBrain> newer version (replaced 65535 with -1)
15:09:50 <TrueBrain> something is wrong ... animation is broken
15:10:07 <TrueBrain> ah, yes
15:11:49 <glx> ./* wsa */ "saboture.wsa",
15:11:53 <glx> seems wrong
15:12:16 <TrueBrain> why?
15:13:31 <TrueBrain> hmm
15:13:34 <TrueBrain> clicking starbase fails hard
15:13:56 <TrueBrain> availability of course can't be written now
15:13:57 <TrueBrain> lol
15:14:06 <glx> oh original typo indeed
15:14:21 <TrueBrain> I didn't type any of the information, in case you were wondering :D
15:15:41 <TrueBrain> guess I could have replaced some values with ENUMs
15:15:46 <TrueBrain> but .. something for another day :P
15:16:38 <TrueBrain> found a possible issue with ObjectInfo being in 32bit/64bit world .. hmm ..
15:17:36 <Xaroth|Work> shouldn't the flags also be made... flags?
15:18:04 <glx> Xaroth|Work: not needed they are bools
15:18:11 <TrueBrain> they are flags
15:18:11 <Xaroth|Work> true that
15:18:37 <Xaroth|Work> TrueBrain: you missed the thought-train, but glx was on board :P
15:20:07 <TrueBrain> and I ran into an issue .. hmm ..
15:23:05 <DorpsGek> SVN: truebrain (r1861) -Fix (r1859): g_table_actionInfo is a const table
15:23:26 <glx> ha yes
15:23:34 <TrueBrain> now at least my patch also fails :D
15:23:43 <glx> you'll can't do that for SI and UI
15:23:48 <TrueBrain> we have to
15:23:58 <TrueBrain> so I have to isolate availabe
15:24:08 <TrueBrain> which is rather hard, because it uses a pointer, not an index
15:26:45 <TrueBrain> okay ... need to think about this a bit ...
15:26:52 <TrueBrain> problem is FactoryWindowItem->objectInfo
15:27:01 <TrueBrain> I need a way to break out of thatone
15:27:50 <glx> ReadProfileIni() is a problem too
15:28:24 <TrueBrain> I have no issues removing thatone tbh
15:28:50 <TrueBrain> don't know what you think about it?
15:29:34 <TrueBrain> profile.ini is too restricted to allow real modification anyway .. I can only see it being used to cheat tbh :D
15:29:42 <glx> :)
15:29:58 <Xaroth> what, cheating is bad? :P
15:30:04 <TrueBrain> but if you want to keep it, we have to do this ObjectInfo differently
15:30:10 <TrueBrain> not impossible or anything; just different :)
15:30:38 <TrueBrain> you know what, you two (glx / Xaroth) talk about it, I am going to make food :D
15:30:44 <Xaroth> hah
15:30:57 <glx> it modifies UnitInfo too
15:31:08 <glx> 4 variables in it
15:31:36 <TrueBrain> glx: I say ObjectInfo becuase I can't be arshed to write StructureInfo / UnitInfo all the time :P
15:31:54 <TrueBrain> they all 3 kinda include eachother for any observation ;)
15:31:59 <glx> let's use OI, UI and SI from now :)
15:36:46 <TrueBrain> so, what is it going to be? Xaroth, I expected more from a leadership position :D
15:37:05 <TrueBrain> do we want profile.ini to overwrite certain values, or are we going compiled-in static for now, and do such things later?
15:37:15 <Xaroth> tbh I'd say be gone with profile.ini.. for now
15:37:24 <Xaroth> we'll want a proper interface for that anyhow, not some silly ini file..
15:38:07 <Xaroth> btw, i see nyer's ini list has some variables that we have left unnamed in unitInfo... but from what I can see, those are a bit hard to verify :P
15:44:09 <Xaroth> that list names variable_0020 (above hasTurret) as 'worm camouflage' .. but that doesn't explain why sonic blast has it
15:45:24 <glx> problem is the order in this list is not the real order
15:45:44 <Xaroth> the values match :)
15:56:16 <glx> ha right, but there are duplicates
15:57:04 <TrueBrain> okay, glx, if I get it right what we did now:
15:57:10 <TrueBrain> every file that needs actionInfo includes the table
15:57:12 <TrueBrain> which is a static const
15:57:20 <TrueBrain> so it optimizes it without pointers, and uses the value (most likely)
15:57:27 <TrueBrain> but every file duplicates the data
15:57:36 <TrueBrain> as 2 .c files have no way of knowing the data is shared with the other
15:57:45 <glx> not nice
15:57:58 <TrueBrain> I also realise how OpenTTD did that: NODEF
15:58:00 <TrueBrain> :P
15:58:21 <glx> you mean VARDEF ?
15:58:25 <TrueBrain> ah, yes
15:58:27 <TrueBrain> sorry :D
15:58:30 <TrueBrain> is 'extern' most of the time
15:59:02 <glx> so table file should be .c
15:59:20 <TrueBrain> hmm
15:59:23 <TrueBrain> I like that idea tbh
16:00:00 <glx> trying something
16:00:13 <TrueBrain> we can put ActionInfo in table/actioninfo.h
16:00:19 <TrueBrain> and the table itself in table/actioninfo.c
16:01:25 <TrueBrain> (also increases compile-speed :D)
16:07:18 <glx> or something like http://svn.opendune.org/~glx/temp.patch
16:14:41 <TrueBrain> missing file :D
16:15:22 <glx> where ?
16:15:29 <glx> it's an svn move
16:15:56 <TrueBrain> doesnt show up :D
16:15:59 <TrueBrain> but I guess no changes then
16:16:05 <glx> I just renamed .h into .c
16:16:25 <TrueBrain> hmm .. why not name it _table_ anymore?
16:16:26 <TrueBrain> it still is?
16:17:03 <glx> it still table but declared outside table
16:17:22 <TrueBrain> but yeah, lets go for something like that
16:17:35 <TrueBrain> also solves the g_unitInfo for now, so
16:18:03 <glx> and that prevent some include mess :)
16:18:41 <glx> hmm I'll readd _table_
16:19:28 <glx> so it's easier to find where it's defined
16:21:11 <TrueBrain> yup :)
16:22:50 <DorpsGek> SVN: glx (r1862) -Fix (r1859): defining tables in headers is not a good idea
16:29:58 <TrueBrain> bah; starport still crashes
16:31:32 <glx> because it changes OI ?
16:31:38 <DorpsGek> SVN: truebrain (r1863) -Fix: filename in WSA_LoadFile is a const
16:33:48 <TrueBrain> because of moving it to 32bit world
16:33:59 <TrueBrain> FactoryWindowItem->objectInfo is 16bit
16:34:27 <TrueBrain> by the looks it is the only one
16:34:36 <glx> oh of course
16:34:41 <glx> it's a csip32 :=
16:35:49 <glx> I can move this array outside global and convert it to "real" world
16:36:03 <TrueBrain> its the only way
16:36:21 <glx> ok I do that now then
16:36:26 <TrueBrain> kewl
16:36:29 <TrueBrain> will do the other table files now
16:41:06 <TrueBrain> bah; NUM_VOICES define no longe rworks than of course
16:41:10 <TrueBrain> alsoa bit silly tbh
16:44:35 <DorpsGek> SVN: truebrain (r1864) -Fix: define tables in headers is not a good idea (part due)
16:55:06 <glx> http://svn.opendune.org/~glx/temp.patch <-- it compiles (that's a good start)
16:56:56 <TrueBrain> why free/malloc?
16:57:19 <glx> why not :)
16:58:43 <TrueBrain> rest reads good :)
16:58:54 <TrueBrain> but why I ask about free/malloc: the size is already known at compile-time, not?
16:58:56 <TrueBrain> so why not use that?
16:59:02 <glx> true
16:59:28 <glx> I'll change that after (I'm removing more stuff from g_global)
17:11:49 <glx> refreshed
17:12:50 <TrueBrain> looks good
17:12:57 <TrueBrain> does construction still works?
17:13:12 <glx> I checked starport
17:13:41 <TrueBrain> k k :)
17:13:57 <TrueBrain> ./* 0007(4) */ struct ObjectInfo *objectInfo; /*!< ?? */
17:13:59 <TrueBrain> disaligned
17:14:51 <glx> fixed :)
17:15:23 <TrueBrain> go for it
17:18:40 <DorpsGek> SVN: glx (r1865) -Add: moved factoryWindowItems[] and other factoryWindow related variables out of g_global and to 32bit/64bit world
17:20:23 <TrueBrain> fuck; removed the unitInfo tables without saving them :D
17:20:32 <TrueBrain> and I lost the code for the UnitInfo :D
17:20:44 <TrueBrain> lets see if the online one is still good enough :P
17:20:51 <glx> outch
17:21:18 <glx> I have one open in firefox
17:22:50 <TrueBrain> I think I got them ..
17:24:01 <glx> http://devs.opendune.org/~glx/temp.patch <-- it's there if you need it
17:25:02 <TrueBrain> compiling ....
17:27:10 <TrueBrain> works :D
17:27:18 <glx> yeah
17:29:55 <TrueBrain> meh; whitespace hook
17:30:07 <glx> hihi
17:31:09 <DorpsGek> SVN: truebrain (r1866) -Add: made a table for g_table_unitinfo and g_table_structureinfo
17:31:13 <TrueBrain> there we go
17:33:10 <TrueBrain> guess HouseInfo is next ..
17:33:56 <TrueBrain> seems simple enough :D
17:38:02 <TrueBrain> compiling ...
17:38:03 <TrueBrain> :D
17:40:00 <glx> hmm I could do g_map
17:43:41 <TrueBrain> go for it
17:46:39 <DorpsGek> SVN: truebrain (r1867) -Add: made a table for g_table_houseInfo
17:55:44 <DorpsGek> SVN: truebrain (r1868) -Fix: align comments
18:08:00 <DorpsGek> SVN: truebrain (r1869) -Add: made StructureInfo / UnitInfo constants as much as possible
18:10:22 <TrueBrain> const correctness ftw
18:10:27 <TrueBrain> 3 places where it isn't
18:12:37 <TrueBrain> what-to-do-next
18:12:38 <TrueBrain> hmm
18:12:52 <TrueBrain> I had a reason I wanted UnitInfo like this .. I just can't remember :D
18:13:16 <TrueBrain> guess it is time to remove wcsip
18:19:01 <DorpsGek> SVN: truebrain (r1870) -Add: replace a csip with a real pointer
18:26:25 <TrueBrain> bah; game crashes now :(
18:27:01 <TrueBrain> when game finishes, weird stuff happens
18:27:41 <TrueBrain> more 16bit pointers hiding I guess
18:29:53 <DorpsGek> SVN: truebrain (r1871) -Fix: more converting to real [ointers
18:30:19 <TrueBrain> well, editbox.c is finished
18:30:23 <TrueBrain> now where does this bug hides ...
18:33:18 <TrueBrain> I can't find why it would crash :s
18:34:08 <TrueBrain> happens while fire
18:35:02 <TrueBrain> well, gone for a few
18:35:06 <TrueBrain> will try to find it after that :D
18:35:14 <TrueBrain> Unit_CreateBullet seems the cause, so ..
18:35:15 <TrueBrain> hat is odd
18:39:37 *** Alberth has joined #openDune
18:39:38 *** ChanServ sets mode: +o Alberth
18:57:26 <glx> I have crash here too
18:57:56 <glx> ERROR: unable to open file 'MENSHP.ENG'.
19:00:10 <glx> but this file doesn't exist
19:00:30 <Alberth> so that's good :p
19:01:21 <Alberth> why is src/table/*.h a bad idea?
19:02:54 <glx> my guess is the fault is in r1867
19:05:58 <Alberth> [r1862] glx: -Fix (r1859): defining tables in headers is not a good idea <-- so that's why you started moving things around 8 revisions earlier :p
19:06:36 *** TB has joined #openDune
19:06:48 <glx> [17:57:07] <TrueBrain> okay, glx, if I get it right what we did now:
19:06:48 <glx> [17:57:12] <TrueBrain> every file that needs actionInfo includes the table
19:06:48 <glx> [17:57:15] <TrueBrain> which is a static const
19:06:48 <glx> [17:57:23] <TrueBrain> so it optimizes it without pointers, and uses the value (most likely)
19:06:48 <glx> [17:57:29] <TrueBrain> but every file duplicates the data
19:06:49 <glx> [17:57:39] <TrueBrain> as 2 .c files have no way of knowing the data is shared with the other
19:06:52 *** tneo- has joined #openDune
19:06:52 <glx> that's why :)
19:07:37 *** pm has joined #openDune
19:07:37 *** ChanServ sets mode: +v pm
19:07:59 <DorpsGek> SVN: glx (r1872) -Fix (r1867): use a char when a char is needed
19:08:59 <Alberth> yeah, including a table more than once is a bad idea :p
19:09:18 *** Osai^2 has joined #openDune
19:09:31 <glx> what's this invasion ???
19:10:38 <Alberth> some chat server came back online? :)
19:11:09 <pm> ;-) haydn obviously did something unexpected...
19:11:32 *** planetmaker has quit IRC
19:11:32 *** Osai has quit IRC
19:11:32 *** tneo has quit IRC
19:11:32 *** TrueBrain has quit IRC
19:11:35 *** pm is now known as planetmaker
19:11:53 <glx> was just a split indeed
19:45:18 *** TinoDidriksen has quit IRC
19:45:32 *** TinoDidriksen has joined #openDune
19:50:07 <Alberth> 32 units?
19:50:18 <Alberth> (max)?
20:16:43 <DorpsGek> SVN: alberth (r1873) -Fix(r1827): Code style fix.
20:49:45 <DorpsGek> SVN: alberth (r1874) -Add: Named two functions.
20:54:12 *** tneo- is now known as tneo
21:02:22 <DorpsGek> SVN: glx (r1875) -Add: renamed g_map to g_mapSpriteID and replaced g_global->mapPointer with g_map
21:02:40 <glx> that removes a lot of indirections
21:07:40 <Alberth> I can imagine :)
21:15:30 <glx> http://svn.opendune.org/~glx/temp.patch <-- some cleanup
21:17:55 <Alberth> segments make such a mess :)
21:22:24 *** TB is now known as TrueBrain
21:23:32 <glx> hmm I think I can remove a little more
21:23:39 <TrueBrain> glx: lo @ 1872 .. I did check most of them :D Missed one .. bah :P
21:23:55 <glx> it was well hidden
21:23:58 <TrueBrain> Alberth: and yeah ... you only need to include the table once, which kinda went wrong really quick :D Reminded me of the issues with OpenTTD :)
21:24:05 <glx> *(uint16 *)emu_get...
21:24:10 <glx> hard to spot
21:24:28 <TrueBrain> many were like that
21:24:32 <TrueBrain> about 30% was [0], rest was *
21:24:37 <TrueBrain> (well, without the uint16 cast :P)
21:24:51 <glx> or was it *(char *)
21:25:00 <glx> anyway it's fixed
21:28:57 <glx> what do you think about my cleanup ?
21:29:35 <TrueBrain> I was tihnking about it, but I was afraid it would mess up some static memory address somewhere
21:30:07 <TrueBrain> but if you tested it
21:30:09 <TrueBrain> go-for-it
21:30:19 <glx> I don't see why it would be a problem
21:30:31 <TrueBrain> I didn't want to test it tbh :D
21:31:00 <TrueBrain> why remove the Map_GetTileByPosition wrapper btw?
21:31:27 <glx> I don't see the need for a wrapper to do &g_map[position]
21:31:41 <TrueBrain> can be useful for later stages, but yeah.. at least it is unified now :D
21:32:23 <DorpsGek> SVN: glx (r1876) -Fix: some cleanup
21:33:13 <glx> now g_global->animations
21:36:28 <DorpsGek> SVN: alberth (r1877) -Add: Renamed Map_B4CD_0C36 to Map_FixupSpiceEdges, removed global array 255E.
21:37:26 <Alberth> good night
21:37:36 <Xaroth> nn
21:38:54 *** Alberth has left #openDune
22:01:47 <glx> hmm memcpy(&emu_get_memory8(0x29E8, 0xA, 0x0), g_global->variable_2179, 36); can be removed in GameLoop_GameIntroAnimationMenu() I think
22:02:50 <glx> it copies something to s_input_local->mouseCoord which is no longer there :)
22:14:54 <DorpsGek> SVN: glx (r1878) -Cleanup (r1768): some leftover
22:19:20 <TrueBrain> k, one of my savegames still segfaults
22:21:37 <TrueBrain> action of -1
22:21:38 <TrueBrain> lol
22:22:01 <glx> buggy savegame
22:22:08 <TrueBrain> nope, always worked
22:22:12 <TrueBrain> so something is wrong in conversion
22:23:22 <TrueBrain> ui->actionID is -1
22:24:05 <TrueBrain> that can indeed happen, according to the unitInfo
22:24:42 <TrueBrain> ah
22:24:42 <DorpsGek> SVN: glx (r1879) -Add: moved animations and variable_395A out of g_global
22:24:44 <TrueBrain> lol
22:24:46 <TrueBrain> ACTION_INVALID
22:24:48 <TrueBrain> :D
22:25:29 <glx> hehe
22:25:43 <TrueBrain> 0xFF vs 0xFFFF
22:25:45 <glx> indeed it's invalid
22:26:13 <TrueBrain> I wonder why it was never before any issue
22:26:15 <TrueBrain> euh, how to solve it ..
22:27:05 <TrueBrain> not THAT easy tbh
22:27:46 <TrueBrain> we have one entry that is an uint8, the other that is an uint16
22:28:13 <glx> I don't find ui->actionID
22:28:18 <TrueBrain> actionAI
22:28:19 <TrueBrain> sorry
22:28:22 <glx> ha
22:28:33 <TrueBrain> it already were uint16 vs uint8 compares
22:28:36 <TrueBrain> but for some reason it worked
22:29:55 <DorpsGek> SVN: truebrain (r1880) -Fix: ACTION_INVALID is 0xFF, despite it (sometimes) being uint16
22:29:59 <TrueBrain> solved it temporary in this way
22:30:02 <TrueBrain> don't really like it, but it has to do
22:30:33 <glx> just use enum
22:31:11 <TrueBrain> we use no enums in table/ yet
22:31:15 <glx> and change type to ActionType in both
22:31:21 <TrueBrain> we do need to convert that some day, but that will be an include hell
22:31:34 <TrueBrain> and you can't change to ActionType yet, as this struct is stored on disk
22:31:37 <TrueBrain> so it matters a lot what it is
22:31:54 <TrueBrain> hence, "but it has to do" :D
22:32:03 <TrueBrain> we come back to that when we fixed save/load mechanics :)
22:34:07 <TrueBrain> what to do with FileInfo. Atm it is local to file.c. So table/fileinfo.c is not really possible. Maybe make it global?
22:36:18 <glx> that's the only viable way
22:37:37 <glx> hmm seems it's not filed at start, or I'm wrong
22:38:28 <TrueBrain> it is partly
22:40:31 <TrueBrain> now realise one mistake in the export
22:40:36 <TrueBrain> it has no indication of index :D
22:40:43 <TrueBrain> I should have added /* 0 */ etc
22:40:45 <TrueBrain> for every element
22:40:50 <glx> hehe
22:41:14 <glx> ha yes FileInfo contais filename and filesize
22:41:38 <TrueBrain> both runtime (shared) information as static :P
22:41:41 <TrueBrain> its funny ..
22:41:43 <TrueBrain> should be split tbh
22:48:29 <DorpsGek> SVN: truebrain (r1881) -Add: number the entries in table/ for easy lockup
23:09:30 <DorpsGek> SVN: truebrain (r1882) -Add: made a table for g_table_fileInfo
23:09:35 <TrueBrain> and another one
23:09:37 <TrueBrain> enough for tonight :)
23:11:49 <DorpsGek> SVN: glx (r1883) -Add: moved tickHouseXXX out of g_global
23:13:54 <glx> oh nice filesize is arbitrary