diff --git a/core/src/mindustry/input/DesktopInput.java b/core/src/mindustry/input/DesktopInput.java index 78038a562b..102b77a76b 100644 --- a/core/src/mindustry/input/DesktopInput.java +++ b/core/src/mindustry/input/DesktopInput.java @@ -31,17 +31,17 @@ public class DesktopInput extends InputHandler{ /** Current cursor type. */ public Cursor cursorType = SystemCursor.arrow; /** Position where the player started dragging a line. */ - private int selectX, selectY, schemX, schemY; + public int selectX, selectY, schemX, schemY; /** Last known line positions.*/ - private int lastLineX, lastLineY, schematicX, schematicY; + public int lastLineX, lastLineY, schematicX, schematicY; /** Whether selecting mode is active. */ public PlaceMode mode; /** Animation scale for line. */ - private float selectScale; + public float selectScale; /** Selected build request for movement. */ public @Nullable BuildPlan sreq; /** Whether player is currently deleting removal requests. */ - private boolean deleting = false, shouldShoot = false; + public boolean deleting = false, shouldShoot = false; @Override public void buildUI(Group group){ diff --git a/core/src/mindustry/input/InputHandler.java b/core/src/mindustry/input/InputHandler.java index dee48a2690..714c5afb8f 100644 --- a/core/src/mindustry/input/InputHandler.java +++ b/core/src/mindustry/input/InputHandler.java @@ -62,13 +62,13 @@ public abstract class InputHandler implements InputProcessor, GestureListener{ public boolean isBuilding = true, buildWasAutoPaused = false; public @Nullable UnitType controlledType; - protected @Nullable Schematic lastSchematic; - protected GestureDetector detector; - protected PlaceLine line = new PlaceLine(); - protected BuildPlan resultreq; - protected BuildPlan brequest = new BuildPlan(); - protected Seq lineRequests = new Seq<>(); - protected Seq selectRequests = new Seq<>(); + public @Nullable Schematic lastSchematic; + public GestureDetector detector; + public PlaceLine line = new PlaceLine(); + public BuildPlan resultreq; + public BuildPlan brequest = new BuildPlan(); + public Seq lineRequests = new Seq<>(); + public Seq selectRequests = new Seq<>(); //methods to override diff --git a/core/src/mindustry/input/MobileInput.java b/core/src/mindustry/input/MobileInput.java index 9f719ce7bb..64d8a7960f 100644 --- a/core/src/mindustry/input/MobileInput.java +++ b/core/src/mindustry/input/MobileInput.java @@ -31,29 +31,29 @@ public class MobileInput extends InputHandler implements GestureListener{ /** Maximum speed the player can pan. */ private static final float maxPanSpeed = 1.3f; /** Distance to edge of screen to start panning. */ - private final float edgePan = Scl.scl(60f); + public final float edgePan = Scl.scl(60f); //gesture data public Vec2 vector = new Vec2(), movement = new Vec2(), targetPos = new Vec2(); public float lastZoom = -1; /** Position where the player started dragging a line. */ - private int lineStartX, lineStartY, lastLineX, lastLineY; + public int lineStartX, lineStartY, lastLineX, lastLineY; /** Animation scale for line. */ - private float lineScale; + public float lineScale; /** Animation data for crosshair. */ - private float crosshairScale; + public float crosshairScale; public Teamc lastTarget; /** Used for shifting build requests. */ - private float shiftDeltaX, shiftDeltaY; + public float shiftDeltaX, shiftDeltaY; /** Place requests to be removed. */ - private Seq removals = new Seq<>(); + public Seq removals = new Seq<>(); /** Whether or not the player is currently shifting all placed tiles. */ - private boolean selecting; + public boolean selecting; /** Whether the player is currently in line-place mode. */ - private boolean lineMode, schematicMode; + public boolean lineMode, schematicMode; /** Current place mode. */ public PlaceMode mode = none; /** Whether no recipe was available when switching to break mode. */ @@ -61,7 +61,7 @@ public class MobileInput extends InputHandler implements GestureListener{ /** Last placed request. Used for drawing block overlay. */ public BuildPlan lastPlaced; /** Down tracking for panning.*/ - private boolean down = false; + public boolean down = false; public Teamc target, moveTarget;