Skip to content

Commit d8e0312

Browse files
Remove ARS sign check from manual room seeding process
Eliminated the ARS sign check and related code from TARDISRoomCommand, TARDISRoomSeeder, and TARDISSeedData. This simplifies the room seeding logic by no longer tracking or validating the presence of an ARS sign when manually growing rooms.
1 parent 686eef0 commit d8e0312

File tree

3 files changed

+6
-18
lines changed

3 files changed

+6
-18
lines changed

src/main/java/me/eccentric_nz/TARDIS/commands/tardis/TARDISRoomCommand.java

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,10 @@
2121
import me.eccentric_nz.TARDIS.blueprints.TARDISPermission;
2222
import me.eccentric_nz.TARDIS.builders.utility.TARDISZeroRoomBuilder;
2323
import me.eccentric_nz.TARDIS.database.data.Tardis;
24-
import me.eccentric_nz.TARDIS.database.resultset.*;
24+
import me.eccentric_nz.TARDIS.database.resultset.ResultSetCondenser;
25+
import me.eccentric_nz.TARDIS.database.resultset.ResultSetPlayerPrefs;
26+
import me.eccentric_nz.TARDIS.database.resultset.ResultSetTardis;
27+
import me.eccentric_nz.TARDIS.database.resultset.ResultSetTravellers;
2528
import me.eccentric_nz.TARDIS.enumeration.Schematic;
2629
import me.eccentric_nz.TARDIS.enumeration.TardisModule;
2730
import me.eccentric_nz.TARDIS.messaging.TARDISRoomLister;
@@ -182,12 +185,6 @@ boolean startRoom(Player player, String[] args) {
182185
sd.setRoom(room);
183186
sd.setSchematic(schm);
184187
sd.setChunkMinMax(chunk);
185-
// check whether they have an ARS sign
186-
HashMap<String, Object> wherea = new HashMap<>();
187-
wherea.put("tardis_id", id);
188-
wherea.put("type", 10);
189-
ResultSetControls rsc = new ResultSetControls(plugin, wherea, false);
190-
sd.setARS(rsc.resultSet());
191188
plugin.getTrackerKeeper().getRoomSeed().put(uuid, sd);
192189
if (room.equals("STAIRCASE")) {
193190
plugin.getMessenger().send(player, TardisModule.TARDIS, "ROOM_SEED_STAIRCASE");

src/main/java/me/eccentric_nz/TARDIS/rooms/TARDISRoomSeeder.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ public void onRoomSeedBlockInteract(PlayerInteractEvent event) {
120120
}
121121
}
122122
// check they are not in an ARS chunk
123-
if (sd.hasARS() && checkARSBounds(block.getChunk(), block.getY(), sd)) {
123+
if (checkARSBounds(block.getChunk(), block.getY(), sd)) {
124124
plugin.getMessenger().send(player, TardisModule.TARDIS, "ROOM_USE_ARS");
125125
plugin.getTrackerKeeper().getRoomSeed().remove(uuid);
126126
return;
@@ -159,7 +159,7 @@ public void onRoomSeedBlockInteract(PlayerInteractEvent event) {
159159
return;
160160
}
161161
// check they are not in an ARS chunk
162-
if (sd.hasARS() && checkARSBounds(c, block.getY(), sd)) {
162+
if (checkARSBounds(c, block.getY(), sd)) {
163163
plugin.getMessenger().send(player, TardisModule.TARDIS, "ROOM_USE_ARS");
164164
plugin.getTrackerKeeper().getRoomSeed().remove(uuid);
165165
return;

src/main/java/me/eccentric_nz/TARDIS/rooms/TARDISSeedData.java

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ public class TARDISSeedData {
3131
private int maxx;
3232
private int minz;
3333
private int maxz;
34-
private boolean ARS;
3534

3635
public int getId() {
3736
return id;
@@ -82,12 +81,4 @@ public void setChunkMinMax(String s) {
8281
minz = z - 4;
8382
maxz = z + 4;
8483
}
85-
86-
boolean hasARS() {
87-
return ARS;
88-
}
89-
90-
public void setARS(boolean ARS) {
91-
this.ARS = ARS;
92-
}
9384
}

0 commit comments

Comments
 (0)