mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 03:44:02 +02:00
revert last change (fix for invalid DeviceProxy)
This commit is contained in:
parent
00bea4d274
commit
0d4d5d024e
1 changed files with 3 additions and 3 deletions
|
@ -90,7 +90,7 @@ void UserInputMapper::update(float deltaTime) {
|
|||
bool isActiveModifier = false;
|
||||
for (auto& modifier : modifiersIt->second) {
|
||||
auto deviceProxy = getDeviceProxy(modifier);
|
||||
if (deviceProxy && deviceProxy->getButton(modifier, currentTimestamp)) {
|
||||
if (deviceProxy->getButton(modifier, currentTimestamp)) {
|
||||
validModifiers.push_back(modifier);
|
||||
isActiveModifier |= (modifier.getID() == inputMapping._modifier.getID());
|
||||
}
|
||||
|
@ -99,8 +99,8 @@ void UserInputMapper::update(float deltaTime) {
|
|||
}
|
||||
|
||||
// if enabled: default input or all modifiers on
|
||||
auto deviceProxy = getDeviceProxy(inputID);
|
||||
if (enabled && deviceProxy) {
|
||||
if (enabled) {
|
||||
auto deviceProxy = getDeviceProxy(inputID);
|
||||
switch (inputMapping._input.getType()) {
|
||||
case ChannelType::BUTTON: {
|
||||
_actionStates[channelInput.first] += inputMapping._scale * float(deviceProxy->getButton(inputID, currentTimestamp));// * deltaTime; // weight the impulse by the deltaTime
|
||||
|
|
Loading…
Reference in a new issue