summaryrefslogtreecommitdiff
path: root/Source/Plugins/InputPluginCommon/Src/ControllerEmu.cpp
diff options
context:
space:
mode:
authorJordan Woyak <jordan.woyak@gmail.com>2010-04-29 18:51:04 +0000
committerJordan Woyak <jordan.woyak@gmail.com>2010-04-29 18:51:04 +0000
commit22c2276cef00c92ecaa814c777ab72de86477e90 (patch)
treea3f68bec6cdefcc59eb70cc22061dcfd38619a08 /Source/Plugins/InputPluginCommon/Src/ControllerEmu.cpp
parent81f06220cec97e093d75e862f98e4b2853cd89a7 (diff)
New Wiimote Plugin: Added "Upright Wiimote" option. Fixed a nunchuk problem in ZTP and Wii Sports with some Hacks. Some work on emulated Swing and Speaker (disabled). Fixes/Cleanups. ControllerInterface: Fixed an issue when a DInput device reports the same axis more than once. Fixed some old comments.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5422 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Plugins/InputPluginCommon/Src/ControllerEmu.cpp')
-rw-r--r--Source/Plugins/InputPluginCommon/Src/ControllerEmu.cpp23
1 files changed, 11 insertions, 12 deletions
diff --git a/Source/Plugins/InputPluginCommon/Src/ControllerEmu.cpp b/Source/Plugins/InputPluginCommon/Src/ControllerEmu.cpp
index b15607e5cc..2e6f73b620 100644
--- a/Source/Plugins/InputPluginCommon/Src/ControllerEmu.cpp
+++ b/Source/Plugins/InputPluginCommon/Src/ControllerEmu.cpp
@@ -251,18 +251,15 @@ ControllerEmu::Triggers::Triggers( const char* const _name ) : ControlGroup( _na
ControllerEmu::Force::Force( const char* const _name ) : ControlGroup( _name, GROUP_TYPE_FORCE )
{
- controls.push_back( new Input( "X-" ) );
- controls.push_back( new Input( "X+" ) );
- controls.push_back( new Input( "Y-" ) );
- controls.push_back( new Input( "Y+" ) );
- controls.push_back( new Input( "Z-" ) );
- controls.push_back( new Input( "Z+" ) );
-}
+ controls.push_back( new Input( "Up" ) );
+ controls.push_back( new Input( "Down" ) );
+ controls.push_back( new Input( "Left" ) );
+ controls.push_back( new Input( "Right" ) );
+ controls.push_back( new Input( "Forward" ) );
+ controls.push_back( new Input( "Backward" ) );
+ controls.push_back( new Input( "Modifier" ) );
-void ControllerEmu::Force::GetState( u8* data, const u8 base, const u8 range )
-{
- for ( unsigned int i=0; i<3; ++i,++data )
- *data = u8( ( controls[i*2+1]->control_ref->State() - controls[i*2]->control_ref->State() ) * range + base );
+ settings.push_back( new Setting("Dead Zone", 0, 1, 50 ) );
}
ControllerEmu::Tilt::Tilt( const char* const _name ) : ControlGroup( _name, GROUP_TYPE_TILT )
@@ -287,10 +284,12 @@ ControllerEmu::Cursor::Cursor( const char* const _name, const SWiimoteInitialize
{
for ( unsigned int i = 0; i < 4; ++i )
controls.push_back( new Input( named_directions[i] ) );
+ controls.push_back( new Input( "Forward" ) );
+ controls.push_back( new Input( "Hide" ) );
+ settings.push_back( new Setting("Center", 0.5f ) );
settings.push_back( new Setting("Width", 0.5f ) );
settings.push_back( new Setting("Height", 0.5f ) );
- settings.push_back( new Setting("Top", 0.5f ) );
}