summaryrefslogtreecommitdiffstats
path: root/src/Blocks/BlockPlant.h (unfollow)
Commit message (Collapse)AuthorFilesLines
2020-11-06Add correct implementation of crops (#4802)0ddlyoko1-1/+10
* [FIX] Add correct implementation of seed drops. > Official percentage of drops has been implemented * Fix C++ conventions * Change "Vals" variable to "m_Vals" * [FIX] Add correct implementation of Carrots, Potatoes, Wheat & Beetroots seed * Add Fortune support with crops Add fortune support with Wheat, Carrots, Potatoes & Beetroots seeds * [FIX] Right-clicking on a grown Beetroot in survival consume 2 bone meals Fix #4805 * Add documentation for "cWorld::IsFullGrownPlantAt" method * Fix dispenser that full grown a plant > Change methods cItemDyeHandler::FertilizePlant & cItemDyeHandler::growPlantsAround to static * Display particle even if tree doesn't grow * When right-clicking on a full grown melon / pumpkin seed, no longer produce a melon / pumpkin Before this commit, when you right-click on a melon or a pumpkin seed, a melon / pumpkin block spawned. With this commit, it no longer spawns * [FIX] Do not create melon / pumpkin block when right-clicking with a bone meal This fix will prevent the creation of a melon / pumpkin block when you right-click with a bone meal on a melon / pumpkin plant - It just detect if the plant is full grown. if yes, the method "Grow" is not called - Remove IsFullGrownPlant Co-authored-by: 12xx12 <12xx12100@gmail.com> Co-authored-by: Tiger Wang <ziwei.tiger@outlook.com>
2020-10-05Fix cmake not adding Werror on clang, and _lots_ of warnings (#4963)peterbell101-36/+30
* 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>
2020-09-20BlockHandler initialisation is a constant expression (#4891)Tiger Wang1-15/+7
* 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>
2020-08-04OnBroken/OnPlaced are for entity actionsTiger Wang1-1/+1
* Call OnPlaced/OnBroken in PlaceBlock/DigBlock - Remove unused Placing/Breaking handlers * Have the blockhandler's Check handle neighbour updating, instead of QueueTickBlockNeighbors
2020-04-17More Vector3 in cBlockHandler (#4644)Mattes D1-6/+11
* cBlockHandler.OnUpdate uses Vector3 params. Also slightly changed how block ticking works.
2020-04-16Using Super.Mattes D1-2/+2
2019-10-28Moved growing from cWorld / cChunk to cBlockHandler descendants.Mattes D1-17/+44
2019-10-16Refactored block-to-pickup conversion. (#4417)Mattes D1-32/+48
2017-07-03cBlockInfo static initialisation (#3832)peterbell101-1/+1
2017-06-13FastRandom rewrite (#3754)peterbell101-2/+1
2015-09-17Added CircleCI for stylechecking.Mattes D1-3/+2
This will allow us to remove the stylecheck from Travis builds, making them a bit faster, and having fast style checks
2015-08-19* Logic for handling plant growth has been centralized into cBlockPlant, and all growable plants now inherit from it.Samuel Barney1-0/+132
* Blocks now have an effect upon plant growth, just like in vanilla.