Changeset 1461 for code/branches/network/src/core
- Timestamp:
- May 28, 2008, 8:07:32 PM (16 years ago)
- Location:
- code/branches/network/src/core
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/network/src/core/InputBuffer.h
r1449 r1461 66 66 { 67 67 struct InputBufferListenerTuple newListener = {listener, (void (InputBufferListener::*)())function, true, bOnlySingleInput, false, '\0', KeyCode::Unassigned}; 68 // TODO: this is a major hack!!! 69 // Fix it properly 68 70 *((int*)(&newListener.listener_)) = (int)(listener); 69 71 -
code/branches/network/src/core/InputManager.cc
r1455 r1461 573 573 marginalsMin_[i] = INT_MAX; 574 574 } 575 COUT( 3) << "Move all joy stick axes in all directions a few times. "575 COUT(1) << "Move all joy stick axes in all directions a few times. " 576 576 << "Then put all axes in zero state and hit enter." << std::endl; 577 577 … … 598 598 _completeCalibration(); 599 599 _restoreState(); 600 keyBinder_->resetJoyStickAxes(); 600 601 state_ = IS_NOCALIBRATE; 601 602 stateRequest_ = savedState_; … … 1121 1122 { 1122 1123 setInputState(IS_NODETECT); 1123 COUT( 3) << "Binding string \"" << bindingCommmandString_s << "\" on key '" << name << "'" << std::endl;1124 CommandExecutor::execute(" setKeyBinder " + name + " " + bindingCommmandString_s, false);1124 COUT(1) << "Binding string \"" << bindingCommmandString_s << "\" on key '" << name << "'" << std::endl; 1125 CommandExecutor::execute("config KeyBinder " + name + " " + bindingCommmandString_s, false); 1125 1126 } 1126 1127 … … 1129 1130 bindingCommmandString_s = command; 1130 1131 setInputState(IS_DETECT); 1131 COUT( 3) << "Press any button/key or move a mouse/joystick axis" << std::endl;1132 COUT(1) << "Press any button/key or move a mouse/joystick axis" << std::endl; 1132 1133 } 1133 1134 -
code/branches/network/src/core/KeyBinder.cc
r1446 r1461 621 621 } 622 622 623 void KeyBinder::resetJoyStickAxes() 624 { 625 for (unsigned int i = 8; i < nHalfAxes_s; i++) 626 { 627 halfAxes_[i].absVal_ = 0.0f; 628 halfAxes_[i].relVal_ = 0.0f; 629 } 630 } 631 623 632 void KeyBinder::tickInput(float dt, const HandlerState& state) 624 633 { -
code/branches/network/src/core/KeyBinder.h
r1446 r1461 146 146 void clearBindings(); 147 147 void setConfigValues(); 148 void resetJoyStickAxes(); 148 149 149 150 protected: // functions
Note: See TracChangeset
for help on using the changeset viewer.