adonthell-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Adonthell-devel] I'm back !!!


From: Alexandre Courbot
Subject: Re: [Adonthell-devel] I'm back !!!
Date: 18 Feb 2002 14:25:15 +0100

[ ^_^ .... skipped the classic troll .... ^_^ ]

> I'm not totally certain about it, but I guess the input handler has a list
> of KeyListeners, and if your object wants to get notified of keypresses,
> you register it with the handler.
> 
> And if a key is pressed, the handler would just call the keyPressed()
> method of each listener in it's list.
> 
> Then each object could check what key has been pressed, and react
> accordingly.

Wouldn't the same listener thing be possible with queues instead of
callbacks? I quite like it (the listener), and actually it looks like
the system the NeL guys put on (see docs section under
http://www.nevrax.org). But using callbacks in such a section, I fear we
could bring the game to an unstable state (launching callbacks over
callbacks over callbacks and so on until the game freezes or at least
gets severely slowed down). It's certainly doable and efficient with a
proven, extremly well designed system (see, I'm talking about Java here
;)), but anyway we would first have to wonder what advantages it would
have over a more classic queue system for us - I'd say it wouldn't
simplify things a lot.

Alex.
-- 
http://www.gnurou.org





reply via email to

[Prev in Thread] Current Thread [Next in Thread]