SteamWar/FightSystem
Archiviert
13
1

Bow drawn potential fix
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Signed-off-by: Lixfel <agga-games@gmx.de>
Dieser Commit ist enthalten in:
Lixfel 2022-03-05 18:13:28 +01:00
Ursprung 77fa08c12b
Commit 141f51ee83

Datei anzeigen

@ -503,7 +503,14 @@ public class PacketProcessor {
boolean drawn = source.readBoolean(); boolean drawn = source.readBoolean();
boolean offHand = source.readBoolean(); boolean offHand = source.readBoolean();
execSync(() -> REntity.getEntity(entityId).setBowDrawn(drawn, offHand)); execSync(() -> {
REntity entity = REntity.getEntity(entityId);
if(entity != null) {
entity.setBowDrawn(drawn, offHand);
} else {
Bukkit.getLogger().log(Level.SEVERE, "Bow drawn of nonexistent player? " + entityId + " " + Arrays.toString(lastPackets.toArray()));
}
});
} }
private void damage() throws IOException { private void damage() throws IOException {