[MCPE-13752] [Internal MCPE] Block registering class is messed up Created: 23/Feb/16 Updated: 31/Aug/16 Resolved: 26/Feb/16 |
|
| Status: | Resolved |
| Project: | Minecraft (Bedrock codebase) |
| Component/s: | None |
| Affects Version/s: | 0.14.0 |
| Fix Version/s: | None |
| Type: | Bug | ||
| Reporter: | inxomnyaa | ||
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Confirmation Status: | Unconfirmed |
| Platform: | Tablet - Android - Samsung Galaxy Note |
| Description |
|
Oh man Mojang.. Whats wrong with your register Block class? Its really messed up and unsorted. In the beginnings, they are listed from highest id to lowest id. (you have to read from bottom to top) Sand But then, especially after id 127 (Lit redstone lamp) the class really messed up. EmeraldOre // thats 129.. wheres EmeraldBlock, the 130? NetherBrickStairs How it actually should be looking like: REDSTONE_LAMP = 123 I know, this no actual "bug".. but thats bad practice i think. A cleanup will maybe help you in future development, due to MCPE being a GREAT project. I am glad if i was able to help you a bit. Thanks ^^ |
| Comments |
| Comment by [Mojang] MissMarzenia (Aleksandra Zajac) [ 31/Aug/16 ] |
|
I meant the other Daniel, but sure. |
| Comment by inxomnyaa [ 31/Aug/16 ] |
|
@Daniel Wustenhoff it would only be the internal order, not changing ID's @MissMarzenia Welcome |
| Comment by [Mojang] MissMarzenia (Aleksandra Zajac) [ 26/Feb/16 ] |
|
Thank you Daniel for taking your time to explain that in detail |
| Comment by Daniel Wustenhoff [ 26/Feb/16 ] |
|
Changing ID's will change world saves, therefor we would have to convert them. The unsorted isn't intended, but the overhead is also rather minor for us, we could win way more performance in other places, which is why we tackle those first |
| Comment by inxomnyaa [ 23/Feb/16 ] |
|
^^ Its code style, you know Sorted arrays are faster in code processing. For example in array search functions, in array pop (remove last), etc "Maybe, it's Intended".. well.. I can't see any reason not to sort it, but the change is just for better internal handling. |
| Comment by Luis Robles [ 23/Feb/16 ] |
|
Do you think this is a bug? Maybe, it's Intended |