SteamWar/BauSystem2.0
Archiviert
12
0

Add basic Simulator Preview
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Signed-off-by: yoyosource <yoyosource@nidido.de>
Dieser Commit ist enthalten in:
yoyosource 2023-08-31 16:53:45 +02:00
Ursprung bb489fd185
Commit 9d91c4e3eb

Datei anzeigen

@ -116,6 +116,10 @@ public class TNTSimulatorListener implements Listener {
if (simulator == null) return; if (simulator == null) return;
Pair<Integer, Map<Integer, List<List<Pair<TNTData, Integer>>>>> toCalculate = simulator.locations(event.getPlayer()); Pair<Integer, Map<Integer, List<List<Pair<TNTData, Integer>>>>> toCalculate = simulator.locations(event.getPlayer());
PreviewRecord previewRecord = Simulator.impl.run(toCalculate); PreviewRecord previewRecord = Simulator.impl.run(toCalculate);
if (previewRecord == null) {
event.setCancelled(true);
return;
}
previewRecord.add(event.getPlayer()); previewRecord.add(event.getPlayer());
} }