Skip to content

Commit

Permalink
Update Mappings and Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
bundabrg committed Jan 22, 2021
1 parent f95b72a commit 27777aa
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,17 +35,13 @@
import it.unimi.dsi.fastutil.objects.Object2ObjectMap;
import it.unimi.dsi.fastutil.objects.Object2ObjectOpenHashMap;
import org.geysermc.connector.GeyserConnector;
import org.geysermc.connector.event.EventManager;
import org.geysermc.connector.event.events.registry.BlockEntityRegistryEvent;
import org.geysermc.connector.network.translators.world.block.entity.BlockEntity;
import org.geysermc.connector.utils.FileUtils;
import org.reflections.Reflections;

import java.io.DataInputStream;
import java.io.InputStream;
import java.util.Iterator;
import java.util.Map;
import java.util.Set;

public class BlockTranslator {
/**
Expand All @@ -58,16 +54,16 @@ public class BlockTranslator {
public static final int BEDROCK_AIR_ID;
public static final int BEDROCK_WATER_ID;

public static final Int2IntMap JAVA_TO_BEDROCK_BLOCK_MAP = new Int2IntOpenHashMap();
public static final Int2IntMap BEDROCK_TO_JAVA_BLOCK_MAP = new Int2IntOpenHashMap();
private static final Int2IntMap JAVA_TO_BEDROCK_BLOCK_MAP = new Int2IntOpenHashMap();
private static final Int2IntMap BEDROCK_TO_JAVA_BLOCK_MAP = new Int2IntOpenHashMap();
/**
* Stores a list of differences in block identifiers.
* Items will not be added to this list if the key and value is the same.
*/
public static final Object2ObjectMap<String, String> JAVA_TO_BEDROCK_IDENTIFIERS = new Object2ObjectOpenHashMap<>();
public static final BiMap<String, Integer> JAVA_ID_BLOCK_MAP = HashBiMap.create();
public static final IntSet WATERLOGGED = new IntOpenHashSet();
public static final Object2IntMap<NbtMap> ITEM_FRAMES = new Object2IntOpenHashMap<>();
private static final Object2ObjectMap<String, String> JAVA_TO_BEDROCK_IDENTIFIERS = new Object2ObjectOpenHashMap<>();
private static final BiMap<String, Integer> JAVA_ID_BLOCK_MAP = HashBiMap.create();
private static final IntSet WATERLOGGED = new IntOpenHashSet();
private static final Object2IntMap<NbtMap> ITEM_FRAMES = new Object2IntOpenHashMap<>();

// Bedrock carpet ID, used in LlamaEntity.java for decoration
public static final int CARPET = 171;
Expand Down Expand Up @@ -102,7 +98,7 @@ public class BlockTranslator {

public static final int JAVA_RUNTIME_SPAWNER_ID;

public static final int BLOCK_STATE_VERSION = 17825808;
private static final int BLOCK_STATE_VERSION = 17825808;

static {
/* Load block palette */
Expand Down
2 changes: 1 addition & 1 deletion connector/src/main/resources/languages
Submodule languages updated 77 files
+0 −0 run-help/af_ZA.txt
+18 −0 run-help/ar_SA.txt
+0 −18 run-help/cs_CZ.help.txt
+0 −18 run-help/da_DK.help.txt
+0 −18 run-help/de_DE.help.txt
+0 −18 run-help/el_GR.help.txt
+6 −6 run-help/el_GR.txt
+0 −18 run-help/en_GB.help.txt
+0 −18 run-help/en_US.help.txt
+0 −18 run-help/es_ES.help.txt
+2 −2 run-help/es_ES.txt
+1 −1 run-help/es_MX.txt
+0 −18 run-help/fi_FI.help.txt
+0 −18 run-help/fr_FR.help.txt
+18 −0 run-help/he_IL.txt
+19 −0 run-help/hi_IN.txt
+0 −18 run-help/hu_HU.help.txt
+1 −1 run-help/hu_HU.txt
+0 −18 run-help/id_ID.help.txt
+1 −1 run-help/id_ID.txt
+0 −18 run-help/it_IT.help.txt
+1 −1 run-help/it_IT.txt
+0 −18 run-help/ja_JP.help.txt
+2 −2 run-help/ja_JP.txt
+0 −18 run-help/ko_KR.help.txt
+1 −1 run-help/ko_KR.txt
+6 −6 run-help/nb_NO.txt
+0 −18 run-help/nl_NL.help.txt
+2 −2 run-help/nl_NL.txt
+0 −18 run-help/no_NO.help.txt
+0 −18 run-help/pl_PL.help.txt
+3 −3 run-help/pl_PL.txt
+6 −6 run-help/pt_BR.txt
+0 −18 run-help/pt_PT.help.txt
+0 −18 run-help/ru_RU.help.txt
+0 −18 run-help/sk_SK.help.txt
+0 −18 run-help/sv_SE.help.txt
+2 −2 run-help/sv_SE.txt
+0 −18 run-help/tr_TR.help.txt
+6 −6 run-help/tr_TR.txt
+0 −18 run-help/uk_UA.help.txt
+0 −18 run-help/zh_CN.help.txt
+0 −18 run-help/zh_TW.help.txt
+6 −6 run-help/zh_TW.txt
+192 −0 texts/af_ZA.properties
+192 −0 texts/ar_SA.properties
+155 −139 texts/bg_BG.properties
+24 −8 texts/cs_CZ.properties
+19 −3 texts/da_DK.properties
+29 −13 texts/de_DE.properties
+105 −89 texts/el_GR.properties
+20 −4 texts/en_GB.properties
+20 −4 texts/en_US.properties
+40 −24 texts/es_ES.properties
+37 −21 texts/es_MX.properties
+20 −4 texts/fi_FI.properties
+21 −5 texts/fr_CA.properties
+28 −12 texts/fr_FR.properties
+192 −0 texts/he_IL.properties
+192 −0 texts/hi_IN.properties
+20 −4 texts/hu_HU.properties
+56 −40 texts/id_ID.properties
+36 −20 texts/it_IT.properties
+27 −11 texts/ja_JP.properties
+65 −49 texts/ko_KR.properties
+134 −118 texts/nb_NO.properties
+99 −83 texts/nl_NL.properties
+20 −4 texts/pl_PL.properties
+189 −173 texts/pt_BR.properties
+20 −4 texts/pt_PT.properties
+21 −5 texts/ru_RU.properties
+20 −4 texts/sk_SK.properties
+39 −23 texts/sv_SE.properties
+172 −156 texts/tr_TR.properties
+20 −4 texts/uk_UA.properties
+36 −20 texts/zh_CN.properties
+186 −170 texts/zh_TW.properties
2 changes: 1 addition & 1 deletion connector/src/main/resources/mappings
Submodule mappings updated 4 files
+1,761 −0 blocks.json
+9 −0 effects.json
+339 −154 items.json
+2 −1 sounds.json

0 comments on commit 27777aa

Please sign in to comment.