Add Steam input binding groups to tutorial tasks. Release Build 8357.

This commit is contained in:
2024-03-25 03:02:38 -05:00
parent 2f8dee095f
commit 37d738fbf9
9 changed files with 84 additions and 39 deletions
+17 -11
View File
@@ -1056,20 +1056,26 @@ const bool Input::UsingGamepad(){
const bool Input::AxesActive(){
float xAxis=0.f,yAxis=0.f;
for(GamePad*gamepad:GamePad::getGamepads()){
if(gamepad->stillConnected){
if(fabs(gamepad->getAxis(GPAxes::RX))>0.f){
xAxis=gamepad->getAxis(GPAxes::RX);
if(SteamInput()){
if(fabs(game->KEY_SCROLLHORZ_R.Analog())>0.f){
return true;
}
if(fabs(game->KEY_SCROLLVERT_R.Analog())>0.f){
return true;
}
}else{
for(GamePad*gamepad:GamePad::getGamepads()){
if(gamepad->stillConnected){
if(fabs(gamepad->getAxis(GPAxes::RX))>0.f){
return true;
}
if(fabs(gamepad->getAxis(GPAxes::RY))>0.f){
return true;
}
}
if(fabs(gamepad->getAxis(GPAxes::RY))>0.f){
yAxis=gamepad->getAxis(GPAxes::RY);
}
if(xAxis!=0.f||yAxis!=0.f)break; //Found a controller, so we're good to break.
}
}
return xAxis!=0.f||yAxis!=0.f;
return false;
}
void Input::StartVibration(const bool override){