Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,7 @@ public static void register(final BedrockProtocol protocol) {
final ResourcePackDownloadTracker downloadTracker = wrapper.user().get(ResourcePackDownloadTracker.class);
final ResourcePackDownloadTracker.Download download = downloadTracker.get(key);
if (download != null) {
ViaBedrock.getPlatform().getLogger().log(Level.INFO, "Downloading resource pack chunk " + chunk + "/" + download.chunkSize() + " for " + key);
final ResourcePack resourcePack = download.processDataChunk(chunk, data);
if (resourcePack != null) {
downloadTracker.remove(key);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ public CompletableFuture<Void> loadRequestedResourcePacks() {
final PacketWrapper resourcePackClientResponse = PacketWrapper.create(ServerboundBedrockPackets.RESOURCE_PACK_CLIENT_RESPONSE, this.user());
resourcePackClientResponse.write(BedrockTypes.UNSIGNED_VAR_INT, ResourcePackResponse.Downloading.getValue()); // status
resourcePackClientResponse.write(BedrockTypes.STRING, "downloading"); // #blameMojang
resourcePackClientResponse.write(BedrockTypes.SHORT_LE_STRING_ARRAY, downloadList.stream().map(ResourcePack.Key::toString).toArray(String[]::new)); // downloading packs
resourcePackClientResponse.write(BedrockTypes.STRING_ARRAY, downloadList.stream().map(ResourcePack.Key::toString).toArray(String[]::new)); // downloading packs
resourcePackClientResponse.scheduleSendToServer(BedrockProtocol.class);
} else {
this.loadFuture.complete(null);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ public final class BedrockTypes {
public static final Type<String> ASCII_STRING = new AsciiStringType();
public static final Type<String> STRING = new StringType();
public static final Type<String> OPTIONAL_STRING = new OptionalType<>(STRING);
public static final Type<String[]> SHORT_LE_STRING_ARRAY = new ArrayType<>(STRING, SHORT_LE);
public static final Type<String[]> STRING_ARRAY = new ArrayType<>(STRING, UNSIGNED_VAR_INT);
public static final Type<String> UTF8_STRING = new Utf8StringType();
public static final Type<String[]> UTF8_STRING_ARRAY = new ArrayType<>(UTF8_STRING, UNSIGNED_INT_LE);
Expand Down