#exult@irc.freenode.net logs for 22 Feb 2001 (GMT)

Archive Today Yesterday Tomorrow
Exult homepage

[00:35:43] <-- wjp has left IRC ([x]chat)
[01:45:16] <-- chimera|work has left IRC (Arcade laserdisc emulation project. get your CVS account today! http://daphne.rulecity.com)
[06:51:10] <-- mattownby has left IRC (pohl.openprojects.net forward.openprojects.net)
[06:51:15] --> mattownby has joined #exult
[06:58:55] <-- mattownby has left IRC (lackey.openprojects.net king.openprojects.net)
[06:59:02] --> mattownby has joined #exult
[07:23:14] <-- mattownby has left IRC (Laserdisc Arcade Emulation Project: http://daphne.rulecity.com , get your CVS password today! =])
[13:08:16] --> exultbot has joined #exult
[13:09:06] <Colourless> there it is :)
[13:09:29] <wjp> I killed and restarted it
[13:09:53] <wjp> (it was still running)
[13:53:05] <-- Colourless has left IRC (Ping timeout for Colourless[])
[13:56:28] --> Colourless has joined #Exult
[14:20:51] <Colourless> brb
[14:20:54] <-- Colourless has left IRC (brb)
[14:24:34] --> Colourless has joined #Exult
[14:24:51] <Colourless> back
[15:30:35] <wjp> bbl
[15:30:39] <-- wjp has left IRC ([x]chat)
[15:33:48] --> Fingolfin has joined #exult
[15:34:16] <Fingolfin> hiya
[15:34:28] <Fingolfin> hi ryan!
[15:34:30] <Fingolfin> exultbot is back !!!
[15:34:31] <Colourless> hey
[15:34:32] <Fingolfin> hi exultbot
[15:34:50] <Fingolfin> I got it behind me!!!! now I only have to have passed that last exam, and I am done with exams for the next half year
[15:34:57] <Fingolfin> also I didn't perform as good as I hoped...
[15:34:59] <Colourless> wjp doesn't actually know what happened to Exultbot.
[15:34:59] <Fingolfin> then again *everyone* I talked to thought so
[15:35:17] <Fingolfin> strange :(
[15:35:19] <Fingolfin> ?seen wjp
[15:35:19] <exultbot> wjp left IRC around Thu Feb 22 15:30:39 2001 (GMT) ([x]chat)
[15:35:38] <Colourless> [2:07] <wjp> bbl
[15:35:48] <Colourless> [2:07] *** wjp has quit IRC ([x]chat)
[15:35:49] <Colourless> [2:11] *** Fingolfin (Fingolfin@p3EE22548.dip.t-dialin.net) has joined #exult
[15:35:59] <Fingolfin> lol
[15:46:53] <Colourless> i've been thinking about the teleport bug that I caused and I've think i've come up with a bit of a solution
[15:46:57] <Colourless> want to hear it?
[15:50:13] <Fingolfin> yes
[15:50:17] <Fingolfin> please ;)
[15:51:45] <Colourless> ok, instead of passing pointers around everywhere we could create a new class that contains information about an actor/game object and similar.
[15:51:59] <Colourless> When we want to then use that actor we use a method in the new class such as ::get_actor or something that will verify if that actor exists or not
[15:52:11] <Colourless> that way, we never use pointers
[15:53:42] <Fingolfin> well
[15:54:02] <Fingolfin> that boils down to what I suggested, using a smart pointer class ;)) but of course you are right
[15:54:13] <Fingolfin> we could even make it easier to use:
[15:54:24] <Fingolfin> just add a type conversion operator to Actor*...
[15:54:52] <Fingolfin> if the actor does not exist, either we return NULL, or an exception...
[15:55:02] <Fingolfin> it could be used almost transparently
[15:55:08] <Fingolfin> i.e. less code has to be changed...
[15:56:14] <Colourless> i might create an example of the class and email it to the General list
[15:58:14] <Fingolfin> hehe
[15:58:19] <Fingolfin> well, maybe use this as a reference:
[15:58:20] <Fingolfin> class Actor_ref
[15:58:20] <Fingolfin> {
[15:58:20] <Fingolfin> private
[15:58:20] <Fingolfin> Actor *m_actor;
[15:58:20] <Fingolfin> public
[15:58:22] <Fingolfin> Actor_ref(Actor *a) : m_actor(a) { ASSERT(a != 0); }
[15:58:24] <Fingolfin>
[15:58:27] <Fingolfin> Actor *get_actor() const
[15:58:28] <Fingolfin> {
[15:58:30] <Fingolfin> if(m_actor valid...)
[15:58:32] <Fingolfin> return m_actor;
[15:58:34] <Fingolfin> else
[15:58:36] <Fingolfin> return 0;
[15:58:39] <Fingolfin> }
[15:58:40] <Fingolfin>
[15:58:42] <Fingolfin> operator Actor*() const
[15:58:44] <Fingolfin> {
[15:58:46] <Fingolfin> if(m_actor valid...)
[15:58:48] <Fingolfin> return m_actor;
[15:58:50] <Fingolfin> else
[15:58:52] <Fingolfin> throw exception;
[15:58:54] <Fingolfin> }
[15:58:56] <Fingolfin> };
[15:58:58] <Fingolfin> ;)
[15:59:47] <Fingolfin> did I kill you? ;)
[15:59:53] <Colourless> no
[16:00:07] <Fingolfin> that was just some pseudo-code...
[16:00:21] <Fingolfin> i.e. I have no idea how you want to make it detect the actor is gone...
[16:00:32] <Fingolfin> do you want to have the actor keep a list of references to it?!?
[16:00:33] <Colourless> i have a few ideas.
[16:00:42] <Fingolfin> sure ;)
[16:00:50] <Fingolfin> I have no doubt about that
[16:01:06] <Fingolfin> well, I guess you'll just do it and then email to the ML
[16:02:01] <Colourless> each actor is always going to have some amount of unique informatino such as timecreated, location created, it's npc_num and it's pointer.
[16:02:42] <Fingolfin> yes...
[16:03:41] <Colourless> the Actor_ref class would store that information and to check if that actor exists, you'd check through all the game actors and see if one of them is the same.
[16:04:04] <Colourless> if one is the same, your actor still exists
[16:04:52] <Colourless> in that previous line 'one' is actually meant to meant 'one actor'
[16:05:45] <Fingolfin> ok
[16:05:50] <Fingolfin> hmmm
[16:06:10] <Colourless> you are concerned about something?
[16:06:12] <Fingolfin> that could be slow if we have a big lot of actors; how many actors are there on avarage?
[16:06:23] <Fingolfin> I mean, the ref might be used a lot...
[16:06:59] <Colourless> that's where the npc_num is used. The actors are stored in an array
[16:07:20] <Colourless> you don't need to search though the entire array, if you already know where it should be
[16:11:30] <Fingolfin> I see...
[16:11:46] <Fingolfin> hm, I need to look at that code
[16:12:00] <Fingolfin> what about stuff like cows/dragons that is non-unique
[16:12:08] <Colourless> they use a linked list :(
[16:12:09] <Fingolfin> don't they have identicall npc_nums?
[16:12:12] <Fingolfin> ahhhh
[16:12:16] <Fingolfin> but there are finitly many
[16:12:46] <Fingolfin> maybe we could store all actors in a binary tree, and assign to them unique (run-time generated) IDs ?
[16:13:03] <Fingolfin> i.e. the ID could just be 0,1,2,3,4,5,6,... etc.
[16:13:07] <Fingolfin> then use a std::set
[16:13:15] <Fingolfin> but maybe I think much to complicated ;)
[16:13:18] <Fingolfin> just go ahead
[16:13:28] <Fingolfin> we can improve the implementation (if needed at all) later, no?
[16:13:34] <Colourless> yeah.
[16:13:58] <Colourless> There isn't usually too many mosters around, so it shouldn't really be a problem.
[16:14:36] <Fingolfin> yeah
[16:15:23] --> Nadir has joined #exult
[16:15:32] <Nadir> hi
[16:15:36] <Colourless> hi
[16:16:06] <Fingolfin> hi nadir
[16:16:18] <Fingolfin> er,, hi tristan ;)
[16:16:21] <Nadir> I've finally managed to repartition the disk on this new PC
[16:25:55] <Nadir> I still need to fetch the U7/SI files from the backups I made
[16:26:34] <Fingolfin> I see
[16:26:53] <Fingolfin> I hope all goes smooth on that ;)
[16:34:11] <Nadir> I've read things about Exult's instability. Is it still the case ?
[16:41:05] <Fingolfin> well
[16:41:12] <Fingolfin> there is a problem with crashes in teleporting
[16:41:14] <Fingolfin> we now it
[16:41:19] <Fingolfin> ryan is working on a fix
[16:41:45] <Fingolfin> the problem is that if you teleport to another superchunk, actors might get "flushed", i.e. spawned monsters are removed etc.
[16:41:56] <Fingolfin> this could cause pointers to become stale
[16:42:04] <Fingolfin> example: dragon breathes fire ball at you
[16:42:13] <Fingolfin> fire ball has a reference to the dragon.
[16:42:28] <Fingolfin> you teleport; the dragon is gone
[16:42:37] <Fingolfin> the fireball has a stale refernce, and this can cause a crash
[16:42:39] <Fingolfin> or so ;)
[17:00:03] --- Fingolfin is now known as Fingolfin|gone
[17:23:27] <Nadir> bye
[17:23:33] <Colourless> cya
[17:23:37] <-- Nadir has left IRC (I feel like dumping a core)
[17:33:00] <Colourless> i'm off
[17:33:20] <-- Colourless has left IRC (time to go)
[17:58:11] --- Fingolfin|gone is now known as Fingolfin
[19:28:51] --> wjp has joined #exult
[19:29:02] <wjp> hi
[19:46:01] <Fingolfin> lo
[19:46:02] <Fingolfin> !
[19:46:05] <Fingolfin> sorry, was afk
[19:46:19] <Fingolfin> this morning I was here and felt so lonely :(
[19:46:26] <Fingolfin> nobody was in the channel except me!
[19:46:26] <Fingolfin> ;)
[19:46:42] <wjp> I didn't get out of bed until 1pm :-)
[19:46:46] <Fingolfin> not even exultbot... and no chimera and no matt0 ...
[19:46:48] <Fingolfin> hm
[19:46:55] <Fingolfin> that was when *I* begun writing my exam! ;)
[19:46:59] <Fingolfin> you bastard you! ;)
[19:47:10] <wjp> yeah, when I woke up and came in here, I was the only one here too
[19:47:20] <wjp> Ryan entered a few minutes later, though
[19:47:28] <wjp> how'd the exam go?
[19:54:02] <wjp> brb
[19:57:26] <wjp> b
[21:01:14] <Fingolfin> b, too
[21:01:15] <Fingolfin> sorry
[21:01:21] <Fingolfin> my uncle just arrived ;)
[21:01:27] <Fingolfin> that is, he arrived one hour ago
[21:02:26] <wjp> I see
[21:02:42] <wjp> I'm just applying Grant's keybinder patch
[21:02:55] <Fingolfin> cool!
[21:03:12] <wjp> it just moves some stuff around, nothing big
[21:04:05] <Fingolfin> the exam went ok, not too well, though... I think I have maximum of 40/45 of 60 points; but nobody else seems to have more ;) and last year they had the same problem, i.e. they had to reduce the required number of point ;)
[21:04:25] <wjp> what was the exam about?
[21:05:34] <Fingolfin> analysis; we did handle sequences, convergence, series, differentiaon, continuity, etc.
[21:05:40] <Fingolfin> well, analysis ;)
[21:06:04] <wjp> yup, that sounds like analysis alright :-)
[21:06:04] <Fingolfin> actually, there were quite nice problems
[21:06:19] <Fingolfin> but everything was *way* harder than in the exercises
[21:06:51] <wjp> hmmm... :-(
[21:07:00] <Fingolfin> and some of the stuff was never ever handled before... ok I sound like a whiner now, but I really am not, please believe me
[21:07:08] <Fingolfin> I mean, I actually enjoyed the problems
[21:07:16] <wjp> don't worry, I believe you :-)
[21:07:19] <Fingolfin> but I think it was too hard compared to what we actually did
[21:07:44] <wjp> actors.h:338: warning: `Actor::move_aside(Actor *, int)' was hidden
[21:07:44] <wjp> actors.h:545: warning: by `Monster_actor::move_aside(int)'
[21:08:11] <wjp> that last one should probably be (Actor *, int), too, right?
[21:10:38] * wjp yawns
[21:10:45] <wjp> I think I'm going to bed soon
[21:11:37] <wjp> In fact, I'm pretty sure I'm going to bed soon :-)
[21:16:44] <Fingolfin> back
[21:16:48] <Fingolfin> hm
[21:16:53] <Fingolfin> me too ;)
[21:16:55] <Fingolfin> I am really tired
[21:16:56] <Fingolfin> oh oh!
[21:17:04] <wjp> ?
[21:17:06] <Fingolfin> I forgot to commit the fixes I made to exult days ago!
[21:17:22] <wjp> hmm... let me guess... that was one of them?
[21:17:30] <Fingolfin> yes ;)
[21:17:42] <wjp> you did fix several of that type, yes
[21:17:51] <Fingolfin> maybe not that one, though..
[21:17:57] <Fingolfin> I'll just make sure I commit everything
[21:18:00] <wjp> k :-)
[21:18:02] * Fingolfin is updating now
[21:18:08] <wjp> I just committed, btw
[21:18:13] <Fingolfin> "unresolved conflicts in actors.cc" grr ;)
[21:18:15] <Fingolfin> hehe
[21:18:32] <Fingolfin> my own fault, I know ;)
[21:18:36] <wjp> I didn't change anything there :-)
[21:18:56] <Fingolfin> well it was actors.h actually ;)
[21:19:01] <wjp> ok, that was me :-)
[21:24:34] * wjp thinks it's 'soon' now...
[21:24:36] <wjp> goodnight :-)
[21:24:43] <-- wjp has left IRC ([x]chat)
[22:40:35] <-- Fingolfin has left IRC (42)
[23:43:26] --> chimera|work has joined #exult