Dylan K. Taylor
cf07af8b55
Fix some strict type violations reported by PhpStorm (strict types <3)
2017-06-07 12:54:12 +01:00
Dylan K. Taylor
db93827650
Fix world saving
2017-06-07 12:54:12 +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
4666560731
Removed some tags that don't exist in vanilla McRegion chunks
2017-06-04 13:04:06 +01:00
Dylan K. Taylor
8779259734
Stop spawning entities to players twice
...
This will be done when the chunk is sent to the player anyway.
2017-05-29 15:57:05 +01:00
Dylan K. Taylor
af06d78725
Merge changes from master
2017-05-24 09:54:11 +01:00
Dylan K. Taylor
0207b22110
Fixed Mojang world converters barfing on PocketMine-MP generated McRegion worlds
...
blame @shoghicp
2017-05-21 12:44:42 +01:00
Dylan K. Taylor
905d3f1610
Only save batch buffer when compressing chunks
...
faster due to not needing to serialize, and reduces memory footprint of caching
2017-05-18 19:46:20 +01:00
Dylan K. Taylor
60f5c7ccef
Async chunk compression and serialization is now non-optional
2017-05-18 12:19:27 +01:00
Dylan K. Taylor
56306f6636
Merge branch 'master' into mcpe-1.1
2017-05-04 21:15:49 +01:00
Dylan K. Taylor
eaef2bd169
Fixed some inspections
2017-05-04 12:19:50 +01:00
Dylan K. Taylor
7aeb3129ac
Merge conflict resolution
2017-04-27 14:27:29 +01:00
Dylan K. Taylor
2a59977440
Added various checks for region file validity ( #393 )
...
Check size, check header size, check location table offsets point to valid locations, check for shared offsets, prevent issues with corrupted or junk data
2017-04-27 09:14:02 +01:00
Dylan K. Taylor
7a2ed232cc
Merge branch 'api3/network' into api3/network-mcpe-1.1
2017-04-24 13:56:19 +01:00
Dylan K. Taylor
559504225a
Throw an exception before calling base entity constructor if skin is not set or invalid, close #835 ( #855 )
2017-04-24 09:50:55 +01:00
Dylan K. Taylor
179210aa27
Merge branch 'api3/network' into api3/network-mcpe-1.1
2017-04-21 22:50:14 +01:00
Dylan K. Taylor
6ece57e23e
Merge changes from master
2017-04-21 22:48:18 +01:00
Dylan K. Taylor
b7b7a93e4e
Merge branch 'api3/network' into api3/network-mcpe-1.1
2017-04-18 14:52:06 +01:00
Dylan K. Taylor
eefa8abaf2
Throw exceptions if something attempts to add a closed Tile or Entity to a chunk
2017-04-18 14:45:33 +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
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
JackNoordhuis
c01e0354bd
Address #816
...
Removes redundant compression argument from NBT::readCompressed() and
NBT:: readNetworkCompressed()
2017-04-12 00:42:27 +10:00
Dylan K. Taylor
202bac28fc
Merge master into api3/network
2017-04-01 19:37:15 +01:00
Dylan K. Taylor
1c3d89cfef
Fixed lighting issues with subchunks containing no blocks
...
A subchunk with no blocks is not necessarily empty.
2017-03-29 11:34:43 +01:00
Dylan K. Taylor
56990eb28b
MCPE protocol gets its own namespace
2017-03-08 20:28:39 +00:00
Dylan K. Taylor
282095513a
Throw exception when attempting to save a non-generated chunk ( #367 )
2017-02-21 19:24:16 +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
2ff565afe5
Fix heightmap crashes at the corner of chunks
...
Stupid unpack() return array indices start at 1, not 0 >_<
2017-02-20 10:28:50 +00:00
Dylan K. Taylor
8f9c52507a
Some PhpStorm cleanup
2017-02-12 12:36:02 +00:00
Dylan K. Taylor
5a12f40074
Only Region file formats are allowed as parameters for RegionLoaders
2017-02-12 12:18:25 +00:00
Dylan K. Taylor
06de85fd33
Revert "Fix entities missing in imported leveldb worlds", fixed entities missing after restart in anything OTHER than LevelDB
...
🤦 I should test this stuff more
This reverts commit ffadc34691
.
2017-02-11 19:22:59 +00:00
Dylan K. Taylor
ffadc34691
Fix entities missing in imported leveldb worlds
2017-02-11 11:15:15 +00:00
Dylan K. Taylor
e4c889ae16
Check if the array contents are already the same, massive performance improvement for Anvil in a lot of cases
2017-01-18 20:04:19 +00:00
Dylan K. Taylor
7de7593b89
Improved nibble array re-ordering in most cases by checking for common values
2017-01-18 19:51:43 +00:00
Dylan K. Taylor
bcf049a660
Remove obsolete methods from Chunk
2017-01-15 18:03:40 +00:00
Dylan K. Taylor
0114cb8399
Better vanilla layers support (no meta, MCPE doesn't support it)
2017-01-15 17:26:21 +00:00
Dylan K. Taylor
b72218ac5b
Fixed flat world terrain generation by MCPE
2017-01-15 17:26:21 +00:00
Dylan K. Taylor
6b9c2b961b
Fix invalid timestamp causing W10 Edition to crash, fixes one bug in #254
2017-01-15 17:26:20 +00:00
Dylan K. Taylor
8ba0b49022
Initial working R/W of 0.16 + 1.0 worlds, highly unstable
2017-01-15 17:26:20 +00:00
Dylan K. Taylor
b28e38ab26
Move some exceptions out of utils into their relevant namespaces, move some Chunk methods to ChunkUtils for I/O, refactor "colour" -> "color"
2017-01-15 11:31:12 +00:00
Dylan K. Taylor
946d301bc7
Fix lighting population, fix lighting issues when read by vanilla Minecraft
2017-01-13 11:33:55 +00:00
Dylan K. Taylor
3bbf2c245a
Shut PhpStorm up
2017-01-11 10:11:13 +00:00
Dylan K. Taylor
8902992473
Fix McRegion read corruption errors, close #232
...
According to the wiki, McRegion heightmap should be ByteArray, not
IntArray. This caused issues with converted worlds with pretty much
every conversion tool. Blame @shoghicp.
IntArray McRegion heightmaps will now be converted to
ByteArray on save.
2017-01-08 21:16:57 +00:00
Dylan K. Taylor
3c9db45cf8
Fix tiles with async chunk sending, TODO: remove this
2017-01-07 10:52:39 +00:00
Dylan K. Taylor
aaf549a469
Docs for Chunk
2017-01-06 17:57:00 +00:00
Dylan K. Taylor
ad0553fbf8
Bump to API 3.0.0-ALPHA2 - READ DESCRIPTION!
...
Refactored level\format\generic\GenericChunk -> level\format\Chunk.
Re-added support for async chunk sending
Refactored most Level IO into new namespaces for more organisation
Removed LevelDB loader completely (will be re-added at a later date)
2017-01-06 17:13:45 +00:00
Dylan K. Taylor
d8908676ac
Refactor GenericChunk::fastSerialize() to be non-static, fix some unbelievable bugs, clean up some leftovers
2017-01-05 17:04:02 +00:00
Dylan K. Taylor
598e7aac8f
More PhpStorm inspections, import cleanup
2017-01-04 14:55:11 +00:00
Dylan K. Taylor
1cb96d24ce
Some fixes, thanks PhpStorm
2017-01-04 11:29:24 +00:00
Dylan K. Taylor
e2dc1a3bc6
Some consistency would be nice... fixed inconsistency between block light and sky light, always use Mojang order
2017-01-03 22:24:40 +00:00