721 Commits

Author SHA1 Message Date
Dylan K. Taylor
561d8e7a39 Regenerated block/item id lists and refactored some names for consistency with MCPE 2017-08-04 12:17:24 +01:00
Dylan K. Taylor
b912b9173c Changed how blocks are registered, add API to allow registering custom blocks 2017-08-03 16:46:48 +01:00
Dylan K. Taylor
ca3cf3e067 Fixed ordering of blocks list and duplicated RedstoneTorch registration 2017-08-03 15:27:46 +01:00
Dylan K. Taylor
17be06a56d Rough implementation of double plants, fixes #882 2017-07-31 08:14:01 +01:00
Dylan K. Taylor
caff686827 Fixed grass growth and death, close #436
way too fast to grow back though :S
2017-07-31 08:00:03 +01:00
Dylan K. Taylor
210bdc2436 Fixed liquid CPU leaks and some flow issues
Liquid still needs a total rewrite, but at least it won't constantly waste CPU anymore.
2017-07-31 07:24:22 +01:00
Dylan K. Taylor
8957dbf08e Use occupied bitflag and added distance check for beds
must be < 2 blocks from either half of the bed
2017-07-30 20:02:48 +01:00
Dylan K. Taylor
2d626d1d90 Improved Beds, fixed bed tiles not getting removed for other halves
relates to #880
2017-07-30 19:57:10 +01:00
Dylan K. Taylor
253db40a11 Fixed bed placement with head over a transparent block 2017-07-30 19:50:47 +01:00
Dylan K. Taylor
1f4e6535bb Added Bed tile and support for coloured beds 2017-07-30 19:34:06 +01:00
Dylan K. Taylor
6ae24c5c19 Removed unnecessary methods Block->canBeActivated() and Item->canBeActivated() (needless extra confusion) 2017-07-30 18:14:43 +01:00
Dylan K. Taylor
036663e0b5 Made rails less weird
Not up to the task of implementing rail connectivity today, some other time
2017-07-30 18:02:24 +01:00
Dylan K. Taylor
344500785c Fixed wrong drops for Bookshelf 2017-07-30 17:58:34 +01:00
Dylan K. Taylor
a95d173989 Fixed a couple of repeated Level->getBlock() calls in Liquid 2017-07-30 17:57:40 +01:00
Dylan K. Taylor
b6fe231bc1 Added melting for ice and snow layers 2017-07-30 17:27:28 +01:00
Dylan K. Taylor
3bd94c9da7 Heads do not drop when the supporting block is removed
https://github.com/PocketMine/PocketMine-MP/pull/4087 didn't get reviewed properly, or at all 🤦
2017-07-30 17:26:55 +01:00
Dylan K. Taylor
2e5e016b87 Remove redundant TODO from CraftingTable 2017-07-30 17:26:06 +01:00
Dylan K. Taylor
822c048af0 Fixed wrong docs in Block 2017-07-30 17:24:59 +01:00
Dylan K. Taylor
6e4b8ba677 Removed some useless code 2017-07-30 17:24:33 +01:00
Dylan K. Taylor
a5a8732800 Removed redundant overriden method from Furnace 2017-07-30 17:24:02 +01:00
Dylan K. Taylor
21887b283f Removed some copy-pasted code, fix leaves2 drops 2017-07-30 17:22:28 +01:00
Dylan K. Taylor
3e8825f826 Fix bad documentation in Block 2017-07-15 12:48:41 +01:00
Dylan K. Taylor
2a7b736f18 Heap of bugfixes, cleanup and PHP 7 upgrades 2017-07-13 19:18:56 +01:00
Dylan K. Taylor
f2467d3dbc Workaround for grass-path/farmland anti-flight issue, close #1170 2017-07-11 10:37:01 +01:00
Dylan K. Taylor
a365c831a8 Fixed some doc problems 2017-06-25 12:07:28 +01:00
Dylan K. Taylor
a4b8dd43e6 Removed useless confusing array indices in CompoundTag constructors (#1116) 2017-06-20 12:11:24 +01:00
Dylan K. Taylor
846be84324 Fixed all file headers 2017-06-16 16:18:16 +01:00
Dylan K. Taylor
8fc38c36f9 Fixed some derp Vector3 aliases 2017-06-16 13:48:53 +01:00
Dylan K. Taylor
1bf18ba8d2 Fixed messed-up header in ItemFrame 2017-06-14 18:46:35 +01:00
Dylan K. Taylor
d358e13868 Strict type all the things and fix lots of assorted bugs exposed by strict types (#993)
Strict type all the things
2017-06-08 11:21:51 +01:00
Dylan K. Taylor
1f630e57f2 Fixed vine block update crashes, close #1032
The meta->side array was the wrong way round (keys & values inverted).
2017-06-08 09:32:38 +01:00
Dylan K. Taylor
51b0673b4b Bite the bullet and enable strict types on everything 2017-06-07 12:53:16 +01:00
Dylan K. Taylor
b7b7bcee4f Fixed some weak comparisons 2017-06-05 21:07:35 +01:00
Dylan K. Taylor
61d354a4ea Block constructor mass-replace to fix #963 and related issues 2017-06-05 10:02:27 +01:00
Dylan K. Taylor
6686bd4442 Quick fix for melons and pumpkins, close #965 2017-06-04 16:57:51 +01:00
Dylan K. Taylor
49eb0eb050 Fixed falling sand glitching on landing, minor logic improvements 2017-05-04 17:48:39 +01:00
Dylan K. Taylor
13fd8b681e Added some sounds, fixed DestroyBlockParticle wrong particles for blocks with different meta values 2017-05-04 16:50:13 +01:00
Dylan K. Taylor
6828ce66b6 Fixed farmland appearing black on clients (farmland is transparent in PE) 2017-04-18 19:40:54 +01:00
Dylan K. Taylor
dab73d8950 Implemented sky light generation-time population and updating, obsolete and close #160 2017-04-18 13:05:01 +01:00
Dylan K. Taylor
b55929b382 Merge branch 'api3/network' into api3/network-mcpe-1.1 2017-04-15 10:30:02 +01:00
Dylan K. Taylor
66924729ff Fixed climbing blocks such as ladders and vines
Seems we can now climb ANY block if the climbing flag is true, and nothing if false. This commit adds local block checks to see if a climbable block exists at the entity's feet and if so, sets the flag.
2017-04-14 19:02:53 +01:00
Dylan K. Taylor
f12a6eed29 Fixed vine block placement 2017-04-14 18:25:50 +01:00
Dylan K. Taylor
f2159c5948 Fixed unlit furnaces glowing in the dark, close #508
Whether Furnace extending BurningFurnace actually makes logical sense is a different question, but that cna be resolved any other time.
2017-04-14 15:30:37 +01:00
Dylan K. Taylor
f3ab45e7d5 Merged in 1.0.6 changes, added autogenerated data for 1.1.0.3 (doesn't work yet) and deliberately made the same merge error as Mojang 2017-04-14 13:00:43 +01:00
Dylan K. Taylor
630f0fab7f Fixed block update recursion issues (#464)
* Schedule all neighbour block updates to execute at the end of the tick, fixed recursion crash, close #251

* doTickPending timings now include neighbour block update times, refactored some var names
2017-04-01 20:18:56 +01:00
Dylan K. Taylor
5926bab323 Block light bug fixes (#454)
* Fixed an age-old light calculation bug causing solid blocks to filter their own light, fixed #375, probably fixed #288
Light spread reduction should be done based on the _target's_ light filter level, not the source.

* Revert "Fix Glowing Obsidian lighting"
This hack is no longer necessary.
This reverts commit 35c33ba980887e9680d62bbcb65f8537bb063f2c.

* Fixed wrong light levels for torch and redstone torch

* Take adjacent light levels and opacity changes into account, block light will now spread when an obstruction is removed, close #455

* Added timings for Level->setBlock() and lighting updates
2017-03-24 17:56:26 +00:00
Dylan K. Taylor
f98a964cdc Fixed and silenced some inspections 2017-02-23 15:17:28 +00:00
Dylan K. Taylor
4ae18526d1 Fix fence gates opening in opposite direction to expected
This still occasionally occurs due to a bug that seems to exist with
entity rotation calculations. May happen at 45° 135° 225° and 315°
2017-02-22 09:46:54 +00:00
Dylan K. Taylor
c21197ef17 Removed entanglement between chunks and providers. WARNING: BREAKING API CHANGES.
- All entity and tile constructors now require a \pocketmine\level\Level instead of a \pocketmine\level\format\Chunk.
- Chunk->getProvider() and Chunk->setProvider() have been removed.
- Chunk::__construct() has had the $provider parameter removed.
- Chunk->unload() has had the unused $save parameter removed.
- ChunkEvents now take a Level parameter instead of going through the Chunk

API bump to 3.0.0-ALPHA4
2017-02-21 17:08:45 +00:00
Dylan K. Taylor
0a8826b21f Fixed anti-fly triggered when walking on unknown blocks 2017-02-21 13:43:00 +00:00