Skip to content

Commit 9a31119

Browse files
ScribbleScribble
authored andcommitted
Closes #119 and closes #121
Removed deprecated stuff
1 parent e30003d commit 9a31119

File tree

2 files changed

+15
-84
lines changed

2 files changed

+15
-84
lines changed

src/main/java/de/scribble/lp/tasmod/inputcontainer/InputContainer.java

Lines changed: 2 additions & 71 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ public class InputContainer {
6868
private BigArrayList<TickInputContainer> inputs = new BigArrayList<TickInputContainer>(directory + File.separator + "temp");
6969

7070
public DesyncMonitoring dMonitor = new DesyncMonitoring();
71-
71+
7272
// =====================================================================================================
7373

7474
private String authors = "Insert author here";
@@ -123,6 +123,7 @@ public String setTASState(TASstate stateIn, boolean verbose) {
123123
return verbose ? TextFormatting.RED + "An error occured while reading the start location of the TAS. The file might be broken" : "";
124124
}
125125
}
126+
Minecraft.getMinecraft().gameSettings.chatLinks = false; // #119
126127
index = 0;
127128
state = TASstate.PLAYBACK;
128129
return verbose ? TextFormatting.GREEN + "Starting playback" : "";
@@ -177,76 +178,6 @@ public TASstate getState() {
177178
return state;
178179
}
179180

180-
@Deprecated
181-
public String setRecording(boolean enabled) {
182-
return setRecording(enabled, true);
183-
}
184-
185-
/**
186-
* Starts/Stops a recording
187-
*
188-
* @param enabled If true: starts a recording, else stops a running recording
189-
* @return Chat message depending on the state
190-
*/
191-
@Deprecated
192-
public String setRecording(boolean enabled, boolean verbose) {
193-
if (state == TASstate.PLAYBACK) {
194-
return verbose ? TextFormatting.RED + "A playback is already running" : "";
195-
}
196-
if (enabled) {
197-
state = TASstate.RECORDING;
198-
} else {
199-
state = TASstate.NONE;
200-
}
201-
202-
if (state == TASstate.RECORDING) {
203-
if (Minecraft.getMinecraft().player != null) {
204-
startLocation = getStartLocation(Minecraft.getMinecraft().player); // TODO #99 Make this a secondary command
205-
}
206-
return verbose ? TextFormatting.GREEN + "Starting the recording" : "";
207-
} else if (state == TASstate.NONE) {
208-
return verbose ? TextFormatting.GREEN + "Stopping the recording" : "";
209-
}
210-
return "";
211-
}
212-
213-
@Deprecated
214-
public String setPlayback(boolean enabled) {
215-
return setPlayback(enabled, true);
216-
}
217-
218-
/**
219-
* Starts/Stops a playback
220-
*
221-
* @param enabled If true: start a playback, else aborts a running playback
222-
* @return Chat message depending on the state
223-
*/
224-
@Deprecated
225-
public String setPlayback(boolean enabled, boolean verbose) {
226-
if (state == TASstate.RECORDING)
227-
return verbose ? TextFormatting.RED + "A recording is already running" : "";
228-
if (enabled) {
229-
state = TASstate.PLAYBACK;
230-
} else {
231-
state = TASstate.NONE;
232-
}
233-
if (state == TASstate.PLAYBACK) {
234-
if (Minecraft.getMinecraft().player != null && !startLocation.isEmpty()) {
235-
try {
236-
tpPlayer(startLocation);
237-
} catch (NumberFormatException e) {
238-
state = TASstate.NONE;
239-
e.printStackTrace();
240-
return verbose ? TextFormatting.RED + "An error occured while reading the start location of the TAS. The file might be broken" : "";
241-
}
242-
}
243-
index = 0;
244-
return verbose ? TextFormatting.GREEN + "Starting playback" : "";
245-
} else {
246-
return verbose ? TextFormatting.GREEN + "Aborting playback" : "";
247-
}
248-
}
249-
250181
// =====================================================================================================
251182
// Methods to update the temporary variables of the container.
252183
// These act as an input and output, depending if a recording or a playback is

src/main/java/de/scribble/lp/tasmod/virtual/VirtualMouse.java

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -54,19 +54,19 @@ public VirtualMouse() {
5454
keyList.put(-100, new VirtualKey("LC", -100));
5555
keyList.put(-99, new VirtualKey("RC", -99));
5656
keyList.put(-98, new VirtualKey("MC", -98));
57-
keyList.put(-97, new VirtualKey("MBUTTON3", -97));
58-
keyList.put(-96, new VirtualKey("MBUTTON4", -96));
59-
keyList.put(-95, new VirtualKey("MBUTTON5", -95));
60-
keyList.put(-94, new VirtualKey("MBUTTON6", -94));
61-
keyList.put(-93, new VirtualKey("MBUTTON7", -93));
62-
keyList.put(-92, new VirtualKey("MBUTTON8", -92));
63-
keyList.put(-91, new VirtualKey("MBUTTON9", -91));
64-
keyList.put(-90, new VirtualKey("MBUTTON10", -90));
65-
keyList.put(-89, new VirtualKey("MBUTTON11", -89));
66-
keyList.put(-88, new VirtualKey("MBUTTON12", -88));
67-
keyList.put(-87, new VirtualKey("MBUTTON13", -87));
68-
keyList.put(-86, new VirtualKey("MBUTTON14", -86));
69-
keyList.put(-85, new VirtualKey("MBUTTON15", -85));
57+
keyList.put(-97, new VirtualKey("MBUTTON4", -97));
58+
keyList.put(-96, new VirtualKey("MBUTTON5", -96));
59+
keyList.put(-95, new VirtualKey("MBUTTON6", -95));
60+
keyList.put(-94, new VirtualKey("MBUTTON7", -94));
61+
keyList.put(-93, new VirtualKey("MBUTTON8", -93));
62+
keyList.put(-92, new VirtualKey("MBUTTON9", -92));
63+
keyList.put(-91, new VirtualKey("MBUTTON10", -91));
64+
keyList.put(-90, new VirtualKey("MBUTTON11", -90));
65+
keyList.put(-89, new VirtualKey("MBUTTON12", -89));
66+
keyList.put(-88, new VirtualKey("MBUTTON13", -88));
67+
keyList.put(-87, new VirtualKey("MBUTTON14", -87));
68+
keyList.put(-86, new VirtualKey("MBUTTON15", -86));
69+
keyList.put(-85, new VirtualKey("MBUTTON16", -85));
7070

7171
this.scrollwheel = 0;
7272

0 commit comments

Comments
 (0)