forked from Clones/Controlify
add controlify.debug.print_trigger_state
debug property
This commit is contained in:
@ -10,6 +10,7 @@ import dev.isxander.controlify.driver.*;
|
||||
import dev.isxander.controlify.rumble.RumbleManager;
|
||||
import dev.isxander.controlify.rumble.RumbleSource;
|
||||
import dev.isxander.controlify.utils.ControllerUtils;
|
||||
import dev.isxander.controlify.utils.Log;
|
||||
import net.minecraft.resources.ResourceLocation;
|
||||
import org.lwjgl.glfw.GLFW;
|
||||
|
||||
@ -90,6 +91,11 @@ public class GamepadController extends AbstractController<GamepadState, GamepadC
|
||||
this.absoluteGyro.add(gyroState);
|
||||
|
||||
state = new GamepadState(deadzoneAxesState, basicState.axes(), basicState.buttons(), gyroState, absoluteGyro);
|
||||
|
||||
if (DebugProperties.PRINT_TRIGGER_STATE) {
|
||||
Log.LOGGER.info("Left Trigger: " + state.gamepadAxes().leftTrigger());
|
||||
Log.LOGGER.info("Right Trigger: " + state.gamepadAxes().rightTrigger());
|
||||
}
|
||||
}
|
||||
|
||||
public GamepadState.GyroState absoluteGyroState() {
|
||||
|
@ -20,6 +20,8 @@ public class DebugProperties {
|
||||
public static final boolean PRINT_GYRO = boolProp("controlify.debug.print_gyro", false, false);
|
||||
/* Print what drivers are being used */
|
||||
public static final boolean PRINT_DRIVER = boolProp("controlify.debug.print_driver", true, true);
|
||||
/* Print the state of the left and right triggers on gamepads */
|
||||
public static final boolean PRINT_TRIGGER_STATE = boolProp("controlify.debug.print_trigger_state", false, false);
|
||||
/* Use experimental anti-snapback */
|
||||
public static final boolean USE_SNAPBACK = boolProp("controlify.debug.use_snapback", false, false);
|
||||
|
||||
|
@ -1,5 +1,8 @@
|
||||
package dev.isxander.controlify.fixes.boatfix;
|
||||
|
||||
/**
|
||||
* @see dev.isxander.controlify.mixins.feature.fixes.boatfix.BoatMixin
|
||||
*/
|
||||
public interface AnalogBoatInput {
|
||||
void setAnalogInput(float forward, float right);
|
||||
}
|
||||
|
Reference in New Issue
Block a user