[Scummvm-devel] Possible new backend features
max at quendi.de
Sun Jan 29 07:06:04 CET 2006
Am 29.01.2006 um 14:07 schrieb Neil Millstone:
> I'd better introduce myself. I'm Neil Millstone (or agentq) and I
> have written an unofficial DS version of ScummVM, which can be
> found at http://scummvm.drunkencoders.com. You can get the source
> there for the latest released version, so you can see how messy and
> horrible it is. :-)
glad to meet you!
> I have been in contact with sev about getting it into CVS, but
> currently there are several hooks and additions to ScummVM which
> would need adding in a non-port-specific way. I am told this is
> the best place to suggest such things!
Definitely. And it sure would be nice if the DS port could be made
> 1) The backend needs to know the GameID of the game that is
> running. I have different interfaces and tweaks for various games
> to make them nice and usable with the 'pen and buttons' interface,
> and I need to know which game is running to enable the necessary
> tweak. All that would be needed for this is a setGameID() function
> in OSystem.
Please be a bit more specific. What kind of game ID specific features
are we talking about here? Generally I am very reluctant to make such
a change, as it taints the clear separation between backends and
frontends. It would have to be done with utmost care as to not break
our flexibility when it comes to adding/chaning game IDs, for example.
Note that I am not saying we can't do this (and I guess some other
porters might want this, too), but I'd first like to understand the
exact reasons for this need. Then we can think about it and either
figure out another "better" method or go with this one :-). For
example, one thing I learned from "autoconf" is that it's usually
better to check for specific features/needs ("Does this machine have
SDL installed? Is this a little or big endian system?" or "Does this
game require a right mouse button?") rather than relying on generic
things like "Is this Mac OS X? Then it must be big endian" or "Is
this game Monkey Island" -> the first example immediately shows the
danger of this approach, given that we now have Mac OS X running on
Intel machines, too.
> 2) The backend needs to be notified where the current speaking
> character is located. I have a zoomed-in view on the top screen
> and it uses pan-and-scan to move around to show the person who's
> speaking. It works pretty well with the simple hack I
> implemented. This could be implemented for all engines (I assume).
That should be simple enough... Something like a
setFocusTo(int x, int y) or focusOnRect(Rect r)
method, possibly with a matching resetFocus() method. Empty
implementations could be provided by default, and only backends that
are "interested" could make use of it (besides the DS, certain small
screen devices might benefit from this).
> 3) I have added several check boxes to two dialogs. These are a
> left handed option which swaps controls over for those holding the
> stylus in their left hand, and an indy fight controls option, which
> replaces the key mappings on the D-pad to those keys used for
> fighting in Indiana Jones. The two dialogs these appear on are the
> main options dialog you get to from the launcher, and the other is
> the in-game options dialog. It would be handy if there was an
> extra tab to the dialogs that was port-specific, and the backend
> could add gui controls to it.
Left-hand option for a stylus? I always thought those are independent
of your handedness :-).
Anyway, the PocketPC port also adds some control to the in-game
options dialog, I think. It sure would be possible to make a port
specific tab. But again, whenever possible I'd prefer a generic
solution over port specific ones. In the case of the stylus, that's
probably not possible. Not sure about the Indy-fight stuff, since I
haven't quite understood what it's supposed to do... It is a checkbox
that you check just before fighting? Or you simply check it for all
"Indy3/Indy4" games in your game list? Or what?
> 4) The Scumm help screen shows PC keybaord controls, which are
> obviously not accurate on other ports without a keyboard. Perhaps
> it could be possible to send new text to the help dialog? Not
> essential though, as there are other ways round it.
Actually, the current help dialog is rather... limited, to say the
least. Besides being SCUMM specific, it is hard to maintain in its
current state. And indeed, it's specific to desktop machines with
keyboards. Maybe we can come up with a more flexible generic "help
system", consisting of a generic multi-screen help dialog, which
displays arbitrary help texts. Those help texts could be written in a
super simple plain text format. For each game we'd have one such
file, possibly with alternate texts depending on the port. Alas, this
might easily turn into overkill... *g*.
> So, any thoughts on how likely some of these changes are? Or
> perhaps another way of doing this stuff that doesn't require
> changing ScummVM?
I think all of those can be solved, some quickly, some with a bit
more effort required, but none of 'em seem insurmountable.
More information about the Scummvm-devel