#exult@irc.freenode.net logs for 20 Apr 2002 (GMT)

Archive Today Yesterday Tomorrow
Exult homepage


[00:44:53] <-- Colourless has left IRC ("no comment")
[07:03:12] --> mru2k1 has joined #exult
[07:07:56] <-- mru2k1 has left IRC (Client Quit)
[12:30:27] * Darke notes that you know you're completely in 'coding mode' when you automatically correct spelling errors in the psudo-code that you're reading.
[13:06:48] --> wjp has joined #exult
[13:06:48] --- ChanServ gives channel operator status to wjp
[13:06:50] <wjp> hi
[13:06:57] <Darke> Hi.
[13:06:58] <wjp> s/psudo/pseudo/ ;-)
[13:07:34] * Darke points out that every spelling 'flame' needs at least one typo, that's it's. <grin>
[13:07:48] <wjp> hehe :-)
[14:19:08] <-- Kirben has left IRC ("System Meltdown")
[14:20:16] --> Colourless has joined #Exult
[14:20:16] --- ChanServ gives channel operator status to Colourless
[14:20:30] <Colourless> hi
[14:21:33] <Darke> Hi.
[14:24:56] * Darke commits, narrowly avoiding committing the colourless0.cc file he accidentally corrected the 'spelling error' in... <grin>
[14:25:15] <Colourless> so, that is what that comment was about
[14:25:37] <Colourless> it almost took me all of a minute to read the exultbot logs for today there were just 'so' many things said
[14:25:54] <Colourless> and, Darke, i'm betting it's all on your screen right now :-)
[14:27:22] <Colourless> so what was it you changed?
[14:27:36] * Darke looks. "Umm... yeah. Actually I'm missing the 'Colourless has left...' comment off the top of my screen." <grin>
[14:28:33] <Darke> In that colourless0.cc document? s/cupple/couple/ I think. <grin> I grabbed a fresh copy just before committing.
[14:29:18] <Colourless> hmm, doesn't surprise me :-)
[14:29:26] <Darke> To be more pedantic, in that particular statement it should have been s/cupple/number/, but I'm not sufficiently pedantic to think of something like that...
[14:29:34] <Colourless> at least there isn't any 'bugs'... as far as I know :-)
[14:30:24] * Darke wonders how you'd define a 'bug' in pseudocode. <grin>
[14:30:52] <Colourless> well, code that plainly obviously doesn't do what it is intended :-)
[14:31:54] <Darke> Hmm... point.
[14:32:28] * Darke would, personally, consider that to be more of 'what was that guy _smoking_?!?' code. But that's just him. <grin>
[14:32:55] <Colourless> typo's also count as 'bugs' too :-)
[14:33:28] <Colourless> "Take that" ;-)
[14:36:00] <Darke> IMHO, the only buggy pseudocode, is pseudocode that doesn't get the message across in general terms. <grin> Typos or no typos 'fro(i=foo.begin(); i!=foo.end(); ++i)' is as accurate as 'for(...)' provided people realise that it's a for loop, that's all that counts.
[14:36:56] <Colourless> so whould this be a bug:
[14:36:56] <Colourless> shape_dirty = cshape != cframe || pshape != pframe;
[14:37:02] <Colourless> when this was intended:
[14:37:03] <Colourless> shape_dirty = cshape != pshape || cframe != pframe;
[14:39:44] <Darke> Most likely, but if you had 'shap_dirty' rather then 'shape_dirty', IMHO, it would be 'correct' because it's obviously a typo.
[14:40:09] <Darke> Not that it shouldn't be corrected. <grin>
[14:40:54] <Colourless> it was a copy and paste error
[14:41:54] <Darke> Or if someone writes the 'i' so that it looks like a 1 or something, again, not a bug, it's just quick and dirty 'trying to get the point across' code, IMHO. <grin>
[14:42:07] * Darke ahhs.
[14:51:38] <wjp> Darke: Colourless and I kind of figured u8's usecode would be cooperatively multithreaded
[14:51:57] <wjp> (ie., the threads suspends themselves, removing the need for things like timeslices)
[14:52:00] <Colourless> how?
[14:52:20] <wjp> Colourless: we did, didn't we?
[14:52:27] <Colourless> hmm, haven't we discuseed that before? ;-)
[14:52:36] * wjp is just reading ucmachine.txt
[14:52:40] <Colourless> yeah :-)
[14:53:04] <Colourless> reminds me of coming to the same realization about the stack as you did :-)
[14:53:18] <wjp> :-)
[14:55:30] <Darke> (cooperativly multithreaded) How do you mean?
[14:55:43] * Darke hasn't encountered the term.
[14:55:59] <Colourless> each thread has to give up it's processing
[14:56:15] <Colourless> i.e. not pre-emptive
[14:57:34] <Darke> So how do they syncronise?
[14:58:05] * Darke has the suspicion he might be misusing a term.
[14:58:10] <wjp> there's probably some kind of 'wait for' opcode, but we haven't quite figured that out yet
[15:30:18] * wjp is going to play some Geneforge
[15:30:23] <wjp> see you later
[15:30:25] <Colourless> cya
[15:30:28] <-- wjp has left IRC ()
[16:39:19] <Darke> Hmm... very quiet night tonight. <grin>
[16:39:20] <-- Darke has left #exult ()
[17:35:02] --> Fing has joined #exult
[17:36:22] <Fing> tskm
[17:36:26] <Fing> sombody using my nick
[17:36:31] <Colourless> hm hi
[17:36:45] * Fing will ghost him or what the command was again
[17:36:48] <Colourless> there are ways of getting it back :-)
[17:36:56] <Colourless> ghost is one of them
[17:36:59] --- Fing is now known as Fingolfin
[17:37:17] <Colourless> :-)
[17:37:22] --- ChanServ gives channel operator status to Fingolfin
[17:37:26] <Fingolfin> I warned him :-)
[17:37:37] <Colourless> heh
[17:44:26] <Fingolfin> dang what did you guys do with pentagram?!?
[17:44:35] * Fingolfin reads the CVS commit mails
[17:44:53] <Colourless> it's been mostly me as far as I know
[17:45:06] <Fingolfin> dang what did you do with pentagram?!?!
[17:45:15] <Fingolfin> better?
[17:45:20] <Colourless> modified it a bit
[17:45:37] <Colourless> yes it's better
[17:47:09] <-- Fingolfin has left IRC ("bbiab")
[18:06:36] --> Fingolfin has joined #exult
[18:17:43] <Colourless> hmm, most interesting....
[18:18:14] <Colourless> unkcoff.dat contains a set of pointers to functions in u8.exe
[18:18:34] <Colourless> could these be the intrinsic functions?
[18:19:41] <Colourless> omg, they are
[18:20:28] <Colourless> offset 0x124 (0x49 * 2) contains a pointer to Item::Bark(unsigned char *)
[18:21:12] <Colourless> we worked out the intrinsics 0x49 to be display_text
[18:21:25] * Colourless thinks he'll just generate all the intrinsic functions
[18:26:01] <Fingolfin> cool
[18:29:19] <Colourless> now i wonder... since i worked that out... what is left that we do not know about? :-)
[18:32:47] <Fingolfin> we do not know when we implent which feature how?
[18:32:58] <Colourless> :-)
[18:37:06] <Colourless> heh, there is a very good reason why the object pointer is always pushed first with the intrinsics... they are calls to C++ methods
[18:37:31] <Colourless> for instance with get shape, wjps'
[18:37:48] <Colourless> comment is // 0x0D - (OBJ*)
[18:37:56] <Colourless> while the actual function was
[18:38:00] <Colourless> Item::getType(void)
[18:39:25] <Fingolfin> ah
[18:39:31] <Fingolfin> wow, this is a pretty cool finding, Colourless
[18:40:28] <Colourless> all thanks to the u8 debug info :-)
[18:46:33] <Colourless> hmm, i think this is going to be easier if i automate it.
[18:46:42] <Colourless> doing it by hand is taking too long
[19:11:55] <Colourless> oh, what a nice intrinsic...
[19:11:55] <Colourless> "Camera::invertScreen(uchar)",
[19:20:10] <Colourless> done
[20:04:52] <Colourless> hmm, it appears that ObjectID's are by usecode assumed to be a 16 bit ID
[20:05:21] <Colourless> this allowed them to do quite a hack to get the Guardian Speech comments to work.
[20:06:13] <Colourless> it turn out that the speech is played if it finds a flex file with the number the same as the shape of the calling item
[20:07:21] <Colourless> since the guardian doesn't have a item, they hard coded item 666 to indicate that it's the guardian speaking, and to then to assume that the shape num is also 666
[20:08:48] <Colourless> the usecode explictly passes a pointer to a variable on the stack that was set to 666 to the Item::bark() intrinsic
[20:09:08] <Colourless> it would therefor appear that the structure or Item is as follows:
[20:09:14] <Colourless> struct Item {
[20:09:26] <Colourless> unsigned short item_num;
[20:09:27] <Colourless> };
[20:09:28] <Colourless> :-)
[20:10:14] <Colourless> the rest if the item data is stored in a set of arrays (itemcach.dat is these arrays stored)
[20:10:21] <Colourless> s/if/of/
[20:12:51] <Colourless> we need not implement things like that
[21:18:49] <Fingolfin> awesome job, ryan
[21:18:55] * Fingolfin just came back to his KB
[21:19:57] <Colourless> :-)
[21:20:55] <Fingolfin> "TonysBalls" ??? :-)
[21:21:13] <Colourless> eh, i know as much as you do :-)
[21:50:27] --> wjp has joined #exult
[21:50:27] --- ChanServ gives channel operator status to wjp
[21:50:42] <wjp> Colourless: great idea to get the intrinsic names this way :-)
[21:50:51] <Colourless> :-)
[21:51:00] * wjp knew what unkcoff was, but hadn't yet realized we actually knew what those offsets meant :-)
[21:52:23] <Colourless> the offset were just simple Seg::Offset pointeres
[21:52:50] <wjp> I guess that's basically the same format as the debugging info?
[21:53:23] <Colourless> tdump by default outputs thte seg offset and function name on the same line :-)
[21:53:47] <wjp> how convenient :-)
[21:54:15] <Colourless> very :-)
[21:54:37] <Colourless> incidently tdump also outputs in hex :-)
[21:56:07] <wjp> ok, so the first pointer to most intrinsics is 'this'?
[21:56:13] <Colourless> yeah
[21:56:39] <wjp> btw, maybe it would be nice to recreate the u8 classes from the debugging info?
[21:57:03] <wjp> (ie. just collect all member functions somewhere)
[21:57:09] <Colourless> it's possible
[21:58:35] <wjp> time to get back to geneforge :-)
[21:58:36] <Colourless> oddly enough, the Item structure appears to only contain a single unsigned short as it's contents. That is then used as an offset into the actual shape other data in the itemcache arrays
[21:58:54] * wjp nods. That's possible
[22:00:43] * wjp has to go again
[22:00:44] <wjp> see you later
[22:00:47] <-- wjp has left IRC ("Leaving")
[22:21:58] <-- Fingolfin has left IRC ("42")