3
0
Mirror von https://github.com/ViaVersion/ViaVersion.git synchronisiert 2024-11-20 06:50:08 +01:00

Created a local variable for ProxiedPlayers

Dieser Commit ist enthalten in:
terrarier2111 2020-11-15 21:15:42 +01:00 committet von GitHub
Ursprung 7abff77c51
Commit 0b256d15b2
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 4AEE18F83AFDEB23

Datei anzeigen

@ -126,9 +126,10 @@ public class BungeePlugin extends Plugin implements ViaPlatform<ProxiedPlayer>,
@Override
public ViaCommandSender[] getOnlinePlayers() {
ViaCommandSender[] array = new ViaCommandSender[getProxy().getPlayers().size()];
Collection<ProxiedPlayer> players = getProxy().getPlayers();
ViaCommandSender[] array = new ViaCommandSender[players.size()];
int i = 0;
for (ProxiedPlayer player : getProxy().getPlayers()) {
for (ProxiedPlayer player : players) {
array[i++] = new BungeeCommandSender(player);
}
return array;