6763 Commits

Author SHA1 Message Date
Dylan K. Taylor
523a7f0999 Fix a very rare light propagation bug
This could occur when light sources were placed near each other and one of them is removed, the other's light would not be propagated far enough because the node wasn't queued for updating although it was marked as if it was.
2017-11-27 19:43:56 +00:00
Dylan K. Taylor
256527c953 Chunk: Fixed possible bug with Chunk->setBlockData()
to be honest this would probably never affect anything, but let's be consistent.
2017-11-27 19:26:20 +00:00
Dylan K. Taylor
b93691a177 Chunk: Remove redundant assignment 2017-11-27 18:58:08 +00:00
Dylan K. Taylor
48c5db4296 Chunk: Add some PhpDoc 2017-11-27 17:51:42 +00:00
Dylan K. Taylor
c564655f9b Chunk: Remove unnecessary default values
these are assigned in the constructor anyway.
2017-11-27 17:49:08 +00:00
Dylan K. Taylor
49301b0d74 Chunk: Use an SplFixedArray for subchunks 2017-11-27 17:46:48 +00:00
Dylan K. Taylor
8bc733514b LevelDB: Fixed nonsensical array access in iterator loop 2017-11-27 17:21:26 +00:00
Dylan K. Taylor
c1a6711514 Fix for explosions modifying the wrong subchunks under some circumstances 2017-11-27 17:11:52 +00:00
Dylan K. Taylor
f477cfa1bf Fixed a mistake in AvailableCommandsPacket 2017-11-25 11:15:20 +00:00
Dylan K. Taylor
1f5f67e087 Liquid: Removed a bad hack-fix, fixed mobs not moving when water flows around them
this breaks more than it appears to fix, and I can't reproduce any CPU
leaks when block updates are enabled, so I'm going to assume this is OK.
2017-11-24 17:23:12 +00:00
Dylan K. Taylor
74967eed87 Liquid: Stop abusing getLevel() in performance-sensitive situations
Most of these methods are called from onUpdate(). It's unreasonable to
assume that the level might be null during a tick (unless a plugin
messes with a block update event or something, but that's undefined
behaviour anyway). Using getLevel() simply wastes processing time by
constantly checking if the level is closed.
2017-11-24 16:58:03 +00:00
Dylan K. Taylor
b88ffa3bdf Fixed a mistake in Block->getSide() documentation
side() -> getSide()
2017-11-24 15:09:55 +00:00
Dylan K. Taylor
79fd9b1c96 added RottenFlesh item 2017-11-24 10:46:55 +00:00
Dylan K. Taylor
ed195e1167 phpdoc 2017-11-23 17:27:41 +00:00
Dylan K. Taylor
667a54fd00 Store world height in the Level for faster access
this might look like a micro optimization, but it shows up big-time on profiler snapshots.
2017-11-23 17:24:37 +00:00
Dylan K. Taylor
b22b493abb Fixed Player->onDeathUpdate() not being called
I did not realize this was going to be a problem... argh! stupid messy player impl D:
2017-11-23 14:23:57 +00:00
Dylan K. Taylor
0badaeb8f4 bump max dead ticks to 25 so death smoke cloud works properly
I wish this wasn't client sided... it's a pain to get it synced properly.
2017-11-22 19:55:25 +00:00
Dylan K. Taylor
c5ac6a7606 Remove redundant count() for effects ticking 2017-11-22 19:44:22 +00:00
Dylan K. Taylor
e9951b1b1f Remove redundant condition for setBreathing() 2017-11-22 19:43:09 +00:00
Dylan K. Taylor
47f94eebd1 Use maxDeadTicks instead of hardcoded 20 2017-11-22 18:58:58 +00:00
Dylan K. Taylor
e9e22db1e7 Cleaned up death animation handling, removed dead ticking from non-Living entities 2017-11-22 17:17:47 +00:00
Dylan K. Taylor
75e469c380 Fixed bad parameter names due to old code additions in Block->place() 2017-11-22 14:26:55 +00:00
JackNoordhuis
686e1c4470 Implement ender chest (#1462) 2017-11-22 14:25:21 +00:00
Dylan K. Taylor
8d59843020 Order tile constants alphabetically 2017-11-22 14:00:41 +00:00
Dylan K. Taylor
580b30b768 update versions 2017-11-22 13:51:40 +00:00
Dylan K. Taylor
589ca45825 Updated RakLib dependency (again) 2017-11-22 09:43:33 +00:00
Dylan K. Taylor
88ad43971a constant visibility 2017-11-21 16:50:27 +00:00
Dylan K. Taylor
1fd9994056 Merge branch 'master' into mcpe-1.2.5 2017-11-21 16:48:18 +00:00
Dylan K. Taylor
808227d9a9 Hack for player spawning issue (ref. #1539) 2017-11-21 15:20:56 +00:00
Dylan K. Taylor
74b074753f Bulk addition of constant visibilities
thanks PhpStorm inspections plugin for annoying the shit out of me until
I did this.
2017-11-21 14:44:10 +00:00
Dylan K. Taylor
3f854127ca Updated RakLib depdendency 2017-11-21 14:36:23 +00:00
Dylan K. Taylor
9da19b5f15 Added API methods for getting & setting armour dye colours 2017-11-21 14:10:33 +00:00
Dylan K. Taylor
78d24b9183 Take 2: Fixed resource pack matching for uppercased UUIDs
fixed the wrong damned bug...
2017-11-21 11:29:12 +00:00
Dylan K. Taylor
46afb7caf1 Fixed resource pack matching for uppercased UUIDs 2017-11-21 11:25:21 +00:00
Dylan K. Taylor
0ee452773d Fixed missing getValue() implementation on CompoundTag 2017-11-21 10:52:00 +00:00
Dylan K. Taylor
a39c9e8c8e add ResourcePack->getPath(), close #1559 2017-11-20 13:24:30 +00:00
Dylan K. Taylor
32714d4564 Don't write server.properties to disk unless it's been modified at runtime 2017-11-20 10:04:39 +00:00
Dylan K. Taylor
feade9d982 Added a flag to Config to allow detecting if it has been modified since it was last saved 2017-11-20 10:04:11 +00:00
Dylan K. Taylor
373f085436 Fixed a usage of get(true) 2017-11-20 09:50:52 +00:00
Dylan K. Taylor
d2416d335e Use keepMovement in spectator and when movement anti-cheat is disabled
this makes it much less expensive for players to move around when anti-cheat is disabled. And let's be honest... who uses this shit anyway
2017-11-19 19:31:03 +00:00
Dylan K. Taylor
a8ad956b29 Fixed keepMovement logic 2017-11-19 19:28:04 +00:00
Dylan K. Taylor
00a9ae6c95 make use of getSavableEntities() in Level->unloadChunk()
why couldn't I have thought of this before I changed this the first time >.>
2017-11-19 18:08:42 +00:00
Dylan K. Taylor
a9df383346 generalized conditions for saving entities with chunks 2017-11-19 18:06:38 +00:00
Dylan K. Taylor
19dc22d6b3 Chunk save: skip entities which won't be saved anyway
don't just hardcode this to players
2017-11-19 17:57:54 +00:00
Dylan K. Taylor
2fd61163bf cleanup some chunks leftovers from 1.0 2017-11-19 17:52:36 +00:00
Dylan K. Taylor
5640bcb0b8 add some new leveldb keys 2017-11-19 17:43:54 +00:00
Dylan K. Taylor
ea3c7383fb Added support for handling MCPE 1.2 leveldb worlds
requires php-leveldb version >=0.2.1 and the latest version of
pmmp/leveldb-mcpe
2017-11-19 17:31:09 +00:00
Dylan K. Taylor
7e496afdd1 Fixed issues with LevelDB worlds silently getting overwritten with the default format when LevelDB extension is not loaded
Always register the level provider (to allow detecting the world format) but throw exceptions if anything tries to use it without the extension being loaded.
2017-11-19 17:28:16 +00:00
Dylan K. Taylor
3bc3a0bb49 Remove redundant inventory resend on gamemode change
inventory isn't modified, so there is no need to resend it
2017-11-19 15:34:29 +00:00
Dylan K. Taylor
c75e62b38c Fix /gamemode output again 2017-11-19 15:28:34 +00:00