Skip to content

Commit

Permalink
Fix codestyle
Browse files Browse the repository at this point in the history
  • Loading branch information
dries-c committed Jun 13, 2024
1 parent 8d13700 commit c97ab91
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/data/bedrock/BedrockDataFiles.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ private function __construct(){
public const BLOCK_ID_TO_ITEM_ID_MAP_1_20_50_JSON = BEDROCK_DATA_PATH . '/block_id_to_item_id_map-1.20.50.json';
public const BLOCK_ID_TO_ITEM_ID_MAP_1_20_60_JSON = BEDROCK_DATA_PATH . '/block_id_to_item_id_map-1.20.60.json';
public const BLOCK_ID_TO_ITEM_ID_MAP_1_20_70_JSON = BEDROCK_DATA_PATH . '/block_id_to_item_id_map-1.20.70.json';
public const BLOCK_ID_TO_ITEM_ID_MAP_1_20_80_JSON = BEDROCK_DATA_PATH . '/block_id_to_item_id_map-1.20.80.json';
public const BLOCK_ID_TO_ITEM_ID_MAP_JSON = BEDROCK_DATA_PATH . '/block_id_to_item_id_map.json';
public const BLOCK_STATE_META_MAP_1_20_0_JSON = BEDROCK_DATA_PATH . '/block_state_meta_map-1.20.0.json';
public const BLOCK_STATE_META_MAP_1_20_10_JSON = BEDROCK_DATA_PATH . '/block_state_meta_map-1.20.10.json';
Expand All @@ -48,6 +49,7 @@ private function __construct(){
public const BLOCK_STATE_META_MAP_1_20_50_JSON = BEDROCK_DATA_PATH . '/block_state_meta_map-1.20.50.json';
public const BLOCK_STATE_META_MAP_1_20_60_JSON = BEDROCK_DATA_PATH . '/block_state_meta_map-1.20.60.json';
public const BLOCK_STATE_META_MAP_1_20_70_JSON = BEDROCK_DATA_PATH . '/block_state_meta_map-1.20.70.json';
public const BLOCK_STATE_META_MAP_1_20_80_JSON = BEDROCK_DATA_PATH . '/block_state_meta_map-1.20.80.json';
public const BLOCK_STATE_META_MAP_JSON = BEDROCK_DATA_PATH . '/block_state_meta_map.json';
public const CANONICAL_BLOCK_STATES_1_20_0_NBT = BEDROCK_DATA_PATH . '/canonical_block_states-1.20.0.nbt';
public const CANONICAL_BLOCK_STATES_1_20_10_NBT = BEDROCK_DATA_PATH . '/canonical_block_states-1.20.10.nbt';
Expand All @@ -56,6 +58,7 @@ private function __construct(){
public const CANONICAL_BLOCK_STATES_1_20_50_NBT = BEDROCK_DATA_PATH . '/canonical_block_states-1.20.50.nbt';
public const CANONICAL_BLOCK_STATES_1_20_60_NBT = BEDROCK_DATA_PATH . '/canonical_block_states-1.20.60.nbt';
public const CANONICAL_BLOCK_STATES_1_20_70_NBT = BEDROCK_DATA_PATH . '/canonical_block_states-1.20.70.nbt';
public const CANONICAL_BLOCK_STATES_1_20_80_NBT = BEDROCK_DATA_PATH . '/canonical_block_states-1.20.80.nbt';
public const CANONICAL_BLOCK_STATES_NBT = BEDROCK_DATA_PATH . '/canonical_block_states.nbt';
public const COMMAND_ARG_TYPES_JSON = BEDROCK_DATA_PATH . '/command_arg_types.json';
public const CREATIVEITEMS_JSON = BEDROCK_DATA_PATH . '/creativeitems.json';
Expand All @@ -72,6 +75,7 @@ private function __construct(){
public const R12_TO_CURRENT_BLOCK_MAP_1_20_50_BIN = BEDROCK_DATA_PATH . '/r12_to_current_block_map-1.20.50.bin';
public const R12_TO_CURRENT_BLOCK_MAP_1_20_60_BIN = BEDROCK_DATA_PATH . '/r12_to_current_block_map-1.20.60.bin';
public const R12_TO_CURRENT_BLOCK_MAP_1_20_70_BIN = BEDROCK_DATA_PATH . '/r12_to_current_block_map-1.20.70.bin';
public const R12_TO_CURRENT_BLOCK_MAP_1_20_80_BIN = BEDROCK_DATA_PATH . '/r12_to_current_block_map-1.20.80.bin';
public const R12_TO_CURRENT_BLOCK_MAP_BIN = BEDROCK_DATA_PATH . '/r12_to_current_block_map.bin';
public const R16_TO_CURRENT_ITEM_MAP_JSON = BEDROCK_DATA_PATH . '/r16_to_current_item_map.json';
public const REQUIRED_ITEM_LIST_1_20_0_JSON = BEDROCK_DATA_PATH . '/required_item_list-1.20.0.json';
Expand All @@ -80,5 +84,6 @@ private function __construct(){
public const REQUIRED_ITEM_LIST_1_20_50_JSON = BEDROCK_DATA_PATH . '/required_item_list-1.20.50.json';
public const REQUIRED_ITEM_LIST_1_20_60_JSON = BEDROCK_DATA_PATH . '/required_item_list-1.20.60.json';
public const REQUIRED_ITEM_LIST_1_20_70_JSON = BEDROCK_DATA_PATH . '/required_item_list-1.20.70.json';
public const REQUIRED_ITEM_LIST_1_20_80_JSON = BEDROCK_DATA_PATH . '/required_item_list-1.20.80.json';
public const REQUIRED_ITEM_LIST_JSON = BEDROCK_DATA_PATH . '/required_item_list.json';
}
1 change: 1 addition & 0 deletions src/data/bedrock/ItemTagToIdMap.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ final class ItemTagToIdMap{

private const PATHS = [
ProtocolInfo::CURRENT_PROTOCOL => "",
ProtocolInfo::PROTOCOL_1_20_80 => "",
ProtocolInfo::PROTOCOL_1_20_70 => "",
ProtocolInfo::PROTOCOL_1_20_60 => "",
ProtocolInfo::PROTOCOL_1_20_50 => "",
Expand Down
4 changes: 4 additions & 0 deletions src/network/mcpe/convert/BlockTranslator.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ final class BlockTranslator{
self::CANONICAL_BLOCK_STATES_PATH => '',
self::BLOCK_STATE_META_MAP_PATH => '',
],
ProtocolInfo::PROTOCOL_1_20_80 => [
self::CANONICAL_BLOCK_STATES_PATH => '-1.20.80',
self::BLOCK_STATE_META_MAP_PATH => '-1.20.80',
],
ProtocolInfo::PROTOCOL_1_20_70 => [
self::CANONICAL_BLOCK_STATES_PATH => '-1.20.70',
self::BLOCK_STATE_META_MAP_PATH => '-1.20.70',
Expand Down
2 changes: 2 additions & 0 deletions src/network/mcpe/convert/ItemTranslator.php
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,8 @@ public function fromNetworkId(int $networkId, int $networkMeta, int $networkBloc

public static function getItemSchemaId(int $protocolId) : int{
return match($protocolId){
ProtocolInfo::PROTOCOL_1_21_0 => 191,

ProtocolInfo::PROTOCOL_1_20_80 => 181,

ProtocolInfo::PROTOCOL_1_20_70 => 171,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ final class ItemTypeDictionaryFromDataHelper{

private const PATHS = [
ProtocolInfo::CURRENT_PROTOCOL => "",
ProtocolInfo::PROTOCOL_1_20_80 => "-1.20.80",
ProtocolInfo::PROTOCOL_1_20_70 => "-1.20.70",
ProtocolInfo::PROTOCOL_1_20_60 => "-1.20.60",
ProtocolInfo::PROTOCOL_1_20_50 => "-1.20.50",
Expand Down

0 comments on commit c97ab91

Please sign in to comment.