diff --git a/Changes.txt b/Changes.txt index bd5295857..c98056fbf 100644 --- a/Changes.txt +++ b/Changes.txt @@ -14,6 +14,15 @@ 3.9.1 to 3.9.2: (August xx, 2013) + * Improved parsing of the DASM lst file for the debugger disassembly; + it sometimes missed constant declarations. + + * Changed 'usemouse' argument from a true/false option to accept + 'always', 'analog' and 'never'. This allows to use the mouse as a + controller under more specific circumstances. The default is + 'analog', which means the mouse is only used to emulate analog-like + devices (paddles, trackball, etc). + * Added ability to use bold fonts within the debugger window, which can be set with the 'dbg.boldfont' commandline argument as well as in the debugger UI Settings dialog. This is useful for those that find the diff --git a/docs/graphics/eventmapping_devsports.png b/docs/graphics/eventmapping_devsports.png index 98253baf8..ff3c663b9 100644 Binary files a/docs/graphics/eventmapping_devsports.png and b/docs/graphics/eventmapping_devsports.png differ diff --git a/docs/index.html b/docs/index.html index 870db8285..9f0c22a11 100644 --- a/docs/index.html +++ b/docs/index.html @@ -1984,8 +1984,10 @@
-usemouse <1|0>
-usemouse <always|analog|never>
Item | Brief description | For more information, see CommandLine |
---|---|---|
Stelladaptor X is | Specifies which virtual port each Stelladaptor/2600-daptor uses (See Advanced Configuration - Stelladaptor/2600-daptor Support) | -saport |
Stelladaptor port order | Specifies which virtual port each Stelladaptor/2600-daptor uses (See Advanced Configuration - Stelladaptor/2600-daptor Support) | -saport |
Use mouse as ... | Allow the mouse to emulate various controllers | -usemouse |
AVox serial port | Described in further detail in Advanced Configuration - AtariVox/SaveKey Support | -avoxport |
Joy deadzone size | Deadzone area for axes on joysticks/gamepads | -joydeadzone |
Digital paddle sensitivity | Sensitvity used when emulating a paddle using a digital device | -dsense |
Digital paddle sensitivity | Sensitivity used when emulating a paddle using a digital device | -dsense |
Mouse paddle sensitivity | Sensitivity used when emulating a paddle using a mouse | -msense |
Allow all 4 ... | Allow all 4 joystick directions to be pressed simultaneously | -joyallow4 |
Grab mouse ... | Keep mouse in window in emulation mode | -grabmouse |
Use mouse as ... | Allow the mouse to emulate various controllers | -usemouse |
Power-on options: Selecting this option shows a dialog whereby
- ROM properties can be temporarily overriden, and joystick/console buttons can be
+ ROM properties can be temporarily overridden, and joystick/console buttons can be
temporarily held down. Selecting options from this dialog will cause all ROMs launched
after that to use those properties you specify. Clicking Defaults will disable
its functionality, and use ROM properties as defined by the ROM itself. The dialog is as
diff --git a/src/emucore/EventHandler.cxx b/src/emucore/EventHandler.cxx
index ee68855e4..d5bef88e7 100644
--- a/src/emucore/EventHandler.cxx
+++ b/src/emucore/EventHandler.cxx
@@ -2020,13 +2020,48 @@ void EventHandler::takeSnapshot(uInt32 number)
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-void EventHandler::setMouseControllerMode(bool enable)
+void EventHandler::setMouseControllerMode(const string& enable)
{
if(&myOSystem->console())
{
delete myMouseControl; myMouseControl = NULL;
- const string& control = enable ?
+ bool usemouse = false;
+ if(BSPF_equalsIgnoreCase(enable, "always"))
+ usemouse = true;
+ else if(BSPF_equalsIgnoreCase(enable, "never"))
+ usemouse = false;
+ else // 'analog'
+ {
+ switch(myOSystem->console().controller(Controller::Left).type())
+ {
+ case Controller::Paddles:
+ case Controller::Driving:
+ case Controller::TrackBall22:
+ case Controller::TrackBall80:
+ case Controller::AmigaMouse:
+ case Controller::MindLink:
+ usemouse = true;
+ break;
+ default:
+ break;
+ }
+ switch(myOSystem->console().controller(Controller::Right).type())
+ {
+ case Controller::Paddles:
+ case Controller::Driving:
+ case Controller::TrackBall22:
+ case Controller::TrackBall80:
+ case Controller::AmigaMouse:
+ case Controller::MindLink:
+ usemouse = true;
+ break;
+ default:
+ break;
+ }
+ }
+
+ const string& control = usemouse ?
myOSystem->console().properties().get(Controller_MouseAxis) : "none";
myMouseControl = new MouseControl(myOSystem->console(), control);
diff --git a/src/emucore/EventHandler.hxx b/src/emucore/EventHandler.hxx
index f6d669896..ab4bd11fd 100644
--- a/src/emucore/EventHandler.hxx
+++ b/src/emucore/EventHandler.hxx
@@ -161,8 +161,10 @@ class EventHandler
the ROM properties, otherwise disable mouse control completely
@param enable Whether to use the mouse to emulate controllers
+ Currently, this will be one of the following values:
+ 'always', 'analog', 'never'
*/
- void setMouseControllerMode(bool enable);
+ void setMouseControllerMode(const string& enable);
/**
Set the number of seconds between taking a snapshot in
diff --git a/src/emucore/OSystem.cxx b/src/emucore/OSystem.cxx
index da508bea9..5750ebf90 100644
--- a/src/emucore/OSystem.cxx
+++ b/src/emucore/OSystem.cxx
@@ -522,7 +522,7 @@ string OSystem::createConsole(const FilesystemNode& rom, const string& md5sum,
//////////////////////////////////////////////////////////////////////////
myConsole->initializeAudio();
myEventHandler->reset(EventHandler::S_EMULATE);
- myEventHandler->setMouseControllerMode(mySettings->getBool("usemouse"));
+ myEventHandler->setMouseControllerMode(mySettings->getString("usemouse"));
if(createFrameBuffer() != kSuccess) // Takes care of initializeVideo()
{
logMessage("ERROR: Couldn't create framebuffer for console", 0);
diff --git a/src/emucore/Settings.cxx b/src/emucore/Settings.cxx
index 4801564d5..7b0880d8a 100644
--- a/src/emucore/Settings.cxx
+++ b/src/emucore/Settings.cxx
@@ -88,7 +88,7 @@ Settings::Settings(OSystem* osystem)
setInternal("combomap", "");
setInternal("joydeadzone", "13");
setInternal("joyallow4", "false");
- setInternal("usemouse", "true");
+ setInternal("usemouse", "analog");
setInternal("dsense", "5");
setInternal("msense", "7");
setInternal("saport", "lr");
@@ -397,7 +397,9 @@ void Settings::usage()
<< " -logtoconsole <1|0> Log output to console/commandline\n"
<< " -joydeadzone