Commit Graph

59 Commits

Author SHA1 Message Date
Koding 4a5736cc7c
Fix unnecessary allocations with block properties function (#1387) 2022-09-06 14:55:21 +02:00
TheMode ace42b6f46 Make ObjectArray interface
Signed-off-by: TheMode <themode@outlook.fr>
2022-05-18 08:54:55 +02:00
TheMode f2fec73202
Tag internal rework (#782) 2022-03-20 01:47:57 +01:00
themode b906bd89ce Oops 2022-03-10 16:07:56 +01:00
themode 9bca6ee0e3 Fix override registry 2022-03-09 17:51:03 +01:00
themode 03cf585121 Unnecessary null check 2022-03-07 22:18:03 +01:00
themode 29f55ee720 Remove PROPERTIES_VALUES 2022-03-07 13:49:56 +01:00
themode 96fee8541d Move ObjectArray 2022-03-02 11:44:11 +01:00
TheMode 95fd6e7c81 Change int array to byte in BlockImpl
Signed-off-by: TheMode <themode@outlook.fr>
2022-02-04 22:30:30 +01:00
TheMode 0743759eed
Do not cache registry (#651) 2022-02-04 22:28:05 +01:00
TheMode 32d692a56a Avoid more allocation
Signed-off-by: TheMode <themode@outlook.fr>
2022-01-25 14:14:01 +01:00
TheMode b5bcd8fd4a Avoid string internal during properties parsing
Signed-off-by: TheMode <themode@outlook.fr>
2022-01-25 13:33:14 +01:00
TheMode 30cf6e8e4f Improve block properties performance
Signed-off-by: TheMode <themode@outlook.fr>
2022-01-25 07:43:52 +01:00
TheMode 7a9b08b085 Improve Registry.Container
Signed-off-by: TheMode <themode@outlook.fr>
2022-01-14 10:45:44 +01:00
themode a31f885cc7 Fix default tag value on blocks 2022-01-10 16:51:21 +01:00
themode 4b89ce33ee Add ArrayUtils#toMap 2022-01-10 16:51:21 +01:00
themode f3221ff412 Make BlockImpl a record 2022-01-10 16:51:21 +01:00
themode 77a14c0750 Use map copies for possible properties 2022-01-10 16:51:21 +01:00
themode 089a90df52 Use collection copies 2022-01-10 16:51:21 +01:00
Xavier Niochaut 9ab4277502 Port to Hephaistos v2 (#424) 2022-01-10 16:51:21 +01:00
TheMode b298334d24
Decrease memory footprint of the registry cache (#521) 2021-11-07 13:40:54 +01:00
TheMode ec2d164e7b Add internal `ObjectArray`
Signed-off-by: TheMode <themode@outlook.fr>
2021-11-06 14:07:42 +01:00
TheMode c745f1e064 Assume ids to start from 0 and increase 1 by 1. Improve lookup performance
Signed-off-by: TheMode <themode@outlook.fr>
2021-11-06 12:49:36 +01:00
TheMode 1b4e0519ee Add experimental `Block#possibleStates`
Signed-off-by: TheMode <themode@outlook.fr>
2021-10-25 16:17:12 +02:00
TheMode 999d774f90 Trim registry hashmaps to improve lookup performance
Signed-off-by: TheMode <themode@outlook.fr>
2021-10-17 14:29:27 +02:00
TheMode e65c9f6a79 Avoid block allocation if the properties map is the same
Signed-off-by: TheMode <themode@outlook.fr>
2021-09-20 18:09:16 +02:00
TheMode 748b24b8ef Expand block properties error 2021-08-25 18:26:45 +02:00
TheMode 2339fe1c07 Cache BlockImpl hashcode 2021-08-16 20:07:57 +02:00
TheMode 88ec8ddffa Fix block hashcode 2021-08-13 05:40:29 +02:00
TheMode 35d63ae547 Implements #equals for BlockImpl 2021-08-11 21:28:13 +02:00
TheMode ba63fe5b63 Remove PropertyEntry map wrapper 2021-08-04 17:45:17 +02:00
TheMode db9906d0ae Override Block#toString 2021-08-01 13:01:56 +02:00
TheMode d0ace7f10e Simplify BlockImpl 2021-07-30 17:34:39 +02:00
TheMode 53dea325f9 Move BlockLoader into impl class 2021-07-30 17:16:52 +02:00
TheMode 6aa55ad7b6 Cleanup 2021-07-24 03:31:03 +02:00
TheMode d146aacd36 Cleanup 2021-07-23 16:14:42 +02:00
TheMode 11b2426629 Micro optimize block properties map 2021-07-23 15:44:53 +02:00
TheMode efc135f48a Handle empty list case, let the try-catch handle NPE 2021-07-20 23:48:13 +02:00
TheMode 4d2b925edd Improve block#withProperty/ies performance 2021-07-19 23:59:40 +02:00
TheMode 99d4682655 Prevent nbt copy when placing a block 2021-07-10 20:41:22 +02:00
TheMode 98f645b344 Micro cleanup 2021-07-10 20:26:30 +02:00
TheMode a8a9f59715 Remove BlockEntry 2021-07-10 18:42:02 +02:00
TheMode b419ce88c1 Improve block getter performance 2021-07-09 00:42:43 +02:00
TheMode b541ef4a74 Simplify block implementation 2021-06-26 20:23:56 +02:00
TheMode af9e102ec1 Add documentation to Block 2021-06-23 18:29:19 +02:00
TheMode 4bbd89f78d Rename BlockImpl 2021-06-23 17:41:46 +02:00
TheMode 2d57235198 Remove legacy methods 2021-06-16 00:33:25 +02:00
TheMode 9c77ab267e Rework Block implementation (`BlockTest`) 2021-06-14 13:31:14 +02:00
TheMode d6a2a5b316 Added CampfireHandler demo 2021-06-12 19:17:50 +02:00
TheMode 7079225045 Remove BlockData.java 2021-06-11 17:33:18 +02:00