5258 Commits

Author SHA1 Message Date
Dylan K. Taylor
0cd1e82c52 Fixed encode/decode of ResourcePacksInfoPacket and ResourcePackClientResponsePacket 2017-03-02 11:04:50 +00:00
Dylan K. Taylor
1ee689e759 Fixed mess of entity ID 0 for players, fixed emeralds 2017-03-02 11:04:00 +00:00
Dylan K. Taylor
d25c8d93ca Revert "Better time ticking and sync (#2)"
didn't consider modded clients, how naive 🤦

This reverts commit e9f2bf0085e89955ec6eb7ff9b07b004e8153e2c.
2017-03-02 10:53:40 +00:00
Dylan K. Taylor
4fbc5738e3 Re-implemented chunk sending (#304)
Re-implement chunk sending, send chunks inside a radius instead of below a count

This sends chunks in concentric squares around players. When the radius is hit, it will pad out the radius until a full circle of chunks is loaded around the player.
TODO: implement radius-per-tick, send chunks in concentric circles, use radius for player spawning.

To set your server chunk radius, change `view-distance` in server.properties. Values are intended to be the same as MCPE render distance values. With matching client and server render distances the chunks should reach the horizon.

NOTE: You may notice significantly increased memory usage per player when increasing these values to something respectable. This is normal and expected.
A player with render distance 14 for example will cause loading of 600+ chunks. A player cannot however exceed the render distance limit set in server.properties - the server will simply not send any more chunks.

Render distance of 8 chunks is approximately 200 chunks. This is roughly equivalent to the original default max-chunks of 192 in pocketmine.yml, but sent in a circle instead of a square.

Wait for client to request a chunk radius before ordering chunks

Use 8 for default maximum radius (roughly matches old setting of 192)

Calculate spawn chunk count from chunk-sending.spawn-radius
2017-03-02 10:30:30 +00:00
Dylan K. Taylor
d588222e84 Added an exception throw for accessing permissions of closed players 2017-02-28 10:49:09 +00:00
Dylan K. Taylor
c3fb2e9f23 Fixed broadcasting quit messages to quitting player, fixed accessing permission of closed players on quit 2017-02-28 10:43:11 +00:00
Dylan K. Taylor
cfb6856634 Fixed Player object memory leak when players with admin channel permissions are closed 2017-02-25 15:39:36 +00:00
Dylan K. Taylor
11e0387e19 Show an error if no language files found during setup, mitigates #380 2017-02-25 11:21:32 +00:00
Dylan K. Taylor
dc7b5b14d5 Fixed wrong encoding of ResourcePacksInfoPacket 2017-02-24 12:38:02 +00:00
Dylan K. Taylor
5eab956da6 Add block-break check for spectator mode, fixes players in spectator able to break blocks when adventure settings are not set correctly 2017-02-23 19:39:08 +00:00
Dylan K. Taylor
ad88ca09bd Fixed cannot remove block metadata 2017-02-23 15:18:42 +00:00
Dylan K. Taylor
f98a964cdc Fixed and silenced some inspections 2017-02-23 15:17:28 +00:00
Dylan K. Taylor
99995579d7 Added WorldBuilder flag to AdventureSettingsPacket 2017-02-23 12:20:36 +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
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
api/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
Dylan K. Taylor
dac6c49bce More php7 mess (EndTag Stone, EndTag Portal Frame) 2017-02-21 12:32:50 +00:00
Dylan K. Taylor
9f7dc32650 Fix some php7 update DoubleTag leftovers 2017-02-21 12:27:27 +00:00
Dylan K. Taylor
9195375af4 Don't allow these blocks to be washed out, we're only inheriting properties 2017-02-21 11:51:36 +00:00
Dylan K. Taylor
c6cf3458de Added UnknownBlock class, fixed not-yet-added blocks in imported worlds killing people, close #181 2017-02-21 11:46:44 +00:00
Dylan K. Taylor
e2cdd9eddc Fixed missing hardness on unimplemented blocks causing gameplay issues 2017-02-21 11:33:06 +00:00
Dylan K. Taylor
f933107af0 Fix some non-properly-implemented blocks killing people and bad inheritances 2017-02-21 11:17:33 +00:00
Dylan K. Taylor
408f63f8fa Accuracy again -_- 2017-02-20 19:46:10 +00:00
Dylan K. Taylor
68998bac48 Update README.md 2017-02-20 16:21:29 +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
20c7e51077 Allow 0.01 of a block diff
Fixes loss of precision when handling player movements causing some position issues.
2017-02-19 17:35:23 +00:00
Dylan K. Taylor
89216c3bd4 Use parse_ini_file instead of home-grown solution (#366)
* Use parse_ini_file instead of home-grown solution

* Updated PocketMine-Language submodule
2017-02-19 15:53:22 +00:00
Dylan K. Taylor
834dc343b0 Updated ItemFrameDropItemPacket for >=1.0.3, fix decode errors
Sorry, this DOES NOT FIX creative, blame Mojang. https://bugs.mojang.com/browse/MCPE-20070
2017-02-18 15:09:44 +00:00
Dylan K. Taylor
91907485b4 Fixed prismarine bad meta crashes 2017-02-18 10:42:25 +00:00
Dylan K. Taylor
ee523eb5cc Reverted botched fix for #284, close #362
Revert "fixed player data not saving"

This reverts commit b3beb9f71dacbc722e743e45b340056c947d607a.

Revert "Call PlayerQuitEvent after unloading chunks, removed some weird code, fixed crash when unloading player level on quit, close #284"

This reverts commit 14a0ff5caa5bcbb6d54ae8a908513ce5e6d4afaa.
2017-02-16 21:04:39 +00:00
Dylan K. Taylor
f2f51a88e5 Updated PocketMine-Language submodule (again) 2017-02-15 17:55:55 +00:00
Dylan K. Taylor
abffe1297d Fixed crashes closing entities with unloaded levels 2017-02-15 17:51:41 +00:00
Dylan K. Taylor
f8b9a13440 Updated PocketMine-Language submodule 2017-02-15 16:06:02 +00:00
Dylan K. Taylor
5c281c6435 Merged #103 2017-02-15 14:58:41 +00:00
Intyre
1908ed5812 Fix for incorrect gamemode messages, close #83 (#86)
Shows the correct message ingame but not in the console.
PocketMine doesn't handle the translation for gamemode changes, MCPE
does. No idea why but it requires the second and third parameter....

commands.gamemode.success.other=Set %2$s's game mode to %3$s
commands.gamemode.success.self=Set own game mode to %3$s

To solve the problem we have to change the language files and let
PocketMine-MP translate it.
2017-02-15 14:48:11 +00:00
Dylan K. Taylor
2d5567d9dd Removed InstallerLang mess, language improvements, updated PocketMine-Language submodule 2017-02-15 14:44:12 +00:00
Dylan K. Taylor
b3beb9f71d fixed player data not saving 2017-02-14 13:40:58 +00:00
Dylan K. Taylor
14a0ff5caa Call PlayerQuitEvent after unloading chunks, removed some weird code, fixed crash when unloading player level on quit, close #284 2017-02-14 12:44:31 +00:00
Dylan K. Taylor
119e458ac8 Removed SQLite3 dependency (no longer used by PocketMine-MP core)
BEFORE anyone yells at me about plugins, having the core demand every extension that a plugin could possibly need is very much sub-optimal. An API for plugin-required extensions will be added in the future.
2017-02-14 11:04:20 +00:00
Dylan K. Taylor
01a07a0b09 Removed years-old leftovers from old PocketMine 2017-02-13 14:41:30 +00:00
Dylan K. Taylor
903534572d Shut some inspections up 2017-02-13 14:27:17 +00:00
Dylan K. Taylor
8a3c30ee7e Moved entity metadata methods out of Binary 2017-02-13 14:05:16 +00:00
Dylan K. Taylor
91fd99d76a Fixed DestroyBlockParticle 2017-02-12 16:01:23 +00:00
Dylan K. Taylor
27f2aec160 Fixed wrong docs for Plugin->getPluginFilters() 2017-02-12 12:52:02 +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
b89a17ffe2 Added missing attributes encoding to AddEntityPacket 2017-02-12 10:35:35 +00:00
Sandertv
6dc6e32656 Added some very useless functions for easier size changing of entities. (#348) 2017-02-11 21:24:38 +00:00
Sandertv
d430ad50be Fixed wrong temperature and temperature -> rainfall (#347) 2017-02-11 20:15:22 +00:00