198 Commits

Author SHA1 Message Date
Dylan K. Taylor
827ee5ff33 more constants in Tile 2017-11-08 10:49:15 +00:00
Dylan K. Taylor
f8e6438efe updated some NBT for tiles 2017-10-31 18:22:06 +00:00
Dylan K. Taylor
91c256f1a9 Added Level->getTileAt() 2017-10-30 13:36:42 +00:00
Dylan K. Taylor
93443992be Fixed chests not getting updated properly on pair/unpair, close #1514
it wasn't clearing spawn compound caches or chunk caches
2017-10-30 11:50:02 +00:00
Dylan K. Taylor
48fefae920 Added cache for tile spawn compounds
avoids expensive repetetive NBT writes on chunk sends when the tile hasn't been changed
2017-10-27 10:23:48 +01:00
Dylan K. Taylor
18e4e5364f Fixed getBlock() performance degradation caused by 781de3efabcd526281fd1adc8ce881d408471563, added Level->getBlockAt() to avoid creating vectors everywhere 2017-10-20 13:22:49 +01:00
Dylan K. Taylor
5a353012de Clean up some unused imports 2017-10-19 16:39:34 +01:00
Dylan K. Taylor
2c34648c3d fixed second half of double chest items getting deleted, close #1477 2017-10-18 12:29:57 +01:00
Dylan K. Taylor
7f0a961526 "Creator" tag on signs may not exist 2017-10-17 13:35:31 +01:00
Dylan K. Taylor
68ac4f538f Added ContainerTrait, reduce copy-pasted code in Tile 2017-10-16 20:01:17 +01:00
Dylan K. Taylor
f4ff5d81ea Added missing parent calls for saveNBT() in Chest and Furnace 2017-10-16 18:56:48 +01:00
Dylan K. Taylor
28a840d161 Make use of CompoundTag->hasTag() 2017-10-16 18:32:08 +01:00
Dylan K. Taylor
20b86bdea8 Cleaned up tile NBT handling, use new CompoundTag API methods 2017-10-16 16:48:24 +01:00
Dylan K. Taylor
0b1a9ba062 Added more typehints to Tile namespace 2017-10-16 16:14:44 +01:00
Dylan K. Taylor
45b003ac2e Removed unnecessary return from Sign 2017-10-16 16:10:33 +01:00
Dylan K. Taylor
af85659c63 Remove redundant property from Tile 2017-10-16 12:35:32 +01:00
Dylan K. Taylor
95fa1824c8 Use a trait for nameable tiles instead of repeating code 2017-10-16 12:32:10 +01:00
Dylan K. Taylor
3b5eb45ff5 More usages of Item->isNull() 2017-10-16 12:29:39 +01:00
Dylan K. Taylor
68809d992b Added BaseInventory->removeAllViewers() 2017-10-16 11:15:03 +01:00
Dylan K. Taylor
cd8006e242 Use constructor parameter for ListTags instead of setTagType() and removed some unnecessary type setting 2017-10-14 13:49:24 +01:00
Dylan K. Taylor
b7a9e10d49 Some cleanup to how tiles are created 2017-10-11 18:08:08 +01:00
Dylan K. Taylor
cef9c4621c added som PhpDoc to Tile 2017-10-09 17:27:34 +01:00
Dylan K. Taylor
151681bd80 Remove some dead properties from Tile 2017-10-09 17:25:10 +01:00
Dylan K. Taylor
327907988b Fixed a typo in Sign->setText() docs 2017-10-09 16:56:25 +01:00
Dylan K. Taylor
7267f1a520 Fixed some usages of Item constants for Blocks
only cosmetic change
2017-10-09 10:37:19 +01:00
Dylan K. Taylor
c47f1f572c Added API method Item->pop() 2017-09-27 10:56:04 +01:00
Dylan K. Taylor
043ae487de Fixed some inconsistent uses of new ShortTag vs setValue() in Furnace 2017-09-24 10:34:25 +01:00
Dylan K. Taylor
f12701e582 Fixed possible undefined NBT in Furnace, close #1398 2017-09-24 10:29:36 +01:00
Dylan K. Taylor
ee052f91d4 Fixed some air items with count 1 instead of 0 2017-09-21 10:30:14 +01:00
Dylan K. Taylor
ef6250967f Use Item->isNull() more 2017-09-21 10:29:29 +01:00
Dylan K. Taylor
85b2b2ae2e Don't send tile inventory slots during the constructor
This is completely pointless and a waste of time.
2017-09-20 10:15:28 +01:00
Dylan K. Taylor
1fb6d12a6b Add getInventory() to Container interface where it's actually useful 2017-09-19 19:26:41 +01:00
Dylan K. Taylor
78d49f8e66 Merge branch 'php/7.0' into mcpe-1.2 2017-09-03 15:02:41 +01:00
Dylan K. Taylor
0b83c61494 Fixed cyclic reference with chest tiles and DoubleChestInventory 2017-09-03 11:24:34 +01:00
Dylan K. Taylor
75e32b11b7 Merge branch 'php/7.0' into mcpe-1.2 2017-09-02 18:29:53 +01:00
Dylan K. Taylor
22d8626e23 Fixed sign bug introduced in #1204 rebase, close #1346 2017-09-02 13:12:55 +01:00
Dylan K. Taylor
5d75d3d5b6 Merge branch 'php/7.0' into mcpe-1.2 2017-09-01 23:10:58 +01:00
Tim (robske_110)
226175f961 setText now nullable instead of overwriting with empty lines (#1204) 2017-09-01 08:34:40 +01:00
Dylan K. Taylor
23752548fe Address several LevelDB related crashdumps in the crash archive 2017-08-30 15:42:31 +01:00
Dylan K. Taylor
b5d2402c9b Merge branch 'master' into mcpe-1.2 2017-08-28 18:02:09 +01:00
Dylan K. Taylor
0b2b9126a2 Improved tile spawning
There's no need to recreate the spawn packet for every single player, or re-serialize the NBT.
2017-08-27 18:40:18 +01:00
Dylan K. Taylor
445a67954d Merge changes from master 2017-08-22 14:13:31 +01:00
Dylan K. Taylor
876659cc73 Item factory refactor and added capability to register custom items 2017-08-21 17:49:26 +01:00
Dylan K. Taylor
1f70a7830e Branch merge 2017-08-20 21:07:19 +01:00
Dylan K. Taylor
02f42eba48 Move block registration to its own class 2017-08-20 18:05:01 +01:00
Dylan K. Taylor
4f1302adf2 Merge branch 'master' into mcpe-1.2 2017-08-17 17:14:16 +01:00
Dylan K. Taylor
6efa4343b1 Cleaned up fuel duration handling, fixed some fuel items not working in furnaces 2017-08-17 10:22:47 +01:00
Dylan K. Taylor
dc3f13cd30 Cleanup from previous commit 2017-08-17 09:42:00 +01:00
Dylan K. Taylor
b4c4005009 Some condition simplifications suggested by static analysis 2017-08-16 20:06:48 +01:00
Dylan K. Taylor
3025f76cd0 Fix a couple of Sign bugs 2017-08-10 08:57:57 +01:00