Skip to content

Commit 5cfc530

Browse files
committed
2 tiny bugs
1 parent 99c843e commit 5cfc530

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

src/com/mtbs3d/minecrift/provider/MCOpenVR.java

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1864,9 +1864,7 @@ private static void processControllerButtonsOculus(boolean sleeping, boolean gui
18641864
boolean pressedStickLeft = controllerStateReference[LEFT_CONTROLLER].rAxis[k_EAxis_TouchPad].x < -0.5 ;
18651865
boolean pressedStickDown = controllerStateReference[LEFT_CONTROLLER].rAxis[k_EAxis_TouchPad].y < -0.5 ;
18661866
boolean pressedStickUp = controllerStateReference[LEFT_CONTROLLER].rAxis[k_EAxis_TouchPad].y > 0.5 ;
1867-
1868-
1869-
1867+
18701868
rtbX = controllerStateReference[LEFT_CONTROLLER].rAxis[k_EAxis_TouchPad].x;
18711869
rtbY = controllerStateReference[LEFT_CONTROLLER].rAxis[k_EAxis_TouchPad].y;
18721870

@@ -1987,7 +1985,7 @@ private static void processControllerButtonsOculus(boolean sleeping, boolean gui
19871985
mc.vrSettings.buttonMappings[ViveButtons.OCULUS_LEFT_STICK_TOUCH.ordinal()].unpress();
19881986
}
19891987

1990-
if(pressedY && !pressedY) { //handle menu directly
1988+
if(pressedY && !lastpressedY) { //handle menu directly
19911989

19921990
if(pressedLHandTrigger){
19931991
setKeyboardOverlayShowing(!keyboardShowing, null);

src/com/mtbs3d/minecrift/provider/OpenVRPlayer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -991,7 +991,7 @@ else if (item instanceof ItemTool ||
991991
){
992992
tool = true;
993993
}
994-
else if(Reflector.forgeExists()){
994+
else if(item !=null && Reflector.forgeExists()){
995995
String c = item.getClass().getSuperclass().getName().toLowerCase();
996996
//System.out.println(c);
997997
if (c.contains("weapon") || c.contains("sword")) {

0 commit comments

Comments
 (0)