| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Co-authored-by: 12xx12 <12xx12100@gmail.com>
Co-authored-by: Tiger Wang <ziwei.tiger@outlook.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Fix cmake not adding Werror on clang, and _lots_ of warnings
* WIP: Build fixes
* Cannot make intermediate blockhandler instance
* Tiger's changes
* Fix BitIndex check
* Handle invalid NextState values in cMultiVersionProtocol
Co-authored-by: Tiger Wang <ziwei.tiger@outlook.com>
|
|
|
|
|
|
|
| |
+ Implemented and standardized all clamped discrete random drops.
+ Changed cItems Add from push_back to emplace_back. Implement fortune for crops.
+ Enabled hoes to be enchanted with efficiency, silk touch and fortune. Made leaves, gravel and crops affected by fortune.
Co-authored-by: Tiger Wang <ziwei.tiger@outlook.com>
|
| |
|
|
|
|
|
| |
- Removed normal BlockHandler knowledge of block entities during conversion
+ Added cBlockEntity::ConvertToPickups that handles it
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Implemented fortune for ores, glowstone and sea lanterns (but nothing organic or flint).
* Cleanup printf
* Stopped playing golf, gave the Camels a FirstHump and moved the FortuneDropMult comment. Thanks for the review :).
* Got rid of FortuneDropMult and replaced with Peter's massive optimization/simplification.
* Fixed default lapis max droprate (8 -> 9).
* Clamp max drops for non-redstone ores to 10.
* Comment justifying the clamp.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* BlockHandler initialisation is a constant expression
If we can't make it all namespaces, this is the next best I guess.
+ Tag handlers constexpr, const as needed
+ Inherit constructors
* Privatise handler functions
* More constexpr
Co-authored-by: Alexander Harkness <me@bearbin.net>
|
|
|
| |
* BlockHandler: no dynamic allocation
|
|
|
|
|
|
| |
* Call OnPlaced/OnBroken in PlaceBlock/DigBlock
- Remove unused Placing/Breaking handlers
* Have the blockhandler's Check handle neighbour updating, instead of QueueTickBlockNeighbors
|
|
|
| |
Refactored all cBlockHandler and cItemHandler descendants to use Vector3.
|
|
|
|
|
| |
* cBlockHandler.OnUpdate uses Vector3 params.
Also slightly changed how block ticking works.
|
|
|
|
|
|
|
|
|
| |
The BlockID.h file was removed from Globals.h and renamed to BlockType.h (main change)
The BlockInfo.h file was removed from Globals.h (main change)
The ENUM_BLOCK_ID and ENUM_ITEM_ID enum names were replaced with ENUM_BLOCK_TYPE and ENUM_ITEM_TYPE (cosmetics)
The various enums, such as eDimension, eDamageType and eExplosionSource were moved from BlockType.h to Defines.h, together with the helper functions for converting between them and strings (StringToDimension et al.) (minor)
Many inline functions were moved from headers to their respective cpp files, so that BlockType.h could be included only into the cpp file, rather than the header.
That broke our tests a bit, since they pick bits and pieces out of the main code and provide stubs for the rest; they had to be re-stubbed and re-verified.
eMonsterType values are no longer tied to E_ITEM_SPAWN_EGG_META_* values
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Add hand parameter to distinguish main hand/off hand.
* Add a new function cClientHandle::HandleUseItem to separate the functionality of using an item without a target block. This matches the protocol with client version >= 1.9
* Always actively update the status of a block if the placement fails (by out of reach or rejected by plugin).
* Do not call plugin callback CallHookPlayerRightClick(-1, 255, -1, -1, 0, 0, 0) when using item.
The CallHookPlayerUsingItem will still be called.
Now at most one of CallHookPlayerRightClick, CallHookPlayerUsingBlock,
CallHookPlayerUsingItem and CallHookPlayerEating will be called based on
the type of action (not including the used version of callbacks).
* Do not count using item as BlockInteractionsRate check (Using item takes time).
* Now we can open chests(etc.) when sneaking as long as the player's hand is empty.
This is what vanilla server does.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Threaded world interface into ConvertBlockToPickups
* Changed how cBlockPiston::PushBlocks sets the old block to air, so that the block exists for the DropBlock call.
* Removed unused a_Digger argument.
* Removed incorrect comment
* This time actually removed a_Digger references.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Check for intersection between placed blocks and entities.
+ Implemented GetPlacementCollisionBox, to permit custom placement collision boxes for blocks.
* Factored block-entity placement checking into another function in cPlayer.
- Removed vector min/max functions
* Use GetWorld to get the world in DoesPlacingBlocksIntersectEntity.
+ Added block height checks, allow different cEntity subclasses to decide whether they will prevent block placement.
|
|
|
|
|
|
|
| |
* BigFlowers fixes
* Correct upper part meta
* Documented parameters to DoesIgnoreBuildCollision
|
|
|
|
|
|
|
|
|
|
| |
* Added bed entity
* Export cBedEntity to lua
* Set color of bed through item damage value
* Added bed entity to APIDoc
* NBT: Added loading and saving
* Crafting recipes for the colored beds
|
| |
|
| |
|
| |
|
|
|
|
| |
* Blocks now have an effect upon plant growth, just like in vanilla.
|
| |
|
| |
|
|
|
|
|
| |
Fixes the OnNeighborChanged endless recursion with large melon / pumpkin fields.
Fixes #2213.
|
| |
|
|
|
|
| |
Fixes #1618.
|
| |
|
| |
|
| |
|
| |
|
|\ |
|
| | |
|
|/
|
|
| |
* Fixes #1242 (the issue addressed within)
|
|\
| |
| |
| |
| |
| | |
Conflicts:
src/Bindings/DeprecatedBindings.cpp
src/Blocks/BlockSapling.h
|
| | |
|
| | |
|
|/
|
|
|
|
| |
- Removed cBlockInfo::RequiresSpecialTool
* Fixes #1195
* Fixes #1201
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
May Fix #640
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Changed the signitures of the following to use interfaces:
GetPlacementBlockTypeMeta
OnPlaced
OnPlacedByPlayer
OnDestroyed
OnNeighbourChanged
NeighbourChanged
OnUse
CanBeAt
Check
|
| |
|
| |
|
| |
|
| |
|
| |
|
|\
| |
| | |
Trapdoors, redstone fixes, and snow
|
| | |
|
|/ |
|
|
|