one painful merge later

This commit is contained in:
Anuken
2018-06-02 00:46:40 -04:00
14 changed files with 290 additions and 4 deletions

View File

@@ -40,7 +40,8 @@ public class DefaultKeybinds {
"chat_history_prev", Input.UP,
"chat_history_next", Input.DOWN,
"chat_scroll", new Axis(Input.SCROLL),
"console", Input.GRAVE
"console", Input.GRAVE,
"block_logs", Input.I,
);
KeyBinds.defaultSection(section, DeviceType.controller,

View File

@@ -151,7 +151,7 @@ public class DesktopInput extends InputHandler{
renderer.minimap().zoomBy(-(int)Inputs.getAxisTapped(section,"zoom_minimap"));
rotation = Mathf.mod(rotation + (int)Inputs.getAxisTapped(section,"rotate"), 4);
Tile cursor = tileAt(control.gdxInput().getX(), control.gdxInput().getY());
if(cursor != null){
@@ -165,6 +165,16 @@ public class DesktopInput extends InputHandler{
&& cursor.block() == Blocks.air){
cursorType = drill;
}
if(recipe == null && !ui.hasMouse() && Inputs.keyDown("block_info")
&& cursor.block().fullDescription != null){
cursorType = hand;
if(Inputs.keyTap("select")){
ui.hudfrag.blockfrag.showBlockInfo(cursor.block());
Cursors.restoreCursor();
cursorType = normal;
}
}
}
if(!ui.hasMouse()) {